Lines 47-54
SKIP: {
Link Here
|
47 |
$driver->get($mainpage); |
47 |
$driver->get($mainpage); |
48 |
like( $driver->get_title, qr(Log in to Koha), 'Hitting the main page should redirect to the login form'); |
48 |
like( $driver->get_title, qr(Log in to Koha), 'Hitting the main page should redirect to the login form'); |
49 |
|
49 |
|
50 |
my $password = Koha::AuthUtils::generate_password(); |
|
|
51 |
my $patron = $builder->build_object({ class => 'Koha::Patrons', value => { flags => 0 }}); |
50 |
my $patron = $builder->build_object({ class => 'Koha::Patrons', value => { flags => 0 }}); |
|
|
51 |
my $password = Koha::AuthUtils::generate_password($patron->category); |
52 |
t::lib::Mocks::mock_preference( 'RequireStrongPassword', 0 ); |
52 |
t::lib::Mocks::mock_preference( 'RequireStrongPassword', 0 ); |
53 |
$patron->set_password({ password => $password }); |
53 |
$patron->set_password({ password => $password }); |
54 |
|
54 |
|
Lines 81-88
SKIP: {
Link Here
|
81 |
$driver->get($mainpage); |
81 |
$driver->get($mainpage); |
82 |
like( $driver->get_title, qr(Koha online catalog), 'Hitting the main page should not redirect to the login form'); |
82 |
like( $driver->get_title, qr(Koha online catalog), 'Hitting the main page should not redirect to the login form'); |
83 |
|
83 |
|
84 |
my $password = Koha::AuthUtils::generate_password(); |
|
|
85 |
my $patron = $builder->build_object({ class => 'Koha::Patrons', value => { flags => 0 }}); |
84 |
my $patron = $builder->build_object({ class => 'Koha::Patrons', value => { flags => 0 }}); |
|
|
85 |
my $password = Koha::AuthUtils::generate_password($patron->category); |
86 |
t::lib::Mocks::mock_preference( 'RequireStrongPassword', 0 ); |
86 |
t::lib::Mocks::mock_preference( 'RequireStrongPassword', 0 ); |
87 |
$patron->set_password({ password => $password }); |
87 |
$patron->set_password({ password => $password }); |
88 |
|
88 |
|