# HG changeset patch # User Sergey Kandaurov # Date 1612804643 -10800 # Node ID 35beaf85de72a6219e1023cd4358d0a125a5a724 # Parent 5b1fa6e32549f194328dcd4ba87567197ea30ca5 Tests: sorted h2.t tests. A test for partial request body is moved closer to relatives. This also fixes graceful shutdown tests that depend on timings. diff --git a/h2.t b/h2.t --- a/h2.t +++ b/h2.t @@ -695,6 +695,15 @@ is($frame->{code}, 1, 'client body timeo ($frame) = grep { $_->{type} eq "PING" && $_->{flags} & 0x1 } @$frames; ok($frame, 'client body timeout - PING'); +# partial request body data frame with connection close after body timeout + +$s = Test::Nginx::HTTP2->new(port(8087)); +$sid = $s->new_stream({ path => '/proxy/t2.html', body_more => 1 }); +$s->h2_body('TEST', { split => [ 12 ], abort => 1 }); + +select undef, undef, undef, 1.1; +undef $s; + # proxied request with logging pristine request header field (e.g., referer) $s = Test::Nginx::HTTP2->new(); @@ -1155,15 +1164,6 @@ my $grace3 = Test::Nginx::HTTP2->new(por $sid = $grace3->new_stream({ path => '/proxy2/t2.html', body_more => 1 }); $grace3->h2_body('TEST', { body_more => 1 }); -# partial request body data frame with connection close after body timeout - -my $grace4 = Test::Nginx::HTTP2->new(port(8087)); -$sid = $grace4->new_stream({ path => '/proxy/t2.html', body_more => 1 }); -$grace4->h2_body('TEST', { split => [ 12 ], abort => 1 }); - -select undef, undef, undef, 1.1; -undef $grace4; - # GOAWAY without awaiting active streams, further streams ignored $s = Test::Nginx::HTTP2->new(port(8080));