如何设置 Google 二进制文件在堆栈 Webdriverio+Selenium+GoogleDriver 上的路径?它期望二进制文件位于 /usr/bin/google-chrome
上,但由于我使用 Heroku,我无法在该文件夹上写入 Google 二进制文件。
最佳答案
您可以在您的功能中指定二进制路径:
var client = require('webdriverio').remote({
desiredCapabilities: {
browserName: 'chrome',
'goog:chromeOptions': {
binary: '/Applications/Google Chrome.app/Contents/MacOS/Google Chrome'
}
}
})
关于selenium - 在Webdriverio+Selenium上设置Google Binary的路径,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/29963868/