示例#1
0
        public virtual SessionContext GetSessionContext(string currentAssemblyLocation, IEnumerable <Assembly> assemblies)
        {
            AssemblyRegistry assemblyRegistry = GetAssemblyRegistry(currentAssemblyLocation, assemblies);

            ParameterConverter.AddCustomConverters(assemblyRegistry);


            return(new SessionContext(assemblyRegistry));
        }
示例#2
0
        private ISessionContext GetSessionContext(ConfigSettings settings)
        {
            var assemblyRegistry = new AssemblyRegistry(settings.AssemblyLocations);

            ParameterConverter.AddCustomConverters(assemblyRegistry);

            var sessionContext = new SessionContext(assemblyRegistry);

            return(sessionContext);
        }
示例#3
0
        protected DriverBase(IEventBus eventBus)
        {
            //ResultListener = resultListener;
            _eventBus = eventBus;
            var assemblyRegistry = new AssemblyRegistry(GetAssemblies());

            ScenarioInterpreter = new ScenarioInterpreter(new InterpreterForTypeFactory(assemblyRegistry), new MostRecentlyUsedContext(), new DefaultLanguageService());
            LineExecuter        = new ScenarioLineExecuter(ScenarioInterpreter, _eventBus);
            _context            = new SessionContext(assemblyRegistry);
            ParameterConverter.AddCustomConverters(assemblyRegistry);
        }
示例#4
0
        public RemoteScenarioExecutor(IRemoteTaskServer server, AssemblyRegistry assemblyRegistry)
        {
            _server = server;
            _assemblyRegistry = assemblyRegistry;
            _sessionContext = new SessionContext(assemblyRegistry);

            _eventBus = new EventBus();

            new EventBusAutoRegistrar(_assemblyRegistry).InstallTo(_eventBus);
            _listener = new ResharperResultListener(_server);
          
            _resolver = new MostRecentlyUsedContext();
            _runner = BuildInPlaceRunner(_resolver);

            _eventBus.Register(_resolver);
            _eventBus.Register(_listener);

            ParameterConverter.AddCustomConverters(_assemblyRegistry);
        }