Class: Flatware::Cucumber::StepResult
- Inherits:
-
Object
- Object
- Flatware::Cucumber::StepResult
- Defined in:
- lib/flatware/cucumber/step_result.rb
Instance Attribute Summary collapse
-
#exception ⇒ Object
readonly
Returns the value of attribute exception.
-
#status ⇒ Object
readonly
Returns the value of attribute status.
Instance Method Summary collapse
- #failed? ⇒ Boolean
-
#initialize(status, exception) ⇒ StepResult
constructor
A new instance of StepResult.
- #passed? ⇒ Boolean
- #progress ⇒ Object
Constructor Details
#initialize(status, exception) ⇒ StepResult
Returns a new instance of StepResult.
7 8 9 |
# File 'lib/flatware/cucumber/step_result.rb', line 7 def initialize(status, exception) @status, @exception = status, (serialized(exception) if exception) end |
Instance Attribute Details
#exception ⇒ Object (readonly)
Returns the value of attribute exception.
5 6 7 |
# File 'lib/flatware/cucumber/step_result.rb', line 5 def exception @exception end |
#status ⇒ Object (readonly)
Returns the value of attribute status.
5 6 7 |
# File 'lib/flatware/cucumber/step_result.rb', line 5 def status @status end |
Instance Method Details
#failed? ⇒ Boolean
15 16 17 |
# File 'lib/flatware/cucumber/step_result.rb', line 15 def failed? status == :failed end |
#passed? ⇒ Boolean
11 12 13 |
# File 'lib/flatware/cucumber/step_result.rb', line 11 def passed? status == :passed end |
#progress ⇒ Object
19 20 21 |
# File 'lib/flatware/cucumber/step_result.rb', line 19 def progress Cucumber::ProgressString.format(status) end |