This repository was archived by the owner on Jul 29, 2024. It is now read-only.
File tree Expand file tree Collapse file tree 3 files changed +22
-3
lines changed Expand file tree Collapse file tree 3 files changed +22
-3
lines changed Original file line number Diff line number Diff line change @@ -93,9 +93,23 @@ export interface Config {
9393 sauceKey ?: string ;
9494 /**
9595 * Use sauceAgent if you need customize agent for https connection to
96- * saucelabs.com (i.e. your computer behind corporate proxy)
96+ * saucelabs.com (i.e. your computer behind corporate proxy).
97+ *
98+ * To match sauce agent implementation, use
99+ * [HttpProxyAgent](https://github.com/TooTallNate/node-http-proxy-agent)
100+ * to generate the agent or use sauceProxy as an alternative where
101+ * sauce generates the agent for you based on the proxy. If a sauceProxy is
102+ * provided, the sauceAgent will be overridden.
103+ */
104+ sauceAgent ?: HttpProxyAgent ;
105+ /**
106+ * Use sauceProxy that will get generated into an agent for https connection
107+ * to saucelabs.com (i.e. your computer behind corporate proxy).
108+ *
109+ * The sauceProxy is used to generate a sauceAgent. If a sauceProxy is
110+ * provided, the sauceAgent will be overridden.
97111 */
98- sauceAgent ?: string ;
112+ sauceProxy ?: string ;
99113 /**
100114 * Use sauceBuild if you want to group test capabilites by a build ID
101115 */
Original file line number Diff line number Diff line change @@ -57,7 +57,8 @@ export class Sauce extends DriverProvider {
5757 this . sauceServer_ = new SauceLabs ( {
5858 username : this . config_ . sauceUser ,
5959 password : this . config_ . sauceKey ,
60- agent : this . config_ . sauceAgent
60+ agent : this . config_ . sauceAgent ,
61+ proxy : this . config_ . sauceProxy
6162 } ) ;
6263 this . config_ . capabilities [ 'username' ] = this . config_ . sauceUser ;
6364 this . config_ . capabilities [ 'accessKey' ] = this . config_ . sauceKey ;
Original file line number Diff line number Diff line change @@ -105,3 +105,7 @@ declare namespace webdriver {
105105 isPresent ?: Function ;
106106 }
107107}
108+
109+ declare interface HttpProxyAgent {
110+ constructor ( opts : Object ) : HttpProxyAgent ;
111+ }
You can’t perform that action at this time.
0 commit comments