Bug 21684: Fix Hold.t

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
This commit is contained in:
Jonathan Druart 2020-01-07 16:06:38 +01:00 committed by Martin Renvoize
parent 276b646925
commit b8c0a387c8
Signed by: martin.renvoize
GPG key ID: 422B469130441A0F

View file

@ -150,7 +150,7 @@ subtest "delete() tests" => sub {
my $hold_object = Koha::Holds->find( $hold->{ reserve_id } );
my $deleted = $hold_object->delete;
is( $deleted, 1, 'Koha::Hold->delete should return 1 if the hold has been correctly deleted' );
is( ref($deleted), 'Koha::Hold', 'Koha::Hold->delete should return the Koha::Hold object if the hold has been correctly deleted' );
is( Koha::Holds->search({ reserve_id => $hold->{ reserve_id } })->count, 0,
"Koha::Hold->delete should have deleted the hold" );
@ -165,7 +165,7 @@ subtest "delete() tests" => sub {
$hold_object = Koha::Holds->find( $hold->{ reserve_id } );
$deleted = $hold_object->delete;
is( $deleted, 1, 'Koha::Hold->delete should return 1 if the hold has been correctly deleted' );
is( ref($deleted), 'Koha::Hold', 'Koha::Hold->delete should return a Koha::Hold object if the hold has been correctly deleted' );
is( Koha::Holds->search({ reserve_id => $hold->{ reserve_id } })->count, 0,
"Koha::Hold->delete should have deleted the hold" );