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" );
$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" );
my $hold = $builder->build_object(
{ class => 'Koha::Holds',
- value => { suspend => 0, suspend_until => undef, waitingdate => undef }
+ value => { found => undef, suspend => 0, suspend_until => undef, waitingdate => undef }
}
);