Skip to content

Commit 338f763

Browse files
musically-utqinhanmin2014
authored andcommitted
TST Throw correct error for pytest version (scikit-learn#12475)
1 parent 2912e3a commit 338f763

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

conftest.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,9 @@
1616
PYTEST_MIN_VERSION = '3.3.0'
1717

1818
if LooseVersion(pytest.__version__) < PYTEST_MIN_VERSION:
19-
raise('Your version of pytest is too old, you should have at least '
20-
'pytest >= {} installed.'.format(PYTEST_MIN_VERSION))
19+
raise ImportError('Your version of pytest is too old, you should have '
20+
'at least pytest >= {} installed.'
21+
.format(PYTEST_MIN_VERSION))
2122

2223

2324
def pytest_addoption(parser):

0 commit comments

Comments
 (0)