Skip to content

Tweak the packages installed #165

Tweak the packages installed

Tweak the packages installed #165

Workflow file for this run

name: PHP Tests
on: push
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
test:
name: WP ${{ matrix.wp }} and PHP ${{ matrix.php }}
runs-on: ubuntu-latest
continue-on-error: ${{ matrix.allowed_failure }}
strategy:
fail-fast: true
matrix:
php: [ '7.4' ]
wp: [ '5.6', '5.7' ]
allowed_failure: [ false ]
include:
- php: '8.0'
wp: '5.6'
allowed_failure: true
- php: '8.0'
wp: '5.7'
allowed_failure: true
steps:
- name: Checkout code
uses: actions/checkout@master
- name: Setup PHP ${{ matrix.php }}
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php }}
coverage: pcov
# https://make.wordpress.org/hosting/handbook/handbook/server-environment/#php-extensions
extensions: curl, dom, exif, fileinfo, hash, json, mbstring, mysqli, libsodium, openssl, pcre, imagick, xml, zip
- name: Install Composer dependencies (PHP < 8.0 )
if: ${{ matrix.php < 8.0 }}
uses: ramsey/composer-install@v1
- name: Install Composer dependencies (PHP >= 8.0)
if: ${{ matrix.php >= 8.0 }}
uses: ramsey/composer-install@v1
with:
composer-options: --ignore-platform-reqs
- name: Start MySQL service
run: sudo systemctl start mysql.service
- name: Install WordPress test site
run: bash bin/install-wp-tests.sh wordpress_test root root localhost ${{ matrix.wp }}
- name: Run PHPCS diff tests
run: bash bin/phpcs-diff.sh
- name: Run PHPUnit tests (single site)
run: composer integration
- name: Run PHPUnit tests (multisite)
run: composer integration-ms