-
Notifications
You must be signed in to change notification settings - Fork 152
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Allow netcoreapp agent to work with non-standard dotnet install locations #941
Comments
@rprouse @mikkelbu @jnm2 @OsirisTerje AssumptionWhen different install locations are used for different versions of .NET, we assume that each location is intended to be independent of the others. For example, if I set up a special non-standard location for a .Net 7.0 RC, I want to test with only that framework available. If I want others, like .NET Core 3.1, to be available, I'll re-install that framework using the same non-standard location. Based on my experiments, I believe this is what the dotnet team intended, but I'll be happy if someone is in a position to contradict me. :-) Implementation
Note: If we are running under an isolated runtime download, not specified in the registry, our list will not contain the standard installation on the machine. Unfortunately, this is exactly the situation we are in when we run our CI.
NOTE: Scanning the directories guarantees that NUnit knows about all available runtimes even when running under an isolated installation. It may be possible to introduce some heuristics to skip this step but I want to include it initially to be sure. I'd definitely like to hear of any problems you see in this approach, but it seems to me that it should work fairly well. The runner will know about all runtimes installed in the normal way plus any isolated runtimes installed for testing, as we do for the 7.0 RC release. |
I have implemented this as described, allowing our own tests on AppVeyor to use an isolated installation of .NET 7.0 RC located on its path, while still accessing the versions of the runtime installed in the normal way. For 4.0, we may want to reconsider this approach since it's quite possible that some users may want an isolated installation to remain isolated for testing purposes. |
This issue has been resolved in version 3.16.0 The release is available on: |
Ref: #937 (comment)
Launching a netcoreapp agent currently relies on dotnet being installed in the default location. It could be good to look at alternatives that do not require that, possibly using
dotnet --list-runtimes
.If we do go ahead removing inprocess running, this may become an issue for the adapter - in that I suspect dotnet test currently supports non-default-location installations of dotnet, which we would break if agents needed to be launched.
The text was updated successfully, but these errors were encountered: