Пример #1
0
        public MasterTestRunner(IServiceLocator services, TestPackage package)
        {
            if (services == null)
            {
                throw new ArgumentNullException("services");
            }
            if (package == null)
            {
                throw new ArgumentNullException("package");
            }

            _services   = services;
            TestPackage = package;

            // Get references to the services we use
            _projectService    = _services.GetService <IProjectService>();
            _testRunnerFactory = _services.GetService <ITestRunnerFactory>();

            _packageAnalyzer = _services.GetService <TestPackageAnalyzer>();
            _runtimeService  = _services.GetService <IRuntimeFrameworkService>();

            _eventDispatcher = _services.GetService <TestEventDispatcher>();

            // Last chance to catch invalid settings in package,
            // in case the client runner missed them.
            _packageAnalyzer.ValidatePackageSettings(package);
        }