Skip to content

Commit 92d8b91

Browse files
authored
Merge pull request #42 from Tobion/patch-1
file mode validation cannot be implemented according to PSR-17
2 parents 9c97cac + 8a0dea9 commit 92d8b91

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

test/StreamFactoryTestCase.php

+3-2
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22

33
namespace Interop\Http\Factory;
44

5+
use Exception;
56
use InvalidArgumentException;
67
use RuntimeException;
78
use PHPUnit\Framework\TestCase;
@@ -119,15 +120,15 @@ public function testCreateStreamFromFileWithNoMode()
119120
{
120121
$filename = $this->createTemporaryFile();
121122

122-
$this->expectException(InvalidArgumentException::class);
123+
$this->expectException(Exception::class);
123124
$stream = $this->factory->createStreamFromFile($filename, '');
124125
}
125126

126127
public function testCreateStreamFromFileWithInvalidMode()
127128
{
128129
$filename = $this->createTemporaryFile();
129130

130-
$this->expectException(InvalidArgumentException::class);
131+
$this->expectException(Exception::class);
131132
$stream = $this->factory->createStreamFromFile($filename, "\u{2620}");
132133
}
133134

0 commit comments

Comments
 (0)