diff --git a/.github/workflows/ci-php.yml b/.github/workflows/ci-php.yml index 37c9dc7a8..882d63055 100644 --- a/.github/workflows/ci-php.yml +++ b/.github/workflows/ci-php.yml @@ -19,12 +19,18 @@ jobs: test: name: "PHPUnit: MW ${{ matrix.mw }}, PHP ${{ matrix.php }}" + continue-on-error: ${{ matrix.experimental }} + strategy: fail-fast: false matrix: include: - mw: 'REL1_43' php: '8.3' + experimental: false + - mw: 'master' + php: '8.5' + experimental: true runs-on: ubuntu-latest diff --git a/.github/workflows/installMediaWiki.sh b/.github/workflows/installMediaWiki.sh index 2ca5b881e..d957a0bab 100644 --- a/.github/workflows/installMediaWiki.sh +++ b/.github/workflows/installMediaWiki.sh @@ -13,6 +13,16 @@ cd mediawiki composer install php maintenance/install.php --dbtype sqlite --dbuser root --dbname mw --dbpath $(pwd) --pass AdminPassword WikiName AdminUser +# MediaWiki 1.46 replaced `phpunit.xml.dist` with `phpunit.xml.template`, which +# is turned into a runnable `phpunit.xml` by `generatePHPUnitConfig.php`. The +# extension's `composer phpunit` script invokes `-c phpunit.xml.dist`, so on +# branches that only ship a template, generate the config and expose it under the +# name the script expects. Generated here (after `composer install` provides the +# autoloader, before the extension load lines are appended to LocalSettings.php). +if [ ! -f phpunit.xml.dist ] && [ -f phpunit.xml.template ]; then + php tests/phpunit/generatePHPUnitConfig.php + cp phpunit.xml phpunit.xml.dist +fi cat <<'EOT' >> LocalSettings.php error_reporting(E_ALL| E_STRICT);