This issue might be simillar to IE driver doesn't load on Windows 8.1
My configuration:
Protractor 1.8 with Selenium 2.45 with chrome and ie drivers
Windows 7 x64
c:\Git\QualityExcites2014-Demo>node node_modules\protractor\bin\webdriver-manager status
selenium standalone is up to date
chromedriver is up to date
IEDriver is up to date
I have got following config. There is no seleniumAddess property so I assume the WD should start automatically:
exports.config = {
allScriptsTimeout: 11000,
specs: ['e2e/3_asyncBarsSpec.js'],
capabilities: {
'browserName': 'chrome'
},
baseUrl: 'http://localhost:8000/app/',
framework: 'jasmine',
jasmineNodeOpts: {
defaultTimeoutInterval: 30000
},
};
When I am starting tests:
c:\Git\QualityExcites2014-Demo>node node_modules\protractor\bin\protractor test\protractor-conf.js --browser=ie
Starting selenium standalone server...
[launcher] Running 1 instances of WebDriver
Selenium standalone server started at http://192.168.11.2:61788/wd/hub
I have following error:
ERROR - Unable to start a WebDriver session.
c:\Git\QualityExcites2014-Demo\node_modules\protractor\node_modules\selenium-webdriver\lib\atoms\error.js:113
var template = new Error(this.message);
^
UnknownError: The path to the driver executable must be set by the webdriver.ie.driver system property; for more information, see http://code.google.com/p/selenium/wiki/InternetExplorerDriver. The latest version can be downloaded from http://selenium-release.storage.googleapis.com/index.html
It works with --browser=chrome
_Side note:_ It even does not work with selenium started as java -jar with -Dwebdriver.ie.driver=<path to IEDriverServer>
To run tests on ie I have to start WebDriver manually with:
c:\Git\QualityExcites2014-Demo>node node_modules\protractor\bin\webdriver-manager start
Output:
18:22:19.820 INFO - Launching a standalone server
Setting system property webdriver.chrome.driver to c:\Git\QualityExcites2014-Demo\node_modules\protractor\selenium\chromedriver.exe
Setting system property webdriver.ie.driver to c:\Git\QualityExcites2014-Demo\node_modules\protractor\selenium\IEDriverServer.exe
18:25:11.130 INFO - Java: Oracle Corporation 25.31-b07
18:25:11.131 INFO - OS: Windows 7 6.1 amd64
18:25:11.149 INFO - v2.45.0, with Core v2.45.0. Built from revision 5017cb8
and start tests with seleniumAddress property provided:
c:\Git\QualityExcites2014-Demo>node node_modules\protractor\bin\protractor test\protractor-conf.js --browser=ie --seleniumAddress=http://localhost:4444/wd/hub
Workaround:
It is possible to start test without WD started as webdriver-manager start:
The WD starts automatically and tests goes to Internet Exploder :).
Sounds like a bug with the WebDriverJS remote, maybe - although that doesn't explain your side note that it doesn't even work if you try to run the java jar manually. If anyone with a windows box can investigate that would be great, or I can take a look later when I have access to one.
Update
Starting WD as:
c:\Git\QualityExcites2014-Demo>java -Dwebdriver.ie.driver=C:\Git\IEDriverServer.exe -jar C:\Selenium\selenium-server-standalone-2.45.0.jar
where _C:\Git_ is not part of _%PATH%_ variable
and starting test as:
c:\Git\QualityExcites2014-Demo>node node_modules\protractor\bin\protractor test\protractor-conf.js --browser="internet explorer" --seleniumAddress=http://localhost:4444/wd/hub
works now.
The Side note is not valid any more, the rest works as I described (reproduced).
It is importand to restart command-line after mixing with environment variables.
So, are you saying this works now? Can this be closed?
I am saying that it work with selenium started as java -jar with -Dwebdriver.ie.driver=<path to IEDriverServer> (side note) but the ERROR - Unable to start a WebDriver session. for automaicaly started WD session is still valid.
I think I have a similar problem when I change browser to internet explorer. I have Win7 64bit, and I do grunt test:protractor (angular.js repo). I get:
Running "webdriver" task
selenium standalone is up to date.
chromedriver is up to date.
Running "connect:testserver" (connect) task
Started connect web server on http://0.0.0.0:8000
Running "protractor:normal" (protractor) task
Starting selenium standalone server...
[launcher] Running 1 instances of WebDriver
Selenium standalone server started at http://192.168.0.10:62764/wd/hub
ERROR - Unable to start a WebDriver session.
Warning: Protractor test(s) failed. Exit code: 1 Use --force to continue.
It only works when I start the webdriver manually:
node_modules/.bin/webdriver-manager start
and add this line in the protractor.conf
config.seleniumAddress = 'http://127.0.0.1:4444/wd/hub';
I'm closing stale issues - please open a new issue if there is still a problem.
I think this issue still exists and isn't a usage error. When running tests with the browser capability set to "internet explorer", it gives an error when Protractor is trying to boot a standalone Selenium server stating that the the ie driver needs to be set on PATH. "The path to the driver executable must be set by the webdriver.ie.driver system property"
As the above commenters state, if running webdriver-manager start manually then pointing the protractor config to this instance, it works fine. Therefore I think possibly there may be a bug in there somewhere in the way the Selenium Standalone server is booted but I can't see where looking at the code. It seems like in local.ts we should be passing default gecko and ie driver locations if they exist to the selenium standalone start process? https://github.com/angular/protractor/blob/master/lib/driverProviders/local.ts But I don't really understand how, when it start the selenium server currently, it knows where the gecko driver is without that being in the path or passed in
If it is a bug, if someone can see where the error is I'll create a PR to fix