

def test_switch_to_new_window(self):
    page = AlertPage()
    handler = WindowsHandler()
    page.open()
    parent = handler.active_window
    handler.save_window_set()
    assert_false(handler.is_new_window_present())
    page.open_new_window_link.click()
    ok_(handler.is_new_window_present())
    new = handler.new_window
    handler.switch_to_new_window()
    eq_(new, handler.active_window)
    handler.drop_active_window()
    eq_(page, handler.active_window)

dataset/ETHPy150Open wgnet/webium/tests/alert_page/test_switch_to_new_window.py TestSwitchToNewWindow.test_switch_to_new_window/VarMisuse@95/122 `parent`->`page`