so you can clean up new tabs in an afterEach, without closing the main tab if there was a test error and it didn't create a second tab.
something like
async function closeExtraTabs() {
while (await this.browser._browser.getWindowHandles() > 1) {
await this.browser.closeTab();
}
}
so you can clean up new tabs in an afterEach, without closing the main tab if there was a test error and it didn't create a second tab.
something like