aboutsummaryrefslogtreecommitdiffstats
path: root/test/handlers/long_polling_h.erl
diff options
context:
space:
mode:
Diffstat (limited to 'test/handlers/long_polling_h.erl')
-rw-r--r--test/handlers/long_polling_h.erl5
1 files changed, 3 insertions, 2 deletions
diff --git a/test/handlers/long_polling_h.erl b/test/handlers/long_polling_h.erl
index 3dd0f77..f9da574 100644
--- a/test/handlers/long_polling_h.erl
+++ b/test/handlers/long_polling_h.erl
@@ -14,8 +14,9 @@ init(Req, _) ->
{cowboy_loop, Req, 2, hibernate}.
info(timeout, Req, 0) ->
- %% @todo Why 102?
- {stop, cowboy_req:reply(102, Req), 0};
+ %% Send an unused status code to make sure there's no
+ %% conflict with whatever Cowboy may send itself.
+ {stop, cowboy_req:reply(<<"299 OK!">>, Req), 0};
info(timeout, Req, Count) ->
erlang:send_after(200, self(), timeout),
{ok, Req, Count - 1, hibernate}.