From e622035283089d3e5a2317da6987975ecd7e90a6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rapha=C3=ABl=20Martin?= Date: Mon, 30 Sep 2024 17:15:41 +0200 Subject: [PATCH] fix end2end modules line count --- tests/end2end/playwright/server-information.spec.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/tests/end2end/playwright/server-information.spec.js b/tests/end2end/playwright/server-information.spec.js index afab482699..c52a779705 100644 --- a/tests/end2end/playwright/server-information.spec.js +++ b/tests/end2end/playwright/server-information.spec.js @@ -25,7 +25,9 @@ test.describe('Server information', () => { await expect(await lwcRow.locator('td').innerText()).not.toEqual(''); } // Check that Lizmap modules contains 2 lines (header and 1 module lizmapdemo) - const modulesRows = page.locator('#lizmap_server_information table.table-lizmap-modules tr:nth-child(1n+2)') + const modulesHeadRows = page.locator('#lizmap_server_information table.table-lizmap-modules thead tr'); + await expect(modulesHeadRows).toHaveCount(1); + const modulesRows = page.locator('#lizmap_server_information table.table-lizmap-modules tbody tr'); await expect(modulesRows).toHaveCount(1); for (const row of await modulesRows.all()) { await modulesRows.scrollIntoViewIfNeeded();