Example #1
0
        private static ActiveConfiguredProjectsLoader CreateInstance(UnconfiguredProject project, IUnconfiguredProjectTasksService tasksService, out ProjectValueDataSource<IConfigurationGroup<ProjectConfiguration>> source)
        {
            var services = IProjectCommonServicesFactory.CreateWithDefaultThreadingPolicy();
            source = ProjectValueDataSourceFactory.Create<IConfigurationGroup<ProjectConfiguration>>(services);
            var activeConfigurationGroupService = IActiveConfigurationGroupServiceFactory.Implement(source);

            var loader = CreateInstance(project, activeConfigurationGroupService, tasksService);

            return loader;
        }
        private static ConfiguredProjectImplicitActivationTracking CreateInstance(ConfiguredProject project, IProjectAsynchronousTasksService tasksService, out ProjectValueDataSource <IConfigurationGroup <ProjectConfiguration> > source)
        {
            project = project ?? ConfiguredProjectFactory.Create();
            var services = IProjectCommonServicesFactory.CreateWithDefaultThreadingPolicy();

            source = ProjectValueDataSourceFactory.Create <IConfigurationGroup <ProjectConfiguration> >(services);
            var activeConfigurationGroupService = IActiveConfigurationGroupServiceFactory.Implement(source);

            tasksService = tasksService ?? IProjectAsynchronousTasksServiceFactory.Create();

            return(new ConfiguredProjectImplicitActivationTracking(project, activeConfigurationGroupService, tasksService));
        }
Example #3
0
        public static IProjectSubscriptionService Create()
        {
            var services = IProjectCommonServicesFactory.CreateWithDefaultThreadingPolicy();
            var source   = ProjectValueDataSourceFactory.Create <IProjectSubscriptionUpdate>(services);

            var mock = new Mock <IProjectSubscriptionService>();

            mock.SetupGet(s => s.ProjectRuleSource)
            .Returns(source);

            mock.SetupGet(s => s.ProjectBuildRuleSource)
            .Returns(source);

            return(mock.Object);
        }