Fix code quality issues: add iframe titles, fix Markdown formatting, update documentation, and clean up test files
This commit is contained in:
@@ -90,14 +90,14 @@ wp import
|
||||
In a WordPress multisite environment, there are two ways to activate plugins:
|
||||
|
||||
1. **Network Activation**: Activates a plugin for all sites in the network
|
||||
- In the WordPress admin, go to Network Admin > Plugins
|
||||
- Click "Network Activate" under the plugin
|
||||
- Or use WP-CLI: `wp plugin install plugin-name --activate-network`
|
||||
* In the WordPress admin, go to Network Admin > Plugins
|
||||
* Click "Network Activate" under the plugin
|
||||
* Or use WP-CLI: `wp plugin install plugin-name --activate-network`
|
||||
|
||||
2. **Per-Site Activation**: Activates a plugin for a specific site
|
||||
- In the WordPress admin, go to the specific site's admin area
|
||||
- Go to Plugins and activate the plugin for that site only
|
||||
- Or use WP-CLI: `wp plugin activate plugin-name --url=site-url`
|
||||
* In the WordPress admin, go to the specific site's admin area
|
||||
* Go to Plugins and activate the plugin for that site only
|
||||
* Or use WP-CLI: `wp plugin activate plugin-name --url=site-url`
|
||||
|
||||
Our multisite blueprint uses network activation for the Plugin Toggle plugin as an example.
|
||||
|
||||
@@ -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/feature/testing-framework/playground/blueprint.json&_t=11)
|
||||
- [Multisite](https://playground.wordpress.net/?blueprint-url=https://raw.githubusercontent.com/wpallstars/wp-plugin-starter-template-for-ai-coding/feature/testing-framework/playground/multisite-blueprint.json&_t=23)
|
||||
* [Single site](https://playground.wordpress.net/?blueprint-url=https://raw.githubusercontent.com/wpallstars/wp-plugin-starter-template-for-ai-coding/feature/testing-framework/playground/blueprint.json&_t=11)
|
||||
* [Multisite](https://playground.wordpress.net/?blueprint-url=https://raw.githubusercontent.com/wpallstars/wp-plugin-starter-template-for-ai-coding/feature/testing-framework/playground/multisite-blueprint.json&_t=23)
|
||||
|
||||
2. Test the plugin manually in the browser
|
||||
|
||||
|
||||
@@ -38,6 +38,7 @@ npm run setup:single
|
||||
```
|
||||
|
||||
This will:
|
||||
|
||||
1. Start a WordPress single site environment using wp-env
|
||||
2. Install and activate our plugin
|
||||
3. Configure WordPress for testing
|
||||
@@ -50,6 +51,7 @@ npm run setup:multisite
|
||||
```
|
||||
|
||||
This will:
|
||||
|
||||
1. Start a WordPress multisite environment using wp-env
|
||||
2. Install and activate our plugin network-wide
|
||||
3. Create a test subsite
|
||||
@@ -158,7 +160,8 @@ describe('WordPress Single Site Tests', () => {
|
||||
|
||||
We have GitHub Actions workflows for running tests in CI/CD:
|
||||
|
||||
* `.github/workflows/cypress.yml`: Runs Cypress tests
|
||||
* `.github/workflows/wordpress-tests.yml`: Runs wp-env e2e tests
|
||||
* `.github/workflows/playground-tests.yml`: Runs Playground e2e tests
|
||||
* `.github/workflows/phpunit.yml`: Runs PHPUnit tests (coming soon)
|
||||
|
||||
## Troubleshooting
|
||||
|
||||
Reference in New Issue
Block a user