Michael
Michael

Reputation: 2288

Unit testing problems and crashing with XCode 5 and Kiwi/XCUnit

I'm having many issues with unit testing in XCode 5 and want to verify if anybody else if having the same problems (and any possible solutions...) I'm using the Kiwi framework developing for ios7 and its a new project therefore is using XCUnit underneath. I'm on a 2011 macbook air on OSX 10.8

  1. The first time I run a test on startup, it runs all tests, even if I only select one case/test class - it even runs all the disabled ones.
  2. Upon adding new unit tests, there is ~1/3 chance that XCode crashes on running all tests.
  3. Clicking on failed unit tests very rarely takes me to the failed unit tests. It acts as if the code has been deleted.
  4. When unit tests have been fixed, errors are often left over both in the issue navigator and in the editor however test is now reporting to succeed.
  5. Upon successful running of all unit tests Xcode often reports that Tests have failed however all show as successful in the navigator.
  6. Unit tests quite regularly get 'stuck' and execute forever. Its then impossible to run/build anything else until have restarted xcode.

Anybody with a similar setup having the same issues? Any solutions? What a bloody mess.

Upvotes: 1

Views: 1753

Answers (2)

andreschneider
andreschneider

Reputation: 6574

It seems that Xcode 5.1 (DP) will solve your issues.

Upvotes: 1

Dave Meehan
Dave Meehan

Reputation: 3201

Yes I get similar problems, also using Kiwi. No idea if its Kiwi related, but certainly I experience crashes when running unit tests, perhaps about 1 in 5 runs, and more often if the program hits a breakpoint and I run the tests again with Cmd-U.

I haven't been using the 'test single' option, so can't comment there.

The errors left over problem appears to be generic to unit tests, not just Kiwi. If you delete the block that contains the left over error, wait a few secs for Xcode to recompile in the background and paste it back it, you'll get rid of it. Or exit and restart Xcode if you have a bunch of them.

Upvotes: 0

Related Questions