@Override public void evaluate() throws Throwable { driver = MethodsForTests.getDriver(); try { base.evaluate(); } finally { MethodsForTests.logInAsAdmin(driver); MethodsForTests.usersClearing(list, driver); driver.quit(); } }
@Override public void evaluate() throws Throwable { Assume.assumeTrue(SignUpPage.isSingUpWorked()); if (authorize && authorizedUserName == null) { authorizedUserName = MethodsForTests.createUser(list); new LoginPage(driver) .get() .signIn(authorizedUserName, MethodsForTests.DEFAULT_PASSWORD); } if (!authorize) { driver.manage().deleteAllCookies(); } signUpPage = new SignUpPage(driver).get(); base.evaluate(); }
private String getExistentName() { if (!authorize) return MethodsForTests.createUser(list); return authorizedUserName; }