sknano.testing.GeneratorTestFixtures.assertRaisesRegexp

GeneratorTestFixtures.assertRaisesRegexp(expected_exception, expected_regexp, callable_obj=None, *args, **kwargs)[source]

Asserts that the message in a raised exception matches a regexp.

Args:

expected_exception: Exception class expected to be raised. expected_regexp: Regexp (re pattern object or string) expected

to be found in error message.

callable_obj: Function to be called. args: Extra args. kwargs: Extra kwargs.