fixed UI test

This commit is contained in:
roy 2012-11-12 20:31:03 +01:00
parent 7ac9f38b84
commit 000d7040e3

View file

@ -22,21 +22,21 @@ class ExampleTest < Test::Unit::TestCase
end end
def test_login_failed def test_login_failed
element_username = browser.find_element :name "username" element_username = browser.find_element :name => "username"
element_username.send_keys = "roy@kaldung.de" element_username.send_keys "roy@kaldung.de"
element_password = browser.find_element :name "password" element_password = browser.find_element :name => "password"
element_password.send_keys = "123456" element_password.send_keys "123456"
element_form = browser.find_element :id "login" element_form = browser.find_element :id => "login"
element_form.submit element_form.submit
assert_equal browser.current_url, "https://portal.znuny.com/#login" assert_equal browser.current_url, "https://portal.znuny.com/#login"
end end
def test_login_passed def test_login_passed
element_username = browser.find_element :name "username" element_username = browser.find_element :name => "username"
element_username.send_keys = "roy@kaldung.com" element_username.send_keys "roy@kaldung.com"
element_password = browser.find_element :name "password" element_password = browser.find_element :name => "password"
element_password.send_keys = "090504" element_password.send_keys "090504"
element_form = browser.find_element :id "login" element_form = browser.find_element :id => "login"
element_form.submit element_form.submit
assert_equal browser.current_url, "https://portal.znuny.com/#ticket_view/my_tickets" assert_equal browser.current_url, "https://portal.znuny.com/#ticket_view/my_tickets"
end end