Sha256: be761d87914dfa240e9074fa0979659b83bcbaa7932f478be372734bdb84d149

Contents?: true

Size: 216 Bytes

Versions: 35

Compression:

Stored size: 216 Bytes

Contents

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

  result.strip
end

Version data entries

35 entries across 35 versions & 1 rubygems

Version Path
locomotivecms_wagon-3.0.0 spec/support/thor.rb
locomotivecms_wagon-3.0.0.rc0 spec/support/thor.rb
locomotivecms_wagon-3.0.0.beta2 spec/support/thor.rb
locomotivecms_wagon-2.4.1 spec/support/thor.rb
locomotivecms_wagon-2.4.0 spec/support/thor.rb
locomotivecms_wagon-2.4.0.rc2 spec/support/thor.rb
locomotivecms_wagon-2.4.0.rc1 spec/support/thor.rb
locomotivecms_wagon-2.3.0 spec/support/thor.rb
locomotivecms_wagon-2.3.0.rc1 spec/support/thor.rb
locomotivecms_wagon-2.2.0 spec/support/thor.rb
locomotivecms_wagon-2.2.0.rc3 spec/support/thor.rb
locomotivecms_wagon-2.2.0.rc2 spec/support/thor.rb
locomotivecms_wagon-2.2.0.rc1 spec/support/thor.rb
locomotivecms_wagon-2.2.0.beta1 spec/support/thor.rb
locomotivecms_wagon-2.1.1 spec/support/thor.rb
locomotivecms_wagon-2.1.0 spec/support/thor.rb
locomotivecms_wagon-2.1.0.rc5 spec/support/thor.rb
locomotivecms_wagon-2.1.0.rc4 spec/support/thor.rb
locomotivecms_wagon-2.1.0.rc3 spec/support/thor.rb
locomotivecms_wagon-2.0.1 spec/support/thor.rb