Sha256: fde5a432b9dce07405b27560f95987d3629315f8c56791f0428f89d239a23b92

Contents?: true

Size: 545 Bytes

Versions: 8

Compression:

Stored size: 545 Bytes

Contents

require 'spork'

Spork.prefork do
  require 'rspec'
  require 'fileutils'

  RSpec.configure do |c|
    def cleanup(dir)
      FileUtils.rm_r(dir, :verbose => true) if File.exists?(dir)
    end

    def capture(stream)
      begin
        stream = stream.to_s
        eval "$#{stream} = StringIO.new"
        yield
        result = eval("$#{stream}").string
      ensure
        eval("$#{stream} = #{stream.upcase}")
      end

      result
    end
  end
end

Spork.each_run do
  require File.expand_path('../../lib/fontrobot.rb', __FILE__)
end

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
fontrobot-0.1.8 spec/spec_helper.rb
fontrobot-0.1.7 spec/spec_helper.rb
fontrobot-0.1.6 spec/spec_helper.rb
fontrobot-0.1.5 spec/spec_helper.rb
fontrobot-0.1.4 spec/spec_helper.rb
fontrobot-0.1.3 spec/spec_helper.rb
fontrobot-0.1.2 spec/spec_helper.rb
fontrobot-0.1 spec/spec_helper.rb