Skip to content
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

Architecture test improvement #3254

Merged
merged 1 commit into from
Jan 15, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -143,12 +143,12 @@ public void DOTNET_ROOTS_EnvironmentVariables(bool dotnetRoot, bool dotnetRootX6
}

// Verify switch using csproj
ExecuteApplication($"{privateX64Installation}/dotnet", $"test {projectPath} --framework net6.0 --arch x64", out stdOut, out stdError, out exitCode, env, projectDirectory);
ExecuteApplication($"{privateX64Installation}/{GetMuxerName}", $"test {projectPath} --framework net6.0 --arch x64", out stdOut, out stdError, out exitCode, env, projectDirectory);
AssertSwitch(stdOut);

// Verify switch using test container
var buildAssemblyPath = GetAssetFullPath("ArchitectureSwitch.dll", "net6.0");
ExecuteApplication($"{privateX64Installation}/dotnet", $"test {buildAssemblyPath} --framework net6.0 --arch x64", out stdOut, out stdError, out exitCode, env, projectDirectory);
ExecuteApplication($"{privateX64Installation}/{GetMuxerName}", $"test {buildAssemblyPath} --framework net6.0 --arch x64", out stdOut, out stdError, out exitCode, env, projectDirectory);
AssertSwitch(stdOut);

void AssertSwitch(string output)
Expand Down Expand Up @@ -185,12 +185,12 @@ public void PrivateX64BuildToGlobalArmInstallation()
Assert.IsTrue(stdOut.Contains("ProcessArchitecture: X64"), "Unexpected ProcessArchitecture");

// Verify switch using csproj
ExecuteApplication($"{privateX64Installation}/dotnet", $"test {projectPath} --framework net6.0 --arch arm64", out stdOut, out stdError, out exitCode, env, projectDirectory);
ExecuteApplication($"{privateX64Installation}/{GetMuxerName}", $"test {projectPath} --framework net6.0 --arch arm64", out stdOut, out stdError, out exitCode, env, projectDirectory);
AssertSwitch(stdOut);

// Verify switch using test container
var buildAssemblyPath = GetAssetFullPath("ArchitectureSwitch.dll", "net6.0");
ExecuteApplication($"{privateX64Installation}/dotnet", $"test {buildAssemblyPath} --framework net6.0 --arch arm64", out stdOut, out stdError, out exitCode, env, projectDirectory);
ExecuteApplication($"{privateX64Installation}/{GetMuxerName}", $"test {buildAssemblyPath} --framework net6.0 --arch arm64", out stdOut, out stdError, out exitCode, env, projectDirectory);
AssertSwitch(stdOut);

void AssertSwitch(string output)
Expand Down Expand Up @@ -240,12 +240,12 @@ public void PrivateX64BuildToDOTNET_ROOTS_EnvironmentVariables(bool dotnetRoot,
}

// Verify switch using csproj
ExecuteApplication($"{privateX64Installation}/dotnet", $"test {projectPath} --framework net6.0 --arch arm64", out stdOut, out stdError, out exitCode, env, projectDirectory);
ExecuteApplication($"{privateX64Installation}/{GetMuxerName}", $"test {projectPath} --framework net6.0 --arch arm64", out stdOut, out stdError, out exitCode, env, projectDirectory);
AssertSwitch(stdOut);

// Verify switch using test container
var buildAssemblyPath = GetAssetFullPath("ArchitectureSwitch.dll", "net6.0");
ExecuteApplication($"{privateX64Installation}/dotnet", $"test {buildAssemblyPath} --framework net6.0 --arch arm64", out stdOut, out stdError, out exitCode, env, projectDirectory);
ExecuteApplication($"{privateX64Installation}/{GetMuxerName}", $"test {buildAssemblyPath} --framework net6.0 --arch arm64", out stdOut, out stdError, out exitCode, env, projectDirectory);
AssertSwitch(stdOut);

void AssertSwitch(string output)
Expand Down