mirror of
https://github.com/4gray/iptvnator.git
synced 2026-10-14 05:06:16 -08:00
test(e2e): find a finished programme for the phone dialog after UTC midnight
The Xtream mock lays its 30-minute EPG slots out relative to now, and the list view shows the programmes that overlap the selected day. In the first half hour after midnight (the spec pins TZ=UTC) today holds only the programme on air, so 'stacks the programme dialog actions on a phone' found no data-when=past row and failed every retry on #1929's Windows shard (00:18-00:23 UTC). The spec now waits for the list, and steps back a day when today has no finished programme yet. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
a49335b4f6
commit
db2b06a74c
1 file changed
+10
@@ -331,6 +331,7 @@ test('@epg @xtream @electron stacks the programme dialog actions on a phone', as
|
||||
) as {
|
||||
WORKSPACE: { SHELL: { RAIL_LIVE: string } };
|
||||
EPG: {
|
||||
PREVIOUS_DAY: string;
|
||||
PROGRAM_DIALOG: { SHOW_PROGRAM_DETAILS: string };
|
||||
TIMELINE: { WATCH_FROM_START: string };
|
||||
};
|
||||
@@ -365,6 +366,15 @@ test('@epg @xtream @electron stacks the programme dialog actions on a phone', as
|
||||
.first()
|
||||
.click();
|
||||
const guide = app.mainWindow.locator('app-epg-list-view');
|
||||
await expect(guide.locator('[data-when="now"]').first()).toBeVisible();
|
||||
// The mock's 30-minute slots run relative to now, so in the first half
|
||||
// hour after UTC midnight today holds only the programme on air: step
|
||||
// back a day for a finished one.
|
||||
if ((await guide.locator('[data-when="past"]').count()) === 0) {
|
||||
await guide
|
||||
.getByRole('button', { name: fr.EPG.PREVIOUS_DAY })
|
||||
.click();
|
||||
}
|
||||
await expect(guide.locator('[data-when="past"]').first()).toBeVisible();
|
||||
|
||||
// The window cannot shrink below its desktop minimum, so emulate a
|
||||
|
||||
Reference in new issue
Block a user