Skip to content

Commit

Permalink
Fix responseCommitted test in webflux error handling
Browse files Browse the repository at this point in the history
This commit updates the `responseCommitted` after changes were made in
`WebTestClient` with spring-projects/spring-framework#24051.

Fixes gh-19083
  • Loading branch information
bclozel committed Nov 22, 2019
1 parent 945ce2e commit 0c5bb60
Showing 1 changed file with 2 additions and 3 deletions.
Expand Up @@ -20,7 +20,6 @@

import javax.validation.Valid;

import org.junit.jupiter.api.Disabled;
import org.junit.jupiter.api.Test;
import org.junit.jupiter.api.extension.ExtendWith;
import reactor.core.publisher.Mono;
Expand Down Expand Up @@ -214,13 +213,13 @@ void testExceptionWithNullMessage() {
}

@Test
@Disabled
void responseCommitted() {
this.contextRunner.run((context) -> {
WebTestClient client = getWebClient(context);
assertThatExceptionOfType(RuntimeException.class)
.isThrownBy(() -> client.get().uri("/commit").exchange().expectStatus())
.withCauseInstanceOf(IllegalStateException.class).withMessageContaining("already committed!");
.withCauseInstanceOf(IllegalStateException.class)
.withMessageContaining("Error occurred after response was completed");
});
}

Expand Down

0 comments on commit 0c5bb60

Please sign in to comment.