##// END OF EJS Templates
Merge pull request #13248 from Kojoley/refactor-test_shim_warning...
Matthias Bussonnier -
r27002:fd60e064 merge
parent child Browse files
Show More
@@ -1,13 +1,10 b''
1 import pytest
1 import sys
2 import sys
2 import warnings
3
3
4 from IPython.utils.shimmodule import ShimWarning
4 from IPython.utils.shimmodule import ShimWarning
5
5
6
6
7 def test_shim_warning():
7 def test_shim_warning():
8 sys.modules.pop('IPython.config', None)
8 sys.modules.pop('IPython.config', None)
9 with warnings.catch_warnings(record=True) as w:
9 with pytest.warns(ShimWarning):
10 warnings.simplefilter("always")
11 import IPython.config
10 import IPython.config
12 assert len(w) == 1
13 assert issubclass(w[-1].category, ShimWarning)
General Comments 0
You need to be logged in to leave comments. Login now