Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

[xharness] Process '$(RootTestsDirectory)' before bailing due to any other variables when resolving paths in project files. #9467

Merged
merged 1 commit into from
Aug 24, 2020
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -971,15 +971,15 @@ public static void ResolveAllPaths (this XmlDocument csproj, string project_path
if (input [0] == '/')
return input; // This is already a full path.

// Don't process anything that starts with a variable, it's either a full path already, or the variable will be updated according to the new location
if (input.StartsWith ("$(", StringComparison.Ordinal))
return input;

input = input.Replace ('\\', '/'); // make unix-style

if (rootDirectory != null)
input = input.Replace ("$(RootTestsDirectory)", rootDirectory);

// Don't process anything that starts with a variable, it's either a full path already, or the variable will be updated according to the new location
if (input.StartsWith ("$(", StringComparison.Ordinal))
return input;

input = System.IO.Path.GetFullPath (System.IO.Path.Combine (dir, input));
input = input.Replace ('/', '\\'); // make windows-style again
return input;
Expand Down