Is it possible to use multiple selenium webdrivers locally without using selenium grid to run multiple test at the same time?
I am creating multiple instances by calling new FireFoxDriver()
but the sessions in the windows seem to interfere with each other.
The driver is created and destroyed by the JUnit-Methods shown below. For every Test-class there is one WebDriver but each testcase has a different execution duration. And after the first Test-class has finished and tearDownClass()
from this class was called.
This exception this thrown:
org.openqa.selenium.remote.SessionNotFoundException: The FirefoxDriver cannot be used after quit() was called. Build info: version: '2.39.0', revision: '14fa800511cc5d66d426e08b0b2ab926c7ed7398', time: '2013-12-16 13:18:38' System info: host: 'T61', ip: '127.0.1.1', os.name: 'Linux', os.arch: 'i386', os.version: '3.11.0-15-generic', java.version: '1.7.0_51'
@BeforeClass
public static void setUpClass() {
driver = new FireFoxDriver();
}
@AfterClass
public static void tearDownClass() {
driver.quit(); // this should only kill the current driver
}