Lines 100-106
my $reservedate = $first_hold->reservedate;
Link Here
|
100 |
my $borrowernumber = $first_hold->borrowernumber; |
100 |
my $borrowernumber = $first_hold->borrowernumber; |
101 |
my $branch_1code = $first_hold->branchcode; |
101 |
my $branch_1code = $first_hold->branchcode; |
102 |
my $reserve_id = $first_hold->reserve_id; |
102 |
my $reserve_id = $first_hold->reserve_id; |
103 |
is( $reservedate, output_pref({ dt => dt_from_string, dateformat => 'iso', dateonly => 1 }), "holds_placed_today should return a valid reserve date"); |
103 |
is( dt_from_string( $reservedate ), dt_from_string, "holds_placed_today should return a valid reserve date"); |
104 |
is( $borrowernumber, $borrowernumbers[0], "holds_placed_today should return a valid borrowernumber"); |
104 |
is( $borrowernumber, $borrowernumbers[0], "holds_placed_today should return a valid borrowernumber"); |
105 |
is( $branch_1code, $branch_1, "holds_placed_today should return a valid branchcode"); |
105 |
is( $branch_1code, $branch_1, "holds_placed_today should return a valid branchcode"); |
106 |
ok($reserve_id, "Test holds_placed_today()"); |
106 |
ok($reserve_id, "Test holds_placed_today()"); |
Lines 688-694
subtest 'CanItemBeReserved / holds_per_day tests' => sub {
Link Here
|
688 |
is_deeply( |
688 |
is_deeply( |
689 |
CanItemBeReserved( $patron->borrowernumber, $itemnumber_2 ), |
689 |
CanItemBeReserved( $patron->borrowernumber, $itemnumber_2 ), |
690 |
{ status => 'tooManyReservesToday', limit => 2 }, |
690 |
{ status => 'tooManyReservesToday', limit => 2 }, |
691 |
'Patron cannot a third item with 2 reserves daily cap' |
691 |
'Patron cannot reserve a third item with 2 reserves daily cap' |
692 |
); |
692 |
); |
693 |
|
693 |
|
694 |
# Update last hold so reservedate is in the past, so 2 holds, but different day |
694 |
# Update last hold so reservedate is in the past, so 2 holds, but different day |
695 |
- |
|
|