@@ -206,6 +206,7 @@ def test_iter(self):
206206 def test_relativelocalfile (self ):
207207 self .assertRaises (ValueError ,urllib .request .urlopen ,'./' + self .pathname )
208208
209+
209210class ProxyTests (unittest .TestCase ):
210211
211212 def setUp (self ):
@@ -259,6 +260,7 @@ def test_proxy_bypass_environment_host_match(self):
259260 self .assertFalse (bypass ('newdomain.com' )) # no port
260261 self .assertFalse (bypass ('newdomain.com:1235' )) # wrong port
261262
263+
262264class ProxyTests_withOrderedEnv (unittest .TestCase ):
263265
264266 def setUp (self ):
@@ -294,6 +296,7 @@ def test_getproxies_environment_prefer_lowercase(self):
294296 proxies = urllib .request .getproxies_environment ()
295297 self .assertEqual ('http://somewhere:3128' , proxies ['http' ])
296298
299+
297300class urlopen_HttpTests (unittest .TestCase , FakeHTTPMixin , FakeFTPMixin ):
298301 """Test urlopen() opening a fake http connection."""
299302
@@ -432,7 +435,6 @@ def test_ftp_cache_pruning(self):
432435 finally :
433436 self .unfakeftp ()
434437
435-
436438 def test_userpass_inurl (self ):
437439 self .fakehttp (b"HTTP/1.0 200 OK\r \n \r \n Hello!" )
438440 try :
@@ -476,6 +478,7 @@ def test_cafile_and_context(self):
476478 "https://localhost" , cafile = "/nonexistent/path" , context = context
477479 )
478480
481+
479482class urlopen_DataTests (unittest .TestCase ):
480483 """Test urlopen() opening a data URL."""
481484
@@ -549,6 +552,7 @@ def test_invalid_base64_data(self):
549552 # missing padding character
550553 self .assertRaises (ValueError ,urllib .request .urlopen ,'data:;base64,Cg=' )
551554
555+
552556class urlretrieve_FileTests (unittest .TestCase ):
553557 """Test urllib.urlretrieve() on local files"""
554558
0 commit comments