Sha256: 5baf28e024b408e173e3a47f981d286e5aa89eac54dc5df2226137715fb73bc4

Contents?: true

Size: 370 Bytes

Versions: 2

Compression:

Stored size: 370 Bytes

Contents

class File2String < String

  def initialize(file)
    content = ''
    f = File.open(file, "r")
    f.each_line { |line|
      content += line
    }
    f.close
    super(content)
  end

end

$LOAD_PATH << Pathname(__FILE__).dirname.parent.expand_path + 'lib'
require 'slf4r'

Dir.mkdir(Pathname(__FILE__).dirname.parent.expand_path + 'tmp') unless File.exists?('tmp')

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
slf4r-0.3.2 spec/spec_helper.rb
slf4r-0.3.1 spec/spec_helper.rb