Sha256: cdc04ccae649cb65dbf4b63c8cef1a5ba810d0b4df6500768506537819050537

Contents?: true

Size: 614 Bytes

Versions: 3

Compression:

Stored size: 614 Bytes

Contents

# feature tests for closed windows
# revision: $Revision: 958 $

$LOAD_PATH.unshift File.join(File.dirname(__FILE__), '..', '..') if $0 == __FILE__
require 'unittests/setup'

class TC_CloseWindow < Watir::TestCase
  include Watir
  execute :sequentially
  
  def setup
    $ie.goto($htmlRoot + "new_browser.html")
  end
  
  # reproduces defect http://jira.openqa.org/browse/WTR-16
  def test_close_window_with_button
    $ie.link(:text, 'New Window').click
    ie_new = IE.attach(:title, 'Pass Page')
    assert(ie_new.text.include?('PASS'))
    assert_nothing_raised {ie_new.close}
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
watir-1.5.2 unittests/windows/close_window_test.rb
watir-1.5.4 unittests/windows/close_window_test.rb
watir-1.5.3 unittests/windows/close_window_test.rb