Skip to content

test(integration): stop pinning the instance version in the OpenAPI assertion - #6653

Merged
delchev merged 1 commit into
masterfrom
fix/openapi-version-assertion
Aug 11, 2026
Merged

test(integration): stop pinning the instance version in the OpenAPI assertion#6653
delchev merged 1 commit into
masterfrom
fix/openapi-version-assertion

Conversation

@delchev

@delchev delchev commented Aug 11, 2026

Copy link
Copy Markdown
Contributor

Fixes the red nightly: run 31453258683 failed EntityDecoratorsSampleProjectIT on both the H2 and the PostgreSQL leg.

What broke

The test compares the served /services/openapi document against a literal that carried:

"version":"${project.version}"

— the unfiltered placeholder every stock instance used to report. #6644 made an instance report its real build version, so the literal stopped matching:

Expected: …\"version\":\"${project.version}\"…
  Actual: …"version":"15.0.0-SNAPSHOT"…

The assertion sits inside a restAssuredExecutor.execute(…, 60) retry, so instead of failing fast it retried for a full minute and surfaced as ConditionTimeout at verifyProject:33 — which is why the cause was not obvious from the summary line. It is a string comparison, so it is database-independent: both legs failed identically.

The fix

Normalise info.version out of both sides rather than pinning it. The served version changes on every release and every development bump, so any literal here is a landmine that fires on the next version set to … commit — this would have broken again at 14.21.0 and again at the following bump, regardless of #6644.

Verification

Ran the IT locally against current master (so #6644's filtering is active) — green in 65s, and the log confirms the instance served "version":"15.0.0-SNAPSHOT". That matters: the test now passes with a real version present, not because the placeholder happened to survive. formatter:validate clean.

Note for whoever reviews: this is @Tag("ui"), so it is not in the PR smoke gate — it only runs on the nightly and on push to master. The nightly is the gate that will confirm it.

🤖 Generated with Claude Code

…ssertion

EntityDecoratorsSampleProjectIT compared the served /services/openapi document
against a literal that carried `"version":"${project.version}"` - the UNFILTERED
placeholder every stock instance used to report. #6644 made the instance report
its real build version, so the literal stopped matching, the assertion retried
for its full minute and the nightly went red on BOTH the H2 and the PostgreSQL
leg (run 31453258683) - a string comparison, hence database-independent.

Normalise `info.version` out of both sides instead of pinning it: the served
version changes on every release and every development bump, so any literal here
is a landmine that fires on the next `version set to ...` commit. Verified
locally against current master, where the instance serves 15.0.0-SNAPSHOT - so
the test now passes with a REAL version present, not because the placeholder
survived.
@delchev
delchev merged commit d1aec0a into master Aug 11, 2026
10 checks passed
@delchev
delchev deleted the fix/openapi-version-assertion branch August 11, 2026 07:18
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