Bugzilla – Attachment 117588 Details for
Bug 26057
Add Koha::Item::Transfer->cancel method
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 26057: (QA follow-up) Fix Indexer tests
Bug-26057-QA-follow-up-Fix-Indexer-tests.patch (text/plain), 2.67 KB, created by
Jonathan Druart
on 2021-03-03 14:31:16 UTC
(
hide
)
Description:
Bug 26057: (QA follow-up) Fix Indexer tests
Filename:
MIME Type:
Creator:
Jonathan Druart
Created:
2021-03-03 14:31:16 UTC
Size:
2.67 KB
patch
obsolete
>From 16611244744cf40c5a6d354fe5b8dcddaf9f5f19 Mon Sep 17 00:00:00 2001 >From: Martin Renvoize <martin.renvoize@ptfs-europe.com> >Date: Mon, 22 Feb 2021 12:31:50 +0000 >Subject: [PATCH] Bug 26057: (QA follow-up) Fix Indexer tests > >The addition of cancellationdate meant that our test objects in the >Indexer tests now longer matched expectations and as such the tests >failed. >--- > t/db_dependent/Koha/SearchEngine/Indexer.t | 35 ++++++++++++++-------- > 1 file changed, 23 insertions(+), 12 deletions(-) > >diff --git a/t/db_dependent/Koha/SearchEngine/Indexer.t b/t/db_dependent/Koha/SearchEngine/Indexer.t >index 3e32f4441a..3d8454c234 100755 >--- a/t/db_dependent/Koha/SearchEngine/Indexer.t >+++ b/t/db_dependent/Koha/SearchEngine/Indexer.t >@@ -20,6 +20,7 @@ use C4::Biblio; > use C4::Circulation; > use C4::Items; > use Koha::Database; >+use Koha::DateUtils; > use Koha::SearchEngine::Elasticsearch; > use Koha::SearchEngine::Indexer; > >@@ -158,21 +159,31 @@ subtest 'Test indexer calls' => sub { > AddReturn($item->barcode, $item->homebranch, 0, undef); > } [$engine,'C4::Circulation'], "index_records is called once for $engine when calling AddReturn if item not issued"; > >- $builder->build({ >- source => 'Branchtransfer', >- value => { >- itemnumber => $item->itemnumber, >- datearrived => undef} >- }); >+ $builder->build( >+ { >+ source => 'Branchtransfer', >+ value => { >+ itemnumber => $item->itemnumber, >+ datesent => dt_from_string, >+ datearrived => undef, >+ datecancelled => undef >+ } >+ } >+ ); > warnings_are{ > LostItem( $item->itemnumber, "tests"); > } [$engine,"Koha::Item"], "index_records is called for $engine when calling LostItem and transfer exists"; >- $builder->build({ >- source => 'Branchtransfer', >- value => { >- itemnumber => $item2->itemnumber, >- datearrived => undef} >- }); >+ $builder->build( >+ { >+ source => 'Branchtransfer', >+ value => { >+ itemnumber => $item2->itemnumber, >+ datesent => dt_from_string, >+ datearrived => undef, >+ datecancelled => undef >+ } >+ } >+ ); > warnings_are{ > LostItem( $item->itemnumber, "tests", undef, { skip_record_index => 1 }); > } undef, "index_records is not called for $engine when calling LostItem and transfer exists if skip_record_index"; >-- >2.20.1
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 26057
:
110476
|
110477
|
111279
|
116554
|
116555
|
116556
|
117585
|
117586
|
117587
| 117588 |
117632
|
117633
|
117635