Sha256: dcd36f718b453568d4244e95fa90006d3eed75bae455c140aba21584c069213e

Contents?: true

Size: 497 Bytes

Versions: 8

Compression:

Stored size: 497 Bytes

Contents

require File.dirname(__FILE__) + "/helper"

class TestGzip < Test::Unit::TestCase
  def setup
    @agent = WWW::Mechanize.new
  end

  def test_request_empty_gzip
    assert_nothing_raised do
      page = @agent.get("http://localhost/gzip")
    end
  end

  def test_request_gzip
    page = nil
    assert_nothing_raised do
      page = @agent.get("http://localhost/gzip?file=index.html")
    end
    assert_kind_of(WWW::Mechanize::Page, page)
    assert_match('Hello World', page.body)
  end
end

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
mechanize-0.7.3 test/tc_gzipping.rb
mechanize-0.7.5 test/tc_gzipping.rb
mechanize-0.7.1 test/tc_gzipping.rb
mechanize-0.7.2 test/tc_gzipping.rb
mechanize-0.7.4 test/tc_gzipping.rb
mechanize-0.7.6 test/tc_gzipping.rb
mechanize-0.7.7 test/test_gzipping.rb
mechanize-0.7.8 test/test_gzipping.rb