TT#56376 selenium: minor improvment to text output

admin_login.t:
- removed diag line, else the xml file could have issues
- swapped return statements

runner.t:
- adjust for swapped return statements

Change-Id: I3f0dd0ed50d8fda2e18a15a30a881ad80a8760fe
changes/95/30395/5
Nico Schedel 7 years ago
parent ed54429c51
commit f85efa0a29

@ -23,18 +23,16 @@ sub admin_login {
try {
my $login = 'administrator';
my $pwd = 'administrator';
diag("Loading login page (logout first)");
my $uri = $ENV{CATALYST_SERVER} || 'http://localhost:3000';
$d->get("$uri/logout"); # make sure we are logged out
$d->get("$uri/login");
$d->find_element('#username', 'css')->send_keys($login);
$d->find_element('#password', 'css')->send_keys($pwd);
$d->find_element('#submit', 'css')->click();
return 0;
return 1;
}
catch {
return 1;
return 0;
};
}

@ -14,7 +14,7 @@ my $dir = 't/selenium/';
my @tests;
my $string;
if(admin_login()) {
if(!admin_login()) {
print "-------------------------------------\n";
print "Test was aborted. Login failed\n";
print $ENV{CATALYST_SERVER} . "\n";

Loading…
Cancel
Save