summaryrefslogtreecommitdiff
path: root/Lib/test/test_posix.py
diff options
context:
space:
mode:
authorSerhiy Storchaka <storchaka@gmail.com>2016-04-08 08:48:20 +0300
committerSerhiy Storchaka <storchaka@gmail.com>2016-04-08 08:48:20 +0300
commit7155b881f249dc9c72cdcea53b2a945798783781 (patch)
treeaec9b3d652c47e0f6961a8dbc721540803340d62 /Lib/test/test_posix.py
parent747be0805d947270b1b334a996b06ebcf50f4e42 (diff)
downloadcpython-git-7155b881f249dc9c72cdcea53b2a945798783781.tar.gz
Issue #26671: Fixed tests for changed error messages.
Diffstat (limited to 'Lib/test/test_posix.py')
-rw-r--r--Lib/test/test_posix.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/Lib/test/test_posix.py b/Lib/test/test_posix.py
index 2a59c38174..28cdd90d11 100644
--- a/Lib/test/test_posix.py
+++ b/Lib/test/test_posix.py
@@ -411,7 +411,7 @@ class PosixTester(unittest.TestCase):
self.assertTrue(posix.stat(bytearray(os.fsencode(support.TESTFN))))
self.assertRaisesRegex(TypeError,
- 'can\'t specify None for path argument',
+ 'should be string, bytes or integer, not',
posix.stat, None)
self.assertRaisesRegex(TypeError,
'should be string, bytes or integer, not',
@@ -863,9 +863,9 @@ class PosixTester(unittest.TestCase):
self.assertEqual(s1, s2)
s2 = posix.stat(support.TESTFN, dir_fd=None)
self.assertEqual(s1, s2)
- self.assertRaisesRegex(TypeError, 'should be integer, not',
+ self.assertRaisesRegex(TypeError, 'should be integer or None, not',
posix.stat, support.TESTFN, dir_fd=posix.getcwd())
- self.assertRaisesRegex(TypeError, 'should be integer, not',
+ self.assertRaisesRegex(TypeError, 'should be integer or None, not',
posix.stat, support.TESTFN, dir_fd=float(f))
self.assertRaises(OverflowError,
posix.stat, support.TESTFN, dir_fd=10**20)