When using Protractor behind a proxy, you may see an error like:
Error updating Sauce pass/fail status: 'Could not send request: connect ETIMEDOUT 162.222.75.243:443'
This can be caused by Protractor not having the correct proxy configuration for communicating with the Sauce Labs REST API or with our OnDemand endpoint. To resolve it, make sure that exports.config section of your Protractor configuration file has these entries:
exports.config = { sauceUser: YOUR_SAUCE_USERNAME, sauceKey: YOUR_SAUCE_ACCESS_KEY, webDriverProxy: 'http://your_proxy_address:port', // Proxy for Commands (e.g. ondemand.saucelabs.com) sauceProxy: 'http://your_proxy_address:port', // Proxy for the REST API
// The rest of your config is omitted }
The webDriverProxy entry ensures that your test commands are sent from WebDriver, through the proxy, to our Selenium address. The sauceProxy entry ensures that the success or failure status of your tests is sent from Protractor, through the proxy, to the Sauce Labs REST API.