summaryrefslogtreecommitdiffstats
path: root/Lib/test/test_macfs.py
diff options
context:
space:
mode:
authorJack Jansen <jack.jansen@cwi.nl>2003-03-11 21:48:57 (GMT)
committerJack Jansen <jack.jansen@cwi.nl>2003-03-11 21:48:57 (GMT)
commitdded84802a0782960ba52a5d55b885fc9cc23a44 (patch)
tree5dc7e18c974492b60ec54f2874f688af797797da /Lib/test/test_macfs.py
parentd65ec37f4637c4584ce83974e0e424410b2bd873 (diff)
downloadcpython-dded84802a0782960ba52a5d55b885fc9cc23a44.zip
cpython-dded84802a0782960ba52a5d55b885fc9cc23a44.tar.gz
cpython-dded84802a0782960ba52a5d55b885fc9cc23a44.tar.bz2
Allow unicode pathnames where FSRefs are expected. Fixes 696253.
Diffstat (limited to 'Lib/test/test_macfs.py')
-rw-r--r--Lib/test/test_macfs.py5
1 files changed, 5 insertions, 0 deletions
diff --git a/Lib/test/test_macfs.py b/Lib/test/test_macfs.py
index c9ca06b..d02d9e1 100644
--- a/Lib/test/test_macfs.py
+++ b/Lib/test/test_macfs.py
@@ -26,6 +26,11 @@ class TestMacfs(unittest.TestCase):
def test_fsref(self):
fsr = macfs.FSRef(test_support.TESTFN)
self.assertEqual(os.path.realpath(test_support.TESTFN), fsr.as_pathname())
+
+ def test_fsref_unicode(self):
+ testfn_unicode = unicode(test_support.TESTFN)
+ fsr = macfs.FSRef(testfn_unicode)
+ self.assertEqual(os.path.realpath(test_support.TESTFN), fsr.as_pathname())
def test_coercion(self):
fss = macfs.FSSpec(test_support.TESTFN)