Skip to content
Snippets Groups Projects
Commit 5196449a authored by Paul McCarthy's avatar Paul McCarthy :mountain_bicyclist:
Browse files

adjust unit test for ensureIsImage

parent bbe0b45e
No related branches found
No related tags found
No related merge requests found
...@@ -22,7 +22,9 @@ def test_ensureIsImage(): ...@@ -22,7 +22,9 @@ def test_ensureIsImage():
assert ensure.ensureIsImage(img) is img assert ensure.ensureIsImage(img) is img
loaded = ensure.ensureIsImage('image.nii') loaded = [ensure.ensureIsImage('image.nii'),
ensure.ensureIsImage('image')]
assert isinstance(loaded, nib.nifti1.Nifti1Image) for l in loaded:
assert np.all(img.get_data() == loaded.get_data()) assert isinstance(l, nib.nifti1.Nifti1Image)
assert np.all(img.get_data() == l.get_data())
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment