Closed dmcmullen closed 3 years ago
Thanks for reporting this, it will be fixed soon.
Hi @dmcmullen 👋
Thanks for reporting the issue, I looked into the code, and on debugging further, I found that we had deprecated selenium_host
and selenium_port
. For more information about it, please look at the documentation here.
you can use the below settings to make it work in v1.7
default: {
launch_url: 'https://nightwatchjs.org',
selenium: {
start_process: false,
port: 443,
host: 'ondemand.saucelabs.com'
}
},
Let me know if you still have an issue
Thank you for the update. That worked for me.
I am closing the issue then, please feel free to reopen if it occurs again
Selenium Host Ignored
When setting selenium_host it is ignored and localhost is used instead.
This occurs during test setup.
Expected behavior looks as follows
This is occurring because here in NightwatchClient is the first time the selenium_host is used if the webdriver.host is undefined. An update occurred in 1.7 that sets a default value for webdriver.host making it impossible to set the value to anything else. That code is here
Changing https://github.com/nightwatchjs/nightwatch/blob/main/lib/settings/settings.js#L151 to
const {port, host = 'localhost'} = this.settings.webdriver;
and deleting the setting of the default should correct this bug.