public TestingService(IServiceProvider serviceProvider) { this.serviceProvider = serviceProvider; this.datasetService = serviceProvider.GetService <IDatasetService>(); this.datasetResolver = serviceProvider.GetService <IDatasetResolverService>(); this.logger = serviceProvider.GetService <ILogger>(); this.resultStore = serviceProvider.GetService <ITestResultStore>(); }
protected TestLogger( IFileSystem fileSystem, IConsoleOutput consoleOutput, ITestResultStore resultStore, ITestResultSerializer resultSerializer) { this.fileSystem = fileSystem ?? throw new ArgumentNullException(nameof(fileSystem)); this.consoleOutput = consoleOutput ?? throw new ArgumentNullException(nameof(consoleOutput)); this.resultStore = resultStore ?? throw new ArgumentNullException(nameof(resultStore)); this.resultSerializer = resultSerializer ?? throw new ArgumentNullException(nameof(resultSerializer)); }
public ITestRunBuilder WithStore(ITestResultStore store) { this.testRun.Store = store ?? throw new ArgumentNullException(nameof(store)); return(this); }