Skip to content

Commit f7fac66

Browse files
committed
Fix build
1 parent ee33f1e commit f7fac66

File tree

2 files changed

+5
-1
lines changed

2 files changed

+5
-1
lines changed

tests/PHPStan/Rules/DeadCode/CallToMethodStatementWithoutImpurePointsRuleTest.php

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44

55
use PHPStan\Rules\Rule;
66
use PHPStan\Testing\RuleTestCase;
7+
use const PHP_VERSION_ID;
78

89
/**
910
* @extends RuleTestCase<CallToMethodStatementWithoutImpurePointsRule>
@@ -60,6 +61,9 @@ public function testRule(): void
6061

6162
public function testBug11011(): void
6263
{
64+
if (PHP_VERSION_ID < 80000) {
65+
$this->markTestSkipped('Test requires PHP 8.0.');
66+
}
6367
$this->analyse([__DIR__ . '/data/bug-11011.php'], [
6468
[
6569
'Call to method Bug11011\AnotherPureImpl::doFoo() on a separate line has no effect.',

tests/PHPStan/Rules/DeadCode/data/bug-11011.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?php
1+
<?php // lint >= 8.0
22

33
namespace Bug11011;
44

0 commit comments

Comments
 (0)