Bugzilla – Attachment 120179 Details for
Bug 28210
C4::Circulation::LostItem should pass through skip_record_index to MarkIssueReturned
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 28210: Unit test
Bug-28210-Unit-test.patch (text/plain), 1.78 KB, created by
Nick Clemens (kidclamp)
on 2021-04-26 15:58:34 UTC
(
hide
)
Description:
Bug 28210: Unit test
Filename:
MIME Type:
Creator:
Nick Clemens (kidclamp)
Created:
2021-04-26 15:58:34 UTC
Size:
1.78 KB
patch
obsolete
>From 7ed6041e41cbfb79b326caadc12ea9ae79aac53e Mon Sep 17 00:00:00 2001 >From: Martin Renvoize <martin.renvoize@ptfs-europe.com> >Date: Fri, 23 Apr 2021 16:52:59 +0100 >Subject: [PATCH] Bug 28210: Unit test > >Add a unit test to check that skip_record_index is adhered to when >passed to LostItem with the force_mark_returned option enabled. > >Signed-off-by: Nick Clemens <nick@bywatersolutions.com> >--- > t/db_dependent/Koha/SearchEngine/Indexer.t | 8 +++++++- > 1 file changed, 7 insertions(+), 1 deletion(-) > >diff --git a/t/db_dependent/Koha/SearchEngine/Indexer.t b/t/db_dependent/Koha/SearchEngine/Indexer.t >index b9ec418e19..8eeb4dc120 100755 >--- a/t/db_dependent/Koha/SearchEngine/Indexer.t >+++ b/t/db_dependent/Koha/SearchEngine/Indexer.t >@@ -61,7 +61,7 @@ subtest 'Test indexer object creation' => sub { > }; > > subtest 'Test indexer calls' => sub { >- plan tests => 36; >+ plan tests => 40; > > my @engines = ('Zebra'); > eval { Koha::SearchEngine::Elasticsearch->get_elasticsearch_params; }; >@@ -158,6 +158,12 @@ subtest 'Test indexer calls' => sub { > warnings_are{ > AddReturn($item->barcode, $item->homebranch, 0, undef); > } [$engine,'C4::Circulation'], "index_records is called once for $engine when calling AddReturn if item not issued"; >+ warnings_are{ >+ LostItem( $item->itemnumber, "tests", 1); >+ } [$engine,"Koha::Item"], "index_records is called for $engine when calling LostItem with 'force_mark_returned'"; >+ warnings_are{ >+ LostItem( $item->itemnumber, "tests", 1, { skip_record_index => 1 }); >+ } undef, "index_records is not called for $engine when calling LostItem with 'force_mark_returned' if skip_record_index"; > > $item->datelastseen('2020-02-02'); > $item->store({skip_record_index=>1}); >-- >2.11.0
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 28210
:
120118
|
120119
| 120179 |
120180
|
120181