Skip to content

Commit 7810dee

Browse files
committed
fix the new test by calling SetWaitNotificationRequired
1 parent b9f8d12 commit 7810dee

1 file changed

Lines changed: 5 additions & 0 deletions

File tree

  • src/libraries/System.Runtime/tests/System.IO.FileSystem.Tests/RandomAccess

src/libraries/System.Runtime/tests/System.IO.FileSystem.Tests/RandomAccess/Mixed.Windows.cs

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -190,6 +190,11 @@ public void SyncIOOnAsyncHandle_DoesNotCorruptMemory_WhenSynchronizationContextT
190190
/// </summary>
191191
private sealed class ThrowingSynchronizationContext : SynchronizationContext
192192
{
193+
public ThrowingSynchronizationContext()
194+
{
195+
SetWaitNotificationRequired();
196+
}
197+
193198
public override int Wait(IntPtr[] waitHandles, bool waitAll, int millisecondsTimeout)
194199
{
195200
throw new InvalidOperationException("SynchronizationContext.Wait threw an exception");

0 commit comments

Comments
 (0)