test
This commit is contained in:
parent
34d896d40d
commit
c0dc94844a
2 changed files with 20 additions and 4 deletions
|
@ -12,12 +12,9 @@ jobs:
|
|||
image: mariadb
|
||||
env:
|
||||
MYSQL_ROOT_PASSWORD: root
|
||||
ports:
|
||||
- 3306:3306
|
||||
strategy:
|
||||
matrix:
|
||||
php-versions: ['8.1']
|
||||
wp-version: [latest]
|
||||
name: Run phpunit tests
|
||||
env:
|
||||
extensions: mysql
|
||||
|
@ -47,7 +44,7 @@ jobs:
|
|||
run: sudo apt update && sudo apt -y upgrade && sudo apt -y install mysql-client
|
||||
|
||||
- name: Setup Test Environment
|
||||
run: bash bin/install-wp-tests.sh wordpress_test root root mysql:3306 ${{ matrix.wp-version }}
|
||||
run: bash bin/install-wp-tests.sh wordpress_test root root mysql latest
|
||||
|
||||
- name: Unit Testing
|
||||
run: ./vendor/bin/phpunit
|
||||
|
|
19
.woodpecker/test.yml
Normal file
19
.woodpecker/test.yml
Normal file
|
@ -0,0 +1,19 @@
|
|||
when:
|
||||
- event: push
|
||||
branch: woodpecker
|
||||
|
||||
steps:
|
||||
- name: build
|
||||
image: php:8.3
|
||||
environment:
|
||||
WP_TESTS_PHPUNIT_POLYFILLS_PATH: vendor/yoast/phpunit-polyfills
|
||||
commands:
|
||||
- apt -y update
|
||||
- apt -y install libonig-dev
|
||||
- docker-php-ext-install mbstring mysqli pdo_mysql intl gd zip bz2
|
||||
- docker-php-ext-enable mbstring mysqli pdo_mysql intl gd zip bz2
|
||||
- composer require --dev yoast/phpunit-polyfills:"^3.0"
|
||||
- composer install
|
||||
- bash bin/install-wp-tests.sh wordpress_tests root mysql mysql latest true
|
||||
- phpunit --configuration phpunit.xml.dist
|
||||
|
Loading…
Reference in a new issue