View Full Version : XCode 3.1 & unittests
robsonj
Jul 26, 2008, 09:17 PM
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
bilboa
Jul 27, 2008, 01:12 AM
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
vBulletin® v3.8.6, Copyright ©2000-2012, Jelsoft Enterprises Ltd.