Sha256: 3fcb0188a22072b40a65ff17f21c19b0abf59654a8429118ebbf53e309e34c3a

Contents?: true

Size: 1.21 KB

Versions: 20

Compression:

Stored size: 1.21 KB

Contents

Shindo.tests('Excon Decompress Middleware') do
  env_init
  with_rackup('basic.ru') do
    tests('encoded uri passed to connection') do
      tests('GET /echo%20dirty').returns(200) do
        connection = Excon::Connection.new({
          :host             => '127.0.0.1',
          :middlewares      => Excon.defaults[:middlewares] + [Excon::Middleware::EscapePath],
          :nonblock         => false,
          :port             => 9292,
          :scheme           => 'http',
          :ssl_verify_peer  => false
        })
        response = connection.request(:method => :get, :path => '/echo%20dirty')
        response[:status]
      end
    end

    tests('unencoded uri passed to connection') do
      tests('GET /echo dirty').returns(200) do
        connection = Excon::Connection.new({
          :host             => '127.0.0.1',
          :middlewares      => Excon.defaults[:middlewares] + [Excon::Middleware::EscapePath],
          :nonblock         => false,
          :port             => 9292,
          :scheme           => 'http',
          :ssl_verify_peer  => false
        })
        response = connection.request(:method => :get, :path => '/echo dirty')
        response[:status]
      end
    end
  end
end

Version data entries

20 entries across 20 versions & 1 rubygems

Version Path
excon-0.43.0 tests/middlewares/escape_path_tests.rb
excon-0.42.1 tests/middlewares/escape_path_tests.rb
excon-0.42.0 tests/middlewares/escape_path_tests.rb
excon-0.41.0 tests/middlewares/escape_path_tests.rb
excon-0.40.0 tests/middlewares/escape_path_tests.rb
excon-0.39.6 tests/middlewares/escape_path_tests.rb
excon-0.39.5 tests/middlewares/escape_path_tests.rb
excon-0.39.4 tests/middlewares/escape_path_tests.rb
excon-0.39.3 tests/middlewares/escape_path_tests.rb
excon-0.39.2 tests/middlewares/escape_path_tests.rb
excon-0.39.1 tests/middlewares/escape_path_tests.rb
excon-0.39.0 tests/middlewares/escape_path_tests.rb
excon-0.38.0 tests/middlewares/escape_path_tests.rb
excon-0.37.0 tests/middlewares/escape_path_tests.rb
excon-0.36.0 tests/middlewares/escape_path_tests.rb
excon-0.35.0 tests/middlewares/escape_path_tests.rb
excon-0.34.0 tests/middlewares/escape_path_tests.rb
excon-0.33.0 tests/middlewares/escape_path_tests.rb
excon-0.32.1 tests/middlewares/escape_path_tests.rb
excon-0.32.0 tests/middlewares/escape_path_tests.rb