Pattern: Unspecified exception in assert_raises
Issue: -
Checks for a specified error in assert_raises
.
# bad
assert_raises { raise FooException }
assert_raises('This should have raised') { raise FooException }
# good
assert_raises(FooException) { raise FooException }
assert_raises(FooException, 'This should have raised') { raise FooException }