sklearn.utils.testing
.assert_raise_message¶
-
sklearn.utils.testing.
assert_raise_message
(exceptions, message, function, *args, **kwargs)[source]¶ Helper function to test the message raised in an exception.
Given an exception, a callable to raise the exception, and a message string, tests that the correct exception is raised and that the message is a substring of the error thrown. Used to test that the specific message thrown during an exception is correct.
Parameters: