diff options
author | Serhiy Storchaka <storchaka@gmail.com> | 2016-04-08 08:48:20 +0300 |
---|---|---|
committer | Serhiy Storchaka <storchaka@gmail.com> | 2016-04-08 08:48:20 +0300 |
commit | 4548059959a787178f4a598143749295292ee0fc (patch) | |
tree | 0e0be858a31defe93a18cdae4f08e6e976914256 /Lib/test/test_posix.py | |
parent | 7152d489cf209af5bd825f34824c6feaab302601 (diff) | |
download | cpython-4548059959a787178f4a598143749295292ee0fc.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.py | 6 |
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) |