Skip to content

Commit b38a99b

Browse files
authored
Merge pull request #1132 from effigies/mnt/cleanups
MNT: Fix spacing and expected error types
2 parents d23a833 + e19f35b commit b38a99b

File tree

2 files changed

+7
-2
lines changed

2 files changed

+7
-2
lines changed

nibabel/ecat.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -853,7 +853,7 @@ def get_data_dtype(self, frame):
853853
def shape(self):
854854
x, y, z = self._subheader.get_shape()
855855
nframes = self._subheader.get_nframes()
856-
return(x, y, z, nframes)
856+
return (x, y, z, nframes)
857857

858858
def get_mlist(self):
859859
""" get access to the mlist

nibabel/tests/test_viewers.py

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,12 @@ def test_viewer():
5555
v.clim = (0, 3)
5656
with pytest.raises(ValueError):
5757
OrthoSlicer3D.clim.fset(v, (0.,)) # bad limits
58-
with pytest.raises(ValueError):
58+
with pytest.raises(
59+
(
60+
ValueError, # MPL3.5 and lower
61+
KeyError, # MPL3.6 and higher
62+
)
63+
):
5964
OrthoSlicer3D.cmap.fset(v, 'foo') # wrong cmap
6065

6166
# decrement/increment volume numbers via keypress

0 commit comments

Comments
 (0)