- Implementing a Test
- Running Tests
- Implementing a Test Suite
- Trick: Incorporating Configuration Files into NUnit
Implementing a Test Suite
NUnit contains several tools: A good one is the SuiteAttribute. Using the SuiteAttribute, you can indicate several test fixtures to be run as part of a test suite. To create a TestSuite, follow these steps (code is left as an exercise):
Adorn a read-only, static property that returns an instance of NUnit.Core.TestSuite with the SuiteAttribute.
Create an instance of the NUnit.Core.TestSuite.
Add instances of each TestFixtureAttribute-adorned class to the TestSuite instance with TestSuite.Add.
Return the instance of the TestSuite object.
For a hint, check out the NUnit documentation online.