#5306: Fix compilation on Windows by properly merging change 69495.

+ fixed an obvious merge glitch in a windows-only test.

Patch by Hirokazu Yamamoto.

I added a _PyVerify_fd() call to os.device_encoding() (new in python 3.0)
which also uses a raw file descriptor.
This commit is contained in:
Amaury Forgeot d'Arc 2009-02-19 23:23:47 +00:00
parent b672b6dea6
commit 2fc224f090
2 changed files with 127 additions and 3 deletions

View file

@ -576,12 +576,12 @@ class Win32ErrorTests(unittest.TestCase):
self.assertRaises(WindowsError, os.chdir, support.TESTFN)
def test_mkdir(self):
f = open(test_support.TESTFN, "w")
f = open(support.TESTFN, "w")
try:
self.assertRaises(WindowsError, os.mkdir, support.TESTFN)
finally:
f.close()
os.unlink(test_support.TESTFN)
os.unlink(support.TESTFN)
def test_utime(self):
self.assertRaises(WindowsError, os.utime, support.TESTFN, None)