From 719d627a9e79ad9ed0255f1c6be1fc49cdffc88a Mon Sep 17 00:00:00 2001 From: Viktor Hofer Date: Thu, 6 Feb 2020 19:19:53 +0100 Subject: [PATCH] Enable .NET Framework F5 & VS TestExplorer support for libraries (#31873) * Enable .NET Framework F5 & TestExplorer Adding a launchSettings profile to enable .NET Framework F5 scenarios. Also setting the DEVPATH variable for the -vs hook to use the locally built .NET Framework runtime. * Set DEVPATH env in F5 --- eng/build.ps1 | 1 + eng/testing/launchSettings.json | 9 +++++++++ 2 files changed, 10 insertions(+) diff --git a/eng/build.ps1 b/eng/build.ps1 index c3109d07b60..81c417a34e7 100644 --- a/eng/build.ps1 +++ b/eng/build.ps1 @@ -85,6 +85,7 @@ if ($vs) { # This tells .NET Core to use the same dotnet.exe that build scripts use $env:DOTNET_ROOT="$PSScriptRoot\..\artifacts\bin\testhost\netcoreapp5.0-Windows_NT-$configuration-$archTestHost"; + $env:DEVPATH="$PSScriptRoot\..\artifacts\bin\testhost\net472-Windows_NT-$configuration-$archTestHost"; } # This tells MSBuild to load the SDK from the directory of the bootstrapped SDK diff --git a/eng/testing/launchSettings.json b/eng/testing/launchSettings.json index c215e10ba94..62d099feb3b 100644 --- a/eng/testing/launchSettings.json +++ b/eng/testing/launchSettings.json @@ -5,6 +5,15 @@ "executablePath": "$(TestHostRootPath)dotnet.exe", "commandLineArgs": "$(RunArguments) -parallel none", "workingDirectory": "$(RunWorkingDirectory)" + }, + ".NET Framework xUnit Console": { + "commandName": "Executable", + "executablePath": "$(RunWorkingDirectory)$(RunCommand)", + "commandLineArgs": "$(RunArguments) -parallel none", + "workingDirectory": "$(RunWorkingDirectory)", + "environmentVariables": { + "DEVPATH": "$(TestHostRootPath)" + } } } } -- 2.34.1