如何以编程方式决定在 NUnit 中运行哪些测试?IE
CoreExtensions.Host.InitializeService();
TestPackage testPackage = new TestPackage(pathToSomeDLL);
// filter by category here??
SimpleTestRunner simpleTestRunner = new SimpleTestRunner();
// or here?
simpleTestRunner.Load(testPackage);
//... maybe here?
testResult = simpleTestRunner.Run(NullListener.NULL);