4 instantiations of BuildEnvironment
Aspire.Workload.Tests (4)
BuildAndRunTemplateTests.cs (1)
132
var testSpecificBuildEnvironment = new
BuildEnvironment
(BuildEnvironment.ForDefaultFramework);
tests\Shared\WorkloadTesting\BuildEnvironment.cs (3)
39
new
BuildEnvironment
(
44
new
BuildEnvironment
(
49
new
BuildEnvironment
(
48 references to BuildEnvironment
Aspire.Workload.Tests (48)
AppHostTemplateTests.cs (1)
25
BuildEnvironment
.ForDefaultFramework,
BuildAndRunTemplateTests.cs (6)
37
buildEnvironment:
BuildEnvironment
.ForDefaultFramework,
49
await using var project = await AspireProject.CreateNewTemplateProjectAsync(id, "aspire", _testOutput, buildEnvironment:
BuildEnvironment
.ForDefaultFramework);
66
await using var project = await AspireProject.CreateNewTemplateProjectAsync(id, "aspire", _testOutput, buildEnvironment:
BuildEnvironment
.ForDefaultFramework);
121
buildEnvironment:
BuildEnvironment
.ForDefaultFramework);
132
var
testSpecificBuildEnvironment = new BuildEnvironment(
BuildEnvironment
.ForDefaultFramework);
NewUpAndBuildStandaloneTemplateTests.cs (4)
18
var
buildEnvToUse = sdk switch
20
TestSdk.Current =>
BuildEnvironment
.ForCurrentSdkOnly,
21
TestSdk.Previous =>
BuildEnvironment
.ForPreviousSdkOnly,
22
TestSdk.CurrentSdkAndPreviousRuntime =>
BuildEnvironment
.ForCurrentSdkAndPreviousRuntime,
NewUpAndBuildSupportProjectTemplatesTests.cs (4)
22
var
buildEnvToUse = sdk switch
24
TestSdk.Current =>
BuildEnvironment
.ForCurrentSdkOnly,
25
TestSdk.Previous =>
BuildEnvironment
.ForPreviousSdkOnly,
26
TestSdk.CurrentSdkAndPreviousRuntime =>
BuildEnvironment
.ForCurrentSdkAndPreviousRuntime,
PerTestFrameworkTemplatesTests.cs (1)
38
buildEnvironment:
BuildEnvironment
.ForDefaultFramework);
StarterTemplateProjectNamesTests.cs (1)
40
BuildEnvironment
.ForDefaultFramework,
TemplateAppFixture.cs (1)
43
buildEnvironment:
BuildEnvironment
.ForDefaultFramework,
tests\Shared\WorkloadTesting\AspireProject.cs (9)
22
Path.Combine(
BuildEnvironment
.TestAssetsPath, "nuget8.config");
39
private readonly
BuildEnvironment
_buildEnv;
41
public AspireProject(string id, string baseDir, ITestOutputHelper testOutput,
BuildEnvironment
buildEnv, TestTargetFramework? tfm = default)
48
TargetFramework = tfm ??
BuildEnvironment
.DefaultTargetFramework;
75
BuildEnvironment
buildEnvironment,
81
string rootDir = Path.Combine(
BuildEnvironment
.TestRootPath, id);
82
string logPath = Path.Combine(
BuildEnvironment
.ForDefaultFramework.LogRootPath, id);
85
var tfmToUse = targetFramework ??
BuildEnvironment
.DefaultTargetFramework;
133
File.Copy(Path.Combine(
BuildEnvironment
.TestAssetsPath, "EndPointWriterHook_cs"), Path.Combine(project.AppHostProjectDirectory, "EndPointWriterHook.cs"));
tests\Shared\WorkloadTesting\BuildEnvironment.cs (8)
38
private static readonly Lazy<
BuildEnvironment
> s_instance_80 = new(() =>
43
private static readonly Lazy<
BuildEnvironment
> s_instance_90 = new(() =>
48
private static readonly Lazy<
BuildEnvironment
> s_instance_90_80 = new(() =>
53
public static
BuildEnvironment
ForPreviousSdkOnly => s_instance_80.Value;
54
public static
BuildEnvironment
ForCurrentSdkOnly => s_instance_90.Value;
55
public static
BuildEnvironment
ForCurrentSdkAndPreviousRuntime => s_instance_90_80.Value;
57
public static
BuildEnvironment
ForDefaultFramework { get; } = DefaultTargetFramework switch
252
public BuildEnvironment(
BuildEnvironment
otherBuildEnvironment)
tests\Shared\WorkloadTesting\DotNetCommand.cs (4)
10
protected readonly
BuildEnvironment
_buildEnvironment;
13
public DotNetCommand(ITestOutputHelper _testOutput, bool useDefaultArgs = true,
BuildEnvironment
? buildEnv = null, string label = "")
14
: base((buildEnv ??
BuildEnvironment
.ForDefaultFramework).DotNet, _testOutput, label)
16
_buildEnvironment = buildEnv ??
BuildEnvironment
.ForDefaultFramework;
tests\Shared\WorkloadTesting\DotNetNewCommand.cs (1)
15
BuildEnvironment
? buildEnv = null,
tests\Shared\WorkloadTesting\RunCommand.cs (1)
10
public RunCommand(ITestOutputHelper _testOutput,
BuildEnvironment
? buildEnv = null, string label="") : base(_testOutput, false, buildEnv, label)
tests\Shared\WorkloadTesting\TemplateCustomHive.cs (5)
28
var customHiveBaseDirectory =
BuildEnvironment
.IsRunningOnCI
35
public async Task EnsureInstalledAsync(
BuildEnvironment
buildEnvironment)
37
if (
BuildEnvironment
.IsRunningOnCI && File.Exists(_stampFilePath))
106
.WithWorkingDirectory(
BuildEnvironment
.IsRunningOnCI
108
: Path.Combine(
BuildEnvironment
.TempDir, "templates", "working")); // avoid running from the repo
WorkloadTestsBase.cs (2)
52
BuildEnvironment
? buildEnvironment = null,
56
buildEnvironment ??=
BuildEnvironment
.ForDefaultFramework;