Skip to content

Commit

Permalink
Update PHPUnit tests workflow to be overridden for experimental jobs
Browse files Browse the repository at this point in the history
  • Loading branch information
thelovekesh committed Oct 10, 2023
1 parent 33de5e3 commit 1301315
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions .github/workflows/build-test-measure.yml
Original file line number Diff line number Diff line change
Expand Up @@ -548,6 +548,17 @@ jobs:
run: |
echo "WP_ENVIRONMENT_TYPE=local" >> $GITHUB_ENV
- name: Override default PHPUnit configuration
if: ${{ matrix.experimental == true && needs.pre-run.outputs.changed-php-count > 0 }}
run: |
cp phpunit.xml.dist phpunit.xml
# Avoid converting deprecations, errors, notices, and warnings to exceptions in experimental mode.
sed -i 's/convertDeprecationsToExceptions="true"/convertDeprecationsToExceptions="false"/g' phpunit.xml
sed -i 's/convertErrorsToExceptions="true"/convertErrorsToExceptions="false"/g' phpunit.xml
sed -i 's/convertNoticesToExceptions="true"/convertNoticesToExceptions="false"/g' phpunit.xml
sed -i 's/convertWarningsToExceptions="true"/convertWarningsToExceptions="false"/g' phpunit.xml
- name: Run tests
if: ${{ matrix.coverage == false && needs.pre-run.outputs.changed-php-count > 0 }}
run: |
Expand Down

0 comments on commit 1301315

Please sign in to comment.