From 9fb01eecb51e097f7ae590a88fbe454b21d8ec06 Mon Sep 17 00:00:00 2001 From: Markus Staab Date: Mon, 29 Jun 2026 12:07:54 +0200 Subject: [PATCH 1/7] Upload coverage reports artifacts --- .github/workflows/tests.yml | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 6503b737bd6..b1a1c98037e 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -345,9 +345,19 @@ jobs: run: | php -d pcov.enabled=1 tests/vendor/bin/paratest \ --passthru-php="'-d' 'pcov.enabled=1'" \ - --coverage-xml=tmp/coverage/coverage-xml --log-junit=tmp/coverage/junit.xml \ + --coverage-xml=tmp/coverage/coverage-xml \ + --coverage-cobertura=tmp/coverage/cobertura.xml \ + --log-junit=tmp/coverage/junit.xml \ --exclude-source-from-xml-coverage + - uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1 + with: + name: coverage-reports + path: | + tmp/coverage/coverage-xml + tmp/coverage/cobertura.xml + tmp/coverage/junit.xml + - name: "Run infection" run: | git fetch --depth=1 origin ${{ steps.default-branch.outputs.name }} From 5ec5e099c08b70122065fb3a7a00b9dfab14e266 Mon Sep 17 00:00:00 2001 From: Markus Staab Date: Mon, 29 Jun 2026 12:21:57 +0200 Subject: [PATCH 2/7] Update tests.yml --- .github/workflows/tests.yml | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index b1a1c98037e..f58390b0b24 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -346,17 +346,14 @@ jobs: php -d pcov.enabled=1 tests/vendor/bin/paratest \ --passthru-php="'-d' 'pcov.enabled=1'" \ --coverage-xml=tmp/coverage/coverage-xml \ - --coverage-cobertura=tmp/coverage/cobertura.xml \ + --coverage-clover=tmp/coverage/clover.xml \ --log-junit=tmp/coverage/junit.xml \ --exclude-source-from-xml-coverage - uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1 with: name: coverage-reports - path: | - tmp/coverage/coverage-xml - tmp/coverage/cobertura.xml - tmp/coverage/junit.xml + path: tmp/coverage - name: "Run infection" run: | From 365094e5a9b5f93a33a8e2a4d6fe865960fac622 Mon Sep 17 00:00:00 2001 From: Markus Staab Date: Mon, 29 Jun 2026 15:27:34 +0200 Subject: [PATCH 3/7] use PHPUnit 13 --- .github/workflows/tests.yml | 5 ++--- composer.json | 2 +- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index f58390b0b24..59faca640d6 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -278,7 +278,6 @@ jobs: fail-fast: false matrix: php-version: - - "8.3" - "8.4" operating-system: [ubuntu-latest] @@ -312,8 +311,8 @@ jobs: - name: "Upgrade PHPUnit with Paratest to speedup coverage generation" shell: bash run: | - composer require --dev phpunit/phpunit:^12 brianium/paratest:^7.16 symfony/process:^7 symfony/string:^7 symfony/console:^7 --update-with-dependencies --ignore-platform-reqs --working-dir=tests - composer require --dev phpunit/phpunit:^12 sebastian/diff --update-with-dependencies --ignore-platform-reqs + composer require --dev phpunit/phpunit:^13 brianium/paratest:^7.16 symfony/process:^7 symfony/string:^7 symfony/console:^7 --update-with-dependencies --ignore-platform-reqs --working-dir=tests + composer require --dev phpunit/phpunit:^13 sebastian/diff --update-with-dependencies --ignore-platform-reqs - uses: "ramsey/composer-install@65e4f84970763564f46a70b8a54b90d033b3bdda" # v4.0.0 with: diff --git a/composer.json b/composer.json index a3fb8379a48..b09154511e0 100644 --- a/composer.json +++ b/composer.json @@ -45,7 +45,7 @@ "react/promise": "^3.2", "react/socket": "^1.3", "react/stream": "^1.1", - "sebastian/diff": "^6.0.2 || ^7", + "sebastian/diff": "^6.0.2 || ^7 || ^8", "symfony/console": "^5.4.3", "symfony/finder": "^5.4.3", "symfony/polyfill-intl-grapheme": "^1.23", From 870339d1b9ff3f857df1113659a6caaf513b07dd Mon Sep 17 00:00:00 2001 From: Markus Staab Date: Mon, 29 Jun 2026 15:28:54 +0200 Subject: [PATCH 4/7] composer update nothing --- composer.lock | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/composer.lock b/composer.lock index 82027982057..039fba45a8d 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "b7c9871087473973539d2887bd1dc7c7", + "content-hash": "76d4dfbbb66dd1c7bdd53b8ced3bad35", "packages": [ { "name": "clue/ndjson-react", From 3c21731108f1a325a7e2c5752df4d4d0d70256ea Mon Sep 17 00:00:00 2001 From: Markus Staab Date: Mon, 29 Jun 2026 15:52:26 +0200 Subject: [PATCH 5/7] Revert "composer update nothing" This reverts commit 870339d1b9ff3f857df1113659a6caaf513b07dd. --- composer.lock | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/composer.lock b/composer.lock index 039fba45a8d..82027982057 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "76d4dfbbb66dd1c7bdd53b8ced3bad35", + "content-hash": "b7c9871087473973539d2887bd1dc7c7", "packages": [ { "name": "clue/ndjson-react", From 8db99a6c9bbdc5b627a5de4a7f90b465cf033f7e Mon Sep 17 00:00:00 2001 From: Markus Staab Date: Mon, 29 Jun 2026 15:52:28 +0200 Subject: [PATCH 6/7] Revert "use PHPUnit 13" This reverts commit 365094e5a9b5f93a33a8e2a4d6fe865960fac622. --- .github/workflows/tests.yml | 5 +++-- composer.json | 2 +- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 59faca640d6..f58390b0b24 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -278,6 +278,7 @@ jobs: fail-fast: false matrix: php-version: + - "8.3" - "8.4" operating-system: [ubuntu-latest] @@ -311,8 +312,8 @@ jobs: - name: "Upgrade PHPUnit with Paratest to speedup coverage generation" shell: bash run: | - composer require --dev phpunit/phpunit:^13 brianium/paratest:^7.16 symfony/process:^7 symfony/string:^7 symfony/console:^7 --update-with-dependencies --ignore-platform-reqs --working-dir=tests - composer require --dev phpunit/phpunit:^13 sebastian/diff --update-with-dependencies --ignore-platform-reqs + composer require --dev phpunit/phpunit:^12 brianium/paratest:^7.16 symfony/process:^7 symfony/string:^7 symfony/console:^7 --update-with-dependencies --ignore-platform-reqs --working-dir=tests + composer require --dev phpunit/phpunit:^12 sebastian/diff --update-with-dependencies --ignore-platform-reqs - uses: "ramsey/composer-install@65e4f84970763564f46a70b8a54b90d033b3bdda" # v4.0.0 with: diff --git a/composer.json b/composer.json index b09154511e0..a3fb8379a48 100644 --- a/composer.json +++ b/composer.json @@ -45,7 +45,7 @@ "react/promise": "^3.2", "react/socket": "^1.3", "react/stream": "^1.1", - "sebastian/diff": "^6.0.2 || ^7 || ^8", + "sebastian/diff": "^6.0.2 || ^7", "symfony/console": "^5.4.3", "symfony/finder": "^5.4.3", "symfony/polyfill-intl-grapheme": "^1.23", From 276e6c21dc294c1dc439f6fc552fba83cd7771ba Mon Sep 17 00:00:00 2001 From: Markus Staab Date: Mon, 29 Jun 2026 17:25:58 +0200 Subject: [PATCH 7/7] Update Makefile --- Makefile | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/Makefile b/Makefile index c37145d6aac..5a426f84b95 100644 --- a/Makefile +++ b/Makefile @@ -209,3 +209,11 @@ phpbench: .PHONY: phpbench-baseline phpbench-baseline: XDEBUG_MODE=off tests/vendor/bin/phpbench run --dump-file=tests/bench/storage/local-baseline.xml + +download-coverage: + rm -rf tmp/coverage-download + mkdir tmp/coverage-download + (cd tmp/coverage-download; gh run download `gh run ls --repo=phpstan/phpstan-src --branch=\`git for-each-ref --format='%(upstream:short)' $$(git symbolic-ref -q HEAD) |cut -d/ -f2\` --workflow=tests.yml --limit=1 --json=databaseId --jq '.[].databaseId'` --repo=phpstan/phpstan-src --name=coverage-reports) + sed -i '' -e 's,/home/runner/work/phpstan-src/phpstan-src/,'"$$PWD"/',g' tmp/coverage-download/clover.xml + cp tmp/coverage-download/clover.xml tmp/coverage/clover.xml +