aboutsummaryrefslogtreecommitdiffstats
path: root/test
diff options
context:
space:
mode:
authorLoïc Hoguin <[email protected]>2019-09-15 16:30:09 +0200
committerLoïc Hoguin <[email protected]>2019-09-15 16:30:09 +0200
commit2888e9e6ef8b3f234a118eeecaadaa7315ce7e62 (patch)
treeb42e5fb51c04ba9c693039ac92e81e5be9d3fcab /test
parentea976f02e0ad3ef7ab026b141a336229aa089c42 (diff)
downloadcowboy-2888e9e6ef8b3f234a118eeecaadaa7315ce7e62.tar.gz
cowboy-2888e9e6ef8b3f234a118eeecaadaa7315ce7e62.tar.bz2
cowboy-2888e9e6ef8b3f234a118eeecaadaa7315ce7e62.zip
Increase the period for req_SUITE:read_body_period
This should increase the likelihood of the test succeeding on slower systems when run over TLS.
Diffstat (limited to 'test')
-rw-r--r--test/req_SUITE.erl8
1 files changed, 4 insertions, 4 deletions
diff --git a/test/req_SUITE.erl b/test/req_SUITE.erl
index cbb0991..f58154f 100644
--- a/test/req_SUITE.erl
+++ b/test/req_SUITE.erl
@@ -53,7 +53,7 @@ init_dispatch(Config) ->
{"/crash/:key/period", echo_h, #{length => 999999999, period => 1000, crash => true}},
{"/no-opts/:key", echo_h, #{crash => true}},
{"/opts/:key/length", echo_h, #{length => 1000}},
- {"/opts/:key/period", echo_h, #{length => 999999999, period => 1000}},
+ {"/opts/:key/period", echo_h, #{length => 999999999, period => 2000}},
{"/opts/:key/timeout", echo_h, #{timeout => 1000, crash => true}},
{"/100-continue/:key", echo_h, []},
{"/full/:key", echo_h, []},
@@ -461,15 +461,15 @@ read_body_mtu(Config) ->
ok.
read_body_period(Config) ->
- doc("Read the request body for at most 1 second."),
+ doc("Read the request body for at most 2 seconds."),
ConnPid = gun_open(Config),
Body = <<0:8000000>>,
Ref = gun:headers(ConnPid, "POST", "/opts/read_body/period", [
{<<"content-length">>, integer_to_binary(byte_size(Body) * 2)}
]),
- %% The body is sent twice, first with nofin, then wait 2 seconds, then again with fin.
+ %% The body is sent twice, first with nofin, then wait 3 seconds, then again with fin.
gun:data(ConnPid, Ref, nofin, Body),
- timer:sleep(2000),
+ timer:sleep(3000),
gun:data(ConnPid, Ref, fin, Body),
{response, nofin, 200, _} = gun:await(ConnPid, Ref),
{ok, Body} = gun:await_body(ConnPid, Ref),