Avoid creating a symbolic link to chromedriver in Travis.
parent
135cf718d5
commit
40094b67a3
|
@ -45,9 +45,8 @@ jobs:
|
||||||
- wget -N https://chromedriver.storage.googleapis.com/78.0.3904.70/chromedriver_linux64.zip -P ~/
|
- wget -N https://chromedriver.storage.googleapis.com/78.0.3904.70/chromedriver_linux64.zip -P ~/
|
||||||
- unzip ~/chromedriver_linux64.zip -d ~/
|
- unzip ~/chromedriver_linux64.zip -d ~/
|
||||||
- rm ~/chromedriver_linux64.zip
|
- rm ~/chromedriver_linux64.zip
|
||||||
- sudo mv -f ~/chromedriver /usr/local/share/
|
- sudo mv -f ~/chromedriver /usr/local/bin/chromedriver
|
||||||
- sudo chmod +x /usr/local/share/chromedriver
|
- sudo chmod +x /usr/local/bin/chromedriver
|
||||||
- sudo ln -s /usr/local/share/chromedriver /usr/bin/chromedriver
|
|
||||||
|
|
||||||
- go mod download
|
- go mod download
|
||||||
script:
|
script:
|
||||||
|
|
|
@ -21,7 +21,7 @@ type WebDriverSession struct {
|
||||||
|
|
||||||
// StartWebDriverWithProxy create a selenium session
|
// StartWebDriverWithProxy create a selenium session
|
||||||
func StartWebDriverWithProxy(proxy string, port int) (*WebDriverSession, error) {
|
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 {
|
if err != nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
|
|
Loading…
Reference in New Issue