diff --git a/tests/game.spec.ts b/tests/game.spec.ts index 2016aab..02eb16e 100644 --- a/tests/game.spec.ts +++ b/tests/game.spec.ts @@ -19,7 +19,8 @@ test('desktop renders models, moves authoritatively, gathers, and reconnects', a await page.keyboard.down('d'); await page.waitForTimeout(1000); await page.keyboard.up('d'); await expect.poll(() => page.evaluate(() => (window as any).__aeternalis.snapshot.self.entity.position.x)).toBeGreaterThan(before.x + 3); await page.getByRole('button', { name: 'Gather', exact: true }).click(); - await expect.poll(() => page.evaluate(() => Object.values((window as any).__aeternalis.snapshot.self.skills).reduce((sum: number, n: any) => sum + n, 0)), { timeout: 15000 }).toBeGreaterThan(0); + // Same slow-CI-hardware headroom as the boss-attack poll below (bumped 15s -> 20s). + await expect.poll(() => page.evaluate(() => Object.values((window as any).__aeternalis.snapshot.self.skills).reduce((sum: number, n: any) => sum + n, 0)), { timeout: 20000 }).toBeGreaterThan(0); await page.getByRole('button', { name: 'Inventory and crafting' }).click(); await expect(page.locator('#inventory')).toBeVisible(); await expect(page.locator('#inventory-items')).toContainText('Knife'); @@ -82,7 +83,8 @@ test('boss event is visible and accepts server-authoritative combat', async ({ p await page.getByRole('button', { name: 'Close display settings' }).click(); const hp = await page.evaluate(() => (window as any).__aeternalis.snapshot.world.bossHp); await page.getByRole('button', { name: 'Target Harbinger', exact: true }).click(); - await expect.poll(() => page.evaluate(() => (window as any).__aeternalis.snapshot.world.bossHp), { timeout: 20000 }).toBeLessThan(hp); + // A little more slow-CI-hardware headroom on top of the prior 15s -> 20s bump. + await expect.poll(() => page.evaluate(() => (window as any).__aeternalis.snapshot.world.bossHp), { timeout: 25000 }).toBeLessThan(hp); await expect(page.locator('#boss-bar')).toBeVisible(); await page.screenshot({ path: 'test-results/boss.png' }); });