Testing of filtering during search by books.filter.name

This commit is contained in:
Veloman Yunkan 2024-03-05 16:42:14 +04:00 committed by Matthieu Gautier
parent d8b4c1584c
commit 6ef4f6396e
1 changed files with 30 additions and 0 deletions

View File

@ -1409,6 +1409,36 @@ TEST(ServerSearchTest, searchResults)
/* pagination */ {} /* pagination */ {}
}, },
// books.filter.name filters by the book name
{
/* query */ "pattern=travel"
"&books.filter.name=wikipedia_en_ray_charles",
/* start */ 0,
/* resultsPerPage */ 10,
/* totalResultCount */ 1,
/* firstResultIndex */ 1,
/* results */ {
SEARCH_RESULT_FOR_TRAVEL_IN_RAYCHARLESZIM
},
/* pagination */ {}
},
// books.filter.name filters by the book name
{
/* query */ "pattern=travel"
"&books.filter.name=bookname_of_example_zim",
/* start */ 0,
/* resultsPerPage */ 10,
/* totalResultCount */ 1,
/* firstResultIndex */ 1,
/* results */ {
SEARCH_RESULT_FOR_TRAVEL_IN_EXAMPLEZIM
},
/* pagination */ {}
},
// Adding a book (without match) doesn't change the results // Adding a book (without match) doesn't change the results
{ {
/* query */ "pattern=jazz" /* query */ "pattern=jazz"