81 references to ReadAsByteArrayAsync
Aspire.Dashboard.Tests (6)
Integration\OtlpHttpServiceTests.cs (5)
50var response = ExportLogsServiceResponse.Parser.ParseFrom(await responseMessage.Content.ReadAsByteArrayAsync().DefaultTimeout()); 176var response = ExportLogsServiceResponse.Parser.ParseFrom(await responseMessage.Content.ReadAsByteArrayAsync().DefaultTimeout()); 291var response = ExportLogsServiceResponse.Parser.ParseFrom(await responseMessage.Content.ReadAsByteArrayAsync()); 320var response = ExportTraceServiceResponse.Parser.ParseFrom(await responseMessage.Content.ReadAsByteArrayAsync().DefaultTimeout()); 349var response = ExportMetricsServiceResponse.Parser.ParseFrom(await responseMessage.Content.ReadAsByteArrayAsync().DefaultTimeout());
Integration\StartupTests.cs (1)
410var response = ExportLogsServiceResponse.Parser.ParseFrom(await responseMessage.Content.ReadAsByteArrayAsync().DefaultTimeout());
Diagnostics.FunctionalTests (1)
WelcomePageSampleTest.cs (1)
25var bytes = await response.Content.ReadAsByteArrayAsync();
IIS.FunctionalTests (2)
src\Servers\IIS\IIS\test\Common.FunctionalTests\RequestResponseTests.cs (2)
138await response.Content.ReadAsByteArrayAsync()); 156await response.Content.ReadAsByteArrayAsync());
IIS.Tests (1)
ResponseBodySizeTests.cs (1)
28var content = await response.Content.ReadAsByteArrayAsync();
IISExpress.FunctionalTests (2)
src\Servers\IIS\IIS\test\Common.FunctionalTests\RequestResponseTests.cs (2)
138await response.Content.ReadAsByteArrayAsync()); 156await response.Content.ReadAsByteArrayAsync());
Infrastructure.Common (2)
ServiceUtilHelper.cs (2)
557return response.Content.ReadAsByteArrayAsync().GetAwaiter().GetResult(); 569return await response.Content.ReadAsByteArrayAsync();
Interop.FunctionalTests (3)
Http3\Http3RequestTests.cs (3)
390await response.Content.ReadAsByteArrayAsync(); 635await response.Content.ReadAsByteArrayAsync(); 2166var data = await response.Content.ReadAsByteArrayAsync();
Microsoft.AspNetCore.Http.Connections.Client (1)
HttpConnection.cs (1)
489var responseBuffer = await response.Content.ReadAsByteArrayAsync().ConfigureAwait(false);
Microsoft.AspNetCore.Mvc.FunctionalTests (4)
BasicTests.cs (2)
198var responseBytes = await response.Content.ReadAsByteArrayAsync(); 214var responseBytes = await response.Content.ReadAsByteArrayAsync();
VersioningTestsBase.cs (2)
207var body = await response.Content.ReadAsByteArrayAsync(); 258var body = await response.Content.ReadAsByteArrayAsync();
Microsoft.AspNetCore.ResponseCompression.Tests (3)
ResponseCompressionMiddlewareTest.cs (3)
479Assert.Equal(expectedLength, (await response.Content.ReadAsByteArrayAsync()).Length); 542Assert.Equal(expectedLength, (await response.Content.ReadAsByteArrayAsync()).Length); 605Assert.Equal(expectedLength, (await response.Content.ReadAsByteArrayAsync()).Length);
Microsoft.AspNetCore.Server.HttpSys.FunctionalTests (30)
Listener\ResponseBodyTests.cs (5)
48Assert.Equal(new byte[10], await response.Content.ReadAsByteArrayAsync()); 72Assert.Equal(20, (await response.Content.ReadAsByteArrayAsync()).Length); 97Assert.Equal(new byte[0], await response.Content.ReadAsByteArrayAsync()); 118Assert.Equal(new byte[20], await response.Content.ReadAsByteArrayAsync()); 140Assert.Equal(new byte[20], await response.Content.ReadAsByteArrayAsync());
ResponseBodyTests.cs (11)
85Assert.True(0 < (await response.Content.ReadAsByteArrayAsync()).Length); 104Assert.True(0 < (await response.Content.ReadAsByteArrayAsync()).Length); 125Assert.Equal(new byte[20], await response.Content.ReadAsByteArrayAsync()); 158var bytes = await response.Content.ReadAsByteArrayAsync(); 182Assert.Equal(new byte[20], await response.Content.ReadAsByteArrayAsync()); 229Assert.Equal(new byte[30], await response.Content.ReadAsByteArrayAsync()); 309Assert.Equal(new byte[10], await response.Content.ReadAsByteArrayAsync()); 340Assert.Equal(new byte[10], await response.Content.ReadAsByteArrayAsync()); 368Assert.Equal(new byte[10], await response.Content.ReadAsByteArrayAsync()); 395Assert.Equal(new byte[10], await response.Content.ReadAsByteArrayAsync()); 430var payload = await response.Content.ReadAsByteArrayAsync();
ResponseCachingTests.cs (1)
478Assert.Equal(new byte[10], await response.Content.ReadAsByteArrayAsync());
ResponseSendFileTests.cs (13)
76Assert.Equal(FileLength, (await response.Content.ReadAsByteArrayAsync()).Length); 95Assert.Equal(FileLength, (await response.Content.ReadAsByteArrayAsync()).Length); 114Assert.Equal(FileLength, (await response.Content.ReadAsByteArrayAsync()).Length); 134Assert.Equal(FileLength * 2, (await response.Content.ReadAsByteArrayAsync()).Length); 153Assert.Equal(FileLength / 2, (await response.Content.ReadAsByteArrayAsync()).Length); 210Assert.Empty((await response.Content.ReadAsByteArrayAsync())); 231Assert.Equal(FileLength, (await response.Content.ReadAsByteArrayAsync()).Length); 252Assert.Equal(10, (await response.Content.ReadAsByteArrayAsync()).Length); 273Assert.Empty((await response.Content.ReadAsByteArrayAsync())); 301Assert.Equal(10, (await response.Content.ReadAsByteArrayAsync()).Length); 324Assert.Equal(10, (await response.Content.ReadAsByteArrayAsync()).Length); 346Assert.Equal(FileLength * 2, (await response.Content.ReadAsByteArrayAsync()).Length); 364Assert.Equal(FileLength * 2, (await response.Content.ReadAsByteArrayAsync()).Length);
Microsoft.AspNetCore.SignalR.Client.Tests (3)
LongPollingTransportTests.cs (2)
470sentRequests.Add(await request.Content.ReadAsByteArrayAsync()); 538sentRequests.Add(await request.Content.ReadAsByteArrayAsync());
TestHttpMessageHandler.cs (1)
244var data = await request.Content.ReadAsByteArrayAsync();
Microsoft.AspNetCore.StaticFiles.FunctionalTests (4)
FallbackStaticFileTest.cs (2)
66var responseContent = await response.Content.ReadAsByteArrayAsync(); 115var responseContent = await response.Content.ReadAsByteArrayAsync();
StaticFileMiddlewareTests.cs (2)
160var responseContent = await response.Content.ReadAsByteArrayAsync(); 207Assert.Empty((await response.Content.ReadAsByteArrayAsync()));
Microsoft.AspNetCore.StaticFiles.Tests (11)
DefaultFilesMiddlewareTests.cs (1)
269Assert.Empty((await response.Content.ReadAsByteArrayAsync()));
DirectoryBrowserMiddlewareTests.cs (4)
173Assert.Equal(response.Content.Headers.ContentLength, (await response.Content.ReadAsByteArrayAsync()).Length); 230Assert.Equal(response.Content.Headers.ContentLength, (await response.Content.ReadAsByteArrayAsync()).Length); 273Assert.Empty((await response.Content.ReadAsByteArrayAsync())); 373Assert.Empty((await response.Content.ReadAsByteArrayAsync()));
StaticFileMiddlewareTests.cs (6)
187var responseContent = await response.Content.ReadAsByteArrayAsync(); 226var responseContent = await response.Content.ReadAsByteArrayAsync(); 268var responseContent = await response.Content.ReadAsByteArrayAsync(); 318var responseContent = await response.Content.ReadAsByteArrayAsync(); 361var responseContent = await response.Content.ReadAsByteArrayAsync(); 484Assert.Empty((await response.Content.ReadAsByteArrayAsync()));
Microsoft.AspNetCore.TestHost.Tests (8)
RequestLifetimeTests.cs (2)
66var ex = await Assert.ThrowsAsync<HttpRequestException>(() => response.Content.ReadAsByteArrayAsync()); 89var ex = await Assert.ThrowsAsync<HttpRequestException>(() => response.Content.ReadAsByteArrayAsync());
ResponseBodyTests.cs (4)
28var bytes = await response.Content.ReadAsByteArrayAsync(); 45var bytes = await response.Content.ReadAsByteArrayAsync(); 80var responseBytes = await response.Content.ReadAsByteArrayAsync(); 119var responseBytes = await response.Content.ReadAsByteArrayAsync();
ResponseResetTests.cs (2)
125var ex = await Assert.ThrowsAsync<HttpRequestException>(() => response.Content.ReadAsByteArrayAsync()); 151var ex = await Assert.ThrowsAsync<HttpRequestException>(() => response.Content.ReadAsByteArrayAsync());