Sha256: d1afaa5e6291f38fbf188c97f42ba64dfa9c7f1afb1a512c9ebdbe4b5abc93c5

Contents?: true

Size: 323 Bytes

Versions: 4

Compression:

Stored size: 323 Bytes

Contents

require 'ruby_version'

require 'rspec'
require 'stringio'

def capture_stdout
  capture = StringIO.new
  restore, $stdout = $stdout, capture
  yield
  $stdout = restore
  capture.string
end

def capture_stderr
  capture = StringIO.new
  restore, $stderr = $stderr, capture
  yield
  $stderr = restore
  capture.string
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
ruby_version-1.0.3 spec/spec_helper.rb
ruby_version-1.0.2 spec/spec_helper.rb
ruby_version-1.0.1 spec/spec_helper.rb
ruby_version-1.0.0 spec/spec_helper.rb