WP-CLI command to spin up a WooCommerce test environment in seconds.
Quick links: Installing | Usage | Contributing
Installing this package requires WP-CLI v0.23.0 or greater. Update to the latest stable release with wp cli update.
Once you've done so, you can install this package with following command.
wp package install [email protected]:nielslange/woo-test-environment.gitwp woo-test-environment setupwp woo-test-environment teardownThe command wp woo-test-environment setup can accept the following optional parameter:
--blocksThis parameter installs a certain WooCommerce Blocks version.--gutenberg[=<true>]This parameter installs and activates the latest version of the Gutenberg plugin.--theme=<theme>This parameter installs and activates the latest version of a certain theme.
Installing WooCommerce only
wp woo-test-environment setupInstalling WooCommerce and WooCommerce Blocks
wp woo-test-environment setup --blocksInstalling WooCommerce, WooCommerce Blocks and Gutenberg
wp woo-test-environment setup --blocks --gutenbergInstalling WooCommerce and WooCommerce Blocks 7.3.0
wp woo-test-environment setup --blocks=7.3.0Installing WooCommerce and WooCommerce Blocks via URL
wp woo-test-environment setup --blocks=https://github.com/woocommerce/woocommerce-blocks/releases/download/v7.8.2/woo-gutenberg-products-block.zipInstalling WooCommerce and Storefront
wp woo-test-environment setup --theme=storefrontInstalling WooCommerce and Stripe
wp woo-test-environment setup --stripeInstalling WooCommerce, WooCommerce Blocks, Gutenberg and Storefront
wp woo-test-environment setup --blocks --gutenberg --theme=storefrontInstalling WooCommerce, WooCommerce Blocks, Gutenberg, Stripe and Storefront
wp woo-test-environment setup --blocks --gutenberg --stripe --theme=storefrontContributions are always welcome! Feel free to create a new issue or pull request.