kazoo
kazoo copied to clipboard
fix(core): Proper retry count in KazooRetry
Make sure the number of attempts matches the max_retry parameter. Add unit tests to that effect.
Why is this needed?
So that users can precisely control the number of retries
Proposed Changes
- Move the location of the attempt increase to before the check against
max_tryso we don't end up callingmax_tries + 1times the function.
Does this PR introduce any breaking change?
No, it shouldn't.
Codecov Report
All modified and coverable lines are covered by tests :white_check_mark:
Project coverage is 97.01%. Comparing base (
2fb93a8) to head (73309b2). Report is 2 commits behind head on master.
Additional details and impacted files
@@ Coverage Diff @@
## master #748 +/- ##
==========================================
+ Coverage 96.81% 97.01% +0.19%
==========================================
Files 27 27
Lines 3549 3549
==========================================
+ Hits 3436 3443 +7
+ Misses 113 106 -7
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.