From dc52ebe4407ac917bbac127a9feae756b44ef940 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lo=C3=AFc=20Hoguin?= Date: Wed, 21 Nov 2018 13:28:20 +0100 Subject: Move some more tests out of the old HTTP test suite --- test/rfc7231_SUITE.erl | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'test/rfc7231_SUITE.erl') diff --git a/test/rfc7231_SUITE.erl b/test/rfc7231_SUITE.erl index 642429b..89ec7b4 100644 --- a/test/rfc7231_SUITE.erl +++ b/test/rfc7231_SUITE.erl @@ -611,6 +611,16 @@ status_code_404(Config) -> {response, _, 404, _} = gun:await(ConnPid, Ref), ok. +status_code_404_not_found(Config) -> + doc("The 404 Not Found status code is sent when the target " + "resource does not exist. (RFC7231 6.5.4)"), + ConnPid = gun_open(Config), + Ref = gun:get(ConnPid, "/not/found", [ + {<<"accept-encoding">>, <<"gzip">>} + ]), + {response, _, 404, _} = gun:await(ConnPid, Ref), + ok. + status_code_405(Config) -> doc("The 405 Method Not Allowed status code can be sent. (RFC7231 6.5.5)"), ConnPid = gun_open(Config), -- cgit v1.2.3