Bug 23102: No mock in selenium
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de> (cherry picked from commit9aa811c334
) Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com> (cherry picked from commit86e78b5511
) Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
This commit is contained in:
parent
282f02b6c0
commit
2c3dacad48
1 changed files with 5 additions and 3 deletions
|
@ -60,7 +60,8 @@ subtest 'SCI can load error pages' => sub {
|
|||
|
||||
my $builder = t::lib::TestBuilder->new;
|
||||
my $patron = $builder->build_object( { class => 'Koha::Patrons', value => { flags => 0 } } );
|
||||
t::lib::Mocks::mock_preference( 'RequireStrongPassword', 0 );
|
||||
my $rsp = C4::Context->preference('RequireStrongPassword');
|
||||
C4::Context->set_preference( 'RequireStrongPassword', '0' );
|
||||
my $password = Koha::AuthUtils::generate_password( $patron->category );
|
||||
$patron->set_password( { password => $password } );
|
||||
|
||||
|
@ -86,8 +87,9 @@ subtest 'SCI can load error pages' => sub {
|
|||
$s->driver->find_element('//form[@id="scan_form"]//button[@id="sci_checkin_button"]')->click;
|
||||
like( $driver->get_title(), qr(Self check-in), );
|
||||
|
||||
C4::Context->set_preference( 'SelfCheckInUserJS', $sci_js );
|
||||
C4::Context->set_preference( 'SelfCheckInModule', $sci_mo );
|
||||
C4::Context->set_preference( 'SelfCheckInUserJS', $sci_js );
|
||||
C4::Context->set_preference( 'SelfCheckInModule', $sci_mo );
|
||||
C4::Context->set_preference( 'RequireStrongPassword', $rsp );
|
||||
push @cleanup, $patron, $patron->category, $patron->library;
|
||||
};
|
||||
|
||||
|
|
Loading…
Reference in a new issue