Re: Unit testing framework suggestions?
Re: Unit testing framework suggestions?
- Subject: Re: Unit testing framework suggestions?
- From: James Bucanek <email@hidden>
- Date: Fri, 24 Sep 2004 08:27:08 -0700
M. Uli Kusterer wrote on Friday, September 24, 2004:
>At 4:56 Uhr +0200 24.09.2004, Marco Scheurer wrote:
>>One reason is that tests can have their own state and ivars, and it
>>wouldn't be a good idea to mix this with the class you want to test.
>
> A-ha! Thanks, that makes a lot of sense. I knew there had to be some
>obvious reason.
The documentation for UnitKit points out another reason why test classes are kept separate. Namely, the performance of an application directly impacted by the size of the code and data structures. Leaving your test code in your production code just makes for a bloated app.
And if you're thinking that you'll remove all of the test code via the pre-processor, that's a hazardous road to go down. You want to test the code that you're going to ship, not the code that you *think* will still work after you flip some compiler switches. Been there, done that, got burned.
--
James Bucanek <mailto:email@hidden>
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden