diff options
author | Loïc Hoguin <[email protected]> | 2023-12-18 18:11:10 +0100 |
---|---|---|
committer | Loïc Hoguin <[email protected]> | 2023-12-18 18:17:09 +0100 |
commit | 627a4508b539f98fb632b4ff9a92a4f9c2c54890 (patch) | |
tree | 5d99c4af8c423251675e54ac88b29ede4a0777f5 /test/stream_handler_SUITE.erl | |
parent | 2558ba65ad3e39dd10ab65196af8f4dbb067f476 (diff) | |
download | cowboy-627a4508b539f98fb632b4ff9a92a4f9c2c54890.tar.gz cowboy-627a4508b539f98fb632b4ff9a92a4f9c2c54890.tar.bz2 cowboy-627a4508b539f98fb632b4ff9a92a4f9c2c54890.zip |
Explicitly close the socket in some tests for speed ups
The socket staying open meant that the graceful shut down
of the Cowboy listeners were waiting for the connections
to be closed gracefully (or a timeout). Closing explicitly
where it makes sense ensures we don't unnecessarily wait.
This commit removes a full minute in the run time of all
Cowboy test suites (minus examples).
Diffstat (limited to 'test/stream_handler_SUITE.erl')
-rw-r--r-- | test/stream_handler_SUITE.erl | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/test/stream_handler_SUITE.erl b/test/stream_handler_SUITE.erl index 0643d3d..e30d420 100644 --- a/test/stream_handler_SUITE.erl +++ b/test/stream_handler_SUITE.erl @@ -293,7 +293,7 @@ flow_after_body_fully_read(Config) -> %% Receive a 200 response, sent after the second flow command, %% confirming that the flow command was accepted. {response, _, 200, _} = gun:await(ConnPid, Ref), - ok. + gun:close(ConnPid). set_options_ignore_unknown(Config) -> doc("Confirm that unknown options are ignored when using the set_options commands."), |