TT#56376 Revert "TT#56376 selenium: change timeout values"

Reset timeout values to what they were before, imo 5 seconds is not enough
in some cases. Will test this first then change timeout values in functions
later if necessary.

This reverts commit df2f8cf448.

Change-Id: I586e68f0b1c1cf57e3691fc71e7619d0ede7d659
changes/87/30887/1
Nico Schedel 6 years ago
parent f7cc62a25e
commit 81a1b5cc6d

@ -30,7 +30,7 @@ sub BUILD {
# $self->set_window_position(0, 50) if ($browsername ne "htmlunit");
# $self->set_window_size($window_h,$window_w) if ($browsername ne "htmlunit");
# diag("Window size: $window_h x $window_w");
$self->set_timeout("implicit", 5_000);
$self->set_timeout("implicit", 10_000);
}
sub find_text {
@ -109,7 +109,7 @@ sub browser_name_in {
sub wait_for_text {
my ($self, $xpath, $expected, $timeout) = @_;
return unless $xpath && $expected;
$timeout = 10 unless $timeout; # seconds. Default timeout value if none is specified.
$timeout = 5 unless $timeout; # seconds. Default timeout value if none is specified.
my $started = time();
my $elapsed = time();
while ($elapsed - $started <= $timeout){
@ -124,7 +124,7 @@ sub wait_for_text {
sub move_and_click {
my ($self, $path, $type, $fallback, $timeout) = @_;
return unless $path && $type;
$timeout = 10 unless $timeout; # seconds. Default timeout value if none is specified.
$timeout = 5 unless $timeout; # seconds. Default timeout value if none is specified.
my $started = time();
my $elapsed = time();
while ($elapsed - $started <= $timeout){

Loading…
Cancel
Save