From 39861d740a460911ce22004dbadeb469e21903be Mon Sep 17 00:00:00 2001 From: "mathias.chouet" <mathias.chouet@irstea.fr> Date: Tue, 15 Sep 2020 12:21:03 +0200 Subject: [PATCH] Update e2e for Grille --- e2e/calculator.po.ts | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/e2e/calculator.po.ts b/e2e/calculator.po.ts index ffe8a5f4e..6053029af 100644 --- a/e2e/calculator.po.ts +++ b/e2e/calculator.po.ts @@ -286,13 +286,17 @@ export class CalculatorPage { if (await i.isDisplayed()) { // N in YAXN child of SPP module must not be float const isN = (await i.getAttribute("id")).includes("_N"); // @TODO strengthen this clodo test + // Ob in Grille is set to 0.5 but cannot exceed 0.58; do not touch it + const isOb = (await i.getAttribute("id")) === "Ob"; const hasDot = (await i.getAttribute("value")).includes("."); const hasExponent = (await i.getAttribute("value")).includes("e"); let keys = "" + Math.floor(Math.random() * 9) + 1; if (!hasDot && !hasExponent && !isN) { keys = "." + keys; } - await i.sendKeys(keys); + if (! isOb) { + await i.sendKeys(keys); + } } }); } -- GitLab