[Home]  [Edit this page]  [Recent Changes]  [Special Pages]  [Help
UnitTesting
Unit testing is a method of testing software (most often, it's object-oriented) on a strict unit-by-unit basis. Unit testing is, or more realisticaly, should be a key component of software development.

It is also closely related to Extreme Programming, although it's also seen in other programming methods.

When doing unit testing we would idealy be able to say that every result tested is a result of '''one single unit and that unit alone'''. If we introduce other units to this testing, it can change the results.

Since we live in an imperfect world, this will rarely be possible. Hence, unit testing usually involves writing highly modular code, and using stub code to replace potentialy incorrect sub-units (until we can unit test those sub-units).

Also very important: by saying ''unit testing'' we usually think about tests that are designed to be run automatically and without user interaction.

Unit tests should be refactored along with the unit it tests, so that no disparity ensues.

The final piece of this puzzle is simple, though many forget it:

'''No release should happen until all unit tests run 100% successfully'''

last edited (December 21, 2002) by IvanStojic, Number of views: 1566, Current Rev: 1

[Edit this page]  [Page history]  [What links here]  [Discuss this topic]  [Printer Friendly]  

Members

Username:

Password:


Register
Forgot Password?




Programmers Heaven - for .NET, Java, C/C++ and WEB Developers!
© 1996-2008 Community Networks Ltd. All rights reserved. Reproduction in whole or in part, in any form or medium without express written permission is prohibited. Violators of this policy may be subject to legal action. Please read Terms Of Use and Privacy Statement for more information. Development by Tore Nestenius at .NET Consultant - Synchron Data.