Here in this sample project you can see that Single.retryWhen() produces inconsistent results, depending on timing:
- retryWhen() test method gets one less retry than expected
- retryWhenWithDelay() test method works as expected
My suspicion is that when we do not add a time delay, onComplete is called immediately after the last onNext() call and immediately terminates the stream with NoSuchElementException.
Here in this sample project you can see that Single.retryWhen() produces inconsistent results, depending on timing:
My suspicion is that when we do not add a time delay, onComplete is called immediately after the last onNext() call and immediately terminates the stream with NoSuchElementException.