When I am using $driver.close_app method, it closes application and crashes all tests running session. I need to close app and open it again between tests.
driver.quit works well in my case. I launch app in @BeforeMethod and close it in @AfterMethod and all test cases cases execute without any exception.
If I use quit after each test case, I am getting next error:
(Selenium::WebDriver::Error::NoSuchDriverError)
It basically terminates driver
Java client has several methods that may be of use:
resetApp()
closeApp()
runAppInBackground()
removeApp()
Thanks. I know about these methods. Closing app method crashes my tests.
Same problem in my caseā¦Error (Selenium::WebDriver::Error::NoSuchDriverError) while using driver_quit in my ruby script.
Resolve this error by using :
start_driver
driver_quit
You could surround driver.quit by try-catch block
Not a great solution to quit the driver. Locally, fine. Remote, more expensive connections this is just wrong. I messed with this a bit, and now driver.close_app() and driver.launch_app() appear to work for me without tearing down the driver connection. (python)