I have an application based on padrinorb and I am using the shoulda testing library for the same. There is a method that I need to test throws exception. I tried finding the documentation for the same, but couldn't find anything.
Here's the sample code that I want to test
def some_method(param)
raise APIException.new('Exception) if param == 2
end
How should I test that the some_method throws an exception when passed the parameter 2.