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 10 |
# File 'lib/flatware/cucumber/step_result.rb', line 7 def initialize(status, exception) @status = status @exception = (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
16 17 18 |
# File 'lib/flatware/cucumber/step_result.rb', line 16 def failed? status == :failed end |
#passed? ⇒ Boolean
12 13 14 |
# File 'lib/flatware/cucumber/step_result.rb', line 12 def passed? status == :passed end |
#progress ⇒ Object
20 21 22 |
# File 'lib/flatware/cucumber/step_result.rb', line 20 def progress Cucumber::ProgressString.format(status) end |