Exception: Tomo::Testing::MockedExitError
- Inherits:
-
Exception
- Object
- Exception
- Tomo::Testing::MockedExitError
- Defined in:
- lib/tomo/testing/mocked_exit_error.rb
Overview
rubocop:disable Lint/InheritException
Instance Attribute Summary collapse
-
#status ⇒ Object
readonly
Returns the value of attribute status.
Instance Method Summary collapse
-
#initialize(status) ⇒ MockedExitError
constructor
A new instance of MockedExitError.
- #success? ⇒ Boolean
Constructor Details
#initialize(status) ⇒ MockedExitError
Returns a new instance of MockedExitError.
8 9 10 11 |
# File 'lib/tomo/testing/mocked_exit_error.rb', line 8 def initialize(status) @status = status super("tomo exited with status #{status}") end |
Instance Attribute Details
#status ⇒ Object (readonly)
Returns the value of attribute status.
6 7 8 |
# File 'lib/tomo/testing/mocked_exit_error.rb', line 6 def status @status end |
Instance Method Details
#success? ⇒ Boolean
13 14 15 |
# File 'lib/tomo/testing/mocked_exit_error.rb', line 13 def success? [true, 0].include?(status) end |