本文整理匯總了TypeScript中pages/navigation.page.NavigationPage類的典型用法代碼示例。如果您正苦於以下問題:TypeScript page.NavigationPage類的具體用法?TypeScript page.NavigationPage怎麽用?TypeScript page.NavigationPage使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。
在下文中一共展示了page.NavigationPage類的4個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的TypeScript代碼示例。
示例1: it
it('visits System Configuration', async () => {
await navigation.visitSystemConfiguration()
await navigation.blur()
ctx.driver.findElement(By.xpath("//div[@class='alert alert-danger']"))
})
示例2: beforeAll
beforeAll(async () => {
await loginPage.login('admin', 'admin')
await navigation.gotoProject('SeleniumBasic')
// await navigation.toggleSidebarExpand()
await navigation.freeze()
})
示例3: sleep
it('visits nodes', async () => {
await navigation.visitNodes()
await sleep(500)
const img = Buffer.from(await navigation.screenshot(true), 'base64')
expect(img).toMatchImageSnapshot({customSnapshotsDir: '__image_snapshots__', customDiffConfig: {threshold: 0.01}})
})
示例4: async
it('Logs in through the GUI', async () => {
await loginPage.get()
await loginPage.login('admin', 'admin')
// await navigation.toggleSidebarExpand()
const img = Buffer.from((await navigation.screenshot()), 'base64')
})