Sha256: 03c42621be327b0cf17356cda2bec951d4a86f43d0b6d93ce3f713b0b8e3e14e

Contents?: true

Size: 274 Bytes

Versions: 95

Compression:

Stored size: 274 Bytes

Contents

module TestingSandbox
  # Temporarily replaces KCODE for the block
  def with_kcode(kcode)
    if RUBY_VERSION < '1.9'
      old_kcode, $KCODE = $KCODE, kcode
      begin
        yield
      ensure
        $KCODE = old_kcode
      end
    else
      yield
    end
  end
end

Version data entries

95 entries across 92 versions & 21 rubygems

Version Path
actionpack-2.3.4 test/testing_sandbox.rb
actionpack-2.3.3 test/testing_sandbox.rb
actionpack-2.0.4 test/testing_sandbox.rb
actionpack-2.0.5 test/testing_sandbox.rb
actionpack-2.3.2 test/testing_sandbox.rb
actionpack-2.2.2 test/testing_sandbox.rb
actionpack-2.1.1 test/testing_sandbox.rb
actionpack-2.1.2 test/testing_sandbox.rb
actionpack-2.1.0 test/testing_sandbox.rb
antfarm-0.3.0 rails/vendor/rails/actionpack/test/testing_sandbox.rb
antfarm-0.4.0 rails/vendor/rails/actionpack/test/testing_sandbox.rb
eactionpack-2.1.2 test/testing_sandbox.rb
radiant-0.7.0 vendor/rails/actionpack/test/testing_sandbox.rb
radiant-0.8.0 vendor/rails/actionpack/test/testing_sandbox.rb
radiant-0.7.1 vendor/rails/actionpack/test/testing_sandbox.rb