Skip to content

Commit

Permalink
#2255 - Fix IsPhpVersionTest test for PHP8.1
Browse files Browse the repository at this point in the history
  • Loading branch information
Jeckerson committed Sep 11, 2021
1 parent d5cb1a0 commit 4070b12
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions tests/Extension/Optimizers/IsPhpVersionTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -85,12 +85,15 @@ public function testOptimizerExceptionNegativeNumber(): void
$this->isPhpVersion(-7);
}

public function testOptimizerExceptionNull(): void
public function testOptimizerExceptionEmpty(): void
{
$this->expectException(Exception::class);
$this->expectExceptionMessage('Could not parse PHP version');

$this->isPhpVersion(null);
/**
* After PHP8.1 it is impossible to pass null value to preg_match()
*/
$this->isPhpVersion('');
}

public function testZephirUsingInteger70000(): void
Expand Down

0 comments on commit 4070b12

Please sign in to comment.