Avoid deprecation warning in RandomHandlerIntegrationTests

This commit is contained in:
Sam Brannen 2019-09-05 13:29:01 +02:00
parent c80705a708
commit 73f5d05fd9
1 changed files with 3 additions and 4 deletions

View File

@ -88,10 +88,8 @@ class RandomHandlerIntegrationTests extends AbstractHttpHandlerIntegrationTests
Mono<Integer> requestSizeMono = request.getBody().
reduce(0, (integer, dataBuffer) -> integer +
dataBuffer.readableByteCount()).
doOnSuccessOrError((size, throwable) -> {
assertThat(throwable).isNull();
assertThat(size).isEqualTo(REQUEST_SIZE);
});
doOnNext(size -> assertThat(size).isEqualTo(REQUEST_SIZE)).
doOnError(throwable -> assertThat(throwable).isNull());
response.getHeaders().setContentLength(RESPONSE_SIZE);
@ -112,4 +110,5 @@ class RandomHandlerIntegrationTests extends AbstractHttpHandlerIntegrationTests
}
}
}