diff options
author | Loïc Hoguin <[email protected]> | 2018-11-22 00:12:18 +0100 |
---|---|---|
committer | Loïc Hoguin <[email protected]> | 2018-11-22 00:12:18 +0100 |
commit | 0223f69fcd2252a4b686b2815e6ee287b1484551 (patch) | |
tree | adc934ca725cd23d7e7a76514ae732bbc62c3cac /test/handlers/content_types_accepted_h.erl | |
parent | 037b286aa85acaaf439011bd7d2ae38685ce2f2e (diff) | |
download | cowboy-0223f69fcd2252a4b686b2815e6ee287b1484551.tar.gz cowboy-0223f69fcd2252a4b686b2815e6ee287b1484551.tar.bz2 cowboy-0223f69fcd2252a4b686b2815e6ee287b1484551.zip |
Move the final old HTTP suite tests and remove it
Diffstat (limited to 'test/handlers/content_types_accepted_h.erl')
-rw-r--r-- | test/handlers/content_types_accepted_h.erl | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/test/handlers/content_types_accepted_h.erl b/test/handlers/content_types_accepted_h.erl index b871dc8..d34135e 100644 --- a/test/handlers/content_types_accepted_h.erl +++ b/test/handlers/content_types_accepted_h.erl @@ -1,5 +1,5 @@ -%% This module accepts a multipart media type with parameters -%% that do not include boundary. +%% This module returns something different in +%% content_types_accepted depending on the query string. -module(content_types_accepted_h). @@ -19,6 +19,8 @@ content_types_accepted(Req=#{qs := <<"multipart">>}, State) -> {[ {{<<"multipart">>, <<"mixed">>, [{<<"v">>, <<"1">>}]}, put_multipart_mixed} ], Req, State}; +content_types_accepted(Req=#{qs := <<"param">>}, State) -> + {[{{<<"text">>, <<"plain">>, [{<<"charset">>, <<"utf-8">>}]}, put_text_plain}], Req, State}; content_types_accepted(Req=#{qs := <<"wildcard-param">>}, State) -> {[{{<<"text">>, <<"plain">>, '*'}, put_text_plain}], Req, State}. |