Skip to content

Commit

Permalink
Compute find_objects before checking values
Browse files Browse the repository at this point in the history
This is important for changes that will be made to `find_objects`, which
require returning a `Delayed` object instead of a `list` of `Delayed`
objects.
  • Loading branch information
jakirkham committed Feb 10, 2019
1 parent 8680f07 commit 9ff734c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions tests/test_dask_image/test_ndmeasure/test_core.py
Original file line number Diff line number Diff line change
Expand Up @@ -202,12 +202,12 @@ def test_find_objects(max_labels):
dask_image.ndmeasure.find_objects(d_l, max_labels)
else:
n_r = spnd.find_objects(n_l, max_labels)
d_r = dask_image.ndmeasure.find_objects(d_l, max_labels)
d_r = dask_image.ndmeasure.find_objects(d_l, max_labels).compute()

assert len(n_r) == len(d_r)

for i in irange(len(n_r)):
assert n_r[i] == d_r[i].compute()
assert n_r[i] == d_r[i]


@pytest.mark.parametrize(
Expand Down

0 comments on commit 9ff734c

Please sign in to comment.