Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

robsonj

macrumors newbie
Original poster
Has anyone had issue getting unittests to run in xcode 3.1? I have tried writing unit test bundles and set my application up as a dependency of the unittest target, but when I execute the unittest target, my app just runs without any breakpoints being hit on my simple unittest.

Any help is appreciated.

Cheers
Jonathan
 
This isn't a new problem, it's just that XCode's support for unit testing is kind of lame. For one thing, it runs the unit tests as part of the build process, not as an executable. Since build steps aren't run under the debugger, your breakpoints will never be hit while running unit tests using the builtin mechanism.

I found this helpful page which describes how to setup an executable target to run your unit tests, which allows running them under the debugger:

http://chanson.livejournal.com/119578.html
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.