Skip to content

Commit 882a4f4

Browse files
committed
Run http_SUITE:graceful_shutdown_listener separately
To avoid intermittent errors that are more likely as more tests are calling cowboy:stop_listener.
1 parent 053e233 commit 882a4f4

File tree

1 file changed

+10
-3
lines changed

1 file changed

+10
-3
lines changed

test/http_SUITE.erl

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -28,9 +28,16 @@
2828
-import(cowboy_test, [raw_recv/3]).
2929
-import(cowboy_test, [raw_expect_recv/2]).
3030

31-
all() -> [{group, clear}].
32-
33-
groups() -> [{clear, [parallel], ct_helper:all(?MODULE)}].
31+
all() ->
32+
[{group, clear_no_parallel}, {group, clear}].
33+
34+
groups() ->
35+
[
36+
%% cowboy:stop_listener can be slow when called many times
37+
%% in parallel so we must run this test separately from the others.
38+
{clear_no_parallel, [], [graceful_shutdown_listener]},
39+
{clear, [parallel], ct_helper:all(?MODULE) -- [graceful_shutdown_listener]}
40+
].
3441

3542
init_per_group(Name, Config) ->
3643
cowboy_test:init_http(Name, #{

0 commit comments

Comments
 (0)