comparison h2_request_body_js.t @ 1693:5ac6efbe5552

Tests: removed TODO and try_run() checks for legacy versions.
author Sergey Kandaurov <pluknet@nginx.com>
date Tue, 01 Jun 2021 16:40:18 +0300
parents efd082b4aa9c
children 18ac4d9e5a2a
comparison
equal deleted inserted replaced
1692:f6795e2e6a4b 1693:5ac6efbe5552
69 $t->write_file('sr', 'SEE-THIS'); 69 $t->write_file('sr', 'SEE-THIS');
70 $t->try_run('no njs available')->plan(3); 70 $t->try_run('no njs available')->plan(3);
71 71
72 ############################################################################### 72 ###############################################################################
73 73
74 local $TODO = 'not yet' unless $t->has_version('1.19.3');
75 $t->todo_alerts() unless $t->has_version('1.19.3');
76
77 my $s = Test::Nginx::HTTP2->new(); 74 my $s = Test::Nginx::HTTP2->new();
78 my $sid = $s->new_stream({ body => 'TEST' }); 75 my $sid = $s->new_stream({ body => 'TEST' });
79 my $frames = $s->read(all => [{ sid => $sid, fin => 1 }]); 76 my $frames = $s->read(all => [{ sid => $sid, fin => 1 }]);
80 77
81 my ($frame) = grep { $_->{type} eq "HEADERS" } @$frames; 78 my ($frame) = grep { $_->{type} eq "HEADERS" } @$frames;
83 is($frame->{headers}->{'x-body'}, 'TEST', 'request body'); 80 is($frame->{headers}->{'x-body'}, 'TEST', 'request body');
84 81
85 ($frame) = grep { $_->{type} eq "DATA" } @$frames; 82 ($frame) = grep { $_->{type} eq "DATA" } @$frames;
86 is($frame->{data}, 'SEE-THIS', 'response body'); 83 is($frame->{data}, 'SEE-THIS', 'response body');
87 84
88 $t->stop();
89
90 ############################################################################### 85 ###############################################################################