changeset 1487:fe0765147e15

Tests: perl and conditional requests processing.
author Sergey Kandaurov <pluknet@nginx.com>
date Wed, 19 Jun 2019 15:07:29 +0300
parents 723c7e08eec7
children dbce8fb5f5f8
files perl.t
diffstat 1 files changed, 13 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/perl.t
+++ b/perl.t
@@ -23,7 +23,7 @@ use Test::Nginx;
 select STDERR; $| = 1;
 select STDOUT; $| = 1;
 
-my $t = Test::Nginx->new()->has(qw/http perl rewrite/)->plan(17)
+my $t = Test::Nginx->new()->has(qw/http perl rewrite/)->plan(18)
 	->write_file_expand('nginx.conf', <<'EOF');
 
 %%TEST_GLOBALS%%
@@ -184,6 +184,18 @@ like(http(
 
 }
 
+TODO: {
+todo_skip 'leaves coredump', 1 unless $t->has_version('1.17.1')
+	or $ENV{TEST_NGINX_UNSAFE};
+
+like(http(
+	'GET / HTTP/1.0' . CRLF
+	. 'Host: localhost' . CRLF
+	. 'If-Match: tt' . CRLF . CRLF
+), qr|200 OK|ms, 'perl precondition failed');
+
+}
+
 # various request body tests
 
 like(http(