How to close a ChromeDriver when running on Grid?

后端 未结 2 1070
遥遥无期
遥遥无期 2020-12-10 18:20

I am currently running my tests with RemoteWebDriver with Selenium Grid 2 through TestNG suites. This works fine with Firefox and IE. Now I added Chrome and the tests run fi

2条回答
  •  萌比男神i
    2020-12-10 19:05

    I see the cause of this may be that you are not closing active browsers before quitting the Driver. Try to close the windows, which may be the cause of some exceptions, with the following code:

    Driver.Close();
    Driver.Quit();
    

    This should solve your issue.

提交回复
热议问题