Refactor query parameter deserialisation logic

This commit is contained in:
Loïc Lecrenier
2023-01-16 16:59:26 +01:00
parent 49ddaaef49
commit 9194508a0f
26 changed files with 1377 additions and 1180 deletions

View File

@ -295,7 +295,7 @@ async fn search_bad_show_matches_position() {
snapshot!(code, @"400 Bad Request");
snapshot!(json_string!(response), @r###"
{
"message": "Invalid value in parameter `showMatchesPosition`: provided string was not `true` or `false`",
"message": "Invalid value in parameter `showMatchesPosition`: could not parse `doggo` as a boolean, expected either `true` or `false`",
"code": "invalid_search_show_matches_position",
"type": "invalid_request",
"link": "https://docs.meilisearch.com/errors#invalid-search-show-matches-position"

View File

@ -43,7 +43,7 @@ async fn task_bad_uids() {
snapshot!(code, @"400 Bad Request");
snapshot!(json_string!(response), @r###"
{
"message": "Invalid value in parameter `uids`: could not parse `dogo` as a positive integer",
"message": "Invalid value in parameter `uids[1]`: could not parse `dogo` as a positive integer",
"code": "invalid_task_uids",
"type": "invalid_request",
"link": "https://docs.meilisearch.com/errors#invalid-task-uids"