hamcrest/PyHamcrest — pull request #29 by perfa (2013-01-10 20:47:49+00:00)
Title: Feature assert raises

### assert_raises function for expected exceptions
I've recreated the assert_raises function me and my team have been using for the last year at work. It validates that A) an assertion is indeed raised and B) the assertion is of the expected sort. The syntax is `assert_raises(exception, function, *args, **kwargs)`. It uses \*args and \*\*kwargs as I've thought of no better syntax that actually allows hamcrest to catch the exception. The down-side is that there's no natural way to add a description as a final argument, though it is a minor issue in my own opinion.