Skip to content

Commit b792ea0

Browse files
committed
GH Actions: update PHP ini configuration
Add `display_startup_errors=On` as per the current recommendation from PHPUnit. Ref: sebastianbergmann/phpunit-documentation-english@b3b159c
1 parent 8200932 commit b792ea0

File tree

5 files changed

+11
-9
lines changed

5 files changed

+11
-9
lines changed

.github/workflows/end-to-end-tests.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ jobs:
4545
uses: shivammathur/setup-php@v2
4646
with:
4747
php-version: ${{ matrix.php }}
48-
ini-values: "error_reporting=-1, display_errors=On"
48+
ini-values: "error_reporting=-1, display_errors=On, display_startup_errors=On"
4949
coverage: none
5050

5151
- name: "Install bashunit"

.github/workflows/quicktest.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ jobs:
5555
uses: shivammathur/setup-php@v2
5656
with:
5757
php-version: ${{ matrix.php }}
58-
ini-values: 'error_reporting=-1, display_errors=On'
58+
ini-values: 'error_reporting=-1, display_errors=On, display_startup_errors=On'
5959
coverage: none
6060

6161
# Install dependencies and handle caching in one go.

.github/workflows/reusable-build-phar.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ jobs:
4040
with:
4141
php-version: ${{ inputs.phpVersion }}
4242
coverage: none
43-
ini-values: phar.readonly=Off, error_reporting=-1, display_errors=On
43+
ini-values: phar.readonly=Off, error_reporting=-1, display_errors=On, display_startup_errors=On
4444

4545
- name: Build the phar files
4646
run: php scripts/build-phar.php

.github/workflows/test.yml

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -183,16 +183,18 @@ jobs:
183183
- name: Setup ini config
184184
id: set_ini
185185
shell: bash
186+
# yamllint disable rule:line-length
186187
run: |
187188
# Set the "short_open_tag" ini to make sure specific conditions are tested.
188189
# Also turn on error_reporting to ensure all notices are shown.
189190
if [[ ${{ matrix.custom_ini }} == true && "${{ matrix.php }}" == '5.5' ]]; then
190-
echo 'PHP_INI=error_reporting=-1, display_errors=On, date.timezone=Australia/Sydney, short_open_tag=On, asp_tags=On' >> "$GITHUB_OUTPUT"
191+
echo 'PHP_INI=error_reporting=-1, display_errors=On, display_startup_errors=On, date.timezone=Australia/Sydney, short_open_tag=On, asp_tags=On' >> "$GITHUB_OUTPUT"
191192
elif [[ ${{ matrix.custom_ini }} == true && "${{ matrix.php }}" != '5.5' ]]; then
192-
echo 'PHP_INI=error_reporting=-1, display_errors=On, date.timezone=Australia/Sydney, short_open_tag=On' >> "$GITHUB_OUTPUT"
193+
echo 'PHP_INI=error_reporting=-1, display_errors=On, display_startup_errors=On, date.timezone=Australia/Sydney, short_open_tag=On' >> "$GITHUB_OUTPUT"
193194
else
194-
echo 'PHP_INI=error_reporting=-1, display_errors=On' >> "$GITHUB_OUTPUT"
195+
echo 'PHP_INI=error_reporting=-1, display_errors=On, display_startup_errors=On' >> "$GITHUB_OUTPUT"
195196
fi
197+
# yamllint enable rule:line-length
196198
197199
- name: Install PHP
198200
uses: shivammathur/setup-php@v2
@@ -314,7 +316,7 @@ jobs:
314316
uses: shivammathur/setup-php@v2
315317
with:
316318
php-version: ${{ matrix.php }}
317-
ini-values: error_reporting=-1, display_errors=On${{ steps.set_ini.outputs.PHP_INI }}
319+
ini-values: error_reporting=-1, display_errors=On, display_startup_errors=On${{ steps.set_ini.outputs.PHP_INI }}
318320
coverage: xdebug
319321

320322
# This action also handles the caching of the dependencies.

.github/workflows/verify-release.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -149,7 +149,7 @@ jobs:
149149
uses: shivammathur/setup-php@v2
150150
with:
151151
php-version: 'latest'
152-
ini-values: error_reporting=-1, display_errors=On
152+
ini-values: error_reporting=-1, display_errors=On, display_startup_errors=On
153153
coverage: none
154154

155155
- name: Create a PHP file
@@ -219,7 +219,7 @@ jobs:
219219
uses: shivammathur/setup-php@v2
220220
with:
221221
php-version: 'latest'
222-
ini-values: error_reporting=-1, display_errors=On
222+
ini-values: error_reporting=-1, display_errors=On, display_startup_errors=On
223223
coverage: none
224224
tools: phive
225225

0 commit comments

Comments
 (0)