Shared Context between Tests
It is common for unit test classes to share setup and cleanup code (often called "test context"). xUnit.net offers several methods for sharing this setup and cleanup code, depending on the scope of things to be shared, as well as the expense associated with the setup and cleanup code.
- (shared setup/cleanup code without sharing object instances)
- (shared object instance across tests in a single class)
- (shared object instances across multiple test classes)