test(workspace): pass the header clearance poll labels as options

Equivalent to the string form, which Playwright 1.62 also accepts, but
explicit in every version (Greptile review).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
4grayandClaude Opus 5.5 committed 2026-10-04 21:11:20 +02:00
1 parent ac971910fd
commit 4a367e149a
1 file changed
+7 -3
@@ -267,13 +267,17 @@ async function expectHeaderClearOfLights(
): Promise<void> {
const layout = () => headerLayout(page);
await expect
.poll(async () => (await layout()).control, label)
.poll(async () => (await layout()).control, { message: label })
.toBe(control);
await expect
.poll(async () => (await layout()).left, `${label}: first control`)
.poll(async () => (await layout()).left, {
message: `${label}: first control`,
})
.toBeGreaterThanOrEqual(lights.x + headerControlOffset);
await expect
.poll(async () => (await layout()).contentTop, `${label}: content top`)
.poll(async () => (await layout()).contentTop, {
message: `${label}: content top`,
})
.toBeGreaterThanOrEqual(lights.y + lightsHeight);
}