View | Details | Raw Unified | Return to bug 25811
Collapse All | Expand All

(-)a/t/db_dependent/selenium/authentication.t (-2 / +19 lines)
Lines 97-103 SKIP: { Link Here
97
        $driver->find_element('//a[@id="user-menu"]')->click;
97
        $driver->find_element('//a[@id="user-menu"]')->click;
98
        $driver->find_element('//a[@id="logout"]')->click;
98
        $driver->find_element('//a[@id="logout"]')->click;
99
        $driver->get($mainpage); # This should not be needed but we the next find_element fails randomly
99
        $driver->get($mainpage); # This should not be needed but we the next find_element fails randomly
100
        $driver->find_element('//div[@id="login"]'); # logged out
100
        { # Temporary debug
101
            $driver->error_handler(
102
                sub {
103
                    my ( $driver, $selenium_error ) = @_;
104
                    print STDERR "\nSTRACE:";
105
                    my $i = 1;
106
                    while ( (my @call_details = (caller($i++))) ){
107
                        print STDERR "\t" . $call_details[1]. ":" . $call_details[2] . " in " . $call_details[3]."\n";
108
                    }
109
                    print STDERR "\n";
110
                    print STDERR sprintf("Is logged in patron: %s (%s)?\n", $patron->surname, $patron->othernames );
111
                    $s->capture( $driver );
112
                    croak $selenium_error;
113
                }
114
            );
115
116
            $driver->find_element('//div[@id="login"]'); # logged out
117
            $s->add_error_handler; # Reset to the default error handler
118
        }
101
119
102
        # Using the form on the right
120
        # Using the form on the right
103
        $s->fill_form( { userid => $patron->userid, password => $password } );
121
        $s->fill_form( { userid => $patron->userid, password => $password } );
104
- 

Return to bug 25811