Wednesday, January 20, 2010

NUnit

Unit testing is validation and verification methodology where the developers test the individual units of source code.

1. Add reference dll " C:\Program Files\NUnit 2.5.2\bin\net-2.0\framework\nunit.framework.dll ".
2. include namespace using NUnit.Framework;

TestFixture: This is an attribute used to define on test class.

Test: This is attribute for method, used to define in the test class, this method actually contains the test logic.


Assert: This is an command, used to check if the expected output and the results return match











No comments: