Add a test for uu.encode() that passed filenames as

in_file and out_file.
This commit is contained in:
Walter Dörwald 2005-11-21 18:55:56 +00:00
parent c69d1c498f
commit 705fd474e9
1 changed files with 8 additions and 0 deletions

View File

@ -128,6 +128,14 @@ class UUFileTest(unittest.TestCase):
s = fout.read()
fout.close()
self.assertEqual(s, encodedtextwrapped % (0644, self.tmpin))
# in_file and out_file as filenames
uu.encode(self.tmpin, self.tmpout, mode=0644)
fout = open(self.tmpout, 'r')
s = fout.read()
fout.close()
self.assertEqual(s, encodedtextwrapped % (0644, self.tmpin))
finally:
self._kill(fin)
self._kill(fout)