How to rewrite closing current tab function with “async/await” instead of “.then”?

后端 未结 0 1502
無奈伤痛
無奈伤痛 2021-01-18 08:04

For closing current tab in my test I use next function:

browser.getAllWindowHandles().then((handles) => {
    browser.driver.switchTo().window(handles[1]);         


        
相关标签:
回答
  • 消灭零回复
提交回复
热议问题