Exception: Contract::ContractError
- Inherits:
-
StandardError
- Object
- StandardError
- Contract::ContractError
- Includes:
- ContractException
- Defined in:
- lib/contract/exception.rb
Overview
Represents an unexpected failure while processing a contract test. This is more critical than ContractMismatch and usually means that something is wrong with the test itself.
Instance Attribute Summary collapse
-
#type ⇒ Object
readonly
The type of the original Exception that triggered the unexpected failure.
Attributes included from ContractException
#original_message, #test_contract, #test_method, #test_object
Instance Method Summary collapse
-
#initialize(*args) ⇒ ContractError
constructor
:nodoc:.
Constructor Details
#initialize(*args) ⇒ ContractError
:nodoc:
53 54 55 56 |
# File 'lib/contract/exception.rb', line 53 def initialize(*args) # :nodoc: @type = args.pop ce_initialize(*args) end |
Instance Attribute Details
#type ⇒ Object (readonly)
The type of the original Exception that triggered the unexpected failure.
60 61 62 |
# File 'lib/contract/exception.rb', line 60 def type @type end |