本文整理汇总了TypeScript中protractor.protractor.ExpectedConditions类的典型用法代码示例。如果您正苦于以下问题:TypeScript protractor.ExpectedConditions类的具体用法?TypeScript protractor.ExpectedConditions怎么用?TypeScript protractor.ExpectedConditions使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
在下文中一共展示了protractor.ExpectedConditions类的6个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的TypeScript代码示例。
示例1: it
it('deleting a file should work', async () => {
let saveBtn = element(by.css('sd-device-toolbar .save')),
filesLink = element(by.css('.primary-sidebar a.files')),
saveModal = element(by.css('.save-modal')),
filenameInput = element(by.css('.save-modal input[name="filename"]')),
count = element(by.css('.primary-sidebar a.files .count'));
// Save file
saveBtn.click();
browser.wait(protractor.ExpectedConditions.visibilityOf(saveModal), 1000);
expect(await saveModal.isDisplayed()).toBe(true);
filenameInput.sendKeys('FILENAME');
filenameInput.sendKeys(protractor.Key.ENTER);
browser.wait(protractor.ExpectedConditions.stalenessOf(element(by.css('.modal-backdrop'))), 1000);
// Open sidebar
filesLink.click();
// Click delete button
element(by.css('.secondary-sidebar .files .delete')).click();
expect(await count.getText()).toBe('(0)');
browser.executeScript('localStorage.removeItem("zephyrjs-ide.FILES.FILENAME");');
// Close sidebar
filesLink.click();
// Close tab
let closeTabBtn = element(by.css('#tab-bar .nav-item.active .close-tab'));
closeTabBtn.click();
});
开发者ID:baleboy,项目名称:zephyrjs-ide,代码行数:30,代码来源:editor.component.e2e-spec.ts
示例2: waitForWalletToBeCreated
waitForWalletToBeCreated() {
browser.wait(
protractor.ExpectedConditions.stalenessOf(element(by.css('app-create-wallet'))),
10000,
'Wallet was not created',
);
}
开发者ID:skycoin,项目名称:skycoin,代码行数:7,代码来源:wallets.po.ts
示例3: hideTransactionModal
hideTransactionModal() {
const el = element(by.css('app-transaction-detail .-header img'));
return browser.wait(protractor.ExpectedConditions.visibilityOf(el), 5000).then(() => el.click().then(() => {
return this.getTransactionDetailIsShow();
}));
}
开发者ID:skycoin,项目名称:skycoin,代码行数:7,代码来源:transactions.po.ts
示例4: element
return btn.click().then(() => {
return browser.wait(
protractor.ExpectedConditions.stalenessOf(element(by.css('app-password-dialog'))),
30000,
'Can not decrypt wallet',
).then(() => {
return element(by.css('.-enable-encryption')).isPresent();
});
});
开发者ID:skycoin,项目名称:skycoin,代码行数:9,代码来源:wallets.po.ts
示例5: getLazyLoadedText
getLazyLoadedText() {
const el = element(by.css('app-root lazy-component'));
return browser.wait(protractor.ExpectedConditions.presenceOf(el)).then(() => el.getText(), err => el.getText());
}
开发者ID:BobChao87,项目名称:angular,代码行数:4,代码来源:app.po.ts
示例6: waitForClickable
static waitForClickable(element: ElementFinder) {
return browser.wait(protractor.ExpectedConditions.elementToBeClickable(element));
}
开发者ID:Margi47,项目名称:DanceSchoolCrm,代码行数:3,代码来源:time.helper.ts
注:本文中的protractor.protractor.ExpectedConditions类示例由纯净天空整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论