Class: Cucumber::Formatter::ConsoleCounts
- Inherits:
-
Object
- Object
- Cucumber::Formatter::ConsoleCounts
- Includes:
- Console
- Defined in:
- lib/cucumber/formatter/console_counts.rb
Constant Summary
Constants included from ANSIColor
Constants included from Term::ANSIColor
Term::ANSIColor::ATTRIBUTES, Term::ANSIColor::ATTRIBUTE_NAMES, Term::ANSIColor::COLORED_REGEXP
Instance Method Summary collapse
-
#initialize(config) ⇒ ConsoleCounts
constructor
A new instance of ConsoleCounts.
- #to_s ⇒ Object
Methods included from Console
#attach, #collect_snippet_data, #collect_undefined_parameter_type_names, #do_print_passing_wip, #do_print_profile_information, #do_print_snippets, #do_print_undefined_parameter_type_snippet, #exception_message_string, #format_step, #format_string, #indent, #linebreaks, #print_element_messages, #print_elements, #print_exception, #print_passing_wip, #print_profile_information, #print_snippets, #print_statistics
Methods included from ANSIColor
apply_custom_colors, #cukes, #green_cukes, #red_cukes, #yellow_cukes
Methods included from Term::ANSIColor
#attributes, included, #uncolored
Methods included from Duration
Constructor Details
#initialize(config) ⇒ ConsoleCounts
Returns a new instance of ConsoleCounts.
10 11 12 |
# File 'lib/cucumber/formatter/console_counts.rb', line 10 def initialize(config) @summary = Core::Report::Summary.new(config.event_bus) end |
Instance Method Details
#to_s ⇒ Object
14 15 16 17 18 19 |
# File 'lib/cucumber/formatter/console_counts.rb', line 14 def to_s [ [scenario_count, status_counts(@summary.test_cases)].compact.join(' '), [step_count, status_counts(@summary.test_steps)].compact.join(' ') ].join("\n") end |