Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 19 additions & 2 deletions .github/workflows/phpunit.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,10 +25,10 @@ jobs:
matrix:
include:
- php: 7.4
wordpress: 6.9
wordpress: trunk
multisite: 0
- php: 8.0
wordpress: 6.9
wordpress: trunk
multisite: 0

name: PHP ${{ matrix.php }} tests in WP ${{ matrix.wordpress }}
Expand All @@ -53,6 +53,23 @@ jobs:
sed -i "s/youremptytestdbnamehere/wordpress_tests/" wp-tests-config.php
sed -i "s/yourusernamehere/root/" wp-tests-config.php
sed -i "s/yourpasswordhere/root/" wp-tests-config.php

- name: Read WP core's required Node version
id: wp-node
run: echo "version=$(cat /tmp/wordpress/.nvmrc)" >> "$GITHUB_OUTPUT"

- name: Set up Node.js for WP core assets
uses: actions/setup-node@v5
with:
node-version: ${{ steps.wp-node.outputs.version }}

- name: Building WP core assets
# Core's dist JS/CSS isn't checked into git; missing it fails wp_head()'s
# wp_maybe_inline_styles() check (test_front_head).
run: |
cd /tmp/wordpress
npm ci
npm run build:dev
- name: Creating database
run: |
sudo /etc/init.d/mysql start
Expand Down
Loading