Skip to content
This repository was archived by the owner on Apr 17, 2023. It is now read-only.
Closed
Show file tree
Hide file tree
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
49 changes: 49 additions & 0 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
version: 2

references:
phpunit_steps: &phpunit_steps
steps:
- checkout

- run: sudo apt-get update
- run: sudo apt-get install subversion default-mysql-client
- run: sudo docker-php-ext-install mysqli

- restore_cache:
keys:
- v1-dependencies-{{ checksum "composer.lock" }}
# fallback to using the latest cache if no exact match is found
- v1-dependencies-
- run: composer install --prefer-source --no-interaction
- save_cache:
key: v1-dependencies-{{ checksum "composer.lock" }}
paths:
- ./vendor

- run: bash bin/install-wp-tests.sh wordpress_test root '' 127.0.0.1 $WP_VERSION

- run: ./vendor/bin/phpunit

jobs:
php7.4-singlesite:
docker:
- image: circleci/php:7.4
- image: circleci/mysql:5.7
environment:
WP_MULTISITE=0
<<: *phpunit_steps

php7.4-multisite:
docker:
- image: circleci/php:7.4
- image: circleci/mysql:5.7
environment:
WP_MULTISITE=1
<<: *phpunit_steps

workflows:
version: 2
test:
jobs:
- php7.4-singlesite
- php7.4-multisite
3 changes: 2 additions & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@
"facebook/graph-sdk": "^5.6"
},
"require-dev": {
"wp-coding-standards/wpcs": "*"
"wp-coding-standards/wpcs": "*",
"phpunit/phpunit": "^7.0"
}
}
Loading