Ejemplo n.º 1
0
        public IEnumerable <TestCaseResult> RunTests(IEnumerable <ITestSession> customSessions, IDictionary <string, string> options)
        {
            var testCases = _testStorage.GetTestCaseIds().Select(_ => _testStorage.GetTestCase(_));

            testCases = _testCasesPreProcessors.Aggregate(testCases, (acc, p) => p.Execute(acc, options));
            using (var testSession = new TestSession(customSessions, _testCaseProcessorFactory, _testCaseLoggerFactory, _loggerFactory, options, _schedule, _testCaseContextFactory))
            {
                testSession.Schedule(testCases, options.GetWorkersCount());
                return(testSession.Results);
            }
        }