Sha256: b2aa8df88ce00a7afc7cfec36402aa4c0a51c9edf22b9a7b032914d3736221ba

Contents?: true

Size: 586 Bytes

Versions: 2

Compression:

Stored size: 586 Bytes

Contents

$:.unshift(File.dirname(__FILE__))
$:.unshift(File.join(File.dirname(__FILE__), '..', 'lib'))

#require 'rspec/mocks'
require 'applix'
require 'applix/oattr'

RSpec.configure do |config|
  config.before :each do
  end

  config.after :each do
  end
end

# captures standard output streams to help testing console I/O
#
def capture(*streams)
  streams.map! { |stream| stream.to_s }
  begin
    result = StringIO.new
    streams.each { |stream| eval "$#{stream} = result" }
    yield
  ensure
    streams.each { |stream| eval("$#{stream} = #{stream.upcase}") }
  end
  result.string
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
applix-0.4.11 spec/spec_helper.rb
applix-0.4.10 spec/spec_helper.rb