Skip to content

Commit 2ac83c8

Browse files
committed
Merge branch 'dev/qit-refined' of https://github.com/woocommerce/pinterest-for-woocommerce into dev/qit-refined
2 parents f91ba98 + cfc9fd2 commit 2ac83c8

1 file changed

Lines changed: 40 additions & 0 deletions

File tree

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
name: Run Unit Tests
2+
3+
on:
4+
workflow_call:
5+
inputs:
6+
wp_version:
7+
required: true
8+
type: string
9+
wc_version:
10+
required: true
11+
type: string
12+
13+
jobs:
14+
php-tests:
15+
name: PHP unit tests - PHP ${{ matrix.php }}, WP ${{ matrix.wp-version }}
16+
runs-on: ubuntu-latest
17+
env:
18+
WP_CORE_DIR: "/tmp/wordpress/src"
19+
WP_TESTS_DIR: "/tmp/wordpress/tests/phpunit"
20+
strategy:
21+
matrix:
22+
php: [7.4, 8.3]
23+
wp-version: [latest]
24+
steps:
25+
- uses: actions/checkout@v4
26+
27+
- name: Prepare PHP
28+
uses: woocommerce/grow/prepare-php@actions-v1
29+
with:
30+
php-version: "${{ matrix.php }}"
31+
32+
- name: Prepare MySQL
33+
uses: woocommerce/grow/prepare-mysql@actions-v1
34+
35+
- name: Install WP tests
36+
shell: bash
37+
run: ./bin/install-wp-tests.sh wordpress_test root root localhost ${{ matrix.wp-version }}
38+
39+
- name: Run PHP unit tests
40+
run: composer test-unit

0 commit comments

Comments
 (0)