aboutsummaryrefslogblamecommitdiffstats
path: root/test/handlers/delayed_hello_h.erl
blob: 68ef1ad65a5533a0c44cdebfcaec1e505a3fae5c (plain) (tree)
1
2
3
4
5
6
7
8
9
10
11










                                                           
%% Feel free to use, reuse and abuse the code in this file.

-module(delayed_hello_h).

-export([init/2]).

init(Req, Timeout) ->
	timer:sleep(Timeout),
	{ok, cowboy_req:reply(200, #{
		<<"content-type">> => <<"text/plain">>
	}, <<"Hello world!">>, Req), Timeout}.