diff --git a/.github/workflows/playground-tests.yml b/.github/workflows/playground-tests.yml index 884dc42..503d7ac 100644 --- a/.github/workflows/playground-tests.yml +++ b/.github/workflows/playground-tests.yml @@ -72,7 +72,7 @@ jobs: timeout 60 bash -c 'until curl -s http://localhost:8888; do sleep 2; done' # Run Cypress tests against WordPress Playground - npm run test:single:headless + npx cypress run --config specPattern=cypress/e2e/playground-single-site.cy.js performance-test: name: WordPress Performance Tests diff --git a/.wiki/Playground-Testing.md b/.wiki/Playground-Testing.md index 2e9bf85..7f4c1c7 100644 --- a/.wiki/Playground-Testing.md +++ b/.wiki/Playground-Testing.md @@ -15,9 +15,9 @@ This document explains how to use WordPress Playground for testing our plugin. The easiest way to test our plugin with WordPress Playground is to use the online version: -1. Single site testing: [Open in WordPress Playground](https://playground.wordpress.net/?blueprint-url=https://raw.githubusercontent.com/wpallstars/wp-plugin-starter-template-for-ai-coding/main/playground/blueprint.json&_t=1) +1. Single site testing: [Open in WordPress Playground](https://playground.wordpress.net/?blueprint-url=https://raw.githubusercontent.com/wpallstars/wp-plugin-starter-template-for-ai-coding/main/playground/blueprint.json&_t=2) -2. Multisite testing: [Open in WordPress Playground](https://playground.wordpress.net/?blueprint-url=https://raw.githubusercontent.com/wpallstars/wp-plugin-starter-template-for-ai-coding/main/playground/multisite-blueprint.json&_t=1) +2. Multisite testing: [Open in WordPress Playground](https://playground.wordpress.net/?blueprint-url=https://raw.githubusercontent.com/wpallstars/wp-plugin-starter-template-for-ai-coding/main/playground/multisite-blueprint.json&_t=2) These links will automatically set up WordPress with multisite enabled, WP_DEBUG enabled, and both the Plugin Toggle and Kadence Blocks plugins activated. @@ -111,8 +111,8 @@ We have two blueprints for testing: To run tests with WordPress Playground: 1. Open the appropriate WordPress Playground link: - * [Single site](https://playground.wordpress.net/?blueprint-url=https://raw.githubusercontent.com/wpallstars/wp-plugin-starter-template-for-ai-coding/main/playground/blueprint.json&_t=1) - * [Multisite](https://playground.wordpress.net/?blueprint-url=https://raw.githubusercontent.com/wpallstars/wp-plugin-starter-template-for-ai-coding/main/playground/multisite-blueprint.json&_t=1) + * [Single site](https://playground.wordpress.net/?blueprint-url=https://raw.githubusercontent.com/wpallstars/wp-plugin-starter-template-for-ai-coding/main/playground/blueprint.json&_t=2) + * [Multisite](https://playground.wordpress.net/?blueprint-url=https://raw.githubusercontent.com/wpallstars/wp-plugin-starter-template-for-ai-coding/main/playground/multisite-blueprint.json&_t=2) 2. Test the plugin manually in the browser diff --git a/.wiki/Testing.md b/.wiki/Testing.md index 715046b..620ef2d 100644 --- a/.wiki/Testing.md +++ b/.wiki/Testing.md @@ -106,9 +106,9 @@ WordPress Playground runs WordPress entirely in the browser using WebAssembly. T The easiest way to test our plugin with WordPress Playground is to use the online version: -1. Single site testing: [Open in WordPress Playground](https://playground.wordpress.net/?blueprint-url=https://raw.githubusercontent.com/wpallstars/wp-plugin-starter-template-for-ai-coding/main/playground/blueprint.json&_t=1) +1. Single site testing: [Open in WordPress Playground](https://playground.wordpress.net/?blueprint-url=https://raw.githubusercontent.com/wpallstars/wp-plugin-starter-template-for-ai-coding/main/playground/blueprint.json&_t=2) -2. Multisite testing: [Open in WordPress Playground](https://playground.wordpress.net/?blueprint-url=https://raw.githubusercontent.com/wpallstars/wp-plugin-starter-template-for-ai-coding/main/playground/multisite-blueprint.json&_t=1) +2. Multisite testing: [Open in WordPress Playground](https://playground.wordpress.net/?blueprint-url=https://raw.githubusercontent.com/wpallstars/wp-plugin-starter-template-for-ai-coding/main/playground/multisite-blueprint.json&_t=2) These links will automatically set up WordPress with multisite enabled, WP_DEBUG enabled, and both the Plugin Toggle and Kadence Blocks plugins activated. diff --git a/playground/blueprint.json b/playground/blueprint.json index 6edd64a..374bdc2 100644 --- a/playground/blueprint.json +++ b/playground/blueprint.json @@ -12,9 +12,23 @@ "WP_DEBUG": true } }, + { + "step": "installPlugin", + "pluginData": { + "resource": "wordpress.org/plugins", + "slug": "plugin-toggle" + } + }, + { + "step": "installPlugin", + "pluginData": { + "resource": "wordpress.org/plugins", + "slug": "kadence-blocks" + } + }, { "step": "wp-cli", - "command": "wp plugin install plugin-toggle kadence-blocks --activate" + "command": "wp plugin activate plugin-toggle kadence-blocks" } ] } diff --git a/playground/index.html b/playground/index.html index 65f5545..9065793 100644 --- a/playground/index.html +++ b/playground/index.html @@ -21,6 +21,6 @@
- +