11from __future__ import annotations
22
3+ from typing import Any
4+
35import numpy as np
46import pytest
57
2022)
2123
2224
23- def test_nd_array_like (xp ) :
25+ def test_nd_array_like (xp : Any ) -> None :
2426 ary = xp .arange (10 )
2527 assert isinstance (ary , ArrayLike )
2628 assert isinstance (ary , NDArrayLike )
2729
2830
2931@pytest .mark .asyncio
30- async def test_async_array_prototype ():
32+ async def test_async_array_prototype () -> None :
3133 """Test the use of a custom buffer prototype"""
3234
3335 expect = np .zeros ((9 , 9 ), dtype = "uint16" , order = "F" )
3436 a = await AsyncArray .create (
35- StorePath (StoreExpectingTestBuffer (mode = "w" )) / "test_async_array_prototype" ,
37+ StorePath (await StoreExpectingTestBuffer . open (mode = "w" )) / "test_async_array_prototype" ,
3638 shape = expect .shape ,
3739 chunk_shape = (5 , 5 ),
3840 dtype = expect .dtype ,
@@ -53,10 +55,10 @@ async def test_async_array_prototype():
5355
5456
5557@pytest .mark .asyncio
56- async def test_codecs_use_of_prototype ():
58+ async def test_codecs_use_of_prototype () -> None :
5759 expect = np .zeros ((10 , 10 ), dtype = "uint16" , order = "F" )
5860 a = await AsyncArray .create (
59- StorePath (StoreExpectingTestBuffer (mode = "w" )) / "test_codecs_use_of_prototype" ,
61+ StorePath (await StoreExpectingTestBuffer . open (mode = "w" )) / "test_codecs_use_of_prototype" ,
6062 shape = expect .shape ,
6163 chunk_shape = (5 , 5 ),
6264 dtype = expect .dtype ,
@@ -84,7 +86,7 @@ async def test_codecs_use_of_prototype():
8486 assert np .array_equal (expect , got )
8587
8688
87- def test_numpy_buffer_prototype ():
89+ def test_numpy_buffer_prototype () -> None :
8890 buffer = numpy_buffer_prototype ().buffer .create_zero_length ()
8991 ndbuffer = numpy_buffer_prototype ().nd_buffer .create (shape = (1 , 2 ), dtype = np .dtype ("int64" ))
9092 assert isinstance (buffer .as_array_like (), np .ndarray )
0 commit comments