diff --git a/tests/Rules/Deprecations/FetchingDeprecatedConstRuleTest.php b/tests/Rules/Deprecations/FetchingDeprecatedConstRuleTest.php index 7f2d451..06bfa51 100644 --- a/tests/Rules/Deprecations/FetchingDeprecatedConstRuleTest.php +++ b/tests/Rules/Deprecations/FetchingDeprecatedConstRuleTest.php @@ -83,4 +83,15 @@ public function testEstrictWithVersionGuard(): void ); } + public function testEstrictWithVersionCompareGuard(): void + { + $errors = []; + + require_once __DIR__ . '/data/bug-162b.php'; + $this->analyse( + [__DIR__ . '/data/bug-162b.php'], + $errors, + ); + } + } diff --git a/tests/Rules/Deprecations/data/bug-162b.php b/tests/Rules/Deprecations/data/bug-162b.php new file mode 100644 index 0000000..02eae22 --- /dev/null +++ b/tests/Rules/Deprecations/data/bug-162b.php @@ -0,0 +1,12 @@ +