diff --git a/src/libraries/System.Net.Http/tests/FunctionalTests/HttpClientTest.cs b/src/libraries/System.Net.Http/tests/FunctionalTests/HttpClientTest.cs index f8307a6bac3c8e..50f237a1dac7ed 100644 --- a/src/libraries/System.Net.Http/tests/FunctionalTests/HttpClientTest.cs +++ b/src/libraries/System.Net.Http/tests/FunctionalTests/HttpClientTest.cs @@ -1117,10 +1117,10 @@ await IgnoreExceptions(async () => [Fact] [OuterLoop] - [ActiveIssue("https://github.com/dotnet/runtime/issues/39056")] [SkipOnPlatform(TestPlatforms.Android, "Synchronous Send is not supported on Android")] public async Task Send_TimeoutRequestContent_Throws() { + var semaphore = new SemaphoreSlim(0); await LoopbackServer.CreateClientAndServerAsync( async uri => { @@ -1146,12 +1146,14 @@ await LoopbackServer.CreateClientAndServerAsync( TaskCanceledException ex = await Assert.ThrowsAsync(() => sendTask); Assert.IsType(ex.InnerException); + semaphore.Release(); }, async server => { await server.AcceptConnectionAsync(async connection => { await IgnoreExceptions(connection.ReadRequestDataAsync()); + await semaphore.WaitAsync(); }); }); }