@@ -41,10 +41,14 @@ jobs:
4141 - name : Checkout code
4242 uses : actions/checkout@v4
4343
44+ - name : Install wordpress environment
45+ run : npm install -g @wordpress/env
46+
4447 - name : Setup PHP ${{ matrix.php }}
4548 uses : shivammathur/setup-php@v2
4649 with :
4750 php-version : ${{ matrix.php }}
51+ tools : composer
4852
4953 - name : Install Composer dependencies
5054 uses : ramsey/composer-install@v3
@@ -57,25 +61,13 @@ jobs:
5761 - name : Setup Problem Matchers for PHPUnit
5862 run : echo "::add-matcher::${{ runner.tool_cache }}/phpunit.json"
5963
60- - name : Show PHP and PHPUnit version info
61- run : |
62- php --version
63- ./vendor/bin/phpunit --version
64-
65- - name : Start MySQL Service
66- run : sudo systemctl start mysql.service
67-
68- # This is needed as the integration tests use SVN to download the WordPress core and test dependencies.
69- - name : Install SVN (Subversion)
70- run : |
71- sudo apt-get update
72- sudo apt-get install subversion
73-
74- - name : Prepare environment for integration tests
75- run : composer prepare-ci ${{ matrix.wordpress }}
64+ - name : Setup wp-env
65+ run : wp-env start
66+ env :
67+ WP_ENV_CORE : WordPress/WordPress#${{ matrix.wordpress }}
7668
7769 - name : Run integration tests (single site)
78- run : composer test
70+ run : composer test-integration
7971
8072 - name : Run integration tests (multisite)
81- run : composer test-ms
73+ run : composer test-integration- ms
0 commit comments