Skip to content

Commit

Permalink
Update StreamTest.php
Browse files Browse the repository at this point in the history
  • Loading branch information
TheTechsTech committed Apr 16, 2022
1 parent 6d758e3 commit 62a903d
Showing 1 changed file with 2 additions and 8 deletions.
10 changes: 2 additions & 8 deletions tests/StreamTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -146,9 +146,7 @@ public function testTellFailure(): void
$fixture = new Stream($resource);
fclose($resource);

$errorType = (float) \phpversion() >= 8.0 ? \TypeError::class : \RuntimeException::class;
$this->expectException($errorType);

$this->expectException(\RuntimeException::class);
$fixture->tell();

error_reporting($level);
Expand Down Expand Up @@ -386,9 +384,6 @@ public function testWriteWhenNotWritable(): void
fclose($resource);

$this->expectException(\RuntimeException::class);
$errorType = (float) \phpversion() >= 8.0 ? \TypeError::class : \RuntimeException::class;
$this->expectException($errorType);

$fixture->write(uniqid());

error_reporting($level);
Expand Down Expand Up @@ -454,8 +449,7 @@ public function testReadWhenNotReadable(): void
$fixture = new Stream($resource);
fclose($resource);

$errorType = (float) \phpversion() >= 8.0 ? \TypeError::class : \RuntimeException::class;
$this->expectException($errorType);
$this->expectException(\RuntimeException::class);

$fixture->read(rand());

Expand Down

0 comments on commit 62a903d

Please sign in to comment.