Class: ResultRow
- Inherits:
-
Object
- Object
- ResultRow
- Defined in:
- lib/rspec_overview/result_row.rb
Instance Attribute Summary collapse
-
#duration_raw ⇒ Object
Returns the value of attribute duration_raw.
-
#example_count ⇒ Object
Returns the value of attribute example_count.
-
#identifier ⇒ Object
readonly
Returns the value of attribute identifier.
Instance Method Summary collapse
- #avg_duration ⇒ Object
-
#initialize(identifier) ⇒ ResultRow
constructor
A new instance of ResultRow.
Constructor Details
#initialize(identifier) ⇒ ResultRow
Returns a new instance of ResultRow.
5 6 7 8 9 |
# File 'lib/rspec_overview/result_row.rb', line 5 def initialize(identifier) @identifier = identifier @example_count = 0 @duration_raw = 0.0 end |
Instance Attribute Details
#duration_raw ⇒ Object
Returns the value of attribute duration_raw.
3 4 5 |
# File 'lib/rspec_overview/result_row.rb', line 3 def duration_raw @duration_raw end |
#example_count ⇒ Object
Returns the value of attribute example_count.
3 4 5 |
# File 'lib/rspec_overview/result_row.rb', line 3 def example_count @example_count end |
#identifier ⇒ Object (readonly)
Returns the value of attribute identifier.
2 3 4 |
# File 'lib/rspec_overview/result_row.rb', line 2 def identifier @identifier end |
Instance Method Details
#avg_duration ⇒ Object
11 12 13 |
# File 'lib/rspec_overview/result_row.rb', line 11 def avg_duration duration_raw / example_count end |