Summary: | t/db_dependent/api/v1/holds.t failing after bug 26988 | ||
---|---|---|---|
Product: | Koha | Reporter: | Andrew Fuerste-Henry <andrew> |
Component: | Hold requests | Assignee: | Bugs List <koha-bugs> |
Status: | CLOSED INVALID | QA Contact: | Jonathan Druart <jonathan.druart> |
Severity: | major | ||
Priority: | P5 - low | CC: | gmcharlt, jonathan.druart, victor |
Version: | 20.05 | ||
Hardware: | All | ||
OS: | All | ||
GIT URL: | Change sponsored?: | --- | |
Patch complexity: | Trivial patch | Documentation contact: | |
Documentation submission: | Text to go in the release notes: | ||
Version(s) released in: | Circulation function: | ||
Bug Depends on: | 26988 | ||
Bug Blocks: | |||
Attachments: |
Bug 27177: Fix failing t/db_dependent/api/v1/holds.t
Bug 27177: Fix failing t/db_dependent/api/v1/holds.t |
Description
Andrew Fuerste-Henry
2020-12-09 12:52:12 UTC
Created attachment 114277 [details] [review] Bug 27177: Fix failing t/db_dependent/api/v1/holds.t To test: 1 - prove t/db_dependent/api/v1/holds.t 2 - it fails! 3 - apply patch, restart 4- prove t/db_dependent/api/v1/holds.t 5 - it passes! Created attachment 114285 [details] [review] Bug 27177: Fix failing t/db_dependent/api/v1/holds.t To test: 1 - prove t/db_dependent/api/v1/holds.t 2 - it fails! 3 - apply patch, restart 4- prove t/db_dependent/api/v1/holds.t 5 - it passes! Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net> It works :) @QA: the script passes I haven't been digging very deep, but this patch is wrong: 416 return try { 417 my @pickup_locations = 418 $hold->itemnumber 419 ? @{ $hold->item->pickup_locations( { patron => $hold->patron } )->as_list() } 420 : @{ $hold->biblio->pickup_locations( { patron => $hold->patron } )->as_list() }; vs 216 sub pickup_locations { ... 231 return \@pickup_locations; So you are calling ->as_list on an arrayref (I bet this is not tested in the tests are you trying to fix). As said in the previous comment, look at bug 27002 instead. Thanks, Jonathan. Closing this and pushing 27002 to 20.05 instead. |