4 Jul 2006 06:46
[TFUI] Unit testing Cocoa user interfaces
A long time ago I promised to several people on a couple of lists that I'd write up my approach to doing user interface unit testing with the Cocoa framework on Mac OS X. My initial write-up a year ago was a philosophical discussion of my approach, which I call "trust, but verify" and can be found here: http://chanson.livejournal.com/118380.html I've just written up an additional post that describes how to actually write OCUnit unit tests that verify the controls in a Cocoa window are set up correctly. http://chanson.livejournal.com/148204.html Note that I'm not trying to teach the Objective-C language, the Cocoa framework, the OCUnit unit testing framework, or the out-of-(Continue reading)the- box integration of OCUnit into Apple's Xcode IDE in this post. Info on all of those can be found at <http://developer.apple.com/>. (I also have a bunch of info available via the tags on the two posts.) I hope someone else finds this useful. I find that this approach makes it very straightforward to do test-driven development of user interfaces without having to change the either design patterns I'm using to build my software or the approach to tools like Interface Builder. -- Chris ------------------------ Yahoo! Groups Sponsor --------------------~--> Something is new at Yahoo! Groups. Check out the enhanced email design.
RSS Feed