Skip to content

Commit 41667b5

Browse files
author
Luke Shaw
committed
Explicitly check overwrite works for existing file in tests
1 parent 5d8a8f3 commit 41667b5

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

tests/ndarray/test_concatenate.py

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -93,3 +93,9 @@ def test_stack(shape, dtype, axis):
9393

9494
newres = blosc2.open("localfile.b2nd", mode="r")
9595
np.testing.assert_almost_equal(newres[:], nparray)
96+
97+
# Test overwriting existing file
98+
result = blosc2.stack(
99+
[ndarr1, ndarr2, ndarr3], axis=axis, cparams=cparams, urlpath="localfile.b2nd", mode="w"
100+
)
101+
np.testing.assert_almost_equal(result[:], nparray)

0 commit comments

Comments
 (0)