In Pex, we added the possibility to specify the type under test of a given fixture:
public class Account {...} [TestFixture, PexClass(typeof(Account))]public class AccountTest {...}
That's nice but why would it be useful... Beyond the fact that it clearly expresses the 'target' of the fixture, this kind of information can be leverage by tools like Pex.
For example, since we know that Account is the type under test, we can tune Pex to prioritize the exploration of the Account type.
Another interesting side effect is the targeted code coverage data. Instead of getting coverage information over the entire assembly, we can directly provide coverage over the type under test: the AccountTest covered xx% of Account.
Still toying around the concept, one can add a special filtering mode to the command line to execute all tests that target 'Account':
pex.exe /type-under-test:Account Bank.Tests.dll
Page rendered at Monday, September 08, 2008 7:06:00 PM UTC
Disclaimer The opinions expressed herein are my own personal opinions and do not represent my employer's view in anyway.