Skip to content

Commit 9325ba6

Browse files
asimchoudharyd-v-b
andauthored
Update tests/test_api.py
Add else block for write operations only Co-authored-by: Davis Bennett <[email protected]>
1 parent 4e54b23 commit 9325ba6

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

tests/test_api.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1094,9 +1094,9 @@ def test_open_modes_creates_group(tmp_path: pathlib.Path, mode: str) -> None:
10941094
# Expect FileNotFoundError to be raised if 'r' or 'r+' mode
10951095
with pytest.raises(FileNotFoundError):
10961096
zarr.open(store=zarr_dir, mode=mode)
1097-
zarr.open(store=zarr_dir, mode="w")
1098-
group = zarr.open(store=zarr_dir, mode=mode)
1099-
assert isinstance(group, Group)
1097+
else:
1098+
group = zarr.open(store=zarr_dir, mode=mode)
1099+
assert isinstance(group, Group)
11001100

11011101

11021102
async def test_metadata_validation_error() -> None:

0 commit comments

Comments
 (0)