Привет. Написал самый элементарный тест. В Хроме. Запустил, всё работает.
Пытаюсь в IE11 запустить.
Дописал:
import org.openqa.selenium.ie.InternetExplorerDriver;
Далее:
// System.setProperty("webdriver.chrome.driver", "C:\\Tools\\chromedriver.exe"); System.setProperty("webdriver.ie.driver", "C:\\Tools\\IEDriverServer.exe"); // driver = new ChromeDriver(); driver = new InternetExplorerDriver(); // driver = new FirefoxDriver();
Запускаю. Возникает пустое окно IE с надписью "This is the initial start page for the WebDriver server.". Потом в консоли среды IDEA ошибка:
"Started InternetExplorerDriver server (32-bit)
3.12.0.0
Listening on port 24367
Only local connections are allowed
org.openqa.selenium.remote.SessionNotFoundException: session null does not exist (WARNING: The server did not provide any stacktrace information)
Command duration or timeout: 0 milliseconds
Build info: version: '2.53.0', revision: '35ae25b1534ae328c771e0856c93e187490ca824', time: '2016-03-15 10:43:46'
System info: host: 'DESKTOP-3RL45DT', ip: '192.168.0.98', os.name: 'Windows 10', os.arch: 'amd64', os.version: '10.0', java.version: '9.0.1'
Driver info: org.openqa.selenium.ie.InternetExplorerDriver
Capabilities [{capabilities={proxy={}, acceptInsecureCerts=false, browserVersion=11, se:ieOptions={nativeEvents=true, browserAttachTimeout=0, ie.ensureCleanSession=false, elementScrollBehavior=0, enablePersistentHover=true, ie.browserCommandLineSwitches=, ie.forceCreateProcessApi=false, requireWindowFocus=false, initialBrowserUrl=http://localhost:24367/, ignoreZoomSetting=false, ie.fileUploadDialogTimeout=3000, ignoreProtectedModeSettings=false}, timeouts={implicit=0, pageLoad=300000, script=30000}, browserName=internet explorer, pageLoadStrategy=normal, unhandledPromptBehavior=dismiss, platformName=windows, setWindowRect=true}, sessionId=e437cd11-b249-4d88-b5ea-8cdcc0156ac4, platform=ANY}]
Session ID: null
.......
......."
Ну и так далее, текст длинный. Я так понимаю сама ошибка в начале пишется, то есть:
org.openqa.selenium.remote.SessionNotFoundException: session null does not exist (WARNING: The server did not provide any stacktrace information)
Всё перегуглил. Там разные советы: одинаковые настройки безопасности IE, окно 100%, запустить файл selenium-server-standalone-3.12.0.jar. Ничего не помогает.
Можете помочь?
P.S.: аналогично в Firefox ничего не работает.