|
|
@ -214,12 +214,13 @@ export class DashboardPage extends BasePage { |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
async closeAllTabs() { |
|
|
|
async closeAllTabs() { |
|
|
|
|
|
|
|
await this.tabBar.locator(`.ant-tabs-tab`).waitFor({ state: 'visible' }); |
|
|
|
const tab = await this.tabBar.locator(`.ant-tabs-tab`); |
|
|
|
const tab = await this.tabBar.locator(`.ant-tabs-tab`); |
|
|
|
const tabCount = await tab.count(); |
|
|
|
const tabCount = await tab.count(); |
|
|
|
|
|
|
|
|
|
|
|
for (let i = 0; i < tabCount; i++) { |
|
|
|
for (let i = 0; i < tabCount; i++) { |
|
|
|
await tab.nth(i).locator('button.ant-tabs-tab-remove').click(); |
|
|
|
await tab.nth(i).locator('button.ant-tabs-tab-remove').click(); |
|
|
|
await this.rootPage.waitForTimeout(200); |
|
|
|
await tab.nth(i).waitFor({ state: 'detached' }); |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|