mirror of
https://github.com/python/cpython.git
synced 2025-07-12 05:45:15 +00:00
Issue #20557: Use specific asserts in io tests.
This commit is contained in:
parent
ce17f76475
commit
0dcd80a6c0
5 changed files with 20 additions and 18 deletions
|
@ -83,8 +83,8 @@ class AutoFileTests:
|
|||
def testErrors(self):
|
||||
f = self.f
|
||||
self.assertEqual(f.name, TESTFN)
|
||||
self.assertTrue(not f.isatty())
|
||||
self.assertTrue(not f.closed)
|
||||
self.assertFalse(f.isatty())
|
||||
self.assertFalse(f.closed)
|
||||
|
||||
if hasattr(f, "readinto"):
|
||||
self.assertRaises((OSError, TypeError), f.readinto, "")
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue