Skip to content

Commit 07ac1da

Browse files
committed
Update test
1 parent c2e9462 commit 07ac1da

1 file changed

Lines changed: 13 additions & 1 deletion

File tree

src/installer/tests/AppHost.Bundle.Tests/StaticHost.cs

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ private void NotMarkedAsBundle_RunSelfContainedApp()
2828
}
2929
}
3030

31-
[Fact]
31+
[ConditionalFact(typeof(StaticHost), nameof(CanCheckExpectedExports))]
3232
private void ExpectedExports()
3333
{
3434
string[] expectedExports =
@@ -79,5 +79,17 @@ private void ExpectedExports()
7979
}
8080
}
8181
}
82+
83+
private static bool CanCheckExpectedExports()
84+
{
85+
// On Windows we verify the exports by loading singlefilehost into the current
86+
// process. That only works when the built host architecture matches the test
87+
// process architecture.
88+
return !OperatingSystem.IsWindows()
89+
|| string.Equals(
90+
TestContext.BuildArchitecture,
91+
RuntimeInformation.ProcessArchitecture.ToString().ToLowerInvariant(),
92+
StringComparison.Ordinal);
93+
}
8294
}
8395
}

0 commit comments

Comments
 (0)