Module: TestBench::Session::Controls::Exception::Cause
- Defined in:
- lib/test_bench/session/controls/exception.rb
Constant Summary collapse
- Example =
self.example
Class Method Summary collapse
- .example(exception_message: nil, exception_class: nil) ⇒ Object
- .exception_class ⇒ Object
- .exception_message ⇒ Object
Class Method Details
.example(exception_message: nil, exception_class: nil) ⇒ Object
46 47 48 49 50 51 52 53 54 55 56 |
# File 'lib/test_bench/session/controls/exception.rb', line 46 def self.example(exception_message: nil, exception_class: nil) ||= self. exception_class ||= self.exception_class Raise.(exception_class, ) rescue SomeOtherException exception = Exception.example(exception_message:, exception_class:) return exception else abort "Unreachable" end |
.exception_class ⇒ Object
62 63 64 |
# File 'lib/test_bench/session/controls/exception.rb', line 62 def self.exception_class SomeOtherException end |
.exception_message ⇒ Object
58 59 60 |
# File 'lib/test_bench/session/controls/exception.rb', line 58 def self. "Some exception cause" end |