Changeset 51604
- Timestamp:
- 08/11/2021 03:42:06 PM (3 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/.github/workflows/phpunit-tests.yml
r51588 r51604 36 36 jobs: 37 37 # Runs the PHPUnit tests for WordPress. 38 # 39 # Note: Steps running tests for PHP 8.1 jobs are allowed to "continue-on-error". 40 # This prevents workflow runs from being marked as "failed" when only PHP 8.1 fails. 38 41 # 39 42 # Performs the following steps: … … 189 192 190 193 - name: Run slow PHPUnit tests 191 if: ${{ matrix. php != '8.1' && matrix.split_slow }}194 if: ${{ matrix.split_slow }} 192 195 run: npm run test:php-composer -- --verbose -c ${{ env.PHPUNIT_CONFIG }} --group ${{ env.SLOW_TESTS }} 193 196 … … 201 204 202 205 - name: Run PHPUnit tests 203 if: ${{ matrix.php >= '7.0' && matrix.php != '8.1' }} 206 if: ${{ matrix.php >= '7.0' }} 207 continue-on-error: ${{ matrix.php == '8.1' }} 204 208 run: npm run test:php-composer -- --verbose -c ${{ env.PHPUNIT_CONFIG }} 205 209 206 210 - name: Run AJAX tests 207 if: ${{ matrix.php != '8.1' && ! matrix.split_slow }} 211 if: ${{ ! matrix.split_slow }} 212 continue-on-error: ${{ matrix.php == '8.1' }} 208 213 run: npm run test:php-composer -- --verbose -c ${{ env.PHPUNIT_CONFIG }} --group ajax 209 214 210 215 - name: Run ms-files tests as a multisite install 211 if: ${{ matrix.php != '8.1' && matrix.multisite && ! matrix.split_slow }} 216 if: ${{ matrix.multisite && ! matrix.split_slow }} 217 continue-on-error: ${{ matrix.php == '8.1' }} 212 218 run: npm run test:php-composer -- --verbose -c tests/phpunit/multisite.xml --group ms-files 213 219 214 220 - name: Run external HTTP tests 215 if: ${{ matrix.php != '8.1' && ! matrix.multisite && ! matrix.split_slow }} 221 if: ${{ ! matrix.multisite && ! matrix.split_slow }} 222 continue-on-error: ${{ matrix.php == '8.1' }} 216 223 run: npm run test:php-composer -- --verbose -c phpunit.xml.dist --group external-http 217 224 218 225 # __fakegroup__ is excluded to force PHPUnit to ignore the <exclude> settings in phpunit.xml.dist. 219 226 - name: Run (xDebug) tests 220 if: ${{ matrix.php != '8.1' && ! matrix.split_slow }} 227 if: ${{ ! matrix.split_slow }} 228 continue-on-error: ${{ matrix.php == '8.1' }} 221 229 run: LOCAL_PHP_XDEBUG=true npm run test:php-composer -- -v --group xdebug --exclude-group __fakegroup__ 222 223 #### Duplicate set of test runs specifically for PHP 8.1 while WP is not yet compatible. ####224 # Splitting off the test runs for PHP 8.1 allows us to apply "continue-on-error" to the job steps,225 # which will prevent the builds from showing as "failed" when they only fail on PHP 8.1.226 # This block should be removed once all PHP 8.1 test failures have been fixed.227 # When the block is removed, the conditions in the block above should also be adjusted back228 # to their original values.229 - name: Run slow PHPUnit tests230 if: ${{ matrix.php == '8.1' && matrix.split_slow }}231 continue-on-error: true232 run: npm run test:php-composer -- --verbose -c ${{ env.PHPUNIT_CONFIG }} --group ${{ env.SLOW_TESTS }}233 234 - name: Run PHPUnit tests235 if: ${{ matrix.php == '8.1' }}236 continue-on-error: true237 run: npm run test:php-composer -- --verbose -c ${{ env.PHPUNIT_CONFIG }}238 239 - name: Run AJAX tests240 if: ${{ matrix.php == '8.1' && ! matrix.split_slow }}241 continue-on-error: true242 run: npm run test:php-composer -- --verbose -c ${{ env.PHPUNIT_CONFIG }} --group ajax243 244 - name: Run ms-files tests as a multisite install245 if: ${{ matrix.php == '8.1' && matrix.multisite && ! matrix.split_slow }}246 continue-on-error: true247 run: npm run test:php-composer -- --verbose -c tests/phpunit/multisite.xml --group ms-files248 249 - name: Run external HTTP tests250 if: ${{ matrix.php == '8.1' && ! matrix.multisite && ! matrix.split_slow }}251 continue-on-error: true252 run: npm run test:php-composer -- --verbose -c phpunit.xml.dist --group external-http253 254 # __fakegroup__ is excluded to force PHPUnit to ignore the <exclude> settings in phpunit.xml.dist.255 - name: Run (xDebug) tests256 if: ${{ matrix.php == '8.1' && ! matrix.split_slow }}257 continue-on-error: true258 run: LOCAL_PHP_XDEBUG=true npm run test:php-composer -- -v --group xdebug --exclude-group __fakegroup__259 #### End of duplicate set of test runs. ####260 230 261 231 - name: Ensure version-controlled files are not modified or deleted
Note: See TracChangeset
for help on using the changeset viewer.