close a specific tab in browser window using web driver io

1.5k views Asked by At

browser.close(window handle) - i tried this but its closing the entire window.

How to close a specific tab from a browser window which has multiple tabs using web-driver io. I am working on chromedriver.

1

There are 1 answers

0
Mike G. On

Before closing the last browser tab please make sure at least one tab exists. Just open some tab before closing.