From 10e38a2fa615dfaf2b93ac7aa6dcb87a086202b8 Mon Sep 17 00:00:00 2001 From: Abdul Malik Ikhsan Date: Tue, 14 Oct 2025 18:51:22 +0700 Subject: [PATCH 1/4] Fix Pin PHP-Parser 4.10.0 --- .github/workflows/compat_tests.yaml.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/compat_tests.yaml.yml b/.github/workflows/compat_tests.yaml.yml index 59a4ff2..47e063b 100644 --- a/.github/workflows/compat_tests.yaml.yml +++ b/.github/workflows/compat_tests.yaml.yml @@ -14,7 +14,7 @@ jobs: actions: - name: 'Rector dev + PHPUnit 10' - run: composer require "phpunit/phpunit:10.*" "nikic/php-parser:4.*" -W + run: composer require "phpunit/phpunit:10.*" "nikic/php-parser:4.10.0" -W php: 8.2 - name: 'Rector dev + PHPUnit 11' From b24554cd67dc5dd5d323328bf6db0e8d7d4ba9b1 Mon Sep 17 00:00:00 2001 From: Abdul Malik Ikhsan Date: Tue, 14 Oct 2025 18:53:12 +0700 Subject: [PATCH 2/4] Fix Pin PHP-Parser 4.10.0 --- .github/workflows/compat_tests.yaml.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/compat_tests.yaml.yml b/.github/workflows/compat_tests.yaml.yml index 47e063b..832bbf8 100644 --- a/.github/workflows/compat_tests.yaml.yml +++ b/.github/workflows/compat_tests.yaml.yml @@ -13,8 +13,8 @@ jobs: matrix: actions: - - name: 'Rector dev + PHPUnit 10' - run: composer require "phpunit/phpunit:10.*" "nikic/php-parser:4.10.0" -W + name: 'Rector dev + PHPUnit 8' + run: composer require "phpunit/phpunit:8.*" "nikic/php-parser:4.10.0" -W php: 8.2 - name: 'Rector dev + PHPUnit 11' From 57f03b4a2dc4e0f51e97b66af125c890d4734af3 Mon Sep 17 00:00:00 2001 From: Abdul Malik Ikhsan Date: Tue, 14 Oct 2025 18:53:53 +0700 Subject: [PATCH 3/4] Fix namespace test --- README.md | 2 +- tests/UsePHPParser4Test.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index db80ae6..04c5d98 100644 --- a/README.md +++ b/README.md @@ -1,7 +1,7 @@ # Todo * [x] add simple custom rule test -* [x] run with PHPUnit 10, 11, 12 +* [x] run with PHPUnit 8, 11, 12 * [x] add PHPStan custom test too * everything should pass * add this to `rectorphp/rector-src` CI to verify everything works well :) diff --git a/tests/UsePHPParser4Test.php b/tests/UsePHPParser4Test.php index 52a230b..073ffbe 100644 --- a/tests/UsePHPParser4Test.php +++ b/tests/UsePHPParser4Test.php @@ -1,6 +1,6 @@ Date: Tue, 14 Oct 2025 18:54:14 +0700 Subject: [PATCH 4/4] Fix namespace test --- tests/UsePHPParser4Test.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/UsePHPParser4Test.php b/tests/UsePHPParser4Test.php index 073ffbe..862c9d5 100644 --- a/tests/UsePHPParser4Test.php +++ b/tests/UsePHPParser4Test.php @@ -10,7 +10,7 @@ final class UsePHPParser4Test extends TestCase public function test(): void { if ((int) Version::id() >= 11) { - $this->markTestSkipped('Only for PHPUnit 11+'); + $this->markTestSkipped('Only for PHPUnit < 11'); } // this uses nikic/php-parser v4 parser