numpy.testing.assert_raises_regex — NumPy v1.11 Manual (original) (raw)
- Scipy.org
- Docs
- NumPy v1.11 Manual
- NumPy Reference
- Routines
- Test Support (numpy.testing)
- index
- next
- previous
numpy.testing.assert_raises_regex(exception_class, expected_regexp, callable_obj=None, *args, **kwargs)[source]¶
Fail unless an exception of class exception_class and with message that matches expected_regexp is thrown by callable when invoked with arguments args and keyword arguments kwargs.
Name of this function adheres to Python 3.2+ reference, but should work in all versions down to 2.6.