Bug 40969: Mock the RenewalPeriodBase preference correctly
Signed-off-by: Trevor Diamond <trevor.diamond@mainlib.org> Signed-off-by: Nick Clemens <nick@bywatersolutions.com> Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
This commit is contained in:
parent
bed343d5ed
commit
412879a418
|
|
@ -339,6 +339,8 @@ subtest 'AddIssue | renewal when adding issue to same borrower' => sub {
|
|||
my $staff = $builder->build_object( { class => "Koha::Patrons" } );
|
||||
t::lib::Mocks::mock_userenv( { patron => $staff } );
|
||||
|
||||
t::lib::Mocks::mock_preference( 'RenewalPeriodBase', 'date_due' );
|
||||
|
||||
my $issue = AddIssue( $patron, $item->barcode );
|
||||
is( dt_from_string( $issue->date_due )->truncate( to => 'day' ), $seven_days, "Item issued for correct term" );
|
||||
$issue = AddIssue( $patron, $item->barcode );
|
||||
|
|
|
|||
Loading…
Reference in New Issue