1. I have just started learning Selenium IDE, RC and Perl script. I created a simple test case in Selenium IDE that completes to the end without any errors, when I set the Speed Control to Slow.
2. I Formatted the HTML to Perl and saved the file as (.pl) and compiled the program.
3. Selenium RC server reports back the Error:
09:24:10.538 INFO - Got result: ERROR: Element link=SQAForums not found on session b98fb731fd034f358dc7d7550ae7fd15
4. The command prompt reports back the Error:
# Error requesting http://localhost:4444/selenium-server/driver/: # ERROR: Element link=SQAForums not found not ok 8 - click, link=SQAForums, # Failed test 'click, link=SQAForums, ' # at sqaforms2.pl line 22.
I think this has something do with the speed\moving forward before it get the Element.
Can anyone help me to fix this error. I have researched this and only found a possible solution for Java Script.
Code:
use strict; use warnings; use Time::HiRes qw(sleep); use Test::WWW::Selenium; use Test::More "no_plan"; use Test::Exception; my $where_firefox_lives = "C:\\Program Files (x86)\\Mozilla Firefox\\f +irefox.exe"; my $sel = Test::WWW::Selenium->new( host => "localhost", port => 4444, browser => "*firefox $where_firefo +x_lives", browser_url => "http://www.sqaforu +ms.com" ); $sel->open_ok("/logout.php"); $sel->click_ok("link=Login"); $sel->wait_for_page_to_load_ok("30000"); $sel->type_ok("Loginname", "patrickee"); $sel->type_ok("Loginpass", "leeee1"); $sel->click_ok("buttlogin"); $sel->wait_for_page_to_load_ok("30000"); $sel->click_ok("link=SQAForums", ""); $sel->wait_for_page_to_load_ok("30000"); $sel->click_ok("link=Logout"); $sel->wait_for_page_to_load_ok("30000"); $sel->click_ok("ss0");
In reply to Selenium RC Perl Error: Element not found by patricklee
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |