Skip to content

Commit 3786235

Browse files
renemadsenclaude
andcommitted
fix(playwright): enable shifts on the same worker we then edit
The prelude was ticking thirdShiftActive on row 0 (#firstColumn0) but the test edits row 3 (#cell3_0), so the workday dialog still opened with the default 2-shift assigned site and timed out waiting for plannedStartOfShift3. Align the assigned-site dialog target with the day-cell target. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
1 parent 687a03e commit 3786235

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

eform-client/playwright/e2e/plugins/time-planning-pn/b/dashboard-edit-multishift.spec.ts

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -108,7 +108,7 @@ test.describe('Dashboard — multi-shift (3-5) round-trip regression guard', ()
108108
// — those bindings reflect the snapshot passed into the dialog, so each
109109
// new checkbox only materialises after a save + reopen cycle.
110110
for (const id of ['thirdShiftActive', 'fourthShiftActive', 'fifthShiftActive']) {
111-
await page.locator('#firstColumn0').click();
111+
await page.locator('#firstColumn3').click();
112112
await expect(page.locator('mat-dialog-container')).toBeVisible({ timeout: 10000 });
113113

114114
const cb = page.locator(`#${id} input[type="checkbox"]`);
@@ -126,7 +126,8 @@ test.describe('Dashboard — multi-shift (3-5) round-trip regression guard', ()
126126
await expect(page.locator('mat-dialog-container')).toHaveCount(0, { timeout: 10000 });
127127
}
128128

129-
// Pick any visible day cell — column 3 (worker index), first date in the range.
129+
// Day cell id is `cell{rowIndex}_{colField}` — row 3 matches the worker
130+
// whose assigned-site row (#firstColumn3) we just configured above.
130131
const cellId = '#cell3_0';
131132
await page.locator(cellId).scrollIntoViewIfNeeded();
132133
await page.locator(cellId).click();

0 commit comments

Comments
 (0)