3 writes to RelativePath
Microsoft.Build (3)
Construction\Solution\SolutionFile.cs (3)
379RelativePath = projectModel.FilePath, 1184RelativePath = Path.Combine(etpProjectRelativeDir, fileElementValue) 1519proj.RelativePath = match.Groups["RELATIVEPATH"].Value.Trim();
66 references to RelativePath
Microsoft.Build (23)
Construction\Solution\SolutionFile.cs (18)
407if (IsEtpProjectFile(proj.RelativePath)) 825if (Uri.TryCreate(proj.RelativePath, UriKind.Absolute, out Uri uri)) 897projectPaths.Add(FileUtilities.FixFilePath(project.RelativePath)); 1115if (IsEtpProjectFile(proj.RelativePath)) 1130string fullPathToEtpProj = Path.Combine(SolutionFileDirectory, etpProj.RelativePath); 1131string etpProjectRelativeDir = Path.GetDirectoryName(etpProj.RelativePath); 1190proj.ProjectName = proj.RelativePath; 1218etpProj.RelativePath, e.Message); 1227etpProj.RelativePath, e.Message); 1236etpProj.RelativePath, e.Message); 1245etpProj.RelativePath, e.Message); 1254etpProj.RelativePath, e.Message); 1289ErrorUtilities.VerifyThrow(proj.RelativePath != null, "Project relative path cannot be null."); 1292ProjectFileErrorUtilities.VerifyThrowInvalidProjectFile(proj.RelativePath.IndexOfAny(Path.GetInvalidPathChars()) == -1, 1296proj.ProjectName, proj.RelativePath); 1299ProjectFileErrorUtilities.VerifyThrowInvalidProjectFile(proj.RelativePath.Length > 0, 1567ProjectFileErrorUtilities.ThrowInvalidProjectFile(new BuildEventFileInfo(FullPath), "ProjectUpgradeNeededToVcxProj", proj.RelativePath); 1901return proj.RelativePath;
Construction\Solution\SolutionProjectGenerator.cs (5)
654if (!solutionFile.ProjectShouldBuild(project.RelativePath)) 1891project.RelativePath); 1902project.RelativePath, 2197new BuildEventFileInfo(project.RelativePath), 2199project.RelativePath,
Microsoft.Build.Engine.OM.UnitTests (11)
Construction\SolutionFile_Tests.cs (11)
104Assert.Equal(ConvertToUnixPathIfNeeded("Relative path\\to\\Project name.myvctype", convertToSlnx || isOptInSlnParsingWithNewParser), solution.ProjectsInOrder[0].RelativePath); 156Assert.Equal("src\\.proj", solution.ProjectsInOrder[0].RelativePath); 212Assert.Equal(ConvertToUnixPathIfNeeded("ConsoleApplication1\\ConsoleApplication1.vbproj", usesNewParser), consoleApplication1.RelativePath); 217Assert.Equal(ConvertToUnixPathIfNeeded("vbClassLibrary\\vbClassLibrary.vbproj", usesNewParser), vbClassLibrary.RelativePath); 222Assert.Equal(ConvertToUnixPathIfNeeded("ClassLibrary1\\ClassLibrary1.csproj", usesNewParser), classLibrary1.RelativePath); 296.FirstOrDefault(p => p.RelativePath == ConvertToUnixPathIfNeeded("ClassLibrary1\\ClassLibrary1.csproj", usesNewParser)); 302.FirstOrDefault(p => p.RelativePath == ConvertToUnixPathIfNeeded("MyPhysicalFolder\\ClassLibrary1\\ClassLibrary1.csproj", usesNewParser)); 307.FirstOrDefault(p => p.RelativePath == ConvertToUnixPathIfNeeded("ClassLibrary2\\ClassLibrary2.csproj", usesNewParser)); 386Assert.Equal(ConvertToUnixPathIfNeeded("ClassLibrary1\\ClassLibrary1.csproj", usesNewParser), classLibrary1.RelativePath); 391Assert.Equal(ConvertToUnixPathIfNeeded("ClassLibrary2\\ClassLibrary2.csproj", usesNewParser), classLibrary2.RelativePath); 398Assert.Equal(ConvertToUnixPathIfNeeded("ClassLibrary3\\ClassLibrary3.csproj", usesNewParser), solution.ProjectsInOrder[2].RelativePath);
Microsoft.Build.Engine.UnitTests (31)
Construction\SolutionFile_NewParser_Tests.cs (1)
89solution.ProjectsInOrder[0].RelativePath.ShouldBe(ConvertToUnixPathIfNeeded(@"C:\WebSites\WebApplication3\"));
Construction\SolutionFile_OldParser_Tests.cs (29)
44proj.RelativePath.ShouldBe("Relative path to project file"); 85proj.RelativePath.ShouldBe("Relative path\\to\\Project name.myvctype"); 104proj.RelativePath.ShouldBe("Relative path to project file"); 140Assert.Equal("Relative path to project file", solution.ProjectsInOrder[0].RelativePath); 160proj.RelativePath.ShouldBe("src\\.proj"); 205solution.ProjectsInOrder[0].RelativePath.ShouldBe(@"someproj.etp"); 206solution.ProjectsInOrder[1].RelativePath.ShouldBe(@"ClassLibrary2.csproj"); 395solution.ProjectsInOrder[0].RelativePath.ShouldBe(@"someproj.etp"); 396solution.ProjectsInOrder[1].RelativePath.ShouldBe(@"someproj2.etp"); 397solution.ProjectsInOrder[2].RelativePath.ShouldBe(@"ClassLibrary1.csproj"); 610solution.ProjectsInOrder[0].RelativePath.ShouldBe(@"someproj.etp"); 611solution.ProjectsInOrder[1].RelativePath.ShouldBe(@"someproj2.etp"); 612solution.ProjectsInOrder[2].RelativePath.ShouldBe(@"ETPProjUpgradeTest\someproj3.etp"); 613solution.ProjectsInOrder[3].RelativePath.ShouldBe(Path.Combine("ETPProjUpgradeTest", "..", "SomeFolder", "ClassLibrary1.csproj")); 723proj.RelativePath.ShouldBe("Relative path to project file"); 760Assert.Equal("Relative path to project file", solution.ProjectsInOrder[0].RelativePath); 786proj.RelativePath.ShouldBe(Path.Combine("RelativePath", "project file")); 985solution.ProjectsInOrder[0].RelativePath.ShouldBe(@"ConsoleApplication1\ConsoleApplication1.vbproj"); 993solution.ProjectsInOrder[1].RelativePath.ShouldBe(@"vbClassLibrary\vbClassLibrary.vbproj"); 1001solution.ProjectsInOrder[2].RelativePath.ShouldBe(@"ClassLibrary1\ClassLibrary1.csproj"); 1009solution.ProjectsInOrder[3].RelativePath.ShouldBe(@"cpsFsProject\ProjectFileName.fsproj"); 1071solution.ProjectsInOrder[0].RelativePath.ShouldBe(@"ClassLibrary1\ClassLibrary1.csproj"); 1083solution.ProjectsInOrder[2].RelativePath.ShouldBe(@"MyPhysicalFolder\ClassLibrary1\ClassLibrary1.csproj"); 1095solution.ProjectsInOrder[4].RelativePath.ShouldBe(@"ClassLibrary2\ClassLibrary2.csproj"); 1468solution.ProjectsInOrder[0].RelativePath.ShouldBe(@"ClassLibrary1\ClassLibrary1.csproj"); 1475solution.ProjectsInOrder[1].RelativePath.ShouldBe(@"ClassLibrary2\ClassLibrary2.csproj"); 1483solution.ProjectsInOrder[2].RelativePath.ShouldBe(@"ClassLibrary3\ClassLibrary3.csproj"); 1545solution.ProjectsInOrder[0].RelativePath.ShouldBe(@"C:\WebSites\WebApplication3\"); 2428solution.ProjectsInOrder[0].RelativePath.ShouldBe(expectedRelativePath);
Construction\SolutionProjectGenerator_Tests.cs (1)
2847projectInSolution.AbsolutePath.ShouldBe(Path.Combine(solution.SolutionFileDirectory, projectInSolution.RelativePath));
Microsoft.CodeAnalysis.Workspaces.MSBuild (1)
MSBuild\MSBuildProjectLoader.cs (1)
211projectPaths.Add(project.RelativePath);