private void Initialize(TaskExecutionNode node)
        {
            config = NBehaveConfiguration.New;

            var codeGenListener = new CodeGenEventListener();
            var resharperResultNotifier = new ResharperResultPublisher(node.Children, Server, codeGenListener);
            var listener = new NBehaveTaskRunnerListener(resharperResultNotifier);

            var files = node.Children.Select(_ => ((NBehaveFeatureTask)_.RemoteTask).FeatureFile).Distinct().ToList();
            var asm = (NBehaveAssemblyTask)node.RemoteTask;
            var assemblies = new[] { asm.AssemblyFile };
            var eventListener = new MultiOutputEventListener(codeGenListener, listener);
            ModifyConfig(files, assemblies, eventListener);
        }
        public virtual void SetUp()
        {
            _listener = new CodeGenEventListener();

            ConfigurationNoAppDomain
                .New
                .SetEventListener(_listener)
                .SetAssemblies(new[] { GetType().Assembly.Location })
                .SetScenarioFiles(new[] { TestFeatures.FeaturesAndScenarios })
                .Build()
                .Run();

            _output = _listener.ToString();
        }
        public void SetUp()
        {
            var codeGeneration = new CodeGenEventListener();
            server = MockRepository.GenerateMock<IRemoteTaskServer>();

            var featureFile = MockRepository.GenerateStub<IProjectFile>();
            featureFile.Stub(_ => _.Location).Return(new FileSystemPath(Source));
            scenarioTask = new NBehaveScenarioTask(featureFile, ScenarioTitle);
            var scenarioTaskNode = new TaskExecutionNode(null, scenarioTask);

            task = new NBehaveStepTask(featureFile, ScenarioTitle, "Given something");
            var stepTaskNode = new TaskExecutionNode(scenarioTaskNode, task);
            var nodes = new List<TaskExecutionNode> { scenarioTaskNode, stepTaskNode };
            resultPublisher = new ResharperResultPublisher(nodes, server, codeGeneration);

            feature = new Narrator.Framework.Feature("feature title");
            Because_of();
        }