Skip to content

test(project): Integration tests for custom-task determineBuildSignature - #1597

Merged
matz3 merged 2 commits into
mainfrom
test/custom-task-build-signature
Sep 16, 2026
Merged

matz3 merged 2 commits into
mainfrom
test/custom-task-build-signature

Conversation

@matz3

@matz3 matz3 commented Sep 16, 2026

Copy link
Copy Markdown
Member

Adds ProjectBuilder coverage for the callback invalidating the cache on change, plus a test.failing BuildServer test documenting that signatures go stale over the server's lifetime.

JIRA: CPOUI5FOUNDATION-1360

…termineBuildSignature

Verify that a custom task can implement and use the determineBuildSignature
callback end-to-end via graph.build(): a stable callback return keeps the
project cache intact, while a changed return invalidates it and forces a
rebuild. The callback derives its signature from an on-disk control file so
the test can flip the signature independently of any source-resource change.
…re staleness

Capture the status quo: a running BuildServer computes each project's build
signature exactly once (BuildContext memoizes the ProjectBuildContext for the
server's lifetime), so a custom task's determineBuildSignature callback is
never re-evaluated. Changing an input the callback reads (here an on-disk
control file outside the watched source paths) while the server runs is
therefore silently ignored, and the server keeps serving a stale build result.

The new test asserts the desired behavior — the change is reflected without a
server restart — and is marked test.failing since the current behavior does
not do this. The build-signature custom task now also appends the control
value to test.js so the served output observably depends on the callback input.
@matz3
matz3 requested a review from a team September 16, 2026 07:43
@matz3
matz3 merged commit 135076c into main Sep 16, 2026
78 checks passed
@matz3
matz3 deleted the test/custom-task-build-signature branch September 16, 2026 09:58
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.

2 participants