Skip to content

Commit e5e45c3

Browse files
committed
fix typing
1 parent 2eaa79d commit e5e45c3

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

tests/test_api.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import pathlib
22
import warnings
3-
from typing import Literal
3+
from typing import Literal, cast
44

55
import numpy as np
66
import pytest
@@ -21,6 +21,7 @@
2121
save_array,
2222
save_group,
2323
)
24+
from zarr.core.buffer import NDArrayLike
2425
from zarr.core.common import MemoryOrder, ZarrFormat
2526
from zarr.errors import MetadataValidationError
2627
from zarr.storage._utils import normalize_path
@@ -137,6 +138,7 @@ async def test_open_group_unspecified_version(
137138
@pytest.mark.parametrize("n_kwargs", [10, 1, 0])
138139
def test_save(store: Store, n_args: int, n_kwargs: int) -> None:
139140
data = np.arange(10)
141+
data = cast(NDArrayLike, data)
140142

141143
if n_kwargs == 0 and n_args == 0:
142144
with pytest.raises(ValueError):

0 commit comments

Comments
 (0)