Skip to content

Commit 81177d1

Browse files
committed
Skip tests on right versions
1 parent 03e1bef commit 81177d1

File tree

2 files changed

+9
-0
lines changed

2 files changed

+9
-0
lines changed

tests/PHPStan/Rules/Properties/PropertiesInInterfaceRuleTest.php

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,9 @@ public function testPhp83AndPropertiesInInterface(): void
2323
if (PHP_VERSION_ID >= 80400) {
2424
$this->markTestSkipped('Test requires PHP 8.3 or earlier.');
2525
}
26+
if (PHP_VERSION_ID < 80000) {
27+
$this->markTestSkipped('Property hooks cause syntax error on PHP 7.4');
28+
}
2629

2730
$this->analyse([__DIR__ . '/data/properties-in-interface.php'], [
2831
[
@@ -45,6 +48,9 @@ public function testPhp83AndPropertyHooksInInterface(): void
4548
if (PHP_VERSION_ID >= 80400) {
4649
$this->markTestSkipped('Test requires PHP 8.3 or earlier.');
4750
}
51+
if (PHP_VERSION_ID < 80000) {
52+
$this->markTestSkipped('Property hooks cause syntax error on PHP 7.4');
53+
}
4854

4955
$this->analyse([__DIR__ . '/data/property-hooks-in-interface.php'], [
5056
[

tests/PHPStan/Rules/Properties/PropertyInClassRuleTest.php

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,9 @@ public function testPhpLessThan84AndHookedPropertiesInClass(): void
2323
if (PHP_VERSION_ID >= 80400) {
2424
$this->markTestSkipped('Test requires PHP 8.3 or earlier.');
2525
}
26+
if (PHP_VERSION_ID < 80000) {
27+
$this->markTestSkipped('Property hooks cause syntax error on PHP 7.4');
28+
}
2629

2730
$this->analyse([__DIR__ . '/data/hooked-properties-in-class.php'], [
2831
[

0 commit comments

Comments
 (0)