Skip to content

[Backport to release/11.1] e2e tests: Fix create-post e2e test against Gutenberg nightly - #67917

Merged
gigitux merged 2 commits into
release/11.1from
cherry-pick-PR67803-to-release/11.1
Aug 21, 2026
Merged

gigitux merged 2 commits into
release/11.1from
cherry-pick-PR67803-to-release/11.1

Conversation

@woocommercebot

Copy link
Copy Markdown
Collaborator

This PR is a cherry-pick of #67803 to release/11.1.

Original PR Description

Changes proposed in this Pull Request:

The nightly Gutenberg e2e job has failed on create-post.spec.ts since 12 August. Gutenberg WordPress/gutenberg#81231 replaced the default block appender with a real empty paragraph block. The element keeps the accessible name Add default block, but its role changed from button to document. The test asked for the button role, so its locator matched nothing and timed out.

The test now matches by label:

await canvas.getByLabel( /Add default block|Empty block/ ).click();

create-page.spec.ts and products.block_theme.spec.ts already do this, after an earlier appender change in #53100. create-post.spec.ts was the last one still asking for the button role.

How to test the changes in this Pull Request:

  1. Check out this branch.
  2. Build the plugin: pnpm --filter=@woocommerce/plugin-woocommerce build.
  3. Start the e2e environment: pnpm --filter=@woocommerce/plugin-woocommerce env:e2e.
  4. Run against Gutenberg nightly: pnpm --filter=@woocommerce/plugin-woocommerce test:e2e:gb-nightly tests/wp-core/create-post.spec.ts. It passes. On trunk it fails at create-post.spec.ts:33 with TimeoutError: locator.click: Timeout 20000ms exceeded.
  5. Run against Gutenberg stable: pnpm --filter=@woocommerce/plugin-woocommerce test:e2e:gb-stable tests/wp-core/create-post.spec.ts. It still passes.

Tested: https://github.com/woocommerce/woocommerce/actions/runs/32123269803

Milestone

@github-actions github-actions Bot added plugin: woocommerce Issues related to the WooCommerce Core plugin. focus: e2e tests Issues related to e2e tests labels Aug 21, 2026
@gigitux
gigitux enabled auto-merge (squash) August 21, 2026 14:02
@github-actions

Copy link
Copy Markdown
Contributor

Testing Guidelines

Hi @adimoldovan @gigitux ,

Apart from reviewing the code changes, please make sure to review the testing instructions (Guide) and verify that relevant tests (E2E, Unit, Integration, etc.) have been added or updated as needed.

Reminder: PR reviewers are required to document testing performed. This includes:

  • 🖼️ Screenshots or screen recordings.
  • 📝 List of functionality tested / steps followed.
  • 🌐 Site details (environment attributes such as hosting type, plugins, theme, store size, store age, and relevant settings).
  • 🔍 Any analysis performed, such as assessing potential impacts on environment attributes and other plugins, conducting performance profiling, or using LLM/AI-based analysis.

⚠️ Within the testing details you provide, please ensure that no sensitive information (such as API keys, passwords, user data, etc.) is included in this public issue.

@gigitux
gigitux merged commit 4d66e5e into release/11.1 Aug 21, 2026
32 of 33 checks passed
@gigitux
gigitux deleted the cherry-pick-PR67803-to-release/11.1 branch August 21, 2026 14:33
@github-actions github-actions Bot added the metric: feature freeze exception A tracking label for PRs that were merged after the feature freeze. label Aug 21, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

focus: e2e tests Issues related to e2e tests metric: feature freeze exception A tracking label for PRs that were merged after the feature freeze. plugin: woocommerce Issues related to the WooCommerce Core plugin.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants