lib/putter/print_strategy.rb in putter-0.2.1 vs lib/putter/print_strategy.rb in putter-0.3.0

- old
+ new

@@ -1,11 +1,12 @@ require "colorize" module Putter module PrintStrategy - Default = Proc.new do |label, method, args, result| - prefix = "\tPutter Debugging: ".colorize(:cyan) - suffix = "#{label} -- Method: :#{method}, Args: #{args}, Result: #{result}".colorize(:green) - puts prefix + suffix + Default = Proc.new do |label, line, method, args, result| + prefix = "\tPutter Debugging: #{label} ".colorize(:cyan) + line = !line.nil? ? ".#{line} " : " " + suffix = "-- Method: :#{method}, Args: #{args}, Result: #{result}".colorize(:green) + puts prefix + line + suffix end end end