Class: MicroTest::DotsFormatter

Inherits:
BaseFormatter show all
Defined in:
lib/micro_test/formatters/dots_formatter.rb

Instance Attribute Summary

Attributes inherited from BaseFormatter

#duration, #failed, #passed

Instance Method Summary collapse

Methods inherited from BaseFormatter

#after_class, #after_results, #before_class, #before_suite, #before_test, inherited, #initialize, set_short_name, short_name

Constructor Details

This class inherits a constructor from MicroTest::BaseFormatter

Instance Method Details

#after_suite(test_classes) ⇒ Object



11
12
13
14
15
16
# File 'lib/micro_test/formatters/dots_formatter.rb', line 11

def after_suite(test_classes)
  puts
  puts "".ljust(80, "-")
  puts "Finished in #{duration} seconds."
  puts
end

#after_test(test) ⇒ Object



7
8
9
# File 'lib/micro_test/formatters/dots_formatter.rb', line 7

def after_test(test)
  print(test.passed? ? green(".") : red("."))
end