本文整理汇总了TypeScript中protractor.protractor.until类的典型用法代码示例。如果您正苦于以下问题:TypeScript protractor.until类的具体用法?TypeScript protractor.until怎么用?TypeScript protractor.until使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
在下文中一共展示了protractor.until类的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的TypeScript代码示例。
示例1: waitForBootstrap
function waitForBootstrap() {
browser.wait(protractor.until.elementLocated(by.css(selector + ' .box')), 5000)
.then(() => {}, () => {
// jasmine will timeout if this gets called too many times
console.error('>> unexpected timeout -> browser.refresh()');
browser.refresh();
waitForBootstrap();
});
}
示例2: it
it('should greet', () => {
// This test can't wait for Angular as Testability is not available when using WebWorker
browser.ignoreSynchronization = true;
browser.get(URL);
browser.wait(protractor.until.elementLocated(by.css(selector)), 15000);
const elem = element(by.css(selector));
browser.wait(ExpectedConditions.textToBePresentInElement(elem, 'hello world!'), 5000);
expect(elem.getText()).toEqual('hello world!');
});
示例3: waitForBootstrap
function waitForBootstrap() {
browser.wait(protractor.until.elementLocated(by.css(selector + ' h2')), 5000)
.then(
() => {
const elem = element(by.css(selector + ' h2'));
browser.wait(
protractor.ExpectedConditions.textToBePresentInElement(elem, 'Input App'), 5000);
},
() => {
// jasmine will timeout if this gets called too many times
console.error('>> unexpected timeout -> browser.refresh()');
browser.refresh();
waitForBootstrap();
});
}
示例4: waitForBootstrap
function waitForBootstrap(): void {
browser.wait(protractor.until.elementLocated(by.css('todo-app #todoapp')), 15000);
}
示例5: waitForElement
function waitForElement(selector: string): void {
browser.wait(protractor.until.elementLocated(by.css(selector)), 15000);
}