@Test(groups = "MercuryRedirectionTest_004") @InBrowser(browser = Browser.CHROME_ANDROID) public void MercuryRedirectionTest_004_RedirectFromFullSiteToMobile() { OasisFooterComponentObject oasisFooter = new OasisFooterComponentObject(driver); SkinHelper helper = new SkinHelper(driver); NavigationSideComponentObject navigation = new NavigationSideComponentObject(driver); new ArticlePageObject(driver).openWikiPage(url); new MercuryFooterComponentObject(driver).clickFullSiteLink(); oasisFooter.clickMobileSiteLink(); navigation.clickSearchButton(); navigation.clickRandomPageButton(); Assertion.assertTrue(helper.isSkin(Skin.MERCURY)); }
@Test( groups = {"MercuryLoginTest_001"}, enabled = false) @Execute(onWikia = "mercuryautomationtesting") public void MercuryLoginTest_001_validUserCanLogIn() { NavigationSideComponentObject nav = new NavigationSideComponentObject(driver); nav.navigateToUrlWithPath(wikiURL, "Map"); String url = driver.getCurrentUrl(); new TopBarComponentObject(driver).clickLogInIcon(); new LoginPageObject(driver) .clickOnSignInButton() .logUserIn( Configuration.getCredentials().userName10, Configuration.getCredentials().password10); new ArticlePageObject(driver).waitForFooterToBeVisible(); boolean result = url.equals(driver.getCurrentUrl()); PageObjectLogging.log("url", "was redirected correctly", result); Assertion.assertTrue(nav.isUserLoggedIn(Configuration.getCredentials().userName10)); }