Skip to content

Commit

Permalink
add edge cases to test
Browse files Browse the repository at this point in the history
  • Loading branch information
melonora committed Nov 27, 2024
1 parent 24a9fbb commit 4340d9c
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions tests/core/operations/test_map.py
Original file line number Diff line number Diff line change
Expand Up @@ -360,6 +360,12 @@ def _is_sequential(arr):
arr = da.asarray(np.array([2, 0]))
assert np.array_equal(relabel_sequential(arr).compute(), np.array([1, 0]))

arr = da.asarray(np.array([0, 9, 5]))
assert np.array_equal(relabel_sequential(arr).compute(), np.array([0, 2, 1]))

arr = da.asarray(np.array([4, 1, 3]))
assert np.array_equal(relabel_sequential(arr).compute(), np.array([3, 1, 2]))


def test_relabel_sequential_fails(sdata_blobs):
with pytest.raises(
Expand Down

0 comments on commit 4340d9c

Please sign in to comment.