Skip to content

Instantly share code, notes, and snippets.

@psorensen
Last active February 17, 2022 16:54
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save psorensen/037b0925696b9c0487ef16211b33bff3 to your computer and use it in GitHub Desktop.
Save psorensen/037b0925696b9c0487ef16211b33bff3 to your computer and use it in GitHub Desktop.
WP Env Failing on CirclCI workflow
## .circleci/config.yml
version: 2.1
executors:
node-executor:
docker:
- image: cimg/node:14.19.0-browsers
user: root
jobs:
release:
executor: node-executor
steps:
- setup_remote_docker:
version: 20.10.11
- checkout
- run: npm install
- run: npm run test # (wp-env start && 10up-toolkit test-unit-jest)
- run: npx semantic-release
workflows:
version: 2
release:
jobs:
- release:
filters:
branches:
only: trunk
context: SECURECREDS
#!/bin/bash -eo pipefail
npm run test
> post-restriction@1.0.0 test /root/project
> wp-env start && 10up-toolkit test-unit-jest
✖ Error while running docker-compose command.
WordPress is already installed.
Success: Updated the constant 'WP_DEBUG' in the 'wp-config.php' file with the raw value 'true'.
Success: Updated the constant 'SCRIPT_DEBUG' in the 'wp-config.php' file with the raw value 'true'.
Success: Updated the constant 'WP_ENVIRONMENT_TYPE' in the 'wp-config.php' file with the value 'local'.
Success: Updated the constant 'WP_PHP_BINARY' in the 'wp-config.php' file with the value 'php'.
Success: Updated the constant 'WP_TESTS_EMAIL' in the 'wp-config.php' file with the value 'admin@example.org'.
Success: Updated the constant 'WP_TESTS_TITLE' in the 'wp-config.php' file with the value 'Test Blog'.
Success: Updated the constant 'WP_TESTS_DOMAIN' in the 'wp-config.php' file with the value 'http://localhost:8888/'.
Success: Updated the constant 'WP_SITEURL' in the 'wp-config.php' file with the value 'http://localhost:8888/'.
Success: Updated the constant 'WP_HOME' in the 'wp-config.php' file with the value 'http://localhost:8888/'.
Container 6abbda60e8dd18e6eadd93b9ff7b42e3-mysql-1 Running
Container 6abbda60e8dd18e6eadd93b9ff7b42e3-wordpress-1 Running
Warning: The 'project' plugin could not be found.
Error: No plugins activated.
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! post-restriction@1.0.0 test: `wp-env start && 10up-toolkit test-unit-jest`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the post-restriction@1.0.0 test script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! /root/.npm/_logs/2022-02-17T05_35_47_475Z-debug.log
Exited with code exit status 1
CircleCI received exit code 1
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment