From a90673352c798a37f4bbb695fb9cd949d854856e Mon Sep 17 00:00:00 2001 From: Jonathan Druart Date: Tue, 14 Jan 2020 10:33:03 +0100 Subject: [PATCH] Bug 20567: Add tests Signed-off-by: Hans Palsson Signed-off-by: Kyle M Hall --- t/db_dependent/Reserves/MultiplePerRecord.t | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/t/db_dependent/Reserves/MultiplePerRecord.t b/t/db_dependent/Reserves/MultiplePerRecord.t index 7f639ce459..80c1c3ecd1 100755 --- a/t/db_dependent/Reserves/MultiplePerRecord.t +++ b/t/db_dependent/Reserves/MultiplePerRecord.t @@ -19,7 +19,7 @@ use Modern::Perl; -use Test::More tests => 38; +use Test::More tests => 39; use t::lib::TestBuilder; use t::lib::Mocks; @@ -289,5 +289,8 @@ ok( $hold_id, 'Second hold was placed' ); $can = CanBookBeReserved($patron->{borrowernumber}, $biblio->{biblionumber}); is( $can->{status}, 'tooManyHoldsForThisRecord', 'Third hold exceeds limit of holds per record' ); -$schema->storage->txn_rollback; +Koha::Holds->find($hold_id)->found("W")->store; +$can = CanBookBeReserved($patron->{borrowernumber}, $biblio->{biblionumber}); +is( $can->{status}, 'tooManyHoldsForThisRecord', 'Third hold exceeds limit of holds per record' ); +$schema->storage->txn_rollback; -- 2.21.1 (Apple Git-122.3)