@@ -60,13 +60,17 @@ protected function __construct() {}
6060 * @param DesiredCapabilities|array $desired_capabilities The desired capabilities
6161 * @param int|null $connection_timeout_in_ms
6262 * @param int|null $request_timeout_in_ms
63+ * @param string|null $http_proxy The proxy to tunnel requests through
64+ * @param int|null $http_proxy_port
6365 * @return RemoteWebDriver
6466 */
6567 public static function create (
6668 $ url = 'http://localhost:4444/wd/hub ' ,
6769 $ desired_capabilities = null ,
6870 $ connection_timeout_in_ms = null ,
69- $ request_timeout_in_ms = null
71+ $ request_timeout_in_ms = null ,
72+ $ http_proxy = null ,
73+ $ http_proxy_port = null
7074 ) {
7175 $ url = preg_replace ('#/+$# ' , '' , $ url );
7276
@@ -76,7 +80,7 @@ public static function create(
7680 $ desired_capabilities = $ desired_capabilities ->toArray ();
7781 }
7882
79- $ executor = new HttpCommandExecutor ($ url );
83+ $ executor = new HttpCommandExecutor ($ url, $ http_proxy , $ http_proxy_port );
8084 if ($ connection_timeout_in_ms !== null ) {
8185 $ executor ->setConnectionTimeout ($ connection_timeout_in_ms );
8286 }
0 commit comments