Skip to content

Commit 3f726b2

Browse files
committed
Fix wrapper tests
1 parent d0d6167 commit 3f726b2

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

tests/test_store/test_wrapper.py

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44

55
import pytest
66

7+
import zarr.core.buffer.cpu
78
from zarr.abc.store import Store
89
from zarr.core.buffer import Buffer
910
from zarr.core.buffer.cpu import buffer_prototype
@@ -25,7 +26,7 @@
2526
)
2627
class TestWrapperStore(StoreTests[WrapperStore[LocalStore], Buffer]):
2728
store_cls = WrapperStore
28-
buffer_cls = Buffer
29+
buffer_cls = zarr.core.buffer.cpu.Buffer
2930

3031
async def get(self, store: WrapperStore[LocalStore], key: str) -> Buffer:
3132
return self.buffer_cls.from_bytes((store._store.root / key).read_bytes())
@@ -93,7 +94,7 @@ async def set(self, key: str, value: Buffer) -> None:
9394
await super().set(key, value)
9495

9596
key = "foo"
96-
value = Buffer.from_bytes(b"bar")
97+
value = zarr.core.buffer.cpu.Buffer.from_bytes(b"bar")
9798
store_wrapped = NoisySetter(store)
9899
await store_wrapped.set(key, value)
99100
captured = capsys.readouterr()
@@ -113,7 +114,7 @@ async def get(
113114
return await super().get(key, prototype=prototype)
114115

115116
key = "foo"
116-
value = Buffer.from_bytes(b"bar")
117+
value = zarr.core.buffer.cpu.Buffer.from_bytes(b"bar")
117118
store_wrapped = NoisyGetter(store)
118119
await store_wrapped.set(key, value)
119120
assert await store_wrapped.get(key, buffer_prototype) == value

0 commit comments

Comments
 (0)