Sha256: 3d4f6431d112efee814f33343e993cee6fbf0b9a88eed5e50c0d6cbc59aa1c7b
Contents?: true
Size: 676 Bytes
Versions: 7
Compression:
Stored size: 676 Bytes
Contents
module Sprinkle module Utility #:nodoc: class LogRecorder #:nodoc: attr_accessor :err, :out, :command, :code def initialize(cmd=nil) reset(cmd) end def log(stream, data) case stream when :err then @err << data when :out then @out << data end end # hash suitable to pass into a pretty failure details hash def hash {:error => err, :stdout => out, :command => command, :code => code} end def reset(cmd=nil) @command=cmd @code=nil @err="" @out="" end end end end
Version data entries
7 entries across 7 versions & 1 rubygems