public void TestIndividualTestExecutionRuns() { this.RunContext.RegisterSettingProvider(BoostTestAdapterSettings.XmlRootName, new BoostTestAdapterSettingsProvider()); this.RunContext.LoadSettings("<RunSettings><BoostTest><BatchTestRuns>false</BatchTestRuns></BoostTest></RunSettings>"); VSTestCase[] testCases = new VSTestCase[] { CreateTestCase("A/1", DefaultSource), CreateTestCase("A/2", DefaultSource), CreateTestCase("B/1", DefaultSource) }; this.Executor.RunTests( testCases, this.RunContext, this.FrameworkHandle ); List <string> testIdentifiers = testCases.Select(test => test.FullyQualifiedName).ToList(); foreach (IBoostTestRunner runner in this.RunnerFactory.ProvisionedRunners) { Assert.That(runner, Is.TypeOf <MockBoostTestRunner>()); MockBoostTestRunner testRunner = (MockBoostTestRunner)runner; // TestRunners may be provisioned but left unused. We are only interested in the ones used to execute tests. if (testRunner.RunCount == 0) { continue; } Assert.That(runner.Source, Is.EqualTo(DefaultSource)); foreach (BoostTestRunnerCommandLineArgs args in testRunner.Args) { // One test at a time should be invoked Assert.That(args.Tests.Count, Is.EqualTo(1)); Assert.That(testIdentifiers.Remove(args.Tests[0]), Is.True); } } // All tests should be have been invoked Assert.That(testIdentifiers, Is.Empty); }