Skip to content

Update doc for update from the core to 3.0.0 #15

Update doc for update from the core to 3.0.0

Update doc for update from the core to 3.0.0 #15

Workflow file for this run

name: Unit/Integration tests
on:
pull_request:
branches:
- trunk
- develop
- branch-*
- feature/*
- v1
jobs:
run:
runs-on: ${{ matrix.operating-system }}
strategy:
fail-fast: true
matrix:
operating-system: [ubuntu-24.04]
php-versions: ['7.4']
wp-versions: ['5.9', 'latest']
name: WP ${{ matrix.wp-versions }} with PHP ${{ matrix.php-versions }} on ${{ matrix.operating-system }}.
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Setup NPM
uses: actions/setup-node@v4
with:
node-version: 'lts/*'
- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php-versions }}
coverage: none # XDebug can be enabled here 'coverage: xdebug'
tools: composer:v2, phpunit
- name: Npm install
run: npm ci
- name: Get composer cache directory
id: composercache
run: echo "::set-output name=dir::$(composer config cache-files-dir)"
- name: Cache dependencies
uses: actions/cache@v2
with:
path: ${{ steps.composercache.outputs.dir }}
key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.json') }}
restore-keys: ${{ runner.os }}-composer-
- name: Install dependencies
run: composer install --prefer-dist --no-interaction
- name: Create override wp-env
if: matrix.wp-versions != 'latest'
env:
PHP_VERSION: ${{ matrix.php-versions }}
WP_VERSION: ${{ matrix.wp-versions }}
run: |
cat <<EOF > .wp-env.override.json
{
"phpVersion": "$PHP_VERSION",
"core": "WordPress/WordPress#$WP_VERSION"
}
EOF
- name: Create override wp-env
if: matrix.wp-versions == 'latest'
env:
PHP_VERSION: ${{ matrix.php-versions }}
run: |
cat <<EOF > .wp-env.override.json
{
"phpVersion": "$PHP_VERSION"
}
EOF
- name: Starting WP ENV
run: npm run wp-env:start
- name: Test
run: npm run run-tests