[Python-checkins] python/dist/src/Lib/test test_urllib.py,1.10,1.11
gvanrossum@users.sourceforge.net
gvanrossum@users.sourceforge.net
Fri, 25 Apr 2003 08:01:08 -0700
Update of /cvsroot/python/python/dist/src/Lib/test
In directory sc8-pr-cvs1:/tmp/cvs-serv20288/Lib/test
Modified Files:
test_urllib.py
Log Message:
Fix the tests on Windows, by writing the test data file in binary
mode.
XXX I'm not convinced that this is the right solution -- arguably,
on Windows, the _fileobject class should honor the mode argument
and do newline translation. But it's never done that so I think
there's no urgent need to fix this today.
Index: test_urllib.py
===================================================================
RCS file: /cvsroot/python/python/dist/src/Lib/test/test_urllib.py,v
retrieving revision 1.10
retrieving revision 1.11
diff -C2 -d -r1.10 -r1.11
*** test_urllib.py 25 Apr 2003 09:39:47 -0000 1.10
--- test_urllib.py 25 Apr 2003 15:01:05 -0000 1.11
***************
*** 25,29 ****
"""Setup of a temp file to use for testing"""
self.text = "test_urllib: %s\n" % self.__class__.__name__
! FILE = file(test_support.TESTFN, 'w')
try:
FILE.write(self.text)
--- 25,29 ----
"""Setup of a temp file to use for testing"""
self.text = "test_urllib: %s\n" % self.__class__.__name__
! FILE = file(test_support.TESTFN, 'wb')
try:
FILE.write(self.text)