Re-enable components E2E tests on the CI
This commit is contained in:
parent
a69555ad96
commit
352df35864
|
|
@ -6,6 +6,7 @@ using System.Collections.Generic;
|
|||
using System.IO;
|
||||
using System.Linq;
|
||||
using System.Reflection;
|
||||
using System.Runtime.ExceptionServices;
|
||||
using System.Threading;
|
||||
|
||||
namespace Microsoft.AspNetCore.Components.E2ETest.Infrastructure.ServerFixtures
|
||||
|
|
@ -52,13 +53,30 @@ namespace Microsoft.AspNetCore.Components.E2ETest.Infrastructure.ServerFixtures
|
|||
{
|
||||
var isDone = new ManualResetEvent(false);
|
||||
|
||||
ExceptionDispatchInfo edi = null;
|
||||
new Thread(() =>
|
||||
{
|
||||
action();
|
||||
try
|
||||
{
|
||||
action();
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
edi = ExceptionDispatchInfo.Capture(ex);
|
||||
}
|
||||
|
||||
isDone.Set();
|
||||
}).Start();
|
||||
|
||||
isDone.WaitOne();
|
||||
if (!isDone.WaitOne(TimeSpan.FromSeconds(10)))
|
||||
{
|
||||
throw new TimeoutException("Timed out waiting for: " + action);
|
||||
}
|
||||
|
||||
if (edi != null)
|
||||
{
|
||||
throw edi.SourceException;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -24,6 +24,7 @@ namespace Microsoft.AspNetCore.Components.E2ETest.Infrastructure.ServerFixtures
|
|||
{
|
||||
// This can be null if creating the webhost throws, we don't want to throw here and hide
|
||||
// the original exception.
|
||||
Host?.Dispose();
|
||||
Host?.StopAsync();
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -7,12 +7,16 @@
|
|||
<TargetFramework>netcoreapp3.0</TargetFramework>
|
||||
<TestGroupName>Components.E2ETests</TestGroupName>
|
||||
|
||||
<SkipTests Condition="$(ContinuousIntegrationBuild) == 'true'" >true</SkipTests>
|
||||
<!-- https://github.com/aspnet/AspNetCore/issues/6857 -->
|
||||
<BuildHelixPayload>false</BuildHelixPayload>
|
||||
|
||||
<!-- Run on platforms where we support Selenium -->
|
||||
<SkipTests Condition="'$(SeleniumE2ETestsSupported)' != 'true'">true</SkipTests>
|
||||
|
||||
<!-- Tests do not work on Helix or when bin/ directory is not in project directory due to undeclared dependency on test content. -->
|
||||
<BaseOutputPath />
|
||||
|
||||
|
||||
<OutputPath />
|
||||
|
||||
</PropertyGroup>
|
||||
|
|
|
|||
Loading…
Reference in New Issue