Skip to content

Commit

Permalink
Ensure the messages are closed after the test execution
Browse files Browse the repository at this point in the history
  • Loading branch information
violetagg committed Sep 21, 2022
1 parent 4b6be49 commit 3b51a75
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
Expand Up @@ -59,6 +59,8 @@ void responseNonChunked() {
channel.writeOutbound(newHttpResponse(false));

channel.writeOutbound(new DefaultLastHttpContent(channel.bufferAllocator().allocate(0)));

assertThat(channel.finishAndReleaseAll()).isTrue();
}

@Test
Expand Down
Expand Up @@ -61,6 +61,8 @@ void accessLogArgs() {
Buffer buffer = channel.bufferAllocator().allocate(RESPONSE_CONTENT.length);
buffer.writeBytes(RESPONSE_CONTENT).makeReadOnly();
channel.writeOutbound(new DefaultHttp2DataFrame(buffer.send(), true));

assertThat(channel.finishAndReleaseAll()).isTrue();
}

private void assertAccessLogArgProvider(AccessLogArgProvider args, SocketAddress remoteAddress) {
Expand Down

0 comments on commit 3b51a75

Please sign in to comment.