JHipsterSampleAppSteps.java 文件源码

java
阅读 22 收藏 0 点赞 0 评论 0

项目:noraui-academy 作者:
/**
 * Check JHipsterSampleApp portal page.
 *
 * @throws FailureException
 *             if the scenario encounters a functional error.
 */
@Then("The JHIPSTERSAMPLEAPP portal is displayed")
public void checkJHipsterSampleAppPage() throws FailureException {
    try {
        Context.waitUntil(ExpectedConditions.presenceOfElementLocated(Utilities.getLocator(jHipsterSampleAppPage.signInMessage)));
        if (!jHipsterSampleAppPage.isDisplayed()) {
            logInToJHipsterSampleAppWithNoraRobot();
        }
        if (!jHipsterSampleAppPage.checkPage()) {
            new Result.Failure<>(jHipsterSampleAppPage.getApplication(), Messages.FAIL_MESSAGE_UNKNOWN_CREDENTIALS, true, jHipsterSampleAppPage.getCallBack());
        }
    } catch (Exception e) {
        new Result.Failure<>(jHipsterSampleAppPage.getApplication(), Messages.FAIL_MESSAGE_UNKNOWN_CREDENTIALS, true, jHipsterSampleAppPage.getCallBack());
    }
    Auth.setConnected(true);
}
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号