Skip to content

Commit e3732ab

Browse files
haargsimbabque
authored andcommitted
remove partial content test
It is only testing that 206 is a success and that max_size applies - these are both user agent behaviors.
1 parent c77cf9d commit e3732ab

1 file changed

Lines changed: 0 additions & 29 deletions

File tree

t/basic.t

Lines changed: 0 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -332,35 +332,6 @@ $res = $ua->request($req);
332332
ok($res->is_success);
333333
ok($res->content =~ /^Content-Type: multipart\/form-data; boundary=/m);
334334

335-
#----------------------------------------------------------------
336-
print "Check partial content response...\n";
337-
338-
sub httpd_get_partial {
339-
my ($c) = @_;
340-
$c->send_basic_header(206);
341-
print $c "Content-Type: image/jpeg\015\012";
342-
$c->send_crlf;
343-
print $c "some fake JPEG content";
344-
345-
}
346-
347-
{
348-
$req = HTTP::Request->new(GET => url("/partial", $base));
349-
$res = $ua->request($req);
350-
ok($res->is_success); # "a 206 response is considered successful"
351-
}
352-
{
353-
$ua->max_size(3);
354-
$req = HTTP::Request->new(GET => url("/partial", $base));
355-
$res = $ua->request($req);
356-
ok($res->is_success); # "a 206 response is considered successful"
357-
# Put max_size back how we found it.
358-
$ua->max_size(undef);
359-
ok($res->as_string, qr/Client-Aborted: max_size/)
360-
; # Client-Aborted is returned when max_size is given
361-
}
362-
363-
364335
#----------------------------------------------------------------
365336
print "Terminating server...\n";
366337

0 commit comments

Comments
 (0)