fix(ui): F3 overlay was always shown as an empty box and could not be closed
This commit is contained in:
@@ -88,3 +88,16 @@ test('shop purchase is checked and stored by the server', async ({ browser }) =>
|
||||
expect((await cheat.json()).money).toBe(after);
|
||||
await ctx.close();
|
||||
});
|
||||
|
||||
test('F3 network overlay: hidden at start, F3 shows it with content, F3 hides it again', async ({ page }) => {
|
||||
await login(page, 'benni', 'Benni2000!');
|
||||
const ov = page.locator('#netov');
|
||||
await expect(ov).toBeHidden(); // regression: an empty box was always on screen
|
||||
await page.keyboard.press('F3');
|
||||
await expect(ov).toBeVisible();
|
||||
await expect(ov).toContainText(/ping/i);
|
||||
await page.keyboard.press('F3');
|
||||
await expect(ov).toBeHidden(); // regression: it could not be closed again
|
||||
await page.keyboard.press('F3');
|
||||
await expect(ov).toBeVisible();
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user