public InPlaceScenarioRunner(IResultListener listener, MemberInvoker memberInvoker,
                              ScenarioInterpreter scenarioInterpreter)
 {
     _listener = listener;
     _scenarioInterpreter = scenarioInterpreter;
     _lineExecuter = new ScenarioLineExecuter(memberInvoker, scenarioInterpreter, listener);
 }
        public void SetupContext()
        {
            ResultListener = MockRepository.GenerateStub<IResultListener>();

            var inPlaceRunner = new InPlaceStoryRunner(ResultListener, new ScenarioPreprocessor(), new ScenarioInterpreter(new InterpreterForTypeFactory(new ExtensionMethodHandler())), new IncludeAllFilter(), new StoryContextFactory());
            inPlaceRunner.Finished();
        }
        public void SetupContext()
        {
            ResultListener = MockRepository.GenerateStub<IResultListener>();
            var remoteHandlerFactory = MockRepository.GenerateStub<IRemoteHandlerFactory>();

            var inPlaceRunner = new InPlaceCompilingStoryRunner(remoteHandlerFactory, ResultListener,new ScenarioPreprocessor(), new IncludeAllFilter(), new StoryContextFactory());
            inPlaceRunner.Finished();
        }
Beispiel #4
0
 public void SetUp()
 {
     mocks          = new MockRepository();
     browser        = mocks.DynamicMock <IWebBrowser>();
     resultParser   = mocks.DynamicMock <IResultParser>();
     resultListener = mocks.DynamicMock <IResultListener>();
     fixtureRunner  = new FixtureRunner(resultListener, browser, resultParser);
 }
 public ScenarioLineExecuter(MemberInvoker memberInvoker, 
                             ScenarioInterpreter scenarioInterpreter,
                             IResultListener listener)
 {
     _memberInvoker = memberInvoker;
     _listener = listener;
     _scenarioInterpreter = scenarioInterpreter;
 }
 public RemoteStoryHandler(string assemblyLocation, IFilesystem filesystem, IResultListener listener,
                           IEnumerable<string> assemblyLocations)
 {
     _assemblyLocation = assemblyLocation;
     _listener = listener;
     _assemblyLocations = assemblyLocations;
     _filesystem = filesystem;
 }
 public InPlaceStoryRunner(IResultListener listener,
                           IScenarioPreprocessor preprocessor,
                           ScenarioInterpreter scenarioInterpreter,
                           IStoryFilter filter,
                           IStoryContextFactory contextFactory)
     : base(listener, preprocessor, filter, contextFactory)
 {
     _scenarioRunner = new InPlaceScenarioRunner(listener,new MemberInvoker(), scenarioInterpreter);
 }
Beispiel #8
0
 /// <summary>
 /// Contructs a new fixture runner
 /// </summary>
 /// <param name="resultListener">Used to get the JSUnit results</param>
 /// <param name="webBrowser">The browser object used to run the test</param>
 /// <param name="resultParser">Parser used to extract the JSUnit results</param>
 public FixtureRunner(
     [NotNull] IResultListener resultListener,
     [NotNull] IWebBrowser webBrowser,
     [NotNull] IResultParser resultParser)
 {
     this.resultListener = resultListener;
     this.webBrowser     = webBrowser;
     this.resultParser   = resultParser;
 }
 public InPlaceCompilingStoryRunner(IRemoteHandlerFactory factory,
                                    IResultListener listener,
                                    IScenarioPreprocessor preprocessor,                                         
                                    IStoryFilter filter,
                                    IStoryContextFactory contextFactory)
     : base(listener, preprocessor, filter, contextFactory)
 {
     _factory = factory;
 }
Beispiel #10
0
        protected DriverBase(IResultListener listener)
        {
            _listener = listener;

            ScenarioInterpreter = new ScenarioInterpreter(new InterpreterForTypeFactory(new ExtensionMethodHandler()));

            LineExecuter = new ScenarioLineExecuter(new MemberInvoker(), ScenarioInterpreter, _listener);

            ContextFactory = new StoryContextFactory();
        }
Beispiel #11
0
 void Propagate(IResultListener rt, ResultTable result)
 {
     try
     {
         rt.OnResultPublished(stepRun.Id, result);
     }
     catch (Exception e)
     {
         log.Warning("Caught exception in result handling task.");
         log.Debug(e);
         planRun.RemoveFaultyResultListener(rt);
     }
 }
Beispiel #12
0
        public TaskViewModel(
            Type taskType,
            MethodInfo task,
            IEnumerable<TaskParameterViewModel> parameterViewModels,
            IResultListener resultListener)
        {
            _task = task;
            _resultListener = resultListener;

            var descriptionAttriute = task.GetCustomAttributes(typeof(DescriptionAttribute), true)
                .Cast<DescriptionAttribute>()
                .FirstOrDefault();

            TaskType = taskType;
            Name = task.GetDisplayName();
            Description = descriptionAttriute.Description;
            DependencyGroupOrder = null;//uiExecutableAttribute.OptionalDependencyGroupOrder;
            Parameters = new ObservableCollection<TaskParameterViewModel>(parameterViewModels);
            ExecuteCommand = new DelegateCommand(Execute);
            ExpandCommand = new DelegateCommand(Expand);
            CollapseCommand = new DelegateCommand(Collapse);
        }
Beispiel #13
0
        public void LoadChatMembers(Guid chatId, IResultListener <INChatMember> chatMembersListener)
        {
            var members = _messagesApi.GetChatMembers(chatId, DateTime.UtcNow);

            chatMembersListener.Notify(members, LoadResultKind.Remote);
        }
Beispiel #14
0
 public ASyncIdMarkerTable(IResultListener i_listener)
 {
     this._mklib = new RawbitSerialIdTable(1);
     this._mklib.addAnyItem("ANY ID", 40);
     this._listener = i_listener;
 }
Beispiel #15
0
 public void registerListener(IResultListener listener)
 {
     this.listener = listener;
 }
 public virtual IRemoteStoryHandler GetHandler(Story story, IEnumerable<Scenario> scenarios, IResultListener listener)
 {
     var assemblyLocation = _assemblyGenerator.GenerateAssembly(story, scenarios, _settings.AssemblyLocations);
     return new RemoteStoryHandler(assemblyLocation, _filesystem, new RemoteListener(listener), _settings.AssemblyLocations);
 }
 public RemoteListener(IResultListener inner)
 {
     _inner = inner;
 }
Beispiel #18
0
 public void InvokeAsync(string operation, string[] args, IResultListener listener)
 {
     throw new NotImplementedException();
 }
 /// <summary>
 /// Removes a previously added result listener. This method can be called in any state.
 /// </summary>
 /// <param name="resultListener">the listener to remove</param>
 public void RemoveResultListener(IResultListener resultListener)
 {
     ResultListeners.Remove(resultListener);
 }
 /// <summary>
 /// Adds a result listener to this recognizer. A result listener is called whenever a new result is generated by the
 /// recognizer. This method can be called in any state.
 /// </summary>
 /// <param name="resultListener"></param>
 public void AddResultListener(IResultListener resultListener)
 {
     ResultListeners.Add(resultListener);
 }
 public ASyncIdMarkerTable(IResultListener i_listener)
 {
     this._mklib=new RawbitSerialIdTable(1);
     this._mklib.addAnyItem("ANY ID",40);
     this._listener=i_listener;
 }
 public void AddListener(IResultListener listener)
 {
     Listeners.Add(listener);
 }