From 17f5445b0313fc0e07d06d6847d7ae2c8e9aaccc Mon Sep 17 00:00:00 2001 From: Nick Clemens Date: Wed, 13 Sep 2017 12:06:50 +0000 Subject: [PATCH] Bug 19307 - Mock the AllowFineOverride preference to ensure expected result To test: 1 - Set 'AllowFineOverride' to allow 2 - prove t/db_dependent/Circulation/NoIssuesChargeGuarantees.t 3 - 1 test fails 4 - Apply patch 5 - prove t/db_dependent/Circulation/NoIssuesChargeGuarantees.t 6 - All tests pass 7 - Set 'AllowFineOverride' to 'Don't allow' 8 - Tests should still pass Signed-off-by: Caroline Cyr La Rose --- t/db_dependent/Circulation/NoIssuesChargeGuarantees.t | 1 + 1 file changed, 1 insertion(+) diff --git a/t/db_dependent/Circulation/NoIssuesChargeGuarantees.t b/t/db_dependent/Circulation/NoIssuesChargeGuarantees.t index 1fc8aa0..2c7f16d 100644 --- a/t/db_dependent/Circulation/NoIssuesChargeGuarantees.t +++ b/t/db_dependent/Circulation/NoIssuesChargeGuarantees.t @@ -55,6 +55,7 @@ my $guarantee = $builder->build( ); t::lib::Mocks::mock_preference( 'NoIssuesChargeGuarantees', '5.00' ); +t::lib::Mocks::mock_preference( 'AllowFineOverride', '' ); my ( $issuingimpossible, $needsconfirmation ) = CanBookBeIssued( $patron, $item->{barcode} ); is( $issuingimpossible->{DEBT_GUARANTEES}, undef, "Patron can check out item" ); -- 1.9.1