diff --git a/src/test/java/org/fremo/fredl/test/BasicTest.java b/src/test/java/org/fremo/fredl/test/BasicTest.java index d644aa2..50c2482 100644 --- a/src/test/java/org/fremo/fredl/test/BasicTest.java +++ b/src/test/java/org/fremo/fredl/test/BasicTest.java @@ -116,7 +116,8 @@ public class BasicTest { public void verifyLogout() { driver.switchTo().defaultContent(); FredlTestHelper.printPageSource(); - driver.switchTo().frame("oben"); + String frameObenName = "oben"; + driver.switchTo().frame(frameObenName); driver.findElement(By.id("logout-menu-button")).click(); diff --git a/src/test/java/org/fremo/fredl/test/FredlTestHelper.java b/src/test/java/org/fremo/fredl/test/FredlTestHelper.java index eac78e9..bbfbe84 100644 --- a/src/test/java/org/fremo/fredl/test/FredlTestHelper.java +++ b/src/test/java/org/fremo/fredl/test/FredlTestHelper.java @@ -22,24 +22,24 @@ public class FredlTestHelper { } public static boolean elementExistsByXpath(String xpath) { - System.out.println("elementExistsByXpath for " + xpath); driver.manage().timeouts().implicitlyWait(0, TimeUnit.MILLISECONDS); boolean exists = driver.findElements(By.xpath(xpath)).size() != 0; + System.out.println("elementExistsByXpath for " + xpath + " = " + exists); driver.manage().timeouts().implicitlyWait(implicitTimeoutMilliseconds, TimeUnit.MILLISECONDS); return exists; } public static boolean elementExistsById(String id) { - System.out.println("elementExistsById for " + id); driver.manage().timeouts().implicitlyWait(0, TimeUnit.MILLISECONDS); boolean exists = driver.findElements(By.id(id)).size() != 0; + System.out.println("elementExistsById for " + id + " = " + exists); driver.manage().timeouts().implicitlyWait(implicitTimeoutMilliseconds, TimeUnit.MILLISECONDS); return exists; } public static void skipConsentCookiePage() { if (FredlTestHelper.elementExistsById("privacy-cookie-statement")) { - System.out.println("Cookies consent page is shown"); + System.out.println("Cookies consent page is shown -- accepting"); WebElement consentButton = driver.findElement(By.id("opt-in-button-allow")); consentButton.click(); }