Bugzilla – Attachment 137171 Details for
Bug 29418
Error searching for analytics in detail view
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 29418: Unit tests
Bug-29418-Unit-tests.patch (text/plain), 1.46 KB, created by
Martin Renvoize (ashimema)
on 2022-07-05 13:50:48 UTC
(
hide
)
Description:
Bug 29418: Unit tests
Filename:
MIME Type:
Creator:
Martin Renvoize (ashimema)
Created:
2022-07-05 13:50:48 UTC
Size:
1.46 KB
patch
obsolete
>From a76f82a621b61788d937b24e5829e224ac3d7d49 Mon Sep 17 00:00:00 2001 >From: Tomas Cohen Arazi <tomascohen@theke.io> >Date: Mon, 4 Jul 2022 15:18:44 -0300 >Subject: [PATCH] Bug 29418: Unit tests > >Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> >Signed-off-by: David Nind <david@davidnind.com> >Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> >--- > t/Koha/SearchEngine/Zebra/QueryBuilder.t | 16 +++++++++++++++- > 1 file changed, 15 insertions(+), 1 deletion(-) > >diff --git a/t/Koha/SearchEngine/Zebra/QueryBuilder.t b/t/Koha/SearchEngine/Zebra/QueryBuilder.t >index 809eb3a524..6dca03263d 100755 >--- a/t/Koha/SearchEngine/Zebra/QueryBuilder.t >+++ b/t/Koha/SearchEngine/Zebra/QueryBuilder.t >@@ -17,7 +17,7 @@ > > use Modern::Perl; > >-use Test::More tests => 3; >+use Test::More tests => 4; > use Test::MockModule; > > use_ok('Koha::SearchEngine::Zebra::QueryBuilder'); >@@ -76,3 +76,17 @@ subtest 'build_query_compat() tests' => sub { > ( undef, $query ) = $qb->build_query_compat( undef, undef, undef, undef, undef, undef, undef, { suppress => 0 } ); > is( $query, 'query', 'Suppress part of the query not added (PQF)'); > }; >+ >+subtest 'clean_search_term() tests' => sub { >+ >+ plan tests => 2; >+ >+ my $qb; >+ ok( >+ $qb = Koha::SearchEngine::Zebra::QueryBuilder->new(), >+ 'Creating a new QueryBuilder object' >+ ); >+ >+ my $res = $qb->clean_search_term('test "query":'); >+ is($res, 'test \"query\":', 'Double-quotes are escaped'); >+}; >-- >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 29418
:
127325
|
127326
|
134865
|
134866
|
137023
|
137048
|
137135
|
137136
|
137137
|
137138
|
137139
|
137140
|
137142
| 137171 |
137172
|
137173
|
137174