Lines 2595-2601
subtest '_FixAccountForLostAndReturned returns undef if patron is deleted' => su
Link Here
|
2595 |
}; |
2595 |
}; |
2596 |
|
2596 |
|
2597 |
subtest 'Set waiting flag' => sub { |
2597 |
subtest 'Set waiting flag' => sub { |
2598 |
plan tests => 4; |
2598 |
plan tests => 9; |
2599 |
|
2599 |
|
2600 |
my $library_1 = $builder->build( { source => 'Branch' } ); |
2600 |
my $library_1 = $builder->build( { source => 'Branch' } ); |
2601 |
my $patron_1 = $builder->build( { source => 'Borrower', value => { branchcode => $library_1->{branchcode}, categorycode => $patron_category->{categorycode} } } ); |
2601 |
my $patron_1 = $builder->build( { source => 'Borrower', value => { branchcode => $library_1->{branchcode}, categorycode => $patron_category->{categorycode} } } ); |
Lines 2632-2637
subtest 'Set waiting flag' => sub {
Link Here
|
2632 |
is( $hold->found, 'W', 'Hold is waiting' ); |
2632 |
is( $hold->found, 'W', 'Hold is waiting' ); |
2633 |
( $status ) = CheckReserves($item->{itemnumber}); |
2633 |
( $status ) = CheckReserves($item->{itemnumber}); |
2634 |
is( $status, 'Waiting', 'Now the hold is waiting'); |
2634 |
is( $status, 'Waiting', 'Now the hold is waiting'); |
|
|
2635 |
|
2636 |
#Bug 21944 - Waiting transfer checked in at branch other than pickup location |
2637 |
set_userenv( $library_1 ); |
2638 |
(undef, my $messages, undef, undef ) = AddReturn ( $item->{barcode}, $library_1->{branchcode} ); |
2639 |
$hold = Koha::Holds->find( $reserve_id ); |
2640 |
is( $hold->found, undef, 'Hold is no longer marked waiting' ); |
2641 |
is( $hold->priority, 1, "Hold is now priority one again"); |
2642 |
is( $messages->{ResFound}->{ResFound}, "Reserved", "Hold is still returned"); |
2643 |
is( $messages->{ResFound}->{found}, undef, "Hold is no longer marked found in return message"); |
2644 |
is( $messages->{ResFound}->{priority}, 1, "Hold is priority 1 in return message"); |
2645 |
|
2635 |
}; |
2646 |
}; |
2636 |
|
2647 |
|
2637 |
subtest 'Cancel transfers on lost items' => sub { |
2648 |
subtest 'Cancel transfers on lost items' => sub { |
2638 |
- |
|
|