Skip to content

Commit 2d0bdd7

Browse files
committed
lint
1 parent f7cab1d commit 2d0bdd7

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed

tests/test_info.py

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,9 @@
11
import textwrap
22

3+
import numpy as np
34
import pytest
45

6+
from zarr.codecs.bytes import BytesCodec
57
from zarr.core._info import ArrayInfo, GroupInfo, human_readable_size
68
from zarr.core.common import ZarrFormat
79

@@ -51,13 +53,13 @@ def test_group_info_complete(zarr_format: ZarrFormat) -> None:
5153
def test_array_info(zarr_format: ZarrFormat) -> None:
5254
info = ArrayInfo(
5355
_zarr_format=zarr_format,
54-
_data_type="int32",
56+
_data_type=np.dtype("int32"),
5557
_shape=(100, 100),
5658
_chunk_shape=(10, 100),
5759
_order="C",
5860
_read_only=True,
5961
_store_type="MemoryStore",
60-
_codecs="[\"BytesCodec(endian=<Endian.little: 'little'>\"]",
62+
_codecs=[BytesCodec()],
6163
)
6264
result = repr(info)
6365
assert result == textwrap.dedent(f"""\
@@ -87,13 +89,13 @@ def test_array_info_complete(
8789
) = bytes_things
8890
info = ArrayInfo(
8991
_zarr_format=zarr_format,
90-
_data_type="int32",
92+
_data_type=np.dtype("int32"),
9193
_shape=(100, 100),
9294
_chunk_shape=(10, 100),
9395
_order="C",
9496
_read_only=True,
9597
_store_type="MemoryStore",
96-
_codecs="[\"BytesCodec(endian=<Endian.little: 'little'>\"]",
98+
_codecs=[BytesCodec()],
9799
_count_bytes=count_bytes,
98100
_count_bytes_stored=count_bytes_stored,
99101
_count_chunks_initialized=count_chunks_initialized,

0 commit comments

Comments
 (0)