public MultiSourceTestExecutor(IEnumerable <string> sources,
                                       IBinaryTestExecutor binaryTestExecutor,
                                       IProgressRecorderFactory progressRecorderFactory,
                                       ISettingsRepository settingsRepository,
                                       ILoggerFactory loggerFactory)
            : this(binaryTestExecutor, progressRecorderFactory, settingsRepository, loggerFactory)
        {
            this.testableItems = sources.Select(source => new SourceTestableItem(source));

            this.sourceDescription = "source paths";
        }
 public MultiSourceTestExecutorFactory(
     IBinaryTestExecutor binaryTestExecutor,
     IProgressRecorderFactory progressRecorderFactory,
     ISettingsRepository settingsRepository,
     ILoggerFactory loggerFactory)
 {
     this.binaryTestExecutor      = binaryTestExecutor;
     this.progressRecorderFactory = progressRecorderFactory;
     this.settingsRepository      = settingsRepository;
     this.loggerFactory           = loggerFactory;
 }
        MultiSourceTestExecutor(
            IBinaryTestExecutor binaryTestExecutor,
            IProgressRecorderFactory progressRecorderFactory,
            ISettingsRepository settingsRepository,
            ILoggerFactory loggerFactory)
        {
            this.binaryTestExecutor      = binaryTestExecutor;
            this.progressRecorderFactory = progressRecorderFactory;
            this.settingsRepository      = settingsRepository;
            this.loggerFactory           = loggerFactory;

            this.isCanceled = false;
        }
        public MultiSourceTestExecutor(IEnumerable <TestCase> tests,
                                       IBinaryTestExecutor binaryTestExecutor,
                                       IProgressRecorderFactory progressRecorderFactory,
                                       ISettingsRepository settingsRepository,
                                       ILoggerFactory loggerFactory)
            : this(binaryTestExecutor, progressRecorderFactory, settingsRepository, loggerFactory)
        {
            var testCaseGroupsBySource = tests.GroupBy(t => t.Source);

            this.testableItems = testCaseGroupsBySource.Select(group => new TestCaseGroupTestableItem(group));

            this.sourceDescription = "TestCases";
        }
Пример #5
0
        public virtual void before_each()
        {
            autoSubstitute = new AutoSubstitute();

            frameworkHandle = autoSubstitute.Resolve <IFrameworkHandle>();

            binaryTestExecutor = autoSubstitute.Resolve <IBinaryTestExecutor>();

            progressRecorder        = autoSubstitute.Resolve <IProgressRecorder>();
            progressRecorderFactory = autoSubstitute.Resolve <IProgressRecorderFactory>();
            progressRecorderFactory.Create(frameworkHandle).Returns(progressRecorder);

            settingsRepository = autoSubstitute.Resolve <ISettingsRepository>();

            outputLogger  = autoSubstitute.Resolve <IOutputLogger>();
            loggerFactory = autoSubstitute.Resolve <ILoggerFactory>();
            loggerFactory.CreateOutput(null, null).ReturnsForAnyArgs(outputLogger);

            actualSources = new List <string>();

            progressRecorder.BinaryPath = Arg.Do <string>(path => actualSources.Add(path));
        }