Reputation: 319
Protractor use webdriver-manager to download the latest chrome driver. but he can't download the driver so I get this error :
etaddrinfo ENOTFOUND chromedriver.storage.googleapis.com chromedriver.storage.googleapis.com:443
I tried to download the driver manually, and inside the protactor-config :
{
chromeDriver: "../../chromedriver.exe", // I also tried with "./chromedriver_2.30.exe"
.... }
(I don't know if the chromedriver is relative path to the protractor.config or to the webdriver-manager module inside protractor)
But I keep getting this error, how can I treat this error without an internet connection at all?
btw, something to consider, we develop on windows, but how can our ci/cd server (linux) will get a driver suitable for linux??
Upvotes: 5
Views: 3138
Reputation: 2983
The best way is to put it in your angular.json:
"e2e": {
"builder": "@angular-devkit/build-angular:protractor",
"options": {
"webdriverUpdate": false,
"protractorConfig": "e2e/protractor.conf.ts",
"devServerTarget": "myproject:serve"
},
Upvotes: 0
Reputation: 13
I had the same problems and my solution it's not the best, but it works.
Locally:
webdriver-manager update
in my example I had to run it with -ignore_ssl
\node_modules\protractor\node_modules\webdriver-manager\selenium\
and copy all files (except update-config.json
) to some root folderOn Offline Machine - TFS in my case
node_modules\protractor\node_modules\webdriver-manager\selenium\
ng e2e --no-webdriver-update
Upvotes: 0
Reputation: 41
I had a similar issue. Found this answer with googling and I tried it. Seems to work.
With recent changes in protractor you can use:
ng e2e --webdriver-update=false
Upvotes: 4
Reputation: 1071
I had a similar issue. After trying different approaches like manually copying the driver or changing the protractor module, I found that the best workaround is to install a local Web server and provide the required driver for download through that local server. This solution worked and is also useful to provide other files (e.g. files that are directly downloaded during "npm install"). Steps are listed below.
Upvotes: 4