[main] Fix dll detection in dotnet test#51264
[main] Fix dll detection in dotnet test#51264github-actions[bot] wants to merge 17 commits intomainfrom
Conversation
|
I don't think this needs to be manually ported to main. This should flow from release/10.0.1xx automatically to release/10.0.2xx (example PR: #51262), then from release/10.0.2xx to main. |
|
I thought that as well, but it was merged 3 weeks and still is not in main. The flow started only 7 hours ago. More people are hitting this now, so probably merging it directly won't hurt. |
| if (arg.EndsWith(".dll", StringComparison.OrdinalIgnoreCase) || arg.EndsWith(".exe", StringComparison.OrdinalIgnoreCase)) | ||
| { | ||
| var previousArg = i > 0 ? args[i - 1] : null; | ||
| if (previousArg != null && CommonOptions.PropertiesOption.Aliases.Contains(previousArg)) |
There was a problem hiding this comment.
This approach will probably not work for #51249 as the dll isn't provided in -p. We probably need to get a proper fix soon and get approval for getting a fix for GA?
|
Merging directly never hurts, especially to |
| foreach (string arg in args) | ||
| for (int i = 0; i < args.Length; i++) | ||
| { | ||
| if (!arg.StartsWith("-") && |
There was a problem hiding this comment.
We shouldn't have removed this StartsWith check. This is likely the cause of #51249.
There was a problem hiding this comment.
the whole parsing changes, so if -dl is not split the same way -p is then the argument is no longer one string "-p:something.dll"
but instead it is
"-p", "something.dll"
essentially there is additioanl split on :, but maybe that parser is only applicable to property, I think I pointed to it in the issue. Will have to look , and add test for it.
|
/azp run |
|
Azure Pipelines successfully started running 1 pipeline(s). |
|
Same issue as #51284 |
|
Fixes flowed to main |
Backport of #50926 to main
/cc @nohwnd