Skip to content

Commit dd4a64d

Browse files
committed
added tests
1 parent 88448fc commit dd4a64d

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

zarr/tests/test_meta_array.py

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
import zarr.codecs
1010
from zarr.core import Array
1111
from zarr.creation import array, empty, full, ones, open_array, zeros
12-
from zarr.hierarchy import open_group
12+
from zarr.hierarchy import open_group, group
1313
from zarr.storage import DirectoryStore, MemoryStore, Store, ZipStore
1414

1515

@@ -234,12 +234,13 @@ def test_full(module, compressor):
234234
assert np.all(np.isnan(z[:]))
235235

236236

237+
@pytest.mark.parametrize("group_create_function", [group, open_group])
237238
@pytest.mark.parametrize("module, compressor", param_module_and_compressor)
238239
@pytest.mark.parametrize("store_type", [None, DirectoryStore, MemoryStore, ZipStore])
239-
def test_group(tmp_path, module, compressor, store_type):
240+
def test_group(tmp_path, group_create_function, module, compressor, store_type):
240241
xp = ensure_module(module)
241242
store = init_store(tmp_path, store_type)
242-
g = open_group(store, meta_array=xp.empty(()))
243+
g = group_create_function(store, meta_array=xp.empty(()))
243244
g.ones("data", shape=(10, 11), dtype=int, compressor=compressor)
244245
a = g["data"]
245246
assert a.shape == (10, 11)

0 commit comments

Comments
 (0)