diff options
Diffstat (limited to 'Lib')
-rw-r--r-- | Lib/test/output/test_urllib2 | 1 | ||||
-rw-r--r-- | Lib/test/test_urllib2.py | 17 |
2 files changed, 18 insertions, 0 deletions
diff --git a/Lib/test/output/test_urllib2 b/Lib/test/output/test_urllib2 new file mode 100644 index 0000000..4c4d6ab --- /dev/null +++ b/Lib/test/output/test_urllib2 @@ -0,0 +1 @@ +test_urllib2 diff --git a/Lib/test/test_urllib2.py b/Lib/test/test_urllib2.py new file mode 100644 index 0000000..d2af276 --- /dev/null +++ b/Lib/test/test_urllib2.py @@ -0,0 +1,17 @@ +from test_support import verify +import urllib2 + +# A couple trivial tests + +try: + urllib2.urlopen('bogus url') +except ValueError: + pass +else: + verify(0) + +file_url = "file://%s" % urllib2.__file__ +f = urllib2.urlopen(file_url) +buf = f.read() +f.close() + |