diff --git a/py/selenium/webdriver/remote/remote_connection.py b/py/selenium/webdriver/remote/remote_connection.py index 2507e7fa31966..5ca59e1fc4626 100644 --- a/py/selenium/webdriver/remote/remote_connection.py +++ b/py/selenium/webdriver/remote/remote_connection.py @@ -135,7 +135,7 @@ def _identify_http_proxy_auth(self): url = url[url.find(":") + 3:] return "@" in url and len(url[:url.find('@')]) > 0 - def _seperate_http_proxy_auth(self): + def _separate_http_proxy_auth(self): url = self._proxy_url protocol = url[:url.find(":") + 3] no_protocol = url[len(protocol):] @@ -156,7 +156,7 @@ def _get_connection_manager(self): from urllib3.contrib.socks import SOCKSProxyManager return SOCKSProxyManager(self._proxy_url, **pool_manager_init_args) elif self._identify_http_proxy_auth(): - self._proxy_url, self._basic_proxy_auth = self._seperate_http_proxy_auth() + self._proxy_url, self._basic_proxy_auth = self._separate_http_proxy_auth() pool_manager_init_args['proxy_headers'] = urllib3.make_headers( proxy_basic_auth=self._basic_proxy_auth) return urllib3.ProxyManager(self._proxy_url, **pool_manager_init_args) diff --git a/py/test/unit/selenium/webdriver/remote/remote_connection_tests.py b/py/test/unit/selenium/webdriver/remote/remote_connection_tests.py index 8bfdfab38231c..4cbd765e73ef6 100644 --- a/py/test/unit/selenium/webdriver/remote/remote_connection_tests.py +++ b/py/test/unit/selenium/webdriver/remote/remote_connection_tests.py @@ -72,7 +72,7 @@ def test_get_proxy_url_none(mock_proxy_settings_missing): def test_get_proxy_url_http_auth(mock_proxy_auth_settings): remote_connection = RemoteConnection('http://remote', keep_alive=False) proxy_url = remote_connection._get_proxy_url() - raw_proxy_url, basic_auth_string = remote_connection._seperate_http_proxy_auth() + raw_proxy_url, basic_auth_string = remote_connection._separate_http_proxy_auth() assert proxy_url == "http://user:password@http_proxy.com:8080" assert raw_proxy_url == "http://http_proxy.com:8080" assert basic_auth_string == "user:password" @@ -81,7 +81,7 @@ def test_get_proxy_url_http_auth(mock_proxy_auth_settings): def test_get_proxy_url_https_auth(mock_proxy_auth_settings): remote_connection = RemoteConnection('https://remote', keep_alive=False) proxy_url = remote_connection._get_proxy_url() - raw_proxy_url, basic_auth_string = remote_connection._seperate_http_proxy_auth() + raw_proxy_url, basic_auth_string = remote_connection._separate_http_proxy_auth() assert proxy_url == "https://user:password@https_proxy.com:8080" assert raw_proxy_url == "https://https_proxy.com:8080" assert basic_auth_string == "user:password"