Migrate E2E tests from @wordpress/env to WordPress Playground#19
Migrate E2E tests from @wordpress/env to WordPress Playground#19mattheu wants to merge 3 commits into
Conversation
Replaces the Docker-based test environment with WordPress Playground via @wp-playground/cli, eliminating the CI hangs and apt-lock issues caused by Docker setup. Playground boots automatically when tests run and tears down after, with no separate start/stop steps needed. Key changes: - Add blueprint.json: defines Playground environment (WP 6.9, PHP 8.3, TwentyTwentyFive, Advanced Query Loop plugin, mu-plugins, 25 test posts) - Add global-setup.js / global-teardown.js at project root (Playground lifecycle) - Update playwright.config.js: dynamic WP_BASE_URL, 120s timeout, no Docker - Update CI workflow: remove Docker steps, add PHP/WP version matrix (PHP 8.3/8.4 × WP 6.8/6.9/latest) - Remove tests/e2e/global-setup.js and wpCli/resetDatabase from fixtures.js - Remove @wordpress/env dependency, add @wp-playground/cli Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Playwright test resultsDetails
Failed testschromium › elasticpress-toggle.spec.js › ElasticPress Toggle › should show the Use ElasticSearch toggle in the panel |
Summary
@wordpress/envwith WordPress Playground (@wp-playground/cli), fixing the CI hangs and apt-lock issues from previous PRsChanges
blueprint.jsonglobal-setup.jsglobal-teardown.jsplaywright.config.jsWP_BASE_URL, 120s timeout, points to new setup/teardown.github/workflows/playwright-tests.ymltests/e2e/fixtures.jswpCli/resetDatabase(wp-env specific)tests/e2e/global-setup.jspackage.json@wp-playground/cli, removes@wordpress/env, updates scriptsCLAUDE.mdTest plan
npm run build && npm run test:e2elocally to verify Playground boots and all tests pass🤖 Generated with Claude Code