diff --git a/t/db_dependent/Holds.t b/t/db_dependent/Holds.t index 10e2597d8f..0a5bd0463b 100755 --- a/t/db_dependent/Holds.t +++ b/t/db_dependent/Holds.t @@ -983,6 +983,9 @@ subtest 'CanItemBeReserved / holds_per_day tests' => sub { $schema->storage->txn_begin; + # Remove any ambient holds_per_day rule so this test is isolated from site configuration + Koha::CirculationRules->search( { rule_name => 'holds_per_day' } )->delete; + my $itemtype = $builder->build_object( { class => 'Koha::ItemTypes' } ); my $library = $builder->build_object( { class => 'Koha::Libraries' } ); my $patron = $builder->build_object( { class => 'Koha::Patrons' } ); @@ -1744,6 +1747,10 @@ subtest 'CanItemBeReserved rule precedence tests' => sub { t::lib::Mocks::mock_preference( 'ReservesControlBranch', 'ItemHomeLibrary' ); $schema->storage->txn_begin; + + # Remove any ambient holds_per_day rule so this test is isolated from site configuration + Koha::CirculationRules->search( { rule_name => 'holds_per_day' } )->delete; + my $library = $builder->build_object( { class => 'Koha::Libraries', diff --git a/t/db_dependent/ILSDI_Services.t b/t/db_dependent/ILSDI_Services.t index 48267c6841..f30073bc9f 100755 --- a/t/db_dependent/ILSDI_Services.t +++ b/t/db_dependent/ILSDI_Services.t @@ -467,6 +467,9 @@ subtest 'Holds test' => sub { $schema->storage->txn_begin; + # Remove any ambient holds_per_day rule so this test is isolated from site configuration + Koha::CirculationRules->search( { rule_name => 'holds_per_day' } )->delete; + t::lib::Mocks::mock_preference( 'AllowHoldsOnDamagedItems', 0 ); my $patron = $builder->build_object( { class => 'Koha::Patrons' } ); diff --git a/t/db_dependent/api/v1/holds.t b/t/db_dependent/api/v1/holds.t index 65fb7df2f4..b60a7cae09 100755 --- a/t/db_dependent/api/v1/holds.t +++ b/t/db_dependent/api/v1/holds.t @@ -844,6 +844,9 @@ subtest 'add() + can_place_holds() tests' => sub { $schema->storage->txn_begin; + # Remove any ambient holds_per_day rule so this test is isolated from site configuration + Koha::CirculationRules->search( { rule_name => 'holds_per_day' } )->delete; + my $password = 'AbcdEFG123'; my $library = $builder->build_object( { class => 'Koha::Libraries', value => { pickup_location => 1 } } );