]> git.koha-community.org Git - koha.git/commit
Bug 12738: C4::Context should set 'keyword' as the default search class
authorTomas Cohen Arazi <tomascohen@gmail.com>
Fri, 8 Aug 2014 15:01:36 +0000 (12:01 -0300)
committerTomas Cohen Arazi <tomascohen@gmail.com>
Mon, 11 Aug 2014 13:06:07 +0000 (10:06 -0300)
commit80a1225bb732fb957af483cfa64face8631165bf
treeb0723919a710465c3582ebdcff48f650fa59f2ca
parentad0d975eda9408fbb4342fb0753f4dd40d9c63f0
Bug 12738: C4::Context should set 'keyword' as the default search class

On a Perl 5.18 environment (e.g. Ubuntu 14.04 LTS):

To reproduce:
- Have UseQueryParser == "Don't try"
- Perform a search typing just a word that would have many matches on your Zebra db.
- Take note of the search results count.
- Make sure you have the queryparser.yaml file in your config dir.
- Set UseQueryParser == "Try"
- Perform the same search a couple of times
=> FAIL: Notice that the search results count differs from one run to the other.
- Run the regression tests
  $ prove -v t/db_dependent/QueryParser.t
=> FAIL: tests fail

To test:
- Apply the patch
- Run tests
  $ prove -v t/db_dependent/QueryParser.t
=> SUCCESS: tests pass
- Repeat the steps 'To reproduce'
=> SUCCESS: Search results count is deterministic :-D
- Sign off :-D

Sponsored-by: Universidad Nacional de Cordoba
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Now search with QueryParser always returns the correct number of
results on a system with the newer Perl version.
Passes all tests and QA script.

Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
C4/Context.pm