Skip to content

chore: add PHPUnit, Jest, and Playwright tests with CI workflows. - #57

Merged
firestar300 merged 8 commits into
developfrom
issue/93930
Oct 2, 2026
Merged

firestar300 merged 8 commits into
developfrom
issue/93930

Conversation

@firestar300

@firestar300 firestar300 commented Sep 29, 2026 •

Copy link
Copy Markdown
Contributor

Align wp-env and wp-scripts with blockparty-tabs and move release scripts under tests/bin.


Note

Medium Risk
The react-jsx-runtime polyfill and always-serialized data-allow-multiple affect editor loading and frontend accordion config on supported WP versions; test/CI changes are mostly isolated from production sites.

Overview
Adds a full automated test stack and CI: PHPUnit (wp-env on port 8889), Jest for icon-block helpers, and Playwright E2E for editor insertion and frontend accordion behavior, plus GitHub workflows for PHP/JS/E2E and a coverage artifact job.

Release and dev tooling moves bump/version checks to tests/bin/ (bump.sh supports patch/minor/major; check-release-version.sh replaces the old PR workflow inline tag check). wp-env is split into dev (.wp-env.json + initialize.sh) and test (.wp-env.test.json), with new npm scripts, upgraded @wordpress/scripts/Node 20+, flat ESLint config, and Composer PHPUnit deps (PHP 8.3/8.4).

Runtime fix for older WordPress: webpack emits build/react-jsx-runtime.js and register_react_jsx_runtime() registers it when core lacks the handle (WP before 6.6), so editor blocks still load.

Smaller product tweaks: accordion save always outputs data-allow-multiple="true|false" (was omitted when true), summary toolbar icon uses an inline SVG instead of @beapi/icons, and widespread JS formatting only.

Reviewed by Cursor Bugbot for commit 7578d84. Bugbot is set up for automated code reviews on this repo. Configure here.

Align wp-env and wp-scripts with blockparty-tabs and move release scripts under tests/bin.

@cursor cursor Bot left a comment •

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Stale Bugbot comment from a previous run.

Comment thread tests/php/AllowAttributesTest.php Outdated
Comment thread .gitattributes Outdated
Replace legacy ESLint config, fix quality-js workflow steps, drop missing
wp-env plugin, remove duplicate block wrapper in accordion-item edit, and
harden Playwright inserter assertions for WP 6.4.

@cursor cursor Bot left a comment •

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Stale Bugbot comment from a previous run.

Comment thread tests/playwright/specs/editor-accordion.spec.js
Editor bundles from @wordpress/scripts 32 depend on a core script handle
that is missing on 6.4–6.5, which prevented block registration in E2E.

@cursor cursor Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes using default effort and found 1 potential issue.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit 31a6a8f. Configure here.

Comment thread assets/compat/react-jsx-runtime.js Outdated
@firestar300
firestar300 merged commit 53ef150 into develop Oct 2, 2026
11 checks passed
@firestar300
firestar300 deleted the issue/93930 branch October 2, 2026 14:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant