Skip to content

Commit fead0d5

Browse files
committed
DOCTEST: Catch deprecation warning in doctest
1 parent f2c1084 commit fead0d5

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

nibabel/gifti/gifti.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -88,7 +88,8 @@ def _sanitize(args, kwargs):
8888
<GiftiMetaData {'key': 'val'}>
8989
>>> GiftiMetaData({"key": "val"})
9090
<GiftiMetaData {'key': 'val'}>
91-
>>> nvpairs = GiftiNVPairs(name='key', value='val')
91+
>>> with pytest.deprecated_call():
92+
... nvpairs = GiftiNVPairs(name='key', value='val')
9293
>>> with pytest.warns(FutureWarning):
9394
... GiftiMetaData(nvpairs)
9495
<GiftiMetaData {'key': 'val'}>

0 commit comments

Comments
 (0)