View | Details | Raw Unified | Return to bug 30447
Collapse All | Expand All

(-)a/t/db_dependent/Holds.t (-2 / +4 lines)
Lines 1706-1712 subtest 'ModReserve can only update expirationdate for found holds' => sub { Link Here
1706
};
1706
};
1707
1707
1708
subtest 'Koha::Holds->get_items_that_can_fill returns items with datecancelled or (inclusive) datearrived' => sub {
1708
subtest 'Koha::Holds->get_items_that_can_fill returns items with datecancelled or (inclusive) datearrived' => sub {
1709
    plan tests => 5;
1709
    plan tests => 8;
1710
    # biblio item with date arrived and date cancelled
1710
    # biblio item with date arrived and date cancelled
1711
    my $biblio1 = $builder->build_sample_biblio();
1711
    my $biblio1 = $builder->build_sample_biblio();
1712
    my $item1 = $builder->build_sample_item({ biblionumber => $biblio1->biblionumber });
1712
    my $item1 = $builder->build_sample_item({ biblionumber => $biblio1->biblionumber });
Lines 1788-1793 subtest 'Koha::Holds->get_items_that_can_fill returns items with datecancelled o Link Here
1788
    is($items_that_can_fill1->next->id, $item1->id, "Koha::Holds->get_items_that_can_fill returns item with defined datearrived and datecancelled");
1788
    is($items_that_can_fill1->next->id, $item1->id, "Koha::Holds->get_items_that_can_fill returns item with defined datearrived and datecancelled");
1789
    is($items_that_can_fill1->count, 1, "Koha::Holds->get_items_that_can_fill returns 1 item with correct parameters");
1789
    is($items_that_can_fill1->count, 1, "Koha::Holds->get_items_that_can_fill returns 1 item with correct parameters");
1790
    is($items_that_can_fill2->next->id, $item2->id, "Koha::Holds->get_items_that_can_fill returns item with defined datearrived and undefined datecancelled");
1790
    is($items_that_can_fill2->next->id, $item2->id, "Koha::Holds->get_items_that_can_fill returns item with defined datearrived and undefined datecancelled");
1791
    is($items_that_can_fill2->count, 1, "Koha::Holds->get_items_that_can_fill returns 1 item with correct parameters");
1791
    is($items_that_can_fill3->next->id, $item3->id, "Koha::Holds->get_items_that_can_fill returns item with undefined datearrived and defined datecancelled");
1792
    is($items_that_can_fill3->next->id, $item3->id, "Koha::Holds->get_items_that_can_fill returns item with undefined datearrived and defined datecancelled");
1793
    is($items_that_can_fill3->count, 1, "Koha::Holds->get_items_that_can_fill returns 1 item with correct parameters");
1792
    is($items_that_can_fill4->next, undef, "Koha::Holds->get_items_that_can_fill doesn't return item with undefined datearrived and undefined datecancelled");
1794
    is($items_that_can_fill4->next, undef, "Koha::Holds->get_items_that_can_fill doesn't return item with undefined datearrived and undefined datecancelled");
1795
    is($items_that_can_fill4->count, 0, "Koha::Holds->get_items_that_can_fill returns 0 item");
1793
}
1796
}
1794
- 

Return to bug 30447