Exemple #1
0
 public GenerateMonoRailSiteTreeTask()
 {
     _logger              = new MsBuildLogger(this.Log);
     _naming              = new DefaultNamingService();
     _treeService         = new DefaultTreeCreationService();
     _source              = new DefaultSourceGenerator();
     _viewSourceMapper    = new ViewSourceMapper(_logger, _treeService, _naming);
     _sourceStorage       = new DefaultSourceStorageService();
     _typeResolver        = new TypeResolver();
     _service             = new SiteTreeGeneratorService(_logger, _typeResolver, _sourceStorage, new NRefactoryParserFactory());
     this.ServiceTypeName = typeof(ICodeGeneratorServices).FullName;
 }
Exemple #2
0
 public GenerateMonoRailSiteTreeTask(ILogger logger, ISiteTreeGeneratorService service, INamingService naming, ISourceGenerator source, IParsedSourceStorageService sourceStorage, ITypeResolver typeResolver, ITreeCreationService treeService, IViewSourceMapper viewSourceMapper, IGenerator generator)
 {
     _service          = service;
     _logger           = logger;
     _naming           = naming;
     _source           = source;
     _sourceStorage    = sourceStorage;
     _typeResolver     = typeResolver;
     _treeService      = treeService;
     _viewSourceMapper = viewSourceMapper;
     _generators.Add(generator);
     this.ServiceTypeName = typeof(ICodeGeneratorServices).FullName;
 }
Exemple #3
0
        public void Setup()
        {
            _ccu            = new CodeCompileUnit();
            _mocks          = new MockRepository();
            _engine         = Engine.GlobalEngine;
            _engine.BinPath = @"C:\Program Files (x86)\MSBuild";
            _project        = new Project();
            _buildEngine    = _mocks.DynamicMock <MockBuildEngine>(_project);

            _logger           = new NullLogger();
            _parserService    = _mocks.DynamicMock <ISiteTreeGeneratorService>();
            _naming           = _mocks.DynamicMock <INamingService>();
            _sourceStorage    = _mocks.DynamicMock <IParsedSourceStorageService>();
            _source           = _mocks.DynamicMock <ISourceGenerator>();
            _typeResolver     = _mocks.DynamicMock <ITypeResolver>();
            _treeService      = _mocks.DynamicMock <ITreeCreationService>();
            _viewSourceMapper = _mocks.DynamicMock <IViewSourceMapper>();
            _generator        = _mocks.DynamicMock <IGenerator>();

            _task = new GenerateMonoRailSiteTreeTask(_logger, _parserService, _naming, _source, _sourceStorage, _typeResolver, _treeService, _viewSourceMapper, _generator);

            _item         = _mocks.DynamicMock <ITaskItem>();
            _parsedSource = _mocks.DynamicMock <IParser>();
        }
    public void Setup()
    {
      _ccu = new CodeCompileUnit();
      _mocks = new MockRepository();
      _engine = Engine.GlobalEngine;
      _engine.BinPath = @"C:\Program Files (x86)\MSBuild";
      _project = new Project();
      _buildEngine = _mocks.DynamicMock<MockBuildEngine>(_project);

      _logger = new NullLogger();
      _parserService = _mocks.DynamicMock<ISiteTreeGeneratorService>();
      _naming = _mocks.DynamicMock<INamingService>();
      _sourceStorage = _mocks.DynamicMock<IParsedSourceStorageService>();
      _source = _mocks.DynamicMock<ISourceGenerator>();
      _typeResolver = _mocks.DynamicMock<ITypeResolver>();
      _treeService = _mocks.DynamicMock<ITreeCreationService>();
      _viewSourceMapper = _mocks.DynamicMock<IViewSourceMapper>();
      _generator = _mocks.DynamicMock<IGenerator>();

      _task = new GenerateMonoRailSiteTreeTask(_logger, _parserService, _naming, _source, _sourceStorage, _typeResolver, _treeService, _viewSourceMapper, _generator);

      _item = _mocks.DynamicMock<ITaskItem>();
      _parsedSource = _mocks.DynamicMock<IParser>();
    }
 public GenerateMonoRailSiteTreeTask(ILogger logger, ISiteTreeGeneratorService service, INamingService naming, ISourceGenerator source, IParsedSourceStorageService sourceStorage, ITypeResolver typeResolver, ITreeCreationService treeService, IViewSourceMapper viewSourceMapper, IGenerator generator)
 {
     _service = service;
     _logger = logger;
     _naming = naming;
     _source = source;
     _sourceStorage = sourceStorage;
     _typeResolver = typeResolver;
     _treeService = treeService;
     _viewSourceMapper = viewSourceMapper;
     _generators.Add(generator);
     this.ServiceTypeName = typeof(ICodeGeneratorServices).FullName;
 }
 public GenerateMonoRailSiteTreeTask()
 {
     _logger = new MsBuildLogger(this.Log);
     _naming = new DefaultNamingService();
     _treeService = new DefaultTreeCreationService();
     _source = new DefaultSourceGenerator();
     _viewSourceMapper = new ViewSourceMapper(_logger, _treeService, _naming);
     _sourceStorage = new DefaultSourceStorageService();
     _typeResolver = new TypeResolver();
     _service = new SiteTreeGeneratorService(_logger, _typeResolver, _sourceStorage, new NRefactoryParserFactory());
     this.ServiceTypeName = typeof(ICodeGeneratorServices).FullName;
 }