Sha256: 08b1fa7c5b68aed01be7266b1e9455b1f9259d19ef522d857b5e51bf5c3dcb1e

Contents?: true

Size: 264 Bytes

Versions: 14

Compression:

Stored size: 264 Bytes

Contents

module Reporting
  def silence_stream(stream)
    old_stream = stream.dup
    stream.reopen(RbConfig::CONFIG["host_os"] =~ /mswin|mingw/ ? "NUL:" : "/dev/null")
    stream.sync = true
    yield
  ensure
    stream.reopen(old_stream)
    old_stream.close
  end
end

Version data entries

14 entries across 14 versions & 1 rubygems

Version Path
kt-paperclip-7.2.2 spec/support/reporting.rb
kt-paperclip-7.2.1 spec/support/reporting.rb
kt-paperclip-7.2.0 spec/support/reporting.rb
kt-paperclip-6.4.2 spec/support/reporting.rb
kt-paperclip-7.1.1 spec/support/reporting.rb
kt-paperclip-7.1.0 spec/support/reporting.rb
kt-paperclip-7.0.1 spec/support/reporting.rb
kt-paperclip-7.0.0 spec/support/reporting.rb
kt-paperclip-6.4.1 spec/support/reporting.rb
kt-paperclip-6.4.0 spec/support/reporting.rb
kt-paperclip-6.3.0 spec/support/reporting.rb
kt-paperclip-6.2.2 spec/support/reporting.rb
kt-paperclip-6.2.1 spec/support/reporting.rb
kt-paperclip-6.2.0 spec/support/reporting.rb