Compare commits
1 Commits
main
...
open_brows
| Author | SHA1 | Date | |
|---|---|---|---|
| 607bb07520 |
11
src/index.ts
11
src/index.ts
@ -58,6 +58,17 @@ async function visitCityPages(): Promise<void> {
|
|||||||
if (seeAllUrl.length == 0) throw `${city} failed`;
|
if (seeAllUrl.length == 0) throw `${city} failed`;
|
||||||
await WebDriverUtils.wait();
|
await WebDriverUtils.wait();
|
||||||
|
|
||||||
|
|
||||||
|
// open new incognito window
|
||||||
|
const driver2 = await useChrome();
|
||||||
|
if (!driver2) throw `${city} failed`;
|
||||||
|
|
||||||
|
await WebDriverUtils.wait();
|
||||||
|
await driver2.get(seeAllUrl);
|
||||||
|
await WebDriverUtils.wait();
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
console.log("Switch tab")
|
console.log("Switch tab")
|
||||||
let windows = await driver.getAllWindowHandles();
|
let windows = await driver.getAllWindowHandles();
|
||||||
// Switch to the newly opened window/tab
|
// Switch to the newly opened window/tab
|
||||||
|
|||||||
Reference in New Issue
Block a user