Sha256: e3e9832d805b4dd018db17fe3f255714d6df69349ea2f11a398d3caab88c0347

Contents?: true

Size: 1.15 KB

Versions: 21

Compression:

Stored size: 1.15 KB

Contents

$LOAD_PATH.unshift File.join(File.dirname(__FILE__), '..') unless $SETUP_LOADED
require 'unittests/setup'

class TC_HTML_Case_Sensitive_Tags < Test::Unit::TestCase
  include Watir::Exception
  location __FILE__

  def setup
    uses_page "a.html"
  end

  def test_html
    # HTML is not case sensitive, so all the links on the page should exist.
    assert browser.link(:id, "link1").exists?, "Could not find link1 by :id"
    assert browser.link(:id, "link2").exists?, "Could not find link2 by :id"
    assert browser.link(:id, "link3").exists?, "Could not find link3 by :id"
    assert browser.link(:id, "link4").exists?, "Could not find link4 by :id"

    links = browser.links
    assert(links.size == 4, "Links did not find 2 elements")

    links_text = [links[0].text, links[1].text, links[2].text, links[3].text].sort

    assert(links_text[0] == "another lowercase link", "Links did not find link3")
    assert(links_text[1] == "another uppercase link", "Links did not find link4")
    assert(links_text[2] == "lowercase link", "Links did not find link1")
    assert(links_text[3] == "uppercase link", "Links did not find link2")
  end
end

Version data entries

21 entries across 21 versions & 1 rubygems

Version Path
firewatir-1.9.4 unittests/html_case_sensitive_tags_test.rb
firewatir-1.9.3 unittests/html_case_sensitive_tags_test.rb
firewatir-1.9.2 unittests/html_case_sensitive_tags_test.rb
firewatir-1.9.2.rc1 unittests/html_case_sensitive_tags_test.rb
firewatir-1.9.1 unittests/html_case_sensitive_tags_test.rb
firewatir-1.9.1.rc1 unittests/html_case_sensitive_tags_test.rb
firewatir-1.9.0 unittests/html_case_sensitive_tags_test.rb
firewatir-1.9.0.rc7 unittests/html_case_sensitive_tags_test.rb
firewatir-1.9.0.rc6 unittests/html_case_sensitive_tags_test.rb
firewatir-1.9.0.rc5 unittests/html_case_sensitive_tags_test.rb
firewatir-1.9.0.rc4 unittests/html_case_sensitive_tags_test.rb
firewatir-1.9.0.rc3 unittests/html_case_sensitive_tags_test.rb
firewatir-1.9.0.rc2 unittests/html_case_sensitive_tags_test.rb
firewatir-1.9.0.rc1 unittests/html_case_sensitive_tags_test.rb
firewatir-1.8.1 unittests/html_case_sensitive_tags_test.rb
firewatir-1.8.1.rc1 unittests/html_case_sensitive_tags_test.rb
firewatir-1.8.0 unittests/html_case_sensitive_tags_test.rb
firewatir-1.8.0.rc1 unittests/html_case_sensitive_tags_test.rb
firewatir-1.7.1 unittests/html_case_sensitive_tags_test.rb
firewatir-1.7.0 unittests/html_case_sensitive_tags_test.rb