Exception: Omnitest::StandardError
- Inherits:
-
StandardError
- Object
- StandardError
- Omnitest::StandardError
- Includes:
- Error
- Defined in:
- lib/omnitest/errors.rb
Overview
Base exception class from which all Omnitest exceptions derive. This class nests an exception when this class is re-raised from a rescue block.
Direct Known Subclasses
Instance Attribute Summary collapse
-
#original ⇒ ::StandardError
readonly
The original (wrapped) exception.
Instance Method Summary collapse
-
#initialize(msg, original = $ERROR_INFO) ⇒ StandardError
constructor
Creates a new StandardError exception which optionally wraps an original exception if given or detected by checking the ‘$!` global variable.
Methods included from Error
formatted_exception, formatted_trace
Constructor Details
#initialize(msg, original = $ERROR_INFO) ⇒ StandardError
Creates a new StandardError exception which optionally wraps an original exception if given or detected by checking the ‘$!` global variable.
108 109 110 111 |
# File 'lib/omnitest/errors.rb', line 108 def initialize(msg, original = $ERROR_INFO) super(msg) @original = original end |
Instance Attribute Details
#original ⇒ ::StandardError (readonly)
Returns the original (wrapped) exception.
100 101 102 |
# File 'lib/omnitest/errors.rb', line 100 def original @original end |