81 instantiations of ProjectGraph
Microsoft.Build (1)
BackEnd\BuildManager\BuildManager.cs (1)
1892
projectGraph = new
ProjectGraph
(
Microsoft.Build.Engine.UnitTests (79)
BackEnd\BuildManager_Tests.cs (3)
3590
return new
ProjectGraph
(projectFilePath, projectCollection);
4203
var graph = new
ProjectGraph
(project1);
4288
var graph = new
ProjectGraph
(project1);
Construction\SolutionFilter_Tests.cs (1)
132
ProjectGraph graphFromSolution =
new
(entryPoint, projectCollection);
Graph\GetCompatiblePlatformGraph_Tests.cs (11)
59
ProjectGraph graph = new
ProjectGraph
(entryProject.Path);
99
ProjectGraph graph = new
ProjectGraph
(entryProject.Path);
141
ProjectGraph graph = new
ProjectGraph
(entryProject.Path);
181
ProjectGraph graph = new
ProjectGraph
(entryProject.Path);
210
ProjectGraph graph = new
ProjectGraph
(entryProject.Path);
238
ProjectGraph graph = new
ProjectGraph
(entryProject.Path);
265
ProjectGraph graph = new
ProjectGraph
(entryProject.Path);
293
ProjectGraph graph = new
ProjectGraph
(entryProject.Path);
320
ProjectGraph graph = new
ProjectGraph
(entryProject.Path);
350
ProjectGraph graph = new
ProjectGraph
(entryProject.Path);
445
ProjectGraph graphFromSolution =
new
(entryPoint, projectCollection);
Graph\GraphLoadedFromSolution_tests.cs (8)
47
new
ProjectGraph
(files);
59
new
ProjectGraph
("nonExistent.sln");
83
var aggException = Should.Throw<AggregateException>(() => new
ProjectGraph
(root.Path));
254
var graph = new
ProjectGraph
(solutionFile);
509
graphFromSolution = new
ProjectGraph
(solutionFile);
596
var graph = new
ProjectGraph
(_env.CreateFile("solution.sln", solutionContents).Path);
620
var graph = new
ProjectGraph
(_env.CreateFile("solution.sln", solutionContents).Path);
683
var graphFromSolution = new
ProjectGraph
(
Graph\IsolateProjects_Tests.cs (1)
322
var projectGraph = new
ProjectGraph
(
Graph\ProjectGraph_Tests.cs (54)
50
var projectGraph = new
ProjectGraph
(Enumerable.Empty<ProjectGraphEntryPoint>());
65
var projectGraph = new
ProjectGraph
(entryProject.Path);
93
Should.Throw<CircularDependencyException>(() => new
ProjectGraph
(entryProject.Path));
105
var projectGraph = new
ProjectGraph
(
207
var aggException = Should.Throw<AggregateException>(() => new
ProjectGraph
(
230
ProjectGraph graph = new
ProjectGraph
(entryProject.Path);
259
ProjectGraph graph = new
ProjectGraph
(entryProject.Path);
310
Should.Throw<CircularDependencyException>(() => new
ProjectGraph
(entryProject.Path)).Message.ShouldContain(expectedErrorMessage);
322
Should.Throw<CircularDependencyException>(() => new
ProjectGraph
(entryProject.Path));
344
Should.Throw<CircularDependencyException>(() => new
ProjectGraph
(entryProject.Path)).Message.ShouldContain(errorMessage);
364
var graph = new
ProjectGraph
(
403
ProjectGraph graph = new
ProjectGraph
(entryProject.Path);
430
ProjectGraph graph = new
ProjectGraph
(entryProject.Path);
461
ProjectGraph graph = new
ProjectGraph
(entryProject.Path);
495
ProjectGraph graph = new
ProjectGraph
(
532
ProjectGraph graph = new
ProjectGraph
(entryProject.Path);
563
var aggException = Should.Throw<AggregateException>(() => new
ProjectGraph
(entryProject.Path));
578
var projectGraph = new
ProjectGraph
(new[] { entryProject1.Path, entryProject2.Path });
601
var projectGraph = new
ProjectGraph
(new[] { entryPoint1, entryPoint2 });
640
var projectGraph = new
ProjectGraph
(new[] { entryPoint1, entryPoint2 });
673
var projectGraph = new
ProjectGraph
(new[] { entryProject1.Path, entryProject2.Path, entryProject3.Path });
861
var projectGraph = new
ProjectGraph
(slnFile.Path);
924
var projectGraph = new
ProjectGraph
(entryProject.Path);
952
var projectGraph = new
ProjectGraph
(entryProject.Path);
983
var projectGraph = new
ProjectGraph
(entryProject.Path);
1005
var projectGraph = new
ProjectGraph
(entryProject.Path);
1023
var projectGraph = new
ProjectGraph
(entryProject.Path);
1046
var projectGraph = new
ProjectGraph
(entryProject.Path);
1069
var projectGraph = new
ProjectGraph
(entryProject.Path);
1086
var projectGraph = new
ProjectGraph
(entryProject.Path);
1109
var projectGraph = new
ProjectGraph
(root1);
1150
var projectGraph = new
ProjectGraph
(root1);
1184
var projectGraph = new
ProjectGraph
(root1);
1251
var graph = new
ProjectGraph
(entryProject);
1356
var projectGraph = new
ProjectGraph
(new[] { root1, root2 });
1394
var projectGraph = new
ProjectGraph
(entryProject.Path);
1417
var projectGraph = new
ProjectGraph
(entryProject.Path);
1447
var projectGraph = new
ProjectGraph
(entryProject.Path);
1504
var projectGraph = new
ProjectGraph
(entryProjectFile: entryProject.Path);
1632
var graph = new
ProjectGraph
(new HashSet<string> { entryProject1.Path, entryProject2.Path });
1884
var graph = new
ProjectGraph
(projectFile);
1911
var graph = new
ProjectGraph
(entryProject);
1945
var graph = new
ProjectGraph
(entryProject);
1978
var graph = new
ProjectGraph
(root);
1997
var graph = new
ProjectGraph
(root);
2025
var graph = new
ProjectGraph
(root);
2044
var graph = new
ProjectGraph
(root, new Dictionary<string, string> { { InnerBuildPropertyName, "foo" } });
2065
var graph = new
ProjectGraph
(root);
2092
var graph = new
ProjectGraph
(root);
2127
var graph = new
ProjectGraph
(new[]
2166
var graph = new
ProjectGraph
(root, additionalGlobalProperties);
2210
var graph = new
ProjectGraph
(new[] { root }, additionalGlobalProperties);
2873
ProjectGraph projectGraph =
new
(slnFile.Path);
2918
ProjectGraph projectGraph =
new
(slnFile.Path);
ProjectCache\ProjectCacheTests.cs (1)
1347
GraphBuildResult graphResult = buildSession.BuildGraph(new
ProjectGraph
(project.Path));
Microsoft.Build.UnitTests.Shared (1)
ObjectModelHelpers.cs (1)
1800
return new
ProjectGraph
(
134 references to ProjectGraph
Microsoft.Build (16)
BackEnd\BuildManager\BuildManager.cs (3)
1889
var
projectGraph = submission.BuildRequestData.ProjectGraph;
1970
static void DumpGraph(
ProjectGraph
graph, IReadOnlyDictionary<ProjectGraphNode, ImmutableList<string>>? targetList = null)
1984
ProjectGraph
projectGraph,
BackEnd\Components\ProjectCache\CacheContext.cs (3)
22
public
ProjectGraph
? Graph { get; }
31
ProjectGraph
? graph = null,
41
ProjectGraph
? graph = null,
BackEnd\Components\ProjectCache\ProjectCacheService.cs (3)
99
ProjectGraph
projectGraph,
160
ProjectGraph
? projectGraph,
195
ProjectGraph
? projectGraph,
Graph\GraphBuilder.cs (2)
51
private readonly
ProjectGraph
.ProjectInstanceFactoryFunc _projectInstanceFactory;
58
ProjectGraph
.ProjectInstanceFactoryFunc projectInstanceFactory,
Graph\GraphBuildRequestData.cs (4)
32
public GraphBuildRequestData(
ProjectGraph
projectGraph, ICollection<string> targetsToBuild)
43
public GraphBuildRequestData(
ProjectGraph
projectGraph, ICollection<string> targetsToBuild, HostServices? hostServices)
55
public GraphBuildRequestData(
ProjectGraph
projectGraph, ICollection<string> targetsToBuild, HostServices? hostServices, BuildRequestDataFlags flags)
180
public
ProjectGraph
? ProjectGraph { get; }
Graph\ProjectInterpretation.cs (1)
77
public IEnumerable<ReferenceInfo> GetReferences(ProjectGraphNode projectGraphNode, ProjectCollection projectCollection,
ProjectGraph
.ProjectInstanceFactoryFunc projectInstanceFactory)
Microsoft.Build.Engine.UnitTests (116)
BackEnd\BuildManager_Tests.cs (5)
177
var
graph = Helpers.CreateProjectGraph(
3585
private
ProjectGraph
CreateProjectGraph(string contents, ProjectCollection projectCollection)
4203
var
graph = new ProjectGraph(project1);
4288
var
graph = new ProjectGraph(project1);
4345
var
graph = Helpers.CreateProjectGraph(env: _env, dependencyEdges: new Dictionary<int, int[]> { { 1, new[] { 2, 3 } } });
Construction\SolutionFilter_Tests.cs (1)
132
ProjectGraph
graphFromSolution = new(entryPoint, projectCollection);
Graph\GetCompatiblePlatformGraph_Tests.cs (11)
59
ProjectGraph
graph = new ProjectGraph(entryProject.Path);
99
ProjectGraph
graph = new ProjectGraph(entryProject.Path);
141
ProjectGraph
graph = new ProjectGraph(entryProject.Path);
181
ProjectGraph
graph = new ProjectGraph(entryProject.Path);
210
ProjectGraph
graph = new ProjectGraph(entryProject.Path);
238
ProjectGraph
graph = new ProjectGraph(entryProject.Path);
265
ProjectGraph
graph = new ProjectGraph(entryProject.Path);
293
ProjectGraph
graph = new ProjectGraph(entryProject.Path);
320
ProjectGraph
graph = new ProjectGraph(entryProject.Path);
350
ProjectGraph
graph = new ProjectGraph(entryProject.Path);
445
ProjectGraph
graphFromSolution = new(entryPoint, projectCollection);
Graph\GraphLoadedFromSolution_tests.cs (8)
210
var
graph = CreateProjectGraph(_env, edges);
254
var
graph = new ProjectGraph(solutionFile);
484
var
graph = CreateProjectGraph(
505
ProjectGraph
graphFromSolution = null;
596
var
graph = new ProjectGraph(_env.CreateFile("solution.sln", solutionContents).Path);
620
var
graph = new ProjectGraph(_env.CreateFile("solution.sln", solutionContents).Path);
666
var
graph = CreateProjectGraph(_env, edges);
683
var
graphFromSolution = new ProjectGraph(
Graph\GraphTestingUtilities.cs (6)
42
ProjectGraph
graph,
131
internal static ProjectGraphNode GetFirstNodeWithProjectNumber(
ProjectGraph
graph, int projectNum)
136
internal static IEnumerable<ProjectGraphNode> GetNodesWithProjectNumber(
ProjectGraph
graph, int projectNum)
141
internal static ProjectGraphNode GetOuterBuild(
ProjectGraph
graph, int projectNumber)
146
internal static IReadOnlyCollection<ProjectGraphNode> GetInnerBuilds(
ProjectGraph
graph, int projectNumber)
232
internal static void AssertReferencesIgnoringOrder(this
ProjectGraph
graph, Dictionary<int, int[]> expectedReferencesForNode)
Graph\IsolateProjects_Tests.cs (1)
322
var
projectGraph = new ProjectGraph(
Graph\ProjectGraph_Tests.cs (64)
50
var
projectGraph = new ProjectGraph(Enumerable.Empty<ProjectGraphEntryPoint>());
65
var
projectGraph = new ProjectGraph(entryProject.Path);
74
var
graph = Helpers.CreateProjectGraph(
105
var
projectGraph = new ProjectGraph(
111
return
ProjectGraph
.StaticProjectInstanceFactory(
230
ProjectGraph
graph = new ProjectGraph(entryProject.Path);
259
ProjectGraph
graph = new ProjectGraph(entryProject.Path);
364
var
graph = new ProjectGraph(
403
ProjectGraph
graph = new ProjectGraph(entryProject.Path);
430
ProjectGraph
graph = new ProjectGraph(entryProject.Path);
461
ProjectGraph
graph = new ProjectGraph(entryProject.Path);
495
ProjectGraph
graph = new ProjectGraph(
532
ProjectGraph
graph = new ProjectGraph(entryProject.Path);
578
var
projectGraph = new ProjectGraph(new[] { entryProject1.Path, entryProject2.Path });
601
var
projectGraph = new ProjectGraph(new[] { entryPoint1, entryPoint2 });
640
var
projectGraph = new ProjectGraph(new[] { entryPoint1, entryPoint2 });
673
var
projectGraph = new ProjectGraph(new[] { entryProject1.Path, entryProject2.Path, entryProject3.Path });
861
var
projectGraph = new ProjectGraph(slnFile.Path);
924
var
projectGraph = new ProjectGraph(entryProject.Path);
952
var
projectGraph = new ProjectGraph(entryProject.Path);
983
var
projectGraph = new ProjectGraph(entryProject.Path);
1005
var
projectGraph = new ProjectGraph(entryProject.Path);
1023
var
projectGraph = new ProjectGraph(entryProject.Path);
1046
var
projectGraph = new ProjectGraph(entryProject.Path);
1069
var
projectGraph = new ProjectGraph(entryProject.Path);
1086
var
projectGraph = new ProjectGraph(entryProject.Path);
1109
var
projectGraph = new ProjectGraph(root1);
1150
var
projectGraph = new ProjectGraph(root1);
1184
var
projectGraph = new ProjectGraph(root1);
1251
var
graph = new ProjectGraph(entryProject);
1356
var
projectGraph = new ProjectGraph(new[] { root1, root2 });
1375
void AssertMultitargetingNode(int projectNumber,
ProjectGraph
projectGraph, IReadOnlyDictionary<ProjectGraphNode, ImmutableList<string>> targetLists, string[] outerBuildTargets, string[] nonOuterBuildTargets)
1394
var
projectGraph = new ProjectGraph(entryProject.Path);
1417
var
projectGraph = new ProjectGraph(entryProject.Path);
1447
var
projectGraph = new ProjectGraph(entryProject.Path);
1504
var
projectGraph = new ProjectGraph(entryProjectFile: entryProject.Path);
1520
ProjectGraph
graph = Helpers.CreateProjectGraph(
1572
ProjectGraph
graph = Helpers.CreateProjectGraph(
1632
var
graph = new ProjectGraph(new HashSet<string> { entryProject1.Path, entryProject2.Path });
1811
var
projectGraph = Helpers.CreateProjectGraph(env, edges);
1832
var
graph = Helpers.CreateProjectGraph(
1884
var
graph = new ProjectGraph(projectFile);
1911
var
graph = new ProjectGraph(entryProject);
1945
var
graph = new ProjectGraph(entryProject);
1978
var
graph = new ProjectGraph(root);
1997
var
graph = new ProjectGraph(root);
2025
var
graph = new ProjectGraph(root);
2044
var
graph = new ProjectGraph(root, new Dictionary<string, string> { { InnerBuildPropertyName, "foo" } });
2065
var
graph = new ProjectGraph(root);
2092
var
graph = new ProjectGraph(root);
2127
var
graph = new ProjectGraph(new[]
2166
var
graph = new ProjectGraph(root, additionalGlobalProperties);
2210
var
graph = new ProjectGraph(new[] { root }, additionalGlobalProperties);
2327
var
projectGraph = Helpers.CreateProjectGraph(env, edges, globalProperties, entryPoints: entryPoints);
2346
var
projectGraph = Helpers.CreateProjectGraph(
2359
var
graph = Helpers.CreateProjectGraph(
2487
var
graph = Helpers.CreateProjectGraph(
2498
var
graph = Helpers.CreateProjectGraph(
2561
var
graph = Helpers.CreateProjectGraph(
2667
var
graph = Helpers.CreateProjectGraph(
2709
var
graph = Helpers.CreateProjectGraph(
2752
ProjectGraph
graph = Helpers.CreateProjectGraph(
2873
ProjectGraph
projectGraph = new(slnFile.Path);
2918
ProjectGraph
projectGraph = new(slnFile.Path);
ProjectCache\ProjectCacheTests.cs (19)
107
public
ProjectGraph
CreateGraph(TestEnvironment env)
457
var
graph = testData.CreateGraph(_env);
483
var
graph = testData.CreateGraph(_env);
518
(MockLogger logger,
ProjectGraph
graph, Dictionary<ProjectGraphNode, BuildResult> nodesToBuildResults) = BuildGraphVsScenario(testData, buildParameters);
536
(MockLogger logger,
ProjectGraph
graph, _) = BuildGraphVsScenario(testData, assertBuildResults: false);
542
private (MockLogger logger,
ProjectGraph
projectGraph, Dictionary<ProjectGraphNode, BuildResult> nodesToBuildResults) BuildGraphVsScenario(
549
ProjectGraph
graph;
682
var
graph = testData.CreateGraph(_env);
740
var
graph = testData.CreateGraph(_env);
772
ProjectGraph
graph,
915
var
graph = testData.CreateGraph(_env);
946
var
graph = testData.CreateGraph(_env);
991
var
graph = testData.CreateGraph(_env);
1021
var
graph = Helpers.CreateProjectGraph(
1053
var
graph = Helpers.CreateProjectGraph(
1229
var
graph = Helpers.CreateProjectGraph(
1368
var
graph = testData.CreateGraph(_env);
1461
var
graph = testData.CreateGraph(_env);
1524
var
graph = testData.CreateGraph(_env);
SolutionFileBuilder.cs (1)
87
ProjectGraph
graph,
Microsoft.Build.UnitTests.Shared (2)
ObjectModelHelpers.cs (2)
1740
public static
ProjectGraph
CreateProjectGraph(
2130
public GraphBuildResult BuildGraph(
ProjectGraph
graph, string[] entryTargets = null)