void CreateOpenMSBuildProjects()
        {
            fakeProjectService = MockRepository.GenerateStub <IPackageManagementProjectService>();
            openProjects       = new SimpleModelCollection <IProject>();
            fakeProjectService.Stub(service => service.AllProjects).Return(openProjects);

            projects = new OpenMSBuildProjects(fakeProjectService);
        }
		void CreateOpenMSBuildProjects()
		{
			fakeProjectService = MockRepository.GenerateStub<IPackageManagementProjectService>();
			openProjects = new SimpleModelCollection<IProject>();
			fakeProjectService.Stub(service => service.AllProjects).Return(openProjects);
			
			projects = new OpenMSBuildProjects(fakeProjectService);
		}
Beispiel #3
0
		void OpenSolution(string fileName)
		{
			fakeSolution = MockRepository.GenerateStub<ISolution>();
			var sections = new SimpleModelCollection<SolutionSection>(new SolutionSection[0]);
			fakeSolution.Stub(s => s.GlobalSections).Return(sections);
			fakeProjectService.OpenSolution = fakeSolution;
			SetOpenSolutionFileName(fileName);
		}
Beispiel #4
0
        void OpenSolution(string fileName)
        {
            fakeSolution = MockRepository.GenerateStub <ISolution>();
            var sections = new SimpleModelCollection <SolutionSection>(new SolutionSection[0]);

            fakeSolution.Stub(s => s.GlobalSections).Return(sections);
            fakeProjectService.OpenSolution = fakeSolution;
            SetOpenSolutionFileName(fileName);
        }
		public AssemblyReferencesTreeNode(IAssemblyModel assemblyModel)
		{
			if (assemblyModel == null)
				throw new ArgumentNullException("assemblyModel");
			this.assemblyModel = assemblyModel;
			this.text = SD.ResourceService.GetString("ICSharpCode.SharpDevelop.Commands.ProjectBrowser.ReferencesNodeText");
			references = new SimpleModelCollection<IAssemblyModel>();
			UpdateReferences();
		}
		public BaseTypesTreeNode(ITypeDefinitionModel definition)
		{
			if (definition == null)
				throw new ArgumentNullException("definition");
			this.definition = definition;
			this.definition.Updated += (sender, e) => UpdateBaseTypes();
			this.text = SD.ResourceService.GetString("MainWindow.Windows.ClassBrowser.BaseTypes");
			baseTypes = new SimpleModelCollection<ITypeDefinitionModel>();
			childrenLoaded = false;
		}
Beispiel #7
0
 public DerivedTypesTreeNode(ITypeDefinitionModel definition)
 {
     if (definition == null)
     {
         throw new ArgumentNullException("definition");
     }
     this.definition          = definition;
     this.definition.Updated += (sender, e) => UpdateDerivedTypes();
     this.text      = SD.ResourceService.GetString("MainWindow.Windows.ClassBrowser.DerivedTypes");
     derivedTypes   = new SimpleModelCollection <ITypeDefinitionModel>();
     childrenLoaded = false;
 }
Beispiel #8
0
		SD.ISolution CreateSharpDevelopSolution(string fileName = @"d:\projects\MyProject\MyProject.sln")
		{
			var solution = MockRepository.GenerateStub<ISolution>();
			var solutionFileName = new FileName(fileName);
			solution.Stub(s => s.FileName).Return(solutionFileName);
			solution.Stub(s => s.Directory).Return(solutionFileName.GetParentDirectory());
			
			var sections = new SimpleModelCollection<SolutionSection>(new SolutionSection[0]);
			solution.Stub(s => s.GlobalSections).Return(sections);
			
			solution.Stub(s => s.MSBuildProjectCollection).Return(new ProjectCollection());
			
			var projects = new SimpleModelCollection<IProject>();
			solution.Stub(s =>s.Projects).Return(projects);
			
			return solution;
		}
        SD.ISolution CreateSharpDevelopSolution(string fileName = @"d:\projects\MyProject\MyProject.sln")
        {
            var solution         = MockRepository.GenerateStub <ISolution>();
            var solutionFileName = new FileName(fileName);

            solution.Stub(s => s.FileName).Return(solutionFileName);
            solution.Stub(s => s.Directory).Return(solutionFileName.GetParentDirectory());

            var sections = new SimpleModelCollection <SolutionSection>(new SolutionSection[0]);

            solution.Stub(s => s.GlobalSections).Return(sections);

            solution.Stub(s => s.MSBuildProjectCollection).Return(new ProjectCollection());

            var projects = new SimpleModelCollection <IProject>();

            solution.Stub(s => s.Projects).Return(projects);

            var items = new NullSafeSimpleModelCollection <ISolutionItem>();

            solution.Stub(s => s.Items).Return(items);

            return(solution);
        }