Browse Source

Uncomment test that should always fail

pull/11146/head
Max Katz 3 years ago
parent
commit
0f3a4b313c
  1. 17
      tests/Avalonia.Headless.UnitTests/ThreadingTests.cs

17
tests/Avalonia.Headless.UnitTests/ThreadingTests.cs

@ -16,14 +16,17 @@ public class ThreadingTests
{ {
Dispatcher.UIThread.VerifyAccess(); Dispatcher.UIThread.VerifyAccess();
} }
// This test should always fail, uncomment to test if it fails.
// [AvaloniaFact]
// public void Should_Fail_Test_On_Delayed_Post_When_FlushDispatcher()
// {
// Dispatcher.UIThread.Post(() => throw new InvalidOperationException(), DispatcherPriority.Default);
// }
#if NUNIT
[AvaloniaTest(Ignore = "This test should always fail, enable to test if it fails")]
#elif XUNIT
[AvaloniaFact(Skip = "This test should always fail, enable to test if it fails")]
#endif
public void Should_Fail_Test_On_Delayed_Post_When_FlushDispatcher()
{
Dispatcher.UIThread.Post(() => throw new InvalidOperationException(), DispatcherPriority.Default);
}
#if NUNIT #if NUNIT
[AvaloniaTheory, Timeout(10000), TestCase(1), TestCase(10), TestCase(100)] [AvaloniaTheory, Timeout(10000), TestCase(1), TestCase(10), TestCase(100)]
#elif XUNIT #elif XUNIT

Loading…
Cancel
Save