method
new
1.3.1 -
Show latest stable
-
0 notes -
Class: Spec::Matchers::RaiseException
- 1.1.4
- 1.1.12
- 1.2.0
- 1.2.8
- 1.3.0 (0)
- 1.3.1 (0)
- What's this?
new(expected_exception_or_message=Exception, expected_message=nil, &block)
public
Hide source
# File lib/spec/matchers/raise_exception.rb, line 4 def initialize(expected_exception_or_message=Exception, expected_message=nil, &block) @block = block @actual_exception = nil case expected_exception_or_message when String, Regexp @expected_exception, @expected_message = Exception, expected_exception_or_message else @expected_exception, @expected_message = expected_exception_or_message, expected_message end end