From e1664148a252629263f1aa215e8e20c7c16fa300 Mon Sep 17 00:00:00 2001 From: Markus Staab Date: Wed, 21 Oct 2026 07:29:17 +0200 Subject: [PATCH] Improve pcov tests --- .github/workflows/e2e-tests.yml | 18 +++++++++--------- e2e/bug-15407/pcov-check.php | 6 ++++++ e2e/bug-15407/phpstan.neon | 6 ++++++ e2e/bug-15407/test.php | 3 +++ 4 files changed, 24 insertions(+), 9 deletions(-) create mode 100644 e2e/bug-15407/pcov-check.php create mode 100644 e2e/bug-15407/phpstan.neon create mode 100644 e2e/bug-15407/test.php diff --git a/.github/workflows/e2e-tests.yml b/.github/workflows/e2e-tests.yml index 98fdc931fbd..7945c6f431b 100644 --- a/.github/workflows/e2e-tests.yml +++ b/.github/workflows/e2e-tests.yml @@ -2036,20 +2036,20 @@ jobs: ../bashunit assert contains 'Bar.php:15:Call to an undefined method Ds\Pair::copy().' "$OUTPUT" ../bashunit assert not_contains 'Ds\Seq' "$OUTPUT" - script: | - echo " test.php - XDEBUG_HANDLER_DEBUG=1 bin/phpstan analyse test.php 2>&1 | tee -a output.txt - e2e/bashunit assert file_contains output.txt "Process restarting" + cd e2e/bug-15407 + XDEBUG_HANDLER_DEBUG=1 ../../bin/phpstan analyse --no-progress 2>&1 | tee -a output.txt + ../bashunit assert file_contains output.txt "Process restarting" coverage: "pcov" - script: | - echo " test.php - XDEBUG_HANDLER_DEBUG=1 bin/phpstan analyse test.php 2>&1 | tee -a output.txt - e2e/bashunit assert file_contains output.txt "Process restarting" + cd e2e/bug-15407 + XDEBUG_HANDLER_DEBUG=1 ../../bin/phpstan analyse --no-progress 2>&1 | tee -a output.txt + ../bashunit assert file_contains output.txt "Process restarting" coverage: "pcov" ini-values: "pcov.enabled=1" - script: | - echo " test.php - XDEBUG_HANDLER_DEBUG=1 bin/phpstan analyse test.php 2>&1 | tee -a output.txt - e2e/bashunit assert file_not_contains output.txt "Process restarting" + cd e2e/bug-15407 + XDEBUG_HANDLER_DEBUG=1 ../../bin/phpstan analyse --no-progress 2>&1 | tee -a output.txt + ../bashunit assert file_not_contains output.txt "Process restarting" coverage: "pcov" ini-values: "pcov.enabled=0" diff --git a/e2e/bug-15407/pcov-check.php b/e2e/bug-15407/pcov-check.php new file mode 100644 index 00000000000..4c4934b8333 --- /dev/null +++ b/e2e/bug-15407/pcov-check.php @@ -0,0 +1,6 @@ +