Skip to content

Commit

Permalink
Correct expectations in retry with fallback spec (#10635)
Browse files Browse the repository at this point in the history
The blocking test scenario in the HttpClientRetryWithFallbackSpec is
corrected to not mistakenly initiate the HTTP requests twice when
verifying that fallback works as expected.
  • Loading branch information
jeremyg484 committed Mar 21, 2024
1 parent d16856c commit 7ff99ee
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -68,11 +68,11 @@ class HttpClientRetryWithFallbackSpec extends Specification{
countFilter.requests.clear()
controller.countThreshold = Integer.MAX_VALUE
controller.count = 0
countClient.getCount()
int fallbackResult = countClient.getCount()

then:"The fallback is called"
countClient.getCount() == 9999
countFilter.requests.size() == 12 //TODO - This seems like a bug in the way blocking retry works with fallback, but is the same as the behavior before HttpClientIntroductionAdvice refactoring
fallbackResult == 9999
countFilter.requests.size() == 6
}

void "test simply retry with reactive publisher"() {
Expand Down

0 comments on commit 7ff99ee

Please sign in to comment.