Sha256: de0a3b2c1824182c845bac765b2c09519e85fda22f4ca15cd2e2b7420758a796

Contents?: true

Size: 529 Bytes

Versions: 3

Compression:

Stored size: 529 Bytes

Contents

require "helper"

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

  def test_base
    page = @agent.get("http://google.com/tc_base_images.html")
    assert_equal page.images[0].url, "http://localhost/a.jpg"
    assert_equal page.images[1].url, "http://localhost/b.gif"
  end

  def test_base2
    page = @agent.get("http://google.com/tc_images.html")
    assert_equal page.images[0].url, "http://google.com/a.jpg"
    assert_equal page.images[1].url, "http://google.com/b.gif"
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
mechanize-2.0 test/test_images.rb
mechanize-2.0.pre.2 test/test_images.rb
mechanize-2.0.pre.1 test/test_images.rb