Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
githubering182 committed Mar 11, 2024
1 parent d5f3dbd commit 0c794c4
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions storage-app/src/shared/shared_tests/services_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -110,11 +110,15 @@ def test_chunks(self):
self.assertEqual(stream.chunk_length, 2)

def test_iterator(self):
stream = ObjectStreaming(self.file({}, b"12345"))
_file = self.file({}, b"12345")
stream = ObjectStreaming(_file)

async def _h():
async for chunk in stream._iterator():
self.assertEqual(chunk, bytes(CHUNK_SIZE))
self.assertEqual(
chunk,
bytes(min(_file.length, CHUNK_SIZE))
)

aiorun(_h())

Expand Down

0 comments on commit 0c794c4

Please sign in to comment.