From 4d863c96dc551ee0bb952f1056a0cdf63cf3f33f Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Fran=C3=A7ois=20Grand?= <francois.grand@inrae.fr>
Date: Wed, 7 Jun 2023 16:30:29 +0200
Subject: [PATCH] fix(e2e): failing tests

refs #622
---
 e2e/examples-empty-fields.e2e-spec.ts | 3 ++-
 e2e/navbar.po.ts                      | 1 +
 2 files changed, 3 insertions(+), 1 deletion(-)

diff --git a/e2e/examples-empty-fields.e2e-spec.ts b/e2e/examples-empty-fields.e2e-spec.ts
index 85bec267..447864c2 100644
--- a/e2e/examples-empty-fields.e2e-spec.ts
+++ b/e2e/examples-empty-fields.e2e-spec.ts
@@ -61,7 +61,7 @@ describe("ngHyd - Check that examples fields are not empty with 'empty fields on
 
         // open initial dialog
         const initDlgButton = await $(".param-computed-more");
-        await initDlgButton.click();
+        await initDlgButton.click(); // TODO #622 : "element click intercepted" à cause du layout (l'input recouvre le bouton "...")
         await browser.pause(200);
 
         // check input value is not null
@@ -91,6 +91,7 @@ describe("ngHyd - Check that examples work with 'empty fields on calculator crea
 
     it("when calculation is run on a generated fish ladder calculator", async () => {
         await newSession(navBar, sideNav);
+        await navBar.clickNewCalculatorButton();
 
         // open 1st example
         await navBar.openNthExampleSession(0);
diff --git a/e2e/navbar.po.ts b/e2e/navbar.po.ts
index 449b3639..45f8a7f3 100644
--- a/e2e/navbar.po.ts
+++ b/e2e/navbar.po.ts
@@ -92,6 +92,7 @@ export class Navbar {
     async clickNewCalculatorButton() {
         const ncb = this.getNewCalculatorButton();
         await ncb.click();
+        await browser.pause(200);
     }
 
     async clickMenuButton() {
-- 
GitLab