Skip to content

Improve Polly coverage#2505

Merged
martincostello merged 2 commits intomainfrom
moar-mutants
Feb 15, 2025
Merged

Improve Polly coverage#2505
martincostello merged 2 commits intomainfrom
moar-mutants

Conversation

@martincostello
Copy link
Member

Extend coverage for unit tests and mutations with low-hanging-fruit parameter validation and removing redundant code.

Extend coverage for unit tests and mutations with low-hanging fruit parameter validation and redundant code.
@martincostello martincostello added enhancement unit-testing .NET Pull requests that update .NET code labels Feb 15, 2025
@codecov
Copy link

codecov bot commented Feb 15, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 86.42%. Comparing base (6a617ed) to head (9bc74ea).
Report is 2 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #2505      +/-   ##
==========================================
+ Coverage   85.36%   86.42%   +1.05%     
==========================================
  Files         312      312              
  Lines        7468     7468              
  Branches     1121     1091      -30     
==========================================
+ Hits         6375     6454      +79     
+ Misses        908      852      -56     
+ Partials      185      162      -23     
Flag Coverage Δ
linux 86.42% <100.00%> (+1.05%) ⬆️
macos 86.42% <100.00%> (+1.05%) ⬆️
windows 86.38% <100.00%> (+1.06%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

- Increase the minimum code coverage thresholds.
- Increase the minimum mutation score.
@martincostello martincostello marked this pull request as ready for review February 15, 2025 18:09
@martincostello martincostello enabled auto-merge (squash) February 15, 2025 18:09
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot reviewed 30 out of 41 changed files in this pull request and generated 2 comments.

Files not reviewed (11)
  • src/Polly/Polly.csproj: Language not supported
  • src/Polly/RateLimit/LockFreeTokenBucketRateLimiter.cs: Evaluated as low risk
  • src/Polly/Retry/AsyncRetryPolicy.cs: Evaluated as low risk
  • src/Polly/Timeout/AsyncTimeoutPolicy.cs: Evaluated as low risk
  • src/Polly/Retry/RetryPolicy.cs: Evaluated as low risk
  • src/Polly/Bulkhead/BulkheadPolicy.cs: Evaluated as low risk
  • src/Polly/Timeout/TimeoutPolicy.cs: Evaluated as low risk
  • src/Polly/Bulkhead/AsyncBulkheadPolicy.cs: Evaluated as low risk
  • src/Polly/Fallback/AsyncFallbackPolicy.cs: Evaluated as low risk
  • src/Polly/Fallback/FallbackPolicy.cs: Evaluated as low risk
  • src/Polly/RateLimit/RateLimitPolicy.cs: Evaluated as low risk
Comments suppressed due to low confidence (1)

src/Polly/RateLimit/AsyncRateLimitPolicy.cs:50

  • The null check for 'rateLimiter' was removed. This can lead to a potential null reference exception if 'rateLimiter' is null.
_rateLimiter = rateLimiter;

@martincostello martincostello merged commit 1f232ca into main Feb 15, 2025
24 checks passed
@martincostello martincostello deleted the moar-mutants branch February 15, 2025 18:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement .NET Pull requests that update .NET code unit-testing

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant