Avoid creating a symbolic link to chromedriver in Travis.

pull/474/head
Clement Michaud 2019-12-05 09:16:32 +01:00 committed by Clément Michaud
parent 135cf718d5
commit 40094b67a3
2 changed files with 3 additions and 4 deletions

View File

@ -45,9 +45,8 @@ jobs:
- wget -N https://chromedriver.storage.googleapis.com/78.0.3904.70/chromedriver_linux64.zip -P ~/
- unzip ~/chromedriver_linux64.zip -d ~/
- rm ~/chromedriver_linux64.zip
- sudo mv -f ~/chromedriver /usr/local/share/
- sudo chmod +x /usr/local/share/chromedriver
- sudo ln -s /usr/local/share/chromedriver /usr/bin/chromedriver
- sudo mv -f ~/chromedriver /usr/local/bin/chromedriver
- sudo chmod +x /usr/local/bin/chromedriver
- go mod download
script:

View File

@ -21,7 +21,7 @@ type WebDriverSession struct {
// StartWebDriverWithProxy create a selenium session
func StartWebDriverWithProxy(proxy string, port int) (*WebDriverSession, error) {
service, err := selenium.NewChromeDriverService("/usr/bin/chromedriver", port)
service, err := selenium.NewChromeDriverService("/usr/local/bin/chromedriver", port)
if err != nil {
return nil, err