Bug 24446: (follow-up) Fix tests

The tests were failing because we weren't actually changing the item, so store was doing nothing.

We need to transfer 'from' a new branch so that the holdingbranch is changed

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
This commit is contained in:
Nick Clemens 2021-04-23 15:22:44 +00:00 committed by Jonathan Druart
parent 7ec4820a65
commit b9d14bc5a0

View file

@ -198,10 +198,10 @@ subtest 'Test indexer calls' => sub {
} undef, "index_records is not called for $engine when calling ModDateLastSeen if skip_record_index"; } undef, "index_records is not called for $engine when calling ModDateLastSeen if skip_record_index";
warnings_are{ warnings_are{
ModItemTransfer( $item->itemnumber, $item->homebranch, $item2->homebranch,'Manual'); ModItemTransfer( $item->itemnumber, $item2->homebranch, $item->homebranch,'Manual');
} [$engine,"Koha::Item"], "index_records is called for $engine when calling ModItemTransfer"; } [$engine,"Koha::Item"], "index_records is called for $engine when calling ModItemTransfer";
warnings_are{ warnings_are{
ModItemTransfer( $item->itemnumber, $item2->homebranch, $item->homebranch,'Manual',{skip_record_index=>1}); ModItemTransfer( $item->itemnumber, $item->homebranch, $item2->homebranch,'Manual',{skip_record_index=>1});
} undef, "index_records is not called for $engine when calling ModItemTransfer with skip_record_index"; } undef, "index_records is not called for $engine when calling ModItemTransfer with skip_record_index";
warnings_are{ warnings_are{