Skip to content

Commit 7123ce3

Browse files
committed
Update byte counts for tests
1 parent d6ba3f4 commit 7123ce3

File tree

1 file changed

+10
-10
lines changed

1 file changed

+10
-10
lines changed

tests/test_array.py

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -376,25 +376,25 @@ async def test_chunks_initialized() -> None:
376376
def test_nbytes_stored() -> None:
377377
arr = zarr.create(shape=(100,), chunks=(10,), dtype="i4")
378378
result = arr.nbytes_stored()
379-
assert result == 366 # the size of the metadata document. This is a fragile test.
379+
assert result == 502 # the size of the metadata document. This is a fragile test.
380380
arr[:50] = 1
381381
result = arr.nbytes_stored()
382-
assert result == 566 # the size with 5 chunks filled.
382+
assert result == 702 # the size with 5 chunks filled.
383383
arr[50:] = 2
384384
result = arr.nbytes_stored()
385-
assert result == 766 # the size with all chunks filled.
385+
assert result == 902 # the size with all chunks filled.
386386

387387

388388
async def test_nbytes_stored_async() -> None:
389389
arr = await zarr.api.asynchronous.create(shape=(100,), chunks=(10,), dtype="i4")
390390
result = await arr.nbytes_stored()
391-
assert result == 366 # the size of the metadata document. This is a fragile test.
391+
assert result == 502 # the size of the metadata document. This is a fragile test.
392392
await arr.setitem(slice(50), 1)
393393
result = await arr.nbytes_stored()
394-
assert result == 566 # the size with 5 chunks filled.
394+
assert result == 702 # the size with 5 chunks filled.
395395
await arr.setitem(slice(50, 100), 2)
396396
result = await arr.nbytes_stored()
397-
assert result == 766 # the size with all chunks filled.
397+
assert result == 902 # the size with all chunks filled.
398398

399399

400400
def test_default_fill_values() -> None:
@@ -489,14 +489,14 @@ def test_info_complete(self) -> None:
489489
_codecs=[BytesCodec()],
490490
_count_bytes=128,
491491
_count_chunks_initialized=0,
492-
_count_bytes_stored=373, # the metadata?
492+
_count_bytes_stored=521, # the metadata?
493493
)
494494
assert result == expected
495495

496496
arr[:2, :2] = 10
497497
result = arr.info_complete()
498498
expected = dataclasses.replace(
499-
expected, _count_chunks_initialized=1, _count_bytes_stored=405
499+
expected, _count_chunks_initialized=1, _count_bytes_stored=553
500500
)
501501
assert result == expected
502502

@@ -545,14 +545,14 @@ async def test_info_complete_async(self) -> None:
545545
_codecs=[BytesCodec()],
546546
_count_bytes=128,
547547
_count_chunks_initialized=0,
548-
_count_bytes_stored=373, # the metadata?
548+
_count_bytes_stored=521, # the metadata?
549549
)
550550
assert result == expected
551551

552552
await arr.setitem((slice(2), slice(2)), 10)
553553
result = await arr.info_complete()
554554
expected = dataclasses.replace(
555-
expected, _count_chunks_initialized=1, _count_bytes_stored=405
555+
expected, _count_chunks_initialized=1, _count_bytes_stored=553
556556
)
557557
assert result == expected
558558

0 commit comments

Comments
 (0)