Skip to content

Spin up a WooCommerce Blocks testing environment in seconds.

License

Notifications You must be signed in to change notification settings

nielslange/woo-test-environment

Repository files navigation

WooCommerce Test Environment

WP-CLI command to spin up a WooCommerce test environment in seconds.

Quick links: Installing | Usage | Contributing

Installing

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.git

Usage

wp woo-test-environment setup
wp woo-test-environment teardown

Parameter

The command wp woo-test-environment setup can accept the following optional parameter:

  • --blocks This 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.

Examples

Installing WooCommerce only

wp woo-test-environment setup

Installing WooCommerce and WooCommerce Blocks

wp woo-test-environment setup --blocks

Installing WooCommerce, WooCommerce Blocks and Gutenberg

wp woo-test-environment setup --blocks --gutenberg

Installing WooCommerce and WooCommerce Blocks 7.3.0

wp woo-test-environment setup --blocks=7.3.0

Installing 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.zip

Installing WooCommerce and Storefront

wp woo-test-environment setup --theme=storefront

Installing WooCommerce and Stripe

wp woo-test-environment setup --stripe

Installing WooCommerce, WooCommerce Blocks, Gutenberg and Storefront

wp woo-test-environment setup --blocks --gutenberg --theme=storefront

Installing WooCommerce, WooCommerce Blocks, Gutenberg, Stripe and Storefront

wp woo-test-environment setup --blocks --gutenberg --stripe --theme=storefront

Contributing

Contributions are always welcome! Feel free to create a new issue or pull request.