Bug 28503: (follow-up) Get rid of tests warnings
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
This commit is contained in:
parent
19660a25fa
commit
1e677a8755
|
|
@ -1313,11 +1313,15 @@ subtest 'ModReserveAffect logging' => sub {
|
|||
$hold = Koha::Holds->find($reserve_id);
|
||||
is( $hold->timestamp, $previous_timestamp, 'Make sure the previous timestamp has been used' );
|
||||
|
||||
# Avoid warnings
|
||||
my $reserve_mock = Test::MockModule->new('C4::Reserves');
|
||||
$reserve_mock->mock( '_koha_notify_reserve', undef );
|
||||
|
||||
# Mark it waiting
|
||||
ModReserveAffect( $item->itemnumber, $patron->borrowernumber );
|
||||
|
||||
$hold = Koha::Holds->find($reserve_id);
|
||||
is( $hold->found, 'W', 'Hold has been set waiting' );
|
||||
$hold->discard_changes;
|
||||
ok( $hold->is_waiting, 'Hold has been set waiting' );
|
||||
isnt( $hold->timestamp, $previous_timestamp, 'The timestamp has been modified' );
|
||||
|
||||
my $log = Koha::ActionLogs->search({ module => 'HOLDS', action => 'MODIFY', object => $hold->reserve_id })->next;
|
||||
|
|
|
|||
Loading…
Reference in New Issue