Skip to content

Commit 5432691

Browse files
committed
fix numerous mistakes
1 parent c7c708e commit 5432691

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

tests/unit/test_fileio.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -416,6 +416,8 @@ def test_close_errors(self):
416416
writer.close()
417417
# Close a second time to verify it successfully does nothing.
418418
writer.close()
419+
420+
self.assertTrue(writer.closed)
419421
# Try to write to closed file.
420422
with self.assertRaises(ValueError):
421423
writer.write(TEST_BINARY_DATA)
@@ -768,7 +770,7 @@ def test_seek(self):
768770
def test_close(self):
769771
buff = self._make_sliding_buffer()
770772
buff.close()
771-
self.assertTrue(buff.closed())
773+
self.assertTrue(buff.closed)
772774
with self.assertRaises(ValueError):
773775
buff.read()
774776

@@ -915,7 +917,7 @@ def test_close(self):
915917
reader = self._make_blob_reader(blob)
916918

917919
reader.close()
918-
self.assertRaises(self.closed)
920+
self.assertTrue(reader.closed)
919921

920922
with self.assertRaises(ValueError):
921923
reader.read()

0 commit comments

Comments
 (0)