MCPcopy Create free account
hub / github.com/aws/aws-cli / test_close_callbacks

Method test_close_callbacks

tests/unit/s3transfer/test_utils.py:793–802  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

791 self.assertEqual(self.amounts_seen, expected)
792
793 def test_close_callbacks(self):
794 with open(self.filename) as f:
795 chunk = ReadFileChunk(
796 f,
797 chunk_size=1,
798 full_file_size=3,
799 close_callbacks=[self.close_callback],
800 )
801 chunk.close()
802 self.assertEqual(self.num_close_callback_calls, 1)
803
804 def test_close_callbacks_when_not_enabled(self):
805 with open(self.filename) as f:

Callers

nothing calls this directly

Calls 2

closeMethod · 0.95
ReadFileChunkClass · 0.90

Tested by

no test coverage detected