Bugzilla – Attachment 104451 Details for
Bug 25325
ElasticSearch mapping export lacks staff_client/opac fields
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 25325: Test ES lack of staff_client/opac fields
Bug-25325-Test-ES-lack-of-staffclientopac-fields.patch (text/plain), 1.83 KB, created by
Victor Grousset/tuxayo
on 2020-05-06 18:44:43 UTC
(
hide
)
Description:
Bug 25325: Test ES lack of staff_client/opac fields
Filename:
MIME Type:
Creator:
Victor Grousset/tuxayo
Created:
2020-05-06 18:44:43 UTC
Size:
1.83 KB
patch
obsolete
>From bb6f50e473734b725e3ed8ae0f84c55401b9291a Mon Sep 17 00:00:00 2001 >From: =?UTF-8?q?Fr=C3=A9d=C3=A9ric=20Demians?= <f.demians@tamil.fr> >Date: Tue, 5 May 2020 19:19:26 +0200 >Subject: [PATCH] Bug 25325: Test ES lack of staff_client/opac fields > >Run this test to see that export_elasticsearch_mappings.pl doesn't export >staff_client/opac fields. > >Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net> >--- > .../Koha/SearchEngine/Elasticsearch/ExportConfig.t | 9 ++++++--- > 1 file changed, 6 insertions(+), 3 deletions(-) > >diff --git a/t/db_dependent/Koha/SearchEngine/Elasticsearch/ExportConfig.t b/t/db_dependent/Koha/SearchEngine/Elasticsearch/ExportConfig.t >index b065b92dfe..82dc5537f6 100644 >--- a/t/db_dependent/Koha/SearchEngine/Elasticsearch/ExportConfig.t >+++ b/t/db_dependent/Koha/SearchEngine/Elasticsearch/ExportConfig.t >@@ -17,7 +17,7 @@ > > use Modern::Perl; > >-use Test::More tests => 16; >+use Test::More tests => 18; > > use Koha::Database; > use Koha::SearchFields; >@@ -40,8 +40,9 @@ my $search_field = Koha::SearchFields->find_or_create( > name => 'title', > label => 'Title', > type => 'string', >- weight => 17 >- >+ weight => 17, >+ staff_client => 0, >+ opac => 1, > }, > { key => 'name' } ); > >@@ -92,6 +93,8 @@ my $mappings = Koha::SearchEngine::Elasticsearch::raw_elasticsearch_mappings(); > is( $mappings->{biblios}{title}{type}, 'string', 'Title is of type string'); > is( $mappings->{biblios}{title}{label}, 'Title', 'title has label Title'); > is( $mappings->{biblios}{title}{facet_order}, undef, 'Facet order is undef'); >+is( $mappings->{biblios}{title}{opac}, 1, 'title is opac searchable'); >+is( $mappings->{biblios}{title}{staff_client}, 0, 'title is not staff searchable'); > > is(scalar(@{ $mappings->{biblios}{title}{mappings} }), 3, 'Title has 3 mappings'); > >-- >2.26.2
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 25325
:
104004
|
104063
|
104376
|
104377
|
104451
|
104452
|
104482
|
104483