diff --git a/tests/StreamTest.php b/tests/StreamTest.php index a100ebd7..90fc58dd 100644 --- a/tests/StreamTest.php +++ b/tests/StreamTest.php @@ -300,6 +300,16 @@ public function readableModeProvider() ]; } + public function testStreamIsNotReadable() + { + $r = fopen('php://output', 'w'); + $stream = new Stream($r); + + $this->assertFalse($stream->isReadable()); + + $stream->close(); + } + /** * @dataProvider writableModeProvider * @@ -338,6 +348,16 @@ public function writableModeProvider() ['a+'], ]; } + + public function testStreamIsNotWritable() + { + $r = fopen('php://input', 'r'); + $stream = new Stream($r); + + $this->assertFalse($stream->isWritable()); + + $stream->close(); + } } namespace GuzzleHttp\Psr7;