public static void refreshUntilElementPresent(BrowserEmulator be, String xpath, int timeout) {
        long start = System.currentTimeMillis();
        while (true) {
            if (System.currentTimeMillis() - start > timeout) {
                Assert.fail();
                break;
            }
            if (be.isElementPresent(xpath, 500)) {
                break;
            } else {
                // 等待6秒后刷新
                be.pause(6000);
                be.refresh();
            }
        }
    }