195 references to BuildEnvironmentHelper
Microsoft.Build (48)
BackEnd\BuildManager\BuildManager.cs (1)
1305
&&
BuildEnvironmentHelper
.Instance.RunningInVisualStudio
BackEnd\BuildManager\BuildParameters.cs (1)
1024
return
BuildEnvironmentHelper
.Instance.CurrentMSBuildExePath;
BackEnd\Components\BuildRequestEngine\BuildRequestEngine.cs (1)
843
if (!NativeMethodsShared.IsWindows ||
BuildEnvironmentHelper
.Instance.RunningInVisualStudio)
BackEnd\Components\Communications\CurrentHost.cs (1)
30
string dotnetExe = Path.Combine(FileUtilities.GetFolderAbove(
BuildEnvironmentHelper
.Instance.CurrentMSBuildToolsDirectory, 2),
BackEnd\Components\Communications\NodeProviderOutOfProc.cs (1)
72
CommunicationsUtilities.Trace("MSBUILDNODEHANDSHAKESALT=\"{0}\", msbuildDirectory=\"{1}\", enableNodeReuse={2}, enableLowPriority={3}", Traits.MSBuildNodeHandshakeSalt,
BuildEnvironmentHelper
.Instance.MSBuildToolsDirectory32, enableNodeReuse, enableLowPriority);
BackEnd\Components\Communications\NodeProviderOutOfProcTaskHost.cs (3)
410
s_baseTaskHostPath =
BuildEnvironmentHelper
.Instance.MSBuildToolsDirectory32;
411
s_baseTaskHostPath64 =
BuildEnvironmentHelper
.Instance.MSBuildToolsDirectory64;
412
s_baseTaskHostPathArm64 =
BuildEnvironmentHelper
.Instance.MSBuildToolsDirectoryArm64;
BackEnd\Components\ProjectCache\CacheContext.cs (1)
51
MSBuildExePath =
BuildEnvironmentHelper
.Instance.CurrentMSBuildExePath;
BackEnd\Components\SdkResolution\DefaultSdkResolver.cs (1)
33
string sdkPath = Path.Combine(
BuildEnvironmentHelper
.Instance.MSBuildSDKsPath, sdk.Name, "Sdk");
BackEnd\Components\SdkResolution\SdkResolverLoader.cs (2)
55
Path.Combine(
BuildEnvironmentHelper
.Instance.MSBuildToolsDirectory32, "SdkResolvers"), location);
82
Path.Combine(
BuildEnvironmentHelper
.Instance.MSBuildToolsDirectoryRoot, "SdkResolvers"), location);
BackEnd\Node\OutOfProcNode.cs (2)
476
NativeMethodsShared.SetCurrentDirectory(
BuildEnvironmentHelper
.Instance.CurrentMSBuildToolsDirectory);
710
NativeMethodsShared.SetCurrentDirectory(
BuildEnvironmentHelper
.Instance.CurrentMSBuildToolsDirectory);
BackEnd\Node\OutOfProcServerNode.cs (2)
252
NativeMethodsShared.SetCurrentDirectory(
BuildEnvironmentHelper
.Instance.CurrentMSBuildToolsDirectory);
426
NativeMethodsShared.SetCurrentDirectory(
BuildEnvironmentHelper
.Instance.CurrentMSBuildToolsDirectory);
BackEnd\Shared\BuildRequestConfiguration.cs (1)
450
BuildEnvironmentHelper
.Instance.CurrentMSBuildToolsDirectory);
BuildEnvironmentHelper.cs (1)
112
msbuildExePath = typeof(
BuildEnvironmentHelper
).Assembly.Location;
CommunicationsUtilities.cs (1)
103
string toolsDirectory =
BuildEnvironmentHelper
.Instance.MSBuildToolsDirectoryRoot;
Definition\ToolsetConfigurationReader.cs (3)
269
if (
BuildEnvironmentHelper
.Instance.Mode != BuildEnvironmentMode.None &&
275
FileSystems.Default.FileExists(
BuildEnvironmentHelper
.Instance.CurrentMSBuildConfigurationFile))
277
var configFile = new ExeConfigurationFileMap { ExeConfigFilename =
BuildEnvironmentHelper
.Instance.CurrentMSBuildConfigurationFile };
Definition\ToolsetLocalReader.cs (4)
28
protected override string MSBuildOverrideTasksPath =>
BuildEnvironmentHelper
.Instance.CurrentMSBuildToolsDirectory;
40
yield return new ToolsetPropertyDefinition(MSBuildConstants.ToolsPath,
BuildEnvironmentHelper
.Instance.CurrentMSBuildToolsDirectory, _sourceLocation);
41
yield return new ToolsetPropertyDefinition(MSBuildConstants.SdksPath,
BuildEnvironmentHelper
.Instance.MSBuildSDKsPath, _sourceLocation);
43
System.IO.Path.Combine(
BuildEnvironmentHelper
.Instance.CurrentMSBuildToolsDirectory, "Roslyn"),
Definition\ToolsetReader.cs (2)
170
var currentDir =
BuildEnvironmentHelper
.Instance.CurrentMSBuildToolsDirectory.TrimEnd(Path.DirectorySeparatorChar);
629
Path.Combine(
BuildEnvironmentHelper
.Instance.CurrentMSBuildToolsDirectory, trimmedValue));
Evaluation\Evaluator.cs (1)
784
if (
BuildEnvironmentHelper
.Instance.RunningInVisualStudio)
Evaluation\IntrinsicFunctions.cs (7)
661
return
BuildEnvironmentHelper
.Instance.CurrentMSBuildToolsDirectory;
666
return
BuildEnvironmentHelper
.Instance.MSBuildToolsDirectory32;
671
return
BuildEnvironmentHelper
.Instance.MSBuildToolsDirectory64;
676
return
BuildEnvironmentHelper
.Instance.MSBuildSDKsPath;
681
return
BuildEnvironmentHelper
.Instance.VisualStudioInstallRootDirectory;
691
return
BuildEnvironmentHelper
.Instance.MSBuildExtensionsPath;
694
public static bool IsRunningFromVisualStudio() =>
BuildEnvironmentHelper
.Instance.Mode == BuildEnvironmentMode.VisualStudio;
FrameworkLocationHelper.cs (3)
1045
DotNetFrameworkArchitecture.Bitness64 =>
BuildEnvironmentHelper
.Instance.MSBuildToolsDirectory64,
1046
DotNetFrameworkArchitecture.Bitness32 =>
BuildEnvironmentHelper
.Instance.MSBuildToolsDirectory32,
1047
_ =>
BuildEnvironmentHelper
.Instance.CurrentMSBuildToolsDirectory,
Instance\TaskRegistry.cs (3)
89
private static string s_potentialTasksV4Location = Path.Combine(
BuildEnvironmentHelper
.Instance.CurrentMSBuildToolsDirectory, s_tasksV4Filename);
108
private static string s_potentialTasksV12Location = Path.Combine(
BuildEnvironmentHelper
.Instance.CurrentMSBuildToolsDirectory, s_tasksV12Filename);
127
private static string s_potentialTasksCoreLocation = Path.Combine(
BuildEnvironmentHelper
.Instance.CurrentMSBuildToolsDirectory, s_tasksCoreFilename);
MSBuildLoadContext.cs (1)
99
var assemblyNameInExecutableDirectory = Path.Combine(
BuildEnvironmentHelper
.Instance.CurrentMSBuildToolsDirectory,
Utilities\NuGetFrameworkWrapper.cs (3)
203
string assemblyDirectory =
BuildEnvironmentHelper
.Instance.Mode == BuildEnvironmentMode.VisualStudio ?
204
Path.Combine(
BuildEnvironmentHelper
.Instance.VisualStudioInstallRootDirectory, "Common7", "IDE", "CommonExtensions", "Microsoft", "NuGet") :
205
BuildEnvironmentHelper
.Instance.CurrentMSBuildToolsDirectory;
Utilities\Utilities.cs (2)
479
string extensionsPath =
BuildEnvironmentHelper
.Instance.CurrentMSBuildToolsDirectory;
553
localAppData =
BuildEnvironmentHelper
.Instance.CurrentMSBuildToolsDirectory;
Microsoft.Build.Engine.UnitTests (144)
BuildEnvironmentHelper_Tests.cs (128)
30
string configFilePath =
BuildEnvironmentHelper
.Instance.CurrentMSBuildConfigurationFile.ToLowerInvariant();
31
string toolsDirectoryPath =
BuildEnvironmentHelper
.Instance.CurrentMSBuildToolsDirectory.ToLowerInvariant();
32
string actualMSBuildPath =
BuildEnvironmentHelper
.Instance.CurrentMSBuildExePath.ToLowerInvariant();
37
BuildEnvironmentHelper
.Instance.Mode.ShouldBe(BuildEnvironmentMode.Standalone);
50
BuildEnvironmentHelper
.ResetInstance_ForUnitTestsOnly(ReturnNull, ReturnNull, ReturnNull, env.VsInstanceMock, env.EnvironmentMock, () => false);
52
BuildEnvironmentHelper
.Instance.CurrentMSBuildToolsDirectory.ShouldBe(path);
53
BuildEnvironmentHelper
.Instance.CurrentMSBuildExePath.ShouldBe(msBuildPath);
54
BuildEnvironmentHelper
.Instance.CurrentMSBuildConfigurationFile.ShouldBe(msBuildConfig);
55
BuildEnvironmentHelper
.Instance.RunningInVisualStudio.ShouldBeFalse();
56
BuildEnvironmentHelper
.Instance.VisualStudioInstallRootDirectory.ShouldBeNull();
57
BuildEnvironmentHelper
.Instance.RunningTests.ShouldBeFalse();
58
BuildEnvironmentHelper
.Instance.Mode.ShouldBe(BuildEnvironmentMode.Standalone);
78
BuildEnvironmentHelper
.ResetInstance_ForUnitTestsOnly(ReturnNull, ReturnNull, ReturnNull, env.VsInstanceMock, env.EnvironmentMock, () => false);
80
BuildEnvironmentHelper
.Instance.Mode.ShouldBe(BuildEnvironmentMode.VisualStudio);
81
BuildEnvironmentHelper
.Instance.MSBuildExtensionsPath.ShouldBe(vsMSBuildDirectory);
82
BuildEnvironmentHelper
.Instance.CurrentMSBuildToolsDirectory.ShouldBe(msbuildBinDirectory);
83
BuildEnvironmentHelper
.Instance.CurrentMSBuildExePath.ShouldBe(msBuildPath);
84
BuildEnvironmentHelper
.Instance.CurrentMSBuildConfigurationFile.ShouldBe(msBuildConfig);
86
BuildEnvironmentHelper
.Instance.RunningInVisualStudio.ShouldBeFalse();
87
BuildEnvironmentHelper
.Instance.VisualStudioInstallRootDirectory.ShouldBe(env.TempFolderRoot);
88
BuildEnvironmentHelper
.Instance.RunningTests.ShouldBeFalse();
98
BuildEnvironmentHelper
.ResetInstance_ForUnitTestsOnly(() => env.MSBuildExePath, ReturnNull, ReturnNull, env.VsInstanceMock, env.EnvironmentMock, () => false);
100
BuildEnvironmentHelper
.Instance.MSBuildToolsDirectory32.ShouldBe(env.BuildDirectory);
101
BuildEnvironmentHelper
.Instance.MSBuildToolsDirectory64.ShouldBe(env.BuildDirectory64);
102
BuildEnvironmentHelper
.Instance.RunningInVisualStudio.ShouldBeFalse();
103
BuildEnvironmentHelper
.Instance.RunningTests.ShouldBeFalse();
104
BuildEnvironmentHelper
.Instance.Mode.ShouldBe(BuildEnvironmentMode.VisualStudio);
115
BuildEnvironmentHelper
.ResetInstance_ForUnitTestsOnly(() => env.MSBuildExePath, ReturnNull, ReturnNull, env.VsInstanceMock, env.EnvironmentMock, () => false);
117
BuildEnvironmentHelper
.Instance.MSBuildToolsDirectory32.ShouldBe(env.BuildDirectory);
118
BuildEnvironmentHelper
.Instance.MSBuildToolsDirectory64.ShouldBe(env.BuildDirectory);
119
BuildEnvironmentHelper
.Instance.RunningInVisualStudio.ShouldBeFalse();
120
BuildEnvironmentHelper
.Instance.RunningTests.ShouldBeFalse();
121
BuildEnvironmentHelper
.Instance.Mode.ShouldBe(BuildEnvironmentMode.Standalone);
131
BuildEnvironmentHelper
.ResetInstance_ForUnitTestsOnly(ReturnNull, () => env.MSBuildExePath, ReturnNull, env.VsInstanceMock, env.EnvironmentMock, () => false);
133
BuildEnvironmentHelper
.Instance.MSBuildToolsDirectory32.ShouldBe(env.BuildDirectory);
134
BuildEnvironmentHelper
.Instance.MSBuildToolsDirectory64.ShouldBe(env.BuildDirectory64);
135
BuildEnvironmentHelper
.Instance.RunningInVisualStudio.ShouldBeFalse();
136
BuildEnvironmentHelper
.Instance.RunningTests.ShouldBeFalse();
137
BuildEnvironmentHelper
.Instance.Mode.ShouldBe(BuildEnvironmentMode.VisualStudio);
148
BuildEnvironmentHelper
.ResetInstance_ForUnitTestsOnly(ReturnNull, () => env.MSBuildExePath, ReturnNull, env.VsInstanceMock, env.EnvironmentMock, () => false);
150
BuildEnvironmentHelper
.Instance.MSBuildToolsDirectory32.ShouldBe(env.BuildDirectory);
151
BuildEnvironmentHelper
.Instance.MSBuildToolsDirectory64.ShouldBe(env.BuildDirectory);
152
BuildEnvironmentHelper
.Instance.RunningInVisualStudio.ShouldBeFalse();
153
BuildEnvironmentHelper
.Instance.RunningTests.ShouldBeFalse();
154
BuildEnvironmentHelper
.Instance.Mode.ShouldBe(BuildEnvironmentMode.Standalone);
165
BuildEnvironmentHelper
.ResetInstance_ForUnitTestsOnly(ReturnNull, () => env.MSBuildExePath, ReturnNull, env.VsInstanceMock, env.EnvironmentMock, () => false);
167
BuildEnvironmentHelper
.Instance.MSBuildToolsDirectory32.ShouldBe(env.BuildDirectory);
168
BuildEnvironmentHelper
.Instance.MSBuildToolsDirectory64.ShouldBe(env.BuildDirectory);
169
BuildEnvironmentHelper
.Instance.RunningInVisualStudio.ShouldBeFalse();
170
BuildEnvironmentHelper
.Instance.RunningTests.ShouldBeFalse();
171
BuildEnvironmentHelper
.Instance.Mode.ShouldBe(BuildEnvironmentMode.Standalone);
181
BuildEnvironmentHelper
.ResetInstance_ForUnitTestsOnly(ReturnNull, ReturnNull, () => env.BuildDirectory, env.VsInstanceMock, env.EnvironmentMock, () => false);
184
Path.GetFileName(
BuildEnvironmentHelper
.Instance.CurrentMSBuildExePath).ShouldBe(MSBuildExeName);
186
BuildEnvironmentHelper
.Instance.MSBuildToolsDirectory32.ShouldBe(env.BuildDirectory);
187
BuildEnvironmentHelper
.Instance.MSBuildToolsDirectory64.ShouldBe(env.BuildDirectory);
188
BuildEnvironmentHelper
.Instance.RunningInVisualStudio.ShouldBeFalse();
189
BuildEnvironmentHelper
.Instance.RunningTests.ShouldBeFalse();
190
BuildEnvironmentHelper
.Instance.Mode.ShouldBe(BuildEnvironmentMode.Standalone);
200
BuildEnvironmentHelper
.ResetInstance_ForUnitTestsOnly(() => env.DevEnvPath, ReturnNull, ReturnNull, env.VsInstanceMock, env.EnvironmentMock, () => false);
202
BuildEnvironmentHelper
.Instance.MSBuildToolsDirectory32.ShouldBe(env.BuildDirectory);
203
BuildEnvironmentHelper
.Instance.MSBuildToolsDirectory64.ShouldBe(env.BuildDirectory64);
204
BuildEnvironmentHelper
.Instance.VisualStudioInstallRootDirectory.ShouldBe(env.TempFolderRoot);
205
BuildEnvironmentHelper
.Instance.RunningInVisualStudio.ShouldBeTrue();
206
BuildEnvironmentHelper
.Instance.RunningTests.ShouldBeFalse();
207
BuildEnvironmentHelper
.Instance.Mode.ShouldBe(BuildEnvironmentMode.VisualStudio);
220
BuildEnvironmentHelper
.ResetInstance_ForUnitTestsOnly(ReturnNull, ReturnNull, ReturnNull, env.VsInstanceMock, env.EnvironmentMock, () => false);
224
BuildEnvironmentHelper
.Instance.VisualStudioInstallRootDirectory.ShouldBe(env.TempFolderRoot);
225
BuildEnvironmentHelper
.Instance.Mode.ShouldBe(BuildEnvironmentMode.VisualStudio);
230
BuildEnvironmentHelper
.Instance.VisualStudioInstallRootDirectory.ShouldBeNull();
231
BuildEnvironmentHelper
.Instance.Mode.ShouldBe(BuildEnvironmentMode.None);
242
BuildEnvironmentHelper
.ResetInstance_ForUnitTestsOnly(() => env.MSBuildExePath, ReturnNull, ReturnNull, env.VsInstanceMock, env.EnvironmentMock, () => false);
244
BuildEnvironmentHelper
.Instance.VisualStudioInstallRootDirectory.ShouldBe(env.TempFolderRoot);
245
BuildEnvironmentHelper
.Instance.Mode.ShouldBe(BuildEnvironmentMode.VisualStudio);
255
BuildEnvironmentHelper
.ResetInstance_ForUnitTestsOnly(() => env.MSBuildExePath64, ReturnNull, ReturnNull, env.VsInstanceMock, env.EnvironmentMock, () => false);
257
BuildEnvironmentHelper
.Instance.VisualStudioInstallRootDirectory.ShouldBe(env.TempFolderRoot);
258
BuildEnvironmentHelper
.Instance.Mode.ShouldBe(BuildEnvironmentMode.VisualStudio);
274
BuildEnvironmentHelper
.ResetInstance_ForUnitTestsOnly(ReturnNull, ReturnNull, ReturnNull, env.VsInstanceMock, env.EnvironmentMock, () => false);
278
BuildEnvironmentHelper
.Instance.VisualStudioInstallRootDirectory.ShouldBe(env.TempFolderRoot);
279
BuildEnvironmentHelper
.Instance.Mode.ShouldBe(BuildEnvironmentMode.VisualStudio);
284
BuildEnvironmentHelper
.Instance.VisualStudioInstallRootDirectory.ShouldBeNull();
285
BuildEnvironmentHelper
.Instance.Mode.ShouldBe(BuildEnvironmentMode.None);
299
BuildEnvironmentHelper
.ResetInstance_ForUnitTestsOnly(ReturnNull, ReturnNull, ReturnNull, env.VsInstanceMock, env.EnvironmentMock, () => false);
301
BuildEnvironmentHelper
.Instance.VisualStudioInstallRootDirectory.ShouldBeNull();
302
BuildEnvironmentHelper
.Instance.Mode.ShouldBe(BuildEnvironmentMode.None);
309
BuildEnvironmentHelper
.Instance.RunningTests.ShouldBeTrue();
310
BuildEnvironmentHelper
.Instance.RunningInVisualStudio.ShouldBeFalse();
318
BuildEnvironmentHelper
.ResetInstance_ForUnitTestsOnly(() => env.DevEnvPath, () => env.MSBuildExePath, ReturnNull, env.VsInstanceMock, env.EnvironmentMock, () => false);
320
BuildEnvironmentHelper
.Instance.RunningInVisualStudio.ShouldBeTrue();
321
BuildEnvironmentHelper
.Instance.VisualStudioInstallRootDirectory.ShouldBe(env.TempFolderRoot);
322
BuildEnvironmentHelper
.Instance.Mode.ShouldBe(BuildEnvironmentMode.VisualStudio);
331
BuildEnvironmentHelper
.ResetInstance_ForUnitTestsOnly(() => env.BlendPath, () => env.MSBuildExePath, ReturnNull, env.VsInstanceMock, env.EnvironmentMock, () => false);
333
BuildEnvironmentHelper
.Instance.RunningInVisualStudio.ShouldBeTrue();
334
BuildEnvironmentHelper
.Instance.VisualStudioInstallRootDirectory.ShouldBe(env.TempFolderRoot);
335
BuildEnvironmentHelper
.Instance.Mode.ShouldBe(BuildEnvironmentMode.VisualStudio);
344
BuildEnvironmentHelper
.ResetInstance_ForUnitTestsOnly(() => env.DevEnvPath, ReturnNull,
347
BuildEnvironmentHelper
.Instance.MSBuildToolsDirectory32.ShouldBe(env.BuildDirectory);
348
BuildEnvironmentHelper
.Instance.MSBuildToolsDirectory64.ShouldBe(env.BuildDirectory64);
349
BuildEnvironmentHelper
.Instance.Mode.ShouldBe(BuildEnvironmentMode.VisualStudio);
360
BuildEnvironmentHelper
.ResetInstance_ForUnitTestsOnly(() => msBuild64Exe, ReturnNull, ReturnNull,
363
BuildEnvironmentHelper
.Instance.MSBuildToolsDirectory32.ShouldBe(env.BuildDirectory);
364
BuildEnvironmentHelper
.Instance.MSBuildToolsDirectory64.ShouldBe(Path.Combine(env.BuildDirectory, "amd64"));
365
BuildEnvironmentHelper
.Instance.VisualStudioInstallRootDirectory.ShouldBeNull();
366
BuildEnvironmentHelper
.Instance.Mode.ShouldBe(BuildEnvironmentMode.Standalone);
376
BuildEnvironmentHelper
.ResetInstance_ForUnitTestsOnly(() => env.MSBuildExePath, ReturnNull,
379
BuildEnvironmentHelper
.Instance.MSBuildToolsDirectory32.ShouldBe(env.BuildDirectory);
380
BuildEnvironmentHelper
.Instance.MSBuildToolsDirectory64.ShouldBe(Path.Combine(env.BuildDirectory, "amd64"));
381
BuildEnvironmentHelper
.Instance.Mode.ShouldBe(BuildEnvironmentMode.Standalone);
391
BuildEnvironmentHelper
.ResetInstance_ForUnitTestsOnly(() => env.MSBuildExePath64, ReturnNull, ReturnNull, env.VsInstanceMock, env.EnvironmentMock, () => false);
393
BuildEnvironmentHelper
.Instance.MSBuildToolsDirectory32.ShouldBe(env.BuildDirectory);
394
BuildEnvironmentHelper
.Instance.MSBuildToolsDirectory64.ShouldBe(env.BuildDirectory64);
395
BuildEnvironmentHelper
.Instance.VisualStudioInstallRootDirectory.ShouldBe(env.TempFolderRoot);
396
BuildEnvironmentHelper
.Instance.Mode.ShouldBe(BuildEnvironmentMode.VisualStudio);
406
BuildEnvironmentHelper
.ResetInstance_ForUnitTestsOnly(() => entryProcess, ReturnNull, ReturnNull,
409
BuildEnvironmentHelper
.Instance.CurrentMSBuildExePath.ShouldBe(entryProcess);
410
BuildEnvironmentHelper
.Instance.CurrentMSBuildToolsDirectory.ShouldBe(Path.GetDirectoryName(entryProcess));
411
BuildEnvironmentHelper
.Instance.VisualStudioInstallRootDirectory.ShouldBeNull();
412
BuildEnvironmentHelper
.Instance.Mode.ShouldBe(BuildEnvironmentMode.None);
423
BuildEnvironmentHelper
.ResetInstance_ForUnitTestsOnly(ReturnNull, () => msBuildAssembly, ReturnNull,
426
BuildEnvironmentHelper
.Instance.MSBuildToolsDirectory32.ShouldBe(env.BuildDirectory);
427
BuildEnvironmentHelper
.Instance.MSBuildToolsDirectory64.ShouldBe(env.BuildDirectory64);
428
BuildEnvironmentHelper
.Instance.VisualStudioInstallRootDirectory.ShouldBe(env.TempFolderRoot);
429
BuildEnvironmentHelper
.Instance.Mode.ShouldBe(BuildEnvironmentMode.VisualStudio);
440
BuildEnvironmentHelper
.ResetInstance_ForUnitTestsOnly(ReturnNull, () => msBuildAssembly, ReturnNull,
443
BuildEnvironmentHelper
.Instance.MSBuildToolsDirectory32.ShouldBe(env.BuildDirectory);
444
BuildEnvironmentHelper
.Instance.MSBuildToolsDirectory64.ShouldBe(env.BuildDirectory64);
445
BuildEnvironmentHelper
.Instance.VisualStudioInstallRootDirectory.ShouldBe(env.TempFolderRoot);
446
BuildEnvironmentHelper
.Instance.Mode.ShouldBe(BuildEnvironmentMode.VisualStudio);
564
BuildEnvironmentHelper
.ResetInstance_ForUnitTestsOnly(runningTests: () => true);
ChangeWaves_Tests.cs (1)
35
BuildEnvironmentHelper
.ResetInstance_ForUnitTestsOnly();
Instance\ProjectInstance_Internal_Tests.cs (1)
567
Directory.SetCurrentDirectory(
BuildEnvironmentHelper
.Instance.CurrentMSBuildToolsDirectory);
ProjectCache\ProjectCacheTests.cs (10)
54
BuildEnvironmentHelper
.Instance.CurrentMSBuildToolsDirectory,
551
var currentBuildEnvironment =
BuildEnvironmentHelper
.Instance;
555
BuildEnvironmentHelper
.ResetInstance_ForUnitTestsOnly(
621
BuildEnvironmentHelper
.ResetInstance_ForUnitTestsOnly(currentBuildEnvironment);
660
var currentBuildEnvironment =
BuildEnvironmentHelper
.Instance;
673
BuildEnvironmentHelper
.ResetInstance_ForUnitTestsOnly(
719
BuildEnvironmentHelper
.ResetInstance_ForUnitTestsOnly(currentBuildEnvironment);
1437
var currentBuildEnvironment =
BuildEnvironmentHelper
.Instance;
1441
BuildEnvironmentHelper
.ResetInstance_ForUnitTestsOnly(
1505
BuildEnvironmentHelper
.ResetInstance_ForUnitTestsOnly(currentBuildEnvironment);
TypeLoader_Dependencies_Tests.cs (1)
17
private static readonly string ProjectFileFolder = Path.Combine(
BuildEnvironmentHelper
.Instance.CurrentMSBuildToolsDirectory, "TaskWithDependency");
TypeLoader_Tests.cs (3)
21
private static readonly string ProjectFileFolder = Path.Combine(
BuildEnvironmentHelper
.Instance.CurrentMSBuildToolsDirectory, "PortableTask");
25
Path.Combine(
BuildEnvironmentHelper
.Instance.CurrentMSBuildToolsDirectory, "..", "..", "..", "Samples", "PortableTask"));
75
string dllPath = Path.Combine(
BuildEnvironmentHelper
.Instance.CurrentMSBuildToolsDirectory, dllName);
Microsoft.Build.UnitTests.Shared (3)
ObjectModelHelpers.cs (1)
1472
BuildEnvironmentHelper
.ResetInstance_ForUnitTestsOnly();
RunnerUtilities.cs (1)
19
public static string PathToCurrentlyRunningMsBuildExe =>
BuildEnvironmentHelper
.Instance.CurrentMSBuildExePath;
TestEnvironment.cs (1)
104
BuildEnvironmentHelper
.ResetInstance_ForUnitTestsOnly();