X-Git-Url: https://git.m6w6.name/?a=blobdiff_plain;ds=sidebyside;f=tests%2Fenvresponse014.phpt;fp=tests%2Fenvresponse014.phpt;h=ef85e2c2f7cbc157f9dae7fa5c4f8f12bfb3f8d4;hb=87db9817d428282792c8146d9c2ae9748ebf6f1e;hp=0000000000000000000000000000000000000000;hpb=7a5c865f6faf8b1b6c91735e9d3b040449ea74ba;p=m6w6%2Fext-http diff --git a/tests/envresponse014.phpt b/tests/envresponse014.phpt new file mode 100644 index 0000000..ef85e2c --- /dev/null +++ b/tests/envresponse014.phpt @@ -0,0 +1,24 @@ +--TEST-- +env response invalid ranges +--SKIPIF-- + +--FILE-- +setHeader("Range", "bytes=321-123,123-0"); +$res = new http\Env\Response; +$res->getBody()->append("foobar"); +$res->setEnvRequest($req); +$res->send($f); +rewind($f); +var_dump(stream_get_contents($f)); +--EXPECTF-- +string(96) "HTTP/1.1 416 Requested Range Not Satisfiable +Accept-Ranges: bytes +Content-Range: bytes */6 + +" +