Skip to content

Commit

Permalink
Add rest acceptance test
Browse files Browse the repository at this point in the history
  • Loading branch information
markkelnar committed Jul 14, 2021
1 parent 9383647 commit 70c85d7
Show file tree
Hide file tree
Showing 9 changed files with 6,741 additions and 43 deletions.
3 changes: 2 additions & 1 deletion .env.dist
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ TEST_SITE_ADMIN_EMAIL=admin@localhost
# Used by wp-graphql-testing docker
TESTS_OUTPUT=tests/_output
SUITES=wpunit
SKIP_TESTS_CLEANUP=1

# Used by wp-config.php
WORDPRESS_DB_HOST=${DB_HOST}
Expand All @@ -56,4 +57,4 @@ MYSQL_PASSWORD=${DB_PASSWORD}
WP_VERSION=5.7.2
PHP_VERSION=7.4
WPGRAPHQL_VERSION=latest
DATA_DUMP_DIR=/var/log/apache2
DATA_DUMP_DIR=/var/log/apache2
6 changes: 5 additions & 1 deletion .github/workflows/tests-wordpress.yml
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,11 @@ jobs:
run: composer install

- name: Run phpunit script
run: docker-compose run app bash -c "cd wp-content/plugins/wp-graphql-persisted-queries ; vendor/bin/phpunit"
run: docker-compose run testing
env:
WP_VERSION: 5.7.2
PHP_VERSION: 7.4
SUITES: acceptance

- name: Run php code sniffer
run: ./vendor/bin/phpcs
3 changes: 2 additions & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@
"codeception/module-filesystem": "^1.0",
"codeception/module-cli": "^1.1",
"codeception/util-universalframework": "^1.0",
"php-webdriver/webdriver": "^1.11"
"php-webdriver/webdriver": "^1.11",
"codeception/module-rest": "^1.3"
}
}
Loading

0 comments on commit 70c85d7

Please sign in to comment.