Sha256: 8dd215989f2b74abea00dc12e3bdb287fed7cabc9a75a8e7bb02afc298428aa7

Contents?: true

Size: 474 Bytes

Versions: 131

Compression:

Stored size: 474 Bytes

Contents

# This class is mainly used for testing.
# When included (and used), it gives us an opportunity to stub out the output streams used for a given class
module Spork::CustomIOStreams
  def self.included(klass)
    klass.send(:extend, ::Spork::CustomIOStreams::ClassMethods)
  end
  
  def stderr
    self.class.stderr
  end

  def stdout
    self.class.stdout
  end
  
  module ClassMethods
    def stderr
      $stderr
    end
  
    def stdout
      $stdout
    end
  end
end

Version data entries

131 entries across 131 versions & 12 rubygems

Version Path
classiccms-0.5.9 vendor/bundle/gems/spork-0.9.0/lib/spork/custom_io_streams.rb
classiccms-0.5.8 vendor/bundle/gems/spork-0.9.0/lib/spork/custom_io_streams.rb
classiccms-0.5.7 vendor/bundle/gems/spork-0.9.0/lib/spork/custom_io_streams.rb
classiccms-0.5.6 vendor/bundle/gems/spork-0.9.0/lib/spork/custom_io_streams.rb
classiccms-0.5.5 vendor/bundle/gems/spork-0.9.0/lib/spork/custom_io_streams.rb
classiccms-0.5.2 vendor/bundle/gems/spork-0.9.0/lib/spork/custom_io_streams.rb
classiccms-0.5.1 vendor/bundle/gems/spork-0.9.0/lib/spork/custom_io_streams.rb
classiccms-0.5.0 vendor/bundle/gems/spork-0.9.0/lib/spork/custom_io_streams.rb
classiccms-0.4.2 vendor/bundle/gems/spork-0.9.0/lib/spork/custom_io_streams.rb
classiccms-0.4.1 vendor/bundle/gems/spork-0.9.0/lib/spork/custom_io_streams.rb
classiccms-0.4.0 vendor/bundle/gems/spork-0.9.0/lib/spork/custom_io_streams.rb
classiccms-0.3.9 vendor/bundle/gems/spork-0.9.0/lib/spork/custom_io_streams.rb
classiccms-0.3.8 vendor/bundle/gems/spork-0.9.0/lib/spork/custom_io_streams.rb
classiccms-0.3.7 vendor/bundle/gems/spork-0.9.0/lib/spork/custom_io_streams.rb
classiccms-0.3.6 vendor/bundle/gems/spork-0.9.0/lib/spork/custom_io_streams.rb
classiccms-0.3.5 vendor/bundle/gems/spork-0.9.0/lib/spork/custom_io_streams.rb
classiccms-0.3.4 vendor/bundle/gems/spork-0.9.0/lib/spork/custom_io_streams.rb
classiccms-0.3.3 vendor/bundle/gems/spork-0.9.0/lib/spork/custom_io_streams.rb
classiccms-0.3.2 vendor/bundle/gems/spork-0.9.0/lib/spork/custom_io_streams.rb
classiccms-0.3.1 vendor/bundle/gems/spork-0.9.0/lib/spork/custom_io_streams.rb