1 write to ProjectNodes
Microsoft.Build (1)
Graph\ProjectGraph.cs (1)
445ProjectNodes = graphBuilder.ProjectNodes;
113 references to ProjectNodes
Microsoft.Build (9)
BackEnd\BuildManager\BuildManager.cs (3)
1997var blockedNodes = new HashSet<ProjectGraphNode>(projectGraph.ProjectNodes); 1998var finishedNodes = new HashSet<ProjectGraphNode>(projectGraph.ProjectNodes.Count); 2000var resultsPerNode = new Dictionary<ProjectGraphNode, BuildResult>(projectGraph.ProjectNodes.Count);
BackEnd\Components\ProjectCache\ProjectCacheService.cs (1)
111projectGraph.ProjectNodes,
Graph\ProjectGraph.cs (5)
449_projectNodesTopologicallySorted = new Lazy<IReadOnlyCollection<ProjectGraphNode>>(() => TopologicalSort(GraphRoots, ProjectNodes)); 486ProjectNodes.Count, 513foreach (var node in ProjectNodes) 556return $"#roots={GraphRoots.Count}, #nodes={ProjectNodes.Count}, #entryPoints={EntryPointNodes.Count}"; 614var targetLists = ProjectNodes.ToDictionary(node => node, node => ImmutableList<string>.Empty);
Microsoft.Build.Engine.UnitTests (104)
BackEnd\BuildManager_Tests.cs (6)
4204graph.ProjectNodes.Count.ShouldBe(2); 4211var node1 = graph.ProjectNodes.First(node => node.ProjectInstance.FullPath.Equals(project1, StringComparison.OrdinalIgnoreCase)); 4215var node2 = graph.ProjectNodes.First(node => node.ProjectInstance.FullPath.Equals(project2, StringComparison.OrdinalIgnoreCase)); 4289graph.ProjectNodes.Count.ShouldBe(2); 4296var node1 = graph.ProjectNodes.First(node => node.ProjectInstance.FullPath.Equals(project1, StringComparison.OrdinalIgnoreCase)); 4300var node2 = graph.ProjectNodes.First(node => node.ProjectInstance.FullPath.Equals(project2, StringComparison.OrdinalIgnoreCase));
Construction\SolutionFilter_Tests.cs (2)
136graphFromSolution.ProjectNodes.ShouldHaveSingleItem(); 137graphFromSolution.ProjectNodes.Single().ProjectInstance.ProjectFileLocation.LocationString.ShouldBe(simpleProject.Path);
Graph\GetCompatiblePlatformGraph_Tests.cs (1)
184graph.ProjectNodes.Count.ShouldBe(3);
Graph\GraphLoadedFromSolution_tests.cs (9)
212var projectSpecificConfigurations = graph.ProjectNodes.ToDictionary( 256graph.ProjectNodes.ShouldBeEmpty(); 690graph.ProjectNodes.Count.ShouldBe(graph.ProjectNodes.Select(GetProjectPath).Distinct().Count()); 694.ShouldBeSetEquivalentTo(graph.ProjectNodes.Select(GetProjectPath)); 696if (projectConfigurations == null || graphFromSolution.ProjectNodes.All(n => n.ProjectReferences.Count == 0)) 701graphFromSolution.ProjectNodes.Select(GetProjectPath) 702.ShouldBeSameIgnoringOrder(graph.ProjectNodes.Select(GetProjectPath)); 708foreach (var node in graphFromSolution.ProjectNodes)
Graph\GraphTestingUtilities.cs (1)
138return graph.ProjectNodes.Where(node => node.ProjectInstance.FullPath.EndsWith(projectNum + ".proj"));
Graph\ProjectGraph_Tests.cs (74)
52projectGraph.ProjectNodes.ShouldBeEmpty(); 66projectGraph.ProjectNodes.Count.ShouldBe(1); 67projectGraph.ProjectNodes.First().ProjectInstance.FullPath.ShouldBe(entryProject.Path); 117projectGraph.ProjectNodes.Count.ShouldBe(1); 118projectGraph.ProjectNodes.First().ProjectInstance.FullPath.ShouldBe(entryProject.Path); 232graph.ProjectNodes.Count.ShouldBe(3); 261graph.ProjectNodes.Count.ShouldBe(7); 406graph.ProjectNodes.Count.ShouldBe(5); 431graph.ProjectNodes.Count.ShouldBe(3); 464graph.ProjectNodes.Count.ShouldBe(6); 500graph.ProjectNodes.Count.ShouldBe(4); 535graph.ProjectNodes.Count.ShouldBe(6); 579projectGraph.ProjectNodes.Count.ShouldBe(3); 602projectGraph.ProjectNodes.Count.ShouldBe(4); 641projectGraph.ProjectNodes.Count.ShouldBe(3); 866projectGraph.ProjectNodes.Count.ShouldBe(7); 868ProjectGraphNode project1Node = projectGraph.ProjectNodes.Single(node => node.ProjectInstance.FullPath == project1Path); 874ProjectGraphNode project2Node = projectGraph.ProjectNodes.Single(node => node.ProjectInstance.FullPath == project2Path); 880ProjectGraphNode project3Node = projectGraph.ProjectNodes.Single(node => node.ProjectInstance.FullPath == project3Path); 887ProjectGraphNode project4Node = projectGraph.ProjectNodes.Single(node => node.ProjectInstance.FullPath == project4Path); 893ProjectGraphNode project5Node = projectGraph.ProjectNodes.Single(node => node.ProjectInstance.FullPath == project5Path); 899ProjectGraphNode project6Node = projectGraph.ProjectNodes.Single(node => node.ProjectInstance.FullPath == project6Path); 905Assert.DoesNotContain(projectGraph.ProjectNodes, node => node.ProjectInstance.FullPath == project7Path); 907ProjectGraphNode project8Node = projectGraph.ProjectNodes.Single(node => node.ProjectInstance.FullPath == project8Path); 925projectGraph.ProjectNodes.Count.ShouldBe(4); 928targetLists.Count.ShouldBe(projectGraph.ProjectNodes.Count); 953projectGraph.ProjectNodes.Count.ShouldBe(3); 956targetLists.Count.ShouldBe(projectGraph.ProjectNodes.Count); 984projectGraph.ProjectNodes.Count.ShouldBe(6); 987targetLists.Count.ShouldBe(projectGraph.ProjectNodes.Count); 1006projectGraph.ProjectNodes.Count.ShouldBe(2); 1009targetLists.Count.ShouldBe(projectGraph.ProjectNodes.Count); 1024projectGraph.ProjectNodes.Count.ShouldBe(2); 1027targetLists.Count.ShouldBe(projectGraph.ProjectNodes.Count); 1047projectGraph.ProjectNodes.Count.ShouldBe(2); 1050targetLists.Count.ShouldBe(projectGraph.ProjectNodes.Count); 1070projectGraph.ProjectNodes.Count.ShouldBe(2); 1073targetLists.Count.ShouldBe(projectGraph.ProjectNodes.Count); 1087projectGraph.ProjectNodes.Count.ShouldBe(1); 1113projectGraph.ProjectNodes.Count.ShouldBe(2); 1116targetLists.Count.ShouldBe(projectGraph.ProjectNodes.Count); 1154projectGraph.ProjectNodes.Count.ShouldBe(2); 1157targetLists.Count.ShouldBe(projectGraph.ProjectNodes.Count); 1188projectGraph.ProjectNodes.Count.ShouldBe(4); 1192targetLists.Count.ShouldBe(projectGraph.ProjectNodes.Count); 1360projectGraph.ProjectNodes.Count.ShouldBe(12); 1364targetLists.Count.ShouldBe(projectGraph.ProjectNodes.Count); 1395projectGraph.ProjectNodes.Count.ShouldBe(2); 1398targetLists.Count.ShouldBe(projectGraph.ProjectNodes.Count); 1418projectGraph.ProjectNodes.Count.ShouldBe(2); 1421targetLists.Count.ShouldBe(projectGraph.ProjectNodes.Count); 1448projectGraph.ProjectNodes.Count.ShouldBe(7); 1451targetLists.Count.ShouldBe(projectGraph.ProjectNodes.Count); 1505projectGraph.ProjectNodes.Count.ShouldBe(expected: 5); 1508targetLists.Count.ShouldBe(expected: projectGraph.ProjectNodes.Count); 1815toposort.Length.ShouldBe(projectGraph.ProjectNodes.Count); 1853foreach (var node in graph.ProjectNodes) 1876Regex.Matches(dot, "label").Count.ShouldBe(graph.ProjectNodes.Count); 1888graph.ProjectNodes.Count.ShouldBe(3); 1915graph.ProjectNodes.Count.ShouldBe(4); 1949graph.ProjectNodes.Count.ShouldBe(4); 1982graph.ProjectNodes.Count.ShouldBe(4); 2001graph.ProjectNodes.Count.ShouldBe(4); 2029graph.ProjectNodes.Count.ShouldBe(2); 2048graph.ProjectNodes.Count.ShouldBe(2); 2069graph.ProjectNodes.Count.ShouldBe(8); 2096graph.ProjectNodes.Count.ShouldBe(11); 2136graph.ProjectNodes.Count.ShouldBe(4); 2170graph.ProjectNodes.Count.ShouldBe(3); 2214graph.ProjectNodes.Count.ShouldBe(5); 2334foreach (var node in projectGraph.ProjectNodes) 2351projectGraph.ProjectNodes.First().ProjectInstance.GlobalProperties[PropertyNames.IsGraphBuild].ShouldBe("xyz"); 2364foreach (var node in graph.ProjectNodes) 2878targetLists.Count.ShouldBe(projectGraph.ProjectNodes.Count);
ProjectCache\ProjectCacheTests.cs (10)
576string solutionConfigurationGlobalProperty = CreateSolutionConfigurationProperty(graph.ProjectNodes); 604foreach (var node in graph.ProjectNodes) 782instanceMockCache.Requests.Count.ShouldBe(graph.ProjectNodes.Count); 788Regex.Matches(mockLogger.FullLog, $"{AssemblyMockCache}: GetCacheResultAsync for").Count.ShouldBe(graph.ProjectNodes.Count); 792foreach (var node in graph.ProjectNodes) 1428return buildSession.BuildProjectFileAsync(graph.ProjectNodes.First(n => GetProjectNumber(n) == projectNumber).ProjectInstance.FullPath); 1465var solutionConfigurationGlobalProperty = CreateSolutionConfigurationProperty(graph.ProjectNodes); 1480foreach (var node in graph.ProjectNodes.Where(n => referenceNumbers.Contains(GetProjectNumber(n)))) 1501StringShouldContainSubstring(logger.FullLog, $"{AssemblyMockCache}: GetCacheResultAsync for", graph.ProjectNodes.Count); 1544cache.QueryStartStops.Count.ShouldBe(graph.ProjectNodes.Count * 2);
SolutionFileBuilder.cs (1)
94Projects = graph.ProjectNodes.ToDictionary(