/// <inheritdoc /> protected override TestResult RunImpl(ITestCommand rootTestCommand, TestStep parentTestStep, TestExecutionOptions options, IProgressMonitor progressMonitor) { ThrowIfDisposed(); IList <ITestCommand> testCommands = rootTestCommand.GetAllCommands(); using (progressMonitor.BeginTask(Resources.NUnitTestController_RunningNUnitTests, testCommands.Count)) { if (progressMonitor.IsCanceled) { return(new TestResult(TestOutcome.Canceled)); } if (options.SkipTestExecution) { return(SkipAll(rootTestCommand, parentTestStep)); } else { using (RunMonitor monitor = new RunMonitor(runner, testCommands, parentTestStep, progressMonitor)) { return(monitor.Run()); } } } }
/// <inheritdoc /> protected override TestResult RunImpl(ITestCommand rootTestCommand, TestStep parentTestStep, TestExecutionOptions options, IProgressMonitor progressMonitor) { ThrowIfDisposed(); using (progressMonitor.BeginTask(Resources.MbUnit2TestController_RunningMbUnitTests, 1)) { if (progressMonitor.IsCanceled) { return(new TestResult(TestOutcome.Canceled)); } if (options.SkipTestExecution) { return(SkipAll(rootTestCommand, parentTestStep)); } else { IList <ITestCommand> testCommands = rootTestCommand.GetAllCommands(); using (InstrumentedFixtureRunner fixtureRunner = new InstrumentedFixtureRunner(fixtureExplorer, testCommands, progressMonitor, parentTestStep)) { return(fixtureRunner.Run()); } } } }
/// <inheritdoc /> protected override TestResult RunImpl(ITestCommand rootTestCommand, TestStep parentTestStep, TestExecutionOptions options, IProgressMonitor progressMonitor) { ThrowIfDisposed(); using (progressMonitor.BeginTask(Resources.MbUnit2TestController_RunningMbUnitTests, 1)) { if (progressMonitor.IsCanceled) return new TestResult(TestOutcome.Canceled); if (options.SkipTestExecution) { return SkipAll(rootTestCommand, parentTestStep); } else { IList<ITestCommand> testCommands = rootTestCommand.GetAllCommands(); using (InstrumentedFixtureRunner fixtureRunner = new InstrumentedFixtureRunner(fixtureExplorer, testCommands, progressMonitor, parentTestStep)) { return fixtureRunner.Run(); } } } }
/// <inheritdoc /> protected override TestResult RunImpl(ITestCommand rootTestCommand, TestStep parentTestStep, TestExecutionOptions options, IProgressMonitor progressMonitor) { IList<ITestCommand> testCommands = rootTestCommand.GetAllCommands(); using (progressMonitor.BeginTask(Resources.CSUnitTestController_RunningCSUnitTests, testCommands.Count)) { if (progressMonitor.IsCanceled) { return new TestResult(TestOutcome.Canceled); } if (options.SkipTestExecution) { return SkipAll(rootTestCommand, parentTestStep); } using (RunnerMonitor monitor = new RunnerMonitor(testCommands, parentTestStep, progressMonitor)) { return monitor.Run(assemblyLocation); } } }
/// <inheritdoc /> protected override TestResult RunImpl(ITestCommand rootTestCommand, TestStep parentTestStep, TestExecutionOptions options, IProgressMonitor progressMonitor) { ThrowIfDisposed(); IList<ITestCommand> testCommands = rootTestCommand.GetAllCommands(); using (progressMonitor.BeginTask(Resources.NUnitTestController_RunningNUnitTests, testCommands.Count)) { if (progressMonitor.IsCanceled) return new TestResult(TestOutcome.Canceled); if (options.SkipTestExecution) { return SkipAll(rootTestCommand, parentTestStep); } else { using (RunMonitor monitor = new RunMonitor(runner, testCommands, parentTestStep, progressMonitor)) { return monitor.Run(); } } } }
private void AssertCommandStructure(params string[] names) { IList <ITestCommand> all = rootCommand.GetAllCommands(); Assert.Over.Pairs(all, names, (node, name) => Assert.AreEqual(name, node.Test.Name)); }