public void Constructor_NullAsImageProvider_ThrowsArgumentNull()
        {
            var designerService = IProjectDesignerServiceFactory.Create();

            Assert.Throws <ArgumentNullException>("imageProvider", () => {
                new AppDesignerFolderProjectTreePropertiesProvider((IProjectImageProvider)null, designerService);
            });
        }
        public void Constructor_NullAsProjectServices_ThrowsArgumentNull()
        {
            var imageProvider   = IProjectImageProviderFactory.Create();
            var designerService = IProjectDesignerServiceFactory.Create();

            Assert.Throws <ArgumentNullException>("projectServices", () => {
                new MyProjectFolderProjectTreePropertiesProvider(imageProvider, (IUnconfiguredProjectCommonServices)null, designerService);
            });
        }
        public void Constructor_NullAsImageProvider_ThrowsArgumentNull()
        {
            var projectServices = IUnconfiguredProjectCommonServicesFactory.Create();
            var designerService = IProjectDesignerServiceFactory.Create();

            Assert.Throws <ArgumentNullException>("imageProvider", () => {
                new PropertiesFolderProjectTreePropertiesProvider((IProjectImageProvider)null, projectServices, designerService);
            });
        }
        private MyProjectFolderProjectTreePropertiesProvider CreateInstance(IProjectImageProvider imageProvider, IProjectDesignerService designerService, string appDesignerFolder = "My Project")
        {
            designerService = designerService ?? IProjectDesignerServiceFactory.Create();
            var threadingService  = IProjectThreadingServiceFactory.Create();
            var project           = IUnconfiguredProjectFactory.Create();
            var projectProperties = ProjectPropertiesFactory.Create(project,
                                                                    new PropertyPageData()
            {
                Category     = nameof(ConfigurationGeneral),
                PropertyName = nameof(ConfigurationGeneral.AppDesignerFolder),
                Value        = appDesignerFolder
            });

            var projectServices = IUnconfiguredProjectCommonServicesFactory.Create(project, threadingService, projectProperties.ConfiguredProject, projectProperties);

            return(new MyProjectFolderProjectTreePropertiesProvider(imageProvider ?? IProjectImageProviderFactory.Create(), projectServices, designerService));
        }
Пример #5
0
 private AppDesignerFolderProjectTreePropertiesProvider CreateInstance(IProjectImageProvider imageProvider, IProjectDesignerService designerService)
 {
     return(new AppDesignerFolderProjectTreePropertiesProvider(imageProvider ?? IProjectImageProviderFactory.Create(), designerService ?? IProjectDesignerServiceFactory.Create()));
 }
Пример #6
0
        internal override AbstractOpenProjectDesignerCommand CreateInstance(IProjectDesignerService designerService = null)
        {
            designerService = designerService ?? IProjectDesignerServiceFactory.Create();

            return(new OpenProjectDesignerOnDefaultActionCommand(designerService));
        }