Koha-clms/t
Nick Clemens ae937750a9
Bug 39079: Follow 'and_or' variable when passed to build_auth_query_compat
When building queries for matchign Zebra uses OR to combine searches - Elasticsearch
has been effectively using 'AND' - this patch checks whether and_or has been passed
and follows the variable when present.

To test:
1 - Have an import file of auths with multiple 035
2 - Setup an authority matching rule
    Search index: other-control-number
    Score: 1000
    Tag: 035
    Subfields: a
3 - Make sure Koha is using Elasticsearch
4 - Stage file without matching, import file
5 - Stage file again, using your matching rule
6 - Note all records match
7 - Setup Cataloging->Marc modification template
8 - Add an action to delete first 035 field
9 - Run it against the records you just imported
    You can use a report:
    SELECT authid FROM auth_header WHERE authid > #### (find the lowest new record number in batch you imported)
10 - Change matching rule in batch to none, then back to your rule
11 - No matches!
12 - Apply patch, restart all
13 - Set matchign rule to none, then back to your rule
14 - Matches!

Signed-off-by: Magnus Enger <magnus@libriotech.no>
Works as advertised!
Signed-off-by: Martin Renvoize <martin.renvoize@openfifth.co.uk>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2025-10-03 14:35:53 +02:00
..
Acquisition
…
Biblio
…
Budgets
…
Circulation Bug 37155: Refactor GetAgeRestrictions 2024-07-01 18:55:50 +02:00
External
…
Koha Bug 38488: Add Template::Toolkit filter for C4::Scrubber 2025-02-18 19:17:20 +01:00
Number Bug 37511: Unit tests 2024-10-30 11:57:27 +01:00
SIP Bug 37816: (QA follow-up) Avoid repetition, typo and pipe test 2025-02-18 19:17:20 +01:00
Search Bug 34969: Remove unneeded module from buildQuery.t 2023-10-04 09:15:42 -04:00
Serials Bug 32392: Tests for changes in C4::Serials::GetNextSeq 2024-04-29 15:19:30 +02:00
Template Bug 33030: Add unit tests 2023-07-14 16:52:06 -03:00
Test Bug 40404: Remove diag from t/Test/Mock/Logger.t 2025-08-01 15:22:48 +02:00
cypress Bug 40121: Fix 'Cannot read properties of undefined' 2025-09-19 15:29:38 +02:00
data Bug 31393: Koha::Config: handle the special case for 'content' attribute 2023-10-30 09:02:17 -03:00
db_dependent Bug 39079: Follow 'and_or' variable when passed to build_auth_query_compat 2025-10-03 14:35:53 +02:00
edi_testfiles Bug 38423: Add unit tests 2025-04-17 14:30:35 +02:00
etc
…
lib Bug 36433: UT 2025-08-04 12:26:59 +02:00
mock_templates/intranet-tmpl/prog Bug 36640: Remove jEditable 2024-11-14 14:19:37 +01:00
00-check-atomic-updates.t Bug 31479: Option to skip t/00-check-atomic-updates.t when building custom packages 2023-05-10 15:26:20 -03:00
00-deprecated.t
…
00-load.t
…
00-merge-conflict-markers.t
…
00-testcritic.t Bug 34911: Test files from HEAD instead of 'master' 2023-10-04 09:15:35 -04:00
00-valid-xml.t
…
Auth.t
…
AuthoritiesMarc_MARC21.t Bug 31023: Unit tests 2022-09-07 13:52:35 -07:00
AuthoritiesMarc_UNIMARC.t
…
Barcodes_EAN13.t
…
Barcodes_annual.t
…
Barcodes_hbyymmincr.t
…
Barcodes_incremental.t
…
Biblio.t Bug 37380: Replace uses of GetMarcControlnumber for get_control_number() 2024-09-16 10:41:05 +02:00
Biblio2.t
…
Budgets.t
…
Charset.t
…
Circulation_barcodedecode.t Bug 30409: (QA follow-up) Avoid uninitialized variable warnings 2022-06-14 08:26:58 -03:00
ClassSortRoutine.t
…
ClassSortRoutine_Dewey.t
…
ClassSortRoutine_Generic.t
…
ClassSortRoutine_LCC.t
…
ClassSource.t
…
Context.t Bug 36081: Use multivalue_preference 2025-02-24 20:43:20 +01:00
Contract.t
…
CookieManager.t Bug 31250: (QA follow-up) The future will be easier 2022-09-12 15:34:11 -03:00
Creators.t
…
DateUtils.t Bug 36432: Remove circular dependency from Koha::Object 2024-04-04 15:24:32 +02:00
EdiInvoice.t
…
Edifact.t Bug 35398: Add unit test for extraction of library_rotation_plan 2024-03-07 15:02:46 +01:00
Ediorder.t Bug 31134: Mock EdifactLSQ for t/Edifact.t 2022-07-18 10:20:44 -03:00
Ediordrsp.t
…
Form_MessagingPreferences.t Bug 34776: Add unit tests for sub restore_form_values 2025-07-28 10:22:07 +02:00
HtmlTags.t
…
ImportBatch.t Bug 18772: Remove warnings from t/ImportBatch.t 2025-08-01 15:50:08 +02:00
Installer_PerlModules.t Bug 30731: Unit tests 2022-06-01 16:15:25 -03:00
ItemCirculationAlertPreference.t
…
Koha_MetadataRecord.t Bug 33749: Use TrimFields instead of stripWhitespaceChars 2023-11-03 12:08:06 -03:00
Koha_SearchEngine_Elasticsearch_Browse.t
…
Koha_Template_Plugin_HtmlId.t
…
Koha_Template_Plugin_Koha.t Bug 31401: (QA follow-up) Remove Koha.ArePluginsEnabled, it is no longer needed 2022-09-07 13:55:37 -07:00
Koha_Util_FrameworkPlugin.t
…
Koha_Util_MARC.t
…
Koha_XSLT_HTTPS.t Bug 12758: Introduce Koha::XSLT::HTTPS 2022-11-09 09:52:17 -03:00
Labels.t Bug 40388: Remove warning from t/Labels.t 2025-08-01 14:29:57 +02:00
Labels_split_Regex.t
…
Labels_split_ccn.t Bug 30110: Fix concatenation during assignements 2022-03-24 14:22:10 -10:00
Labels_split_ddcn.t Bug 30110: Fix concatenation during assignements 2022-03-24 14:22:10 -10:00
Labels_split_lccn.t Bug 30110: Fix concatenation during assignements 2022-03-24 14:22:10 -10:00
Languages.t Bug 38630: (QA follow-up) Two typos 2025-09-29 09:34:51 +02:00
Logger.t Bug 35907: Add ability to log all custom report runs with or without query 2024-05-10 16:45:45 +02:00
Makefile.t Bug 39304: Make sure git commands return something 2025-06-19 12:27:18 +02:00
Members_Messaging.t
…
OpenLibrarySearch.t
…
Output.t Bug 30524: Unit tests 2023-08-07 20:59:59 -03:00
Output_JSONStream.t
…
Patroncards.t
…
Patroncards_Batch.t
…
Patroncards_Lib.t
…
Patroncards_Patroncard.t
…
Patroncards_Profile.t
…
Patroncards_Template.t
…
RecordProcessor.t Bug 40128: Unit tests 2025-07-31 16:18:10 +02:00
Ris.t
…
SMS.t Bug 36307: SMS::Send driver errors are not captured and stored 2024-04-05 17:39:46 +02:00
Scheduler.t
…
Scrubber.t Bug 40079: (follow-up) Improve test coverage and fix undef handling 2025-07-25 16:49:49 +02:00
Search.t Bug 34968: Remove unneeded module from Search.t 2023-10-04 09:32:46 -04:00
Search_PazPar2.t
…
SimpleMARC.t Bug 36515: (QA follow-up) Tidy code 2024-08-02 19:00:05 +02:00
SuggestionEngine.t
…
SuggestionEngine_AuthorityFile.t Bug 34970: Remove most modules from SuggestionEngine_AuthorityFile.t 2023-10-04 09:15:41 -04:00
TmplToken.t
…
Token.t Bug 36367: Fix test t/Token.t 2024-06-14 11:17:19 +01:00
template_filters.t Bug 38872: Add a test 2025-04-22 23:02:08 +02:00
timezones.t
…