test(ui): fix DependsOnHarmoniaIT caption assertion (master IT failure)#6388
Merged
Conversation
The test asserted exactly one <span> containing 'Orders' as the create-form caption. Since the fixture entity is named 'Orders', its derived entityLabel (the form caption) equals its menuLabel (the list toolbar title), and #6361 unified both to caption <span>s - so the label legitimately renders in two places and the ExistsByTypeAndContainsText finder (which rejects >1 match) fails with 'Found [2] ... expected at most one'. (#6372 surfaced it by lowercasing the form caption to match the list title's 'Orders'.) The assertion's real intent is that the generator DERIVED the label rather than leaking the literal ${ENTITYLABEL}; assert that placeholder is ABSENT instead - count-immune, and the form rendering + label resolution stay proven by the Country/City depends-on assertions that follow. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
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.
Fix
DependsOnHarmoniaIT— master Integration tests failureThe
master Buildrun 29921866092 failed (both H2 and PostgreSQL) onDependsOnHarmoniaIT.test:Cause
The test asserted exactly one
<span>containing "Orders" as the create-form caption. The fixture entity is namedOrders, so its derivedentityLabel(the form caption) equals itsmenuLabel(the list toolbar title). Since #6361 unified page/record title styling, both render as caption<span>s — the label legitimately appears in two places, andassertElementExistsByTypeAndContainsText(built on a finder that rejects>1match) fails. #6372 surfaced this by lowercasing the form caption fromORDERStoOrders, making it collide with the list title's already-lowercaseOrders.This is correct product behavior (a list title and a form caption both showing the entity's label), not a regression — the test assertion was too strict.
Fix (test-only)
The assertion's stated intent is that the generator derived the label rather than leaking the literal
${ENTITYLABEL}placeholder (the depends-on entities are hand-authored). Assert that the placeholder is absent instead of that the resolved text is present — count-immune, and the create form's rendering + label resolution remain proven by the Country/City depends-on assertions that follow.Test-compiles clean; the change reuses the existing
assertElementDoesNotExistsByTypeAndContainsText(already used for the "Milano" negative in the same test).🤖 Generated with Claude Code