changeset 1379:14bfd6643bbb

Tests: updated rewrite.t for the return r->err_status change.
author Maxim Dounin <mdounin@mdounin.ru>
date Fri, 21 Sep 2018 17:33:41 +0300
parents ba7e2e60f8b6
children f50c7d90f5c9
files rewrite.t
diffstat 1 files changed, 9 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/rewrite.t
+++ b/rewrite.t
@@ -158,7 +158,15 @@ like(http_get('/return200'), qr!200 OK!,
 like(http_get('/return306'), qr!HTTP/1.1 306 !, 'return 306');
 like(http_get('/return405'), qr!HTTP/1.1 405.*body!ms, 'return 405');
 
-like(http_get('/error404return405'), qr!HTTP/1.1 404!, 'error 404 return 405');
+# this used to result in 404, but was changed in 1.15.4
+# to respond with 405 instead, much like a real error would do
+
+TODO: {
+local $TODO = 'not yet' unless $t->has_version('1.15.4');
+
+like(http_get('/error404return405'), qr!HTTP/1.1 405!, 'error 404 return 405');
+
+}
 
 # status code should be 405, and entity body is expected (vs. normal 204
 # replies which doesn't expect to have body); use HTTP/1.1 for test