aboutsummaryrefslogtreecommitdiffstats
path: root/test/rfc7230_SUITE.erl
diff options
context:
space:
mode:
authorLoïc Hoguin <[email protected]>2018-11-19 09:05:34 +0100
committerLoïc Hoguin <[email protected]>2018-11-19 09:05:34 +0100
commitbed328b6c9ce41782c340a89554599a838574d82 (patch)
tree065bd9faad0b6abe234302b599624fe6981fad5d /test/rfc7230_SUITE.erl
parent6cc3b0ccca6c06592c2a1881cae39945de805747 (diff)
downloadcowboy-bed328b6c9ce41782c340a89554599a838574d82.tar.gz
cowboy-bed328b6c9ce41782c340a89554599a838574d82.tar.bz2
cowboy-bed328b6c9ce41782c340a89554599a838574d82.zip
Use ?FUNCTION_NAME instead of ct_helper:name()
Cowboy is 19+ so it's OK to use it.
Diffstat (limited to 'test/rfc7230_SUITE.erl')
-rw-r--r--test/rfc7230_SUITE.erl5
1 files changed, 2 insertions, 3 deletions
diff --git a/test/rfc7230_SUITE.erl b/test/rfc7230_SUITE.erl
index 6887d27..d42a454 100644
--- a/test/rfc7230_SUITE.erl
+++ b/test/rfc7230_SUITE.erl
@@ -17,7 +17,6 @@
-compile(nowarn_export_all).
-import(ct_helper, [doc/1]).
--import(ct_helper, [name/0]).
-import(cowboy_test, [gun_open/1]).
-import(cowboy_test, [gun_down/1]).
-import(cowboy_test, [raw_open/1]).
@@ -1591,7 +1590,7 @@ reject_absolute_form_different_host(Config) ->
empty_host(Config0) ->
doc("The host header is empty when the authority component is undefined. (RFC7230 5.4)"),
Routes = [{'_', [{"/echo/:key[/:arg]", echo_h, []}]}],
- Config = cowboy_test:init_http(name(), #{
+ Config = cowboy_test:init_http(?FUNCTION_NAME, #{
env => #{dispatch => cowboy_router:compile(Routes)}
}, Config0),
#{code := 200, body := <<>>} = do_raw(Config, [
@@ -1602,7 +1601,7 @@ empty_host(Config0) ->
"GET /echo/host HTTP/1.1\r\n"
"Host: \r\n"
"\r\n"]),
- cowboy:stop_listener(name()).
+ cowboy:stop_listener(?FUNCTION_NAME).
%% The effective request URI can be rebuilt by concatenating scheme,
%% "://", authority, path and query components. (RFC7230 5.5)