]> granicus.if.org Git - python/commitdiff
Read HTTP response inside transient_internet()
authorAntoine Pitrou <solipsis@pitrou.net>
Sat, 26 Mar 2011 17:38:06 +0000 (18:38 +0100)
committerAntoine Pitrou <solipsis@pitrou.net>
Sat, 26 Mar 2011 17:38:06 +0000 (18:38 +0100)
1  2 
Lib/test/test_urllibnet.py

index c8851031e894b30f316cbfccd317a92ba13b402c,a019ddd2a6a9071062fb5dafadb17dcb07c9de8a..32efb2b06e617492e8bd02463e48babf14a70b5c
@@@ -12,6 -12,6 +12,7 @@@ import tim
  
  
  class URLTimeoutTest(unittest.TestCase):
++    # XXX this test doesn't seem to test anything useful.
  
      TIMEOUT = 30.0
  
@@@ -24,7 -24,7 +25,7 @@@
      def testURLread(self):
          with support.transient_internet("www.python.org"):
              f = urllib.request.urlopen("http://www.python.org/")
--        x = f.read()
++            x = f.read()
  
  class urlopenNetworkTests(unittest.TestCase):
      """Tests urllib.reqest.urlopen using the network.