Skip to content

Commit

Permalink
test different behaviour for php 8.1 and 8.2-onwards
Browse files Browse the repository at this point in the history
  • Loading branch information
shish committed Dec 2, 2024
1 parent 0748231 commit ad5c2b4
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion generator/tests/PhpStanFunctions/PhpStanTypeTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,11 @@ public function testVoid(): void
{
$param = new PhpStanType('');
$this->assertEquals('', $param->getDocBlockType());
$this->assertEquals('void', $param->getSignatureType());
if (PHP_VERSION_ID >= 80100) {
$this->assertEquals('void', $param->getSignatureType());
} else {
$this->assertEquals('', $param->getSignatureType());
}

$param = new PhpStanType('void');
$this->assertEquals('void', $param->getDocBlockType());
Expand Down

0 comments on commit ad5c2b4

Please sign in to comment.