Lines 1705-1717
subtest 'ModReserve can only update expirationdate for found holds' => sub {
Link Here
|
1705 |
|
1705 |
|
1706 |
}; |
1706 |
}; |
1707 |
|
1707 |
|
1708 |
<<<<<<< HEAD |
|
|
1709 |
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 { |
1710 |
plan tests => 8; |
1709 |
plan tests => 8; |
1711 |
======= |
|
|
1712 |
subtest 'Koha::Holds->get_items_that_can_fill returns items with datecancelled and datearrived' => sub { |
1713 |
plan tests => 4; |
1714 |
>>>>>>> Added test to ensure that Koha::Holds->get_items_that_can_fill returns items with datecancelled and datearrived |
1715 |
# biblio item with date arrived and date cancelled |
1710 |
# biblio item with date arrived and date cancelled |
1716 |
my $biblio1 = $builder->build_sample_biblio(); |
1711 |
my $biblio1 = $builder->build_sample_biblio(); |
1717 |
my $item1 = $builder->build_sample_item({ biblionumber => $biblio1->biblionumber }); |
1712 |
my $item1 = $builder->build_sample_item({ biblionumber => $biblio1->biblionumber }); |
Lines 1790-1796
subtest 'Koha::Holds->get_items_that_can_fill returns items with datecancelled a
Link Here
|
1790 |
my $items_that_can_fill3 = $holds3->get_items_that_can_fill; |
1785 |
my $items_that_can_fill3 = $holds3->get_items_that_can_fill; |
1791 |
my $items_that_can_fill4 = $holds4->get_items_that_can_fill; |
1786 |
my $items_that_can_fill4 = $holds4->get_items_that_can_fill; |
1792 |
|
1787 |
|
1793 |
<<<<<<< HEAD |
|
|
1794 |
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"); |
1795 |
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"); |
1796 |
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"); |
Lines 1799-1817
subtest 'Koha::Holds->get_items_that_can_fill returns items with datecancelled a
Link Here
|
1799 |
is($items_that_can_fill3->count, 1, "Koha::Holds->get_items_that_can_fill returns 1 item with correct parameters"); |
1793 |
is($items_that_can_fill3->count, 1, "Koha::Holds->get_items_that_can_fill returns 1 item with correct parameters"); |
1800 |
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"); |
1801 |
is($items_that_can_fill4->count, 0, "Koha::Holds->get_items_that_can_fill returns 0 item"); |
1795 |
is($items_that_can_fill4->count, 0, "Koha::Holds->get_items_that_can_fill returns 0 item"); |
1802 |
======= |
|
|
1803 |
# get the item number that will be compared to with the items that are called which get_items_that_can_fill returns |
1804 |
my %item_unblessed1 = $item1->unblessed; |
1805 |
# used for first test case |
1806 |
|
1807 |
my %items_that_can_fill_unblessed1 = $items_that_can_fill1->unblessed; |
1808 |
my %items_that_can_fill_unblessed2 = $items_that_can_fill2->unblessed; |
1809 |
my %items_that_can_fill_unblessed3 = $items_that_can_fill3->unblessed; |
1810 |
my %items_that_can_fill_unblessed4 = $items_that_can_fill4->unblessed; |
1811 |
|
1812 |
is($items_that_can_fill_unblessed1{"itemnumber"}, $item_unblessed1{"itemnumber"}, "Koha::Holds->get_items_that_can_fill returns item with defined datearrived and datecancelled"); |
1813 |
is($items_that_can_fill_unblessed2{"itemnumber"}, undef, "Koha::Holds->get_items_that_can_fill doesn't return item with defined datearrived and undefined datecancelled"); |
1814 |
is($items_that_can_fill_unblessed3{"itemnumber"}, undef, "Koha::Holds->get_items_that_can_fill doesn't return item with undefined datearrived and defined datecancelled"); |
1815 |
is($items_that_can_fill_unblessed3{"itemnumber"}, undef, "Koha::Holds->get_items_that_can_fill doesn't return item with undefined datearrived and undefined datecancelled"); |
1816 |
>>>>>>> Added test to ensure that Koha::Holds->get_items_that_can_fill returns items with datecancelled and datearrived |
1817 |
} |
1796 |
} |
1818 |
- |
|
|