Skip to content

Commit

Permalink
fix regression from changes.
Browse files Browse the repository at this point in the history
  • Loading branch information
andrueastman committed Jan 7, 2025
1 parent f7180cf commit 7ce320d
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/http/httpClient/Middleware/BodyInspectionHandler.cs
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ static async Task<Stream> CopyToStreamAsync(
CancellationToken cancellationToken

Check warning on line 85 in src/http/httpClient/Middleware/BodyInspectionHandler.cs

View workflow job for this annotation

GitHub Actions / Build

Remove this unused method parameter 'cancellationToken'. (https://rules.sonarsource.com/csharp/RSPEC-1172)

Check warning on line 85 in src/http/httpClient/Middleware/BodyInspectionHandler.cs

View workflow job for this annotation

GitHub Actions / Build

Remove this unused method parameter 'cancellationToken'. (https://rules.sonarsource.com/csharp/RSPEC-1172)

Check warning on line 85 in src/http/httpClient/Middleware/BodyInspectionHandler.cs

View workflow job for this annotation

GitHub Actions / Build

Remove this unused method parameter 'cancellationToken'. (https://rules.sonarsource.com/csharp/RSPEC-1172)

Check warning on line 85 in src/http/httpClient/Middleware/BodyInspectionHandler.cs

View workflow job for this annotation

GitHub Actions / Build

Remove this unused method parameter 'cancellationToken'. (https://rules.sonarsource.com/csharp/RSPEC-1172)

Check warning on line 85 in src/http/httpClient/Middleware/BodyInspectionHandler.cs

View workflow job for this annotation

GitHub Actions / Build

Remove this unused method parameter 'cancellationToken'. (https://rules.sonarsource.com/csharp/RSPEC-1172)

Check warning on line 85 in src/http/httpClient/Middleware/BodyInspectionHandler.cs

View workflow job for this annotation

GitHub Actions / Build

Remove this unused method parameter 'cancellationToken'. (https://rules.sonarsource.com/csharp/RSPEC-1172)
)
{
if(httpContent is null)
if(httpContent is null or { Headers.ContentLength: 0 })
{
return Stream.Null;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ public async Task BodyInspectionHandlerGetsResponseBodyStream()
Assert.Equal("response test", await response.Content.ReadAsStringAsync()); // response from option is separate from "normal" response stream
}

[Fact(Skip = "Test can potentially be flaky due to usage limitations on Github. Enable to verify locally.")]
[Fact(Skip = "Test can potentially be flaky due to usage limitations on Github. Enable to verify.")]
public async Task BodyInspectionHandlerGetsResponseBodyStreamFromGithub()
{
var option = new BodyInspectionHandlerOption { InspectResponseBody = true, InspectRequestBody = true };
Expand Down

0 comments on commit 7ce320d

Please sign in to comment.