[Koha-bugs] [Bug 26814] Add onsite_checkout to circulation rules
bugzilla-daemon at bugs.koha-community.org
bugzilla-daemon at bugs.koha-community.org
Wed Dec 16 00:31:40 CET 2020
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26814
Lari Taskula <lari.taskula at hypernova.fi> changed:
What |Removed |Added
----------------------------------------------------------------------------
Attachment #112380|0 |1
is obsolete| |
--- Comment #33 from Lari Taskula <lari.taskula at hypernova.fi> ---
Created attachment 114421
-->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=114421&action=edit
Bug 26814: Add onsite_checkout to set_rule
To test:
1. Find all occurrences of set_rule that are missing onsite_checkout
where required
grep --exclude-dir '.git' --exclude-dir 'misc/translator' \
--exclude-dir 'koha-tmpl' -Przo '(?s)(::|->)set_rule(?!s).*?\)' | \
grep -avz 'onsite_checkout' | grep -Pavz
'hold|reserves|article_requests|lostreturn' \
&& echo ""
The only occasions this should return anything are cases where
a HASH or HASHref is given to set_rule(), or that we are
explicitly testing missing parameters in an unit test.
1.2 Verify the HASH/HASHref cases. The hash should contain
a onsite_checkout (unless the rule is related to holds)
2. Find all subroutines using set_rule()
git grep --no-index -n -p -P 'set_rule\s*\(' | grep -v 'sub {' \
| grep -P 'sub .*'
2.1 The only return should be
Koha/CirculationRules.pm=331=sub set_rules {
3. The boring step. Find all occurrences of set_rule() with
the following command:
grep --exclude-dir='.git' -Prn 'set_rule' | grep -v set_rules
Go through this list and make sure all neccessary locations are
updated. A change is required when the rule scope includes
onsite_checkout. See Koha/CirculationRules.pm for scopes.
Hold/reserve related rules do not require it.
4. Check changes to CirculationRule objects built with TestBuilder
cd t && grep -Prn "CirculationRules?'"
Make sure all these cases are updated with onsite_checkout => undef,
otherwise tests will fail later on.
Sponsored-by: The National Library of Finland
--
You are receiving this mail because:
You are watching all bug changes.
More information about the Koha-bugs
mailing list