Hi All,
I am having problem with verifying wrong password. I am testing one webpage with wrong password. After entering the wrong password, i am verifying for the text present "Invalid Username / Password!", and again when i am entering the wrong password, since the web page is not reloading, it is simply showing the same page within a fraction of second. And due to that, when i am entering the correct password third time, it's not happening. But the same thing is working fine with IE, may be because IE is slow. Here is the part of code:
test_modules->login_logout(\$sel, "admin", "admin");
$sel->wait_for_text_present_ok("Invalid",30000);
$sel->is_text_present_ok("Invalid Username / Password!");
test_modules->login_logout(\$sel, "ADMIN", "PASSWORD");
$sel->wait_for_text_present_ok("Invalid",30000);
$sel->is_text_present_ok("Invalid Username / Password!");
test_modules->login_logout(\$sel, "admin", "password");
even after entering the correct password third time, my web page stays on "Invalid Username/ Password!" page only and rest of test cases are failing.
login_logout function enters the user id and password and click on login button.
How can i put a put a wait for few seconds after clicking on login button.
Regards,
Shambhu.
hi,
Yes ur right. There is a synchronization problem arising alot in selenium on different browser. So, for that you to use wait command to various places.
Bye
