summaryrefslogtreecommitdiffstats
path: root/Lib/test/test_support.py
diff options
context:
space:
mode:
authorMartin v. Löwis <martin@v.loewis.de>2007-08-30 20:58:02 (GMT)
committerMartin v. Löwis <martin@v.loewis.de>2007-08-30 20:58:02 (GMT)
commit234a34a564aa74e6ff6433e6c66ac2ad01401dca (patch)
treea85eea6df5098129ad6fe5366cb7abc47857e49a /Lib/test/test_support.py
parent5495957b6c3aab91bbb6660f4bb2f5168bc536e7 (diff)
downloadcpython-234a34a564aa74e6ff6433e6c66ac2ad01401dca.zip
cpython-234a34a564aa74e6ff6433e6c66ac2ad01401dca.tar.gz
cpython-234a34a564aa74e6ff6433e6c66ac2ad01401dca.tar.bz2
Explicitly use UTF-8 as the encoding for the normalization file.
Diffstat (limited to 'Lib/test/test_support.py')
-rw-r--r--Lib/test/test_support.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/Lib/test/test_support.py b/Lib/test/test_support.py
index 99f57e6..637043d 100644
--- a/Lib/test/test_support.py
+++ b/Lib/test/test_support.py
@@ -244,7 +244,7 @@ def check_syntax_error(testcase, statement):
else:
testcase.fail('Missing SyntaxError: "%s"' % statement)
-def open_urlresource(url):
+def open_urlresource(url, *args, **kw):
import urllib, urlparse
requires('urlfetch')
@@ -253,11 +253,11 @@ def open_urlresource(url):
for path in [os.path.curdir, os.path.pardir]:
fn = os.path.join(path, filename)
if os.path.exists(fn):
- return open(fn)
+ return open(fn, *args, **kw)
print('\tfetching %s ...' % url, file=get_original_stdout())
fn, _ = urllib.urlretrieve(url, filename)
- return open(fn)
+ return open(fn, *args, **kw)
class WarningMessage(object):