From fc7e7816166030c5239adbbe963470cdac018ddc Mon Sep 17 00:00:00 2001 From: jrfnl Date: Sun, 10 Aug 2025 00:51:33 +0200 Subject: [PATCH] GH Actions: update PHP ini configuration Add `display_startup_errors=On` as per the current recommendation from PHPUnit. Ref: https://github.com/sebastianbergmann/phpunit-documentation-english/commit/b3b159cbe9bd7eb5656dd381fc6f028549601dce --- .github/workflows/quicktest.yml | 6 +++--- .github/workflows/test.yml | 6 +++--- .github/workflows/update-website.yml | 2 +- 3 files changed, 7 insertions(+), 7 deletions(-) diff --git a/.github/workflows/quicktest.yml b/.github/workflows/quicktest.yml index d8b5a85..f81e66e 100644 --- a/.github/workflows/quicktest.yml +++ b/.github/workflows/quicktest.yml @@ -43,7 +43,7 @@ jobs: uses: shivammathur/setup-php@v2 with: php-version: ${{ matrix.php }} - ini-values: error_reporting=-1, display_errors=On + ini-values: error_reporting=-1, display_errors=On, display_startup_errors=On coverage: none # Install dependencies and handle caching in one go. @@ -124,9 +124,9 @@ jobs: id: set_ini run: | if [ "${{ contains( matrix.phpcs_version, 'dev' ) }}" != "true" ]; then - echo 'PHP_INI=error_reporting=E_ALL & ~E_DEPRECATED, display_errors=On' >> "$GITHUB_OUTPUT" + echo 'PHP_INI=error_reporting=E_ALL & ~E_DEPRECATED, display_errors=On, display_startup_errors=On' >> "$GITHUB_OUTPUT" else - echo 'PHP_INI=error_reporting=-1, display_errors=On' >> "$GITHUB_OUTPUT" + echo 'PHP_INI=error_reporting=-1, display_errors=On, display_startup_errors=On' >> "$GITHUB_OUTPUT" fi - name: Install PHP diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index e348c39..004ecb7 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -46,7 +46,7 @@ jobs: uses: shivammathur/setup-php@v2 with: php-version: ${{ matrix.php }} - ini-values: error_reporting=-1, display_errors=On + ini-values: error_reporting=-1, display_errors=On, display_startup_errors=On coverage: none tools: cs2pr @@ -170,9 +170,9 @@ jobs: # On stable PHPCS versions, allow for PHP deprecation notices. # Unit tests don't need to fail on those for stable releases where those issues won't get fixed anymore. if [ "${{ contains( matrix.phpcs_version, 'dev' ) }}" != "true" ]; then - echo 'PHP_INI=error_reporting=E_ALL & ~E_DEPRECATED, display_errors=On' >> "$GITHUB_OUTPUT" + echo 'PHP_INI=error_reporting=E_ALL & ~E_DEPRECATED, display_errors=On, display_startup_errors=On' >> "$GITHUB_OUTPUT" else - echo 'PHP_INI=error_reporting=-1, display_errors=On' >> "$GITHUB_OUTPUT" + echo 'PHP_INI=error_reporting=-1, display_errors=On, display_startup_errors=On' >> "$GITHUB_OUTPUT" fi - name: Install PHP diff --git a/.github/workflows/update-website.yml b/.github/workflows/update-website.yml index 7255d94..33613a0 100644 --- a/.github/workflows/update-website.yml +++ b/.github/workflows/update-website.yml @@ -56,7 +56,7 @@ jobs: uses: shivammathur/setup-php@v2 with: php-version: 'latest' - ini-values: error_reporting=-1, display_errors=On, log_errors_max_len=0 + ini-values: error_reporting=-1, display_errors=On, display_startup_errors=On, log_errors_max_len=0 coverage: none - name: Prepare the files which will be deployed to the GH Pages website