Skip to content

Commit 0d0712f

Browse files
committed
add tests for codecjson typeguard
1 parent 9a2f35b commit 0d0712f

2 files changed

Lines changed: 12 additions & 0 deletions

File tree

tests/test_abc/__init__.py

Whitespace-only changes.

tests/test_abc/test_codec.py

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
from __future__ import annotations
2+
3+
from zarr.abc.codec import _check_codecjson_v2
4+
5+
6+
def test_check_codecjson_v2_valid() -> None:
7+
"""
8+
Test that the _check_codecjson_v2 function works
9+
"""
10+
assert _check_codecjson_v2({"id": "gzip"})
11+
assert not _check_codecjson_v2({"id": 10})
12+
assert not _check_codecjson_v2([10, 11])

0 commit comments

Comments
 (0)