File tree Expand file tree Collapse file tree 2 files changed +2
-3
lines changed Expand file tree Collapse file tree 2 files changed +2
-3
lines changed Original file line number Diff line number Diff line change @@ -201,13 +201,12 @@ def test_save_tractogram_file(self):
201
201
nib .streamlines .save (trk_file , "dummy.trk" , header = {})
202
202
203
203
# Wrong extension.
204
- with pytest .warns (None ) as w :
204
+ with pytest .warns (ExtensionWarning ) as w :
205
205
trk_file = trk .TrkFile (tractogram )
206
206
with self .assertRaises (ValueError ):
207
207
nib .streamlines .save (trk_file , "dummy.tck" , header = {})
208
208
209
209
assert len (w ) == 1
210
- assert issubclass (w [0 ].category , ExtensionWarning )
211
210
assert "extension" in str (w [0 ].message )
212
211
213
212
with InTemporaryDirectory ():
Original file line number Diff line number Diff line change 58
58
59
59
60
60
def maybe_deprecated (meth_name ):
61
- return pytest .deprecated_call () if meth_name == 'get_data' else nullcontext ()
61
+ return pytest .deprecated_call () if meth_name == 'get_data' else nullcontext ()
62
62
63
63
64
64
class GenericImageAPI (ValidateAPI ):
You can’t perform that action at this time.
0 commit comments