0
Fork 0
mirror of https://github.com/ninenines/cowboy.git synced 2025-07-14 12:20:24 +00:00

Use random ports for tests

This commit is contained in:
Loïc Hoguin 2013-03-02 14:38:10 +01:00
parent 8dd6ce8357
commit 0ba06578f2
2 changed files with 18 additions and 18 deletions

View file

@ -75,10 +75,10 @@ end_per_suite(_Config) ->
ok.
init_per_group(ws, Config) ->
Port = 33080,
cowboy:start_http(ws, 100, [{port, Port}], [
cowboy:start_http(ws, 100, [{port, 0}], [
{env, [{dispatch, init_dispatch()}]}
]),
Port = ranch:get_port(ws),
[{port, Port}|Config].
end_per_group(Listener, _Config) ->