lib/turn/reporters/progress_reporter.rb in turn-0.7.0 vs lib/turn/reporters/progress_reporter.rb in turn-0.8.0
- old
+ new
@@ -1,8 +1,7 @@
require 'turn/reporter'
require 'ansi/progressbar'
-require 'facets/string/tab'
module Turn
#
class ProgressReporter < Reporter
@@ -51,11 +50,11 @@
files = nil
suite.each do |testrun|
if testrun.files != [testrun.name] && testrun.files != files
label = testrun.files.join(' ')
- label = ::ANSI::Code.magenta(label) if COLORIZE
+ label = Colorize.magenta(label)
io.puts(label + "\n")
files = testrun.files
end
io.puts paint_line(testrun, width)
end
@@ -75,10 +74,10 @@
#if tally[2] != 0 or tally[3] != 0
unless fails.empty? # or verbose?
io.puts "\n\n-- Failures and Errors --\n\n"
fails.uniq.each do |testrun|
message = testrun.message.tabto(0).strip
- message = ::ANSI::Code.red(message) if COLORIZE
+ message = Colorize.red(message)
io.puts(message+"\n\n")
end
io.puts
end
#end