public TestRunResults[] RunTests(TestRunInfo[] runInfos, Action <AutoTest.TestRunners.Shared.Targeting.Platform, Version, Action <ProcessStartInfo, bool> > processWrapper, Func <bool> abortWhen) { var options = generateOptions(runInfos); if (options == null) { return new TestRunResults[] { } } ; AutoTestRunnerFeedback feedback = null; if (_handleRunnerFeedback) { feedback = new AutoTestRunnerFeedback(_runCache, _bus, options); } var runner = new TestRunProcess(feedback) .WrapTestProcessWith(processWrapper) .AbortWhen(abortWhen); if (_configuration.RunAssembliesInParallel) { runner.RunParallel(); } if (_configuration.TestRunnerCompatibilityMode) { runner.RunInCompatibilityMode(); } var tests = runner.ProcessTestRuns(options); return(getResults(tests, runInfos).ToArray()); }
public TestRunResults[] RunTests(TestRunInfo[] runInfos, Action<AutoTest.TestRunners.Shared.Targeting.Platform,Version,Action<ProcessStartInfo, bool>> processWrapper, Func<bool> abortWhen) { var options = generateOptions(runInfos); if (options == null) return new TestRunResults[] { }; AutoTestRunnerFeedback feedback = null; if (_handleRunnerFeedback) feedback = new AutoTestRunnerFeedback(_runCache, _bus, options); var runner = new TestRunProcess(feedback) .WrapTestProcessWith(processWrapper) .AbortWhen(abortWhen); if (_configuration.RunAssembliesInParallel) runner.RunParallel(); if (_configuration.TestRunnerCompatibilityMode) runner.RunInCompatibilityMode(); var tests = runner.ProcessTestRuns(options); return getResults(tests, runInfos).ToArray(); }
public void Setup() { _cache = MockRepository.GenerateMock<IRunResultCache>(); _bus = MockRepository.GenerateMock<IMessageBus>(); _feedback = new AutoTestRunnerFeedback(_cache, _bus, new AutoTest.TestRunners.Shared.Options.RunOptions()); }