changeset 1648:48d8c16d48ea

Tests: HTTP/2 connection timeout tests removed. Both http2_recv_timeout and http2_idle_timeout are scheduled for removal.
author Sergey Kandaurov <pluknet@nginx.com>
date Tue, 09 Feb 2021 10:51:56 +0300
parents 35beaf85de72
children 20e0ec3b4dec
files h2.t
diffstat 1 files changed, 1 insertions(+), 37 deletions(-) [+]
line wrap: on
line diff
--- a/h2.t
+++ b/h2.t
@@ -26,7 +26,7 @@ select STDERR; $| = 1;
 select STDOUT; $| = 1;
 
 my $t = Test::Nginx->new()->has(qw/http http_v2 proxy rewrite charset gzip/)
-	->plan(150);
+	->plan(144);
 
 $t->write_file_expand('nginx.conf', <<'EOF');
 
@@ -110,7 +110,6 @@ http {
         listen       127.0.0.1:8084 http2;
         server_name  localhost;
 
-        http2_recv_timeout 1s;
         client_header_timeout 1s;
         send_timeout 1s;
     }
@@ -119,7 +118,6 @@ http {
         listen       127.0.0.1:8085 http2;
         server_name  localhost;
 
-        http2_idle_timeout 1s;
         client_body_timeout 1s;
 
         location /proxy2/ {
@@ -244,40 +242,6 @@ is($frame->{value}, 'SEE-THIS', 'PING pa
 is($frame->{flags}, 1, 'PING flags ack');
 is($frame->{sid}, 0, 'PING stream');
 
-# timeouts
-
-SKIP: {
-skip 'long tests', 6 unless $ENV{TEST_NGINX_UNSAFE};
-
-push my @s, Test::Nginx::HTTP2->new(port(8084), pure => 1);
-push @s, Test::Nginx::HTTP2->new(port(8084), pure => 1);
-$s[-1]->h2_ping('SEE-THIS');
-push @s, Test::Nginx::HTTP2->new(port(8085), pure => 1);
-push @s, Test::Nginx::HTTP2->new(port(8085), pure => 1);
-$s[-1]->h2_ping('SEE-THIS');
-
-select undef, undef, undef, 2.1;
-
-$frames = (shift @s)->read(all => [{ type => "GOAWAY" }]);
-($frame) = grep { $_->{type} eq "GOAWAY" } @$frames;
-ok($frame, 'recv timeout - new connection GOAWAY');
-is($frame->{code}, 1, 'recv timeout - new connection code');
-
-$frames = (shift @s)->read(all => [{ type => "GOAWAY" }]);
-($frame) = grep { $_->{type} eq "GOAWAY" } @$frames;
-is($frame, undef, 'recv timeout - idle connection GOAWAY');
-
-$frames = (shift @s)->read(all => [{ type => "GOAWAY" }]);
-($frame) = grep { $_->{type} eq "GOAWAY" } @$frames;
-is($frame, undef, 'idle timeout - new connection GOAWAY');
-
-$frames = (shift @s)->read(all => [{ type => "GOAWAY" }]);
-($frame) = grep { $_->{type} eq "GOAWAY" } @$frames;
-ok($frame, 'idle timeout - idle connection GOAWAY');
-is($frame->{code}, 0, 'idle timeout - idle connection code');
-
-}
-
 # GOAWAY
 
 Test::Nginx::HTTP2->new()->h2_goaway(0, 0, 5);