fix(e2e): deflake viewQualifiedName authoring test (toolbar teardown race) - #1960
Merged
Conversation
…race)
A config-dialog submit fires an asynchronous editable re-render that
repositions overlays and hides the shared #EditableToolbar. The test
proceeded straight to openEditableToolbar, so the late re-render tore the
toolbar down after it was opened and the trailing should('be.visible')
(commands.js:311, never re-clicks) timed out with "#EditableToolbar has
display: none". At retries=0 this reproduced 4/5; masked but still ~41%
flaky at CI retries=3.
- Add central cy.submitConfigureDialog() command that registers the same
cq-editables-updated + cq-overlays-repositioned listeners
deleteComponentByPath uses BEFORE submit and blocks until both fire, so
the editor is settled before the next openEditableToolbar. Reusable by
the other submit sites across specs.
- Use it in the Forms-editor and Sites-editor flows of the spec.
- Suppress the intermittent CoralUI3 "Cannot create property '_namespace'
on boolean 'true'" editor-bootstrap error in the index.js allow-list; it
is racy, self-recovers, and has no functional impact on the form.
Verified: 20 consecutive post-fix runs at retries=0 with zero failures
(baseline 4/5 failing).
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
Accessibility Violations Found
|
Accessibility Violations Found
|
This was referenced Aug 14, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
viewQualifiedName.authoring.cy.jsis flaky, failing with:Root cause (data-backed)
A component config-dialog submit fires an asynchronous editable re-render (
cq-editables-updated→cq-overlays-repositioned) that repositions the overlays and hides the shared#EditableToolbar. The test proceeded straight toopenEditableToolbar, so the late re-render tore the toolbar down after it was opened.openEditableToolbar'srecurseretries only the overlay click; the trailingcy.get(path).should('be.visible')(commands.js:311) is passive — it only re-checks visibility, never re-clicks — so it spins for the full timeout and fails.The earlier
recursechange fixed a lost click, but never synchronised on this re-render, so retries only masked it.Reproduction (retries=0):
commands.js:311)At CI's
retries: 3the baseline is still ≈0.8⁴≈ 41% chance to fail all attempts.Fix
cy.submitConfigureDialog(selector)(libs/support/commands.js) — registers the samecq-editables-updated+cq-overlays-repositionedlistenersdeleteComponentByPathalready relies on before clicking submit, then blocks until both fire, so the editor is fully settled before the nextopenEditableToolbar. Reusable by the other submit sites across specs.dropComponentAndSetName) and Sites-editor flows of the spec.Cannot create property '_namespace' on boolean 'true'editor-bootstrap error in theindex.jsuncaught:exceptionallow-list. It is a Coral custom-element upgrade race that self-recovers and has no functional impact on the form under test; it was simply missing from the existing allow-list, so it randomly failed the test whenever it fired.Verification
20 consecutive runs of the previously-failing Wizard case at
retries=0— zero failures (baseline 4/5 failing).🤖 Generated with Claude Code