Created attachment 137851 [details] [review] Bug 31183: Unit tests Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Created attachment 137852 [details] [review] Bug 31183: Add Koha::Item::Transfers->filter_by_current This patch introduces the aforementioned method. To test: 1. Apply this unit tests patch 2. Run: $ kshell k$ prove t/db_dependent/Koha/Item/Transfers.t => FaIL: method not defined? 3. Apply this patch 4. Repeat 2 => SUCCESS: Tests pass! 5. Sign off :-D Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Created attachment 137853 [details] [review] Bug 31183: Use filter_by_current in Koha::Holds->get_items_that_can_fill This patch makes the method use the new Koha::Item::Transfers->filter_by_current one. To test: 1. Run: $ kshell k$ prove t/db_dependent/Koha/Holds.t => SUCCESS: Tests pass 2. Apply this patch 3. Repeat 1 => SUCCESS: Tests still pass 4. Sign off :-D Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Created attachment 137944 [details] [review] Bug 31183: Unit tests Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Created attachment 137945 [details] [review] Bug 31183: Add Koha::Item::Transfers->filter_by_current This patch introduces the aforementioned method. To test: 1. Apply this unit tests patch 2. Run: $ kshell k$ prove t/db_dependent/Koha/Item/Transfers.t => FaIL: method not defined? 3. Apply this patch 4. Repeat 2 => SUCCESS: Tests pass! 5. Sign off :-D Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Created attachment 137946 [details] [review] Bug 31183: Use filter_by_current in Koha::Holds->get_items_that_can_fill This patch makes the method use the new Koha::Item::Transfers->filter_by_current one. To test: 1. Run: $ kshell k$ prove t/db_dependent/Koha/Holds.t => SUCCESS: Tests pass 2. Apply this patch 3. Repeat 1 => SUCCESS: Tests still pass 4. Sign off :-D Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> Signed-off-by: Michal Urban <michalurban177@gmail.com>
Created attachment 138887 [details] [review] Bug 31183: Unit tests Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Created attachment 138888 [details] [review] Bug 31183: Add Koha::Item::Transfers->filter_by_current This patch introduces the aforementioned method. To test: 1. Apply this unit tests patch 2. Run: $ kshell k$ prove t/db_dependent/Koha/Item/Transfers.t => FaIL: method not defined? 3. Apply this patch 4. Repeat 2 => SUCCESS: Tests pass! 5. Sign off :-D Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Created attachment 138889 [details] [review] Bug 31183: Use filter_by_current in Koha::Holds->get_items_that_can_fill This patch makes the method use the new Koha::Item::Transfers->filter_by_current one. To test: 1. Run: $ kshell k$ prove t/db_dependent/Koha/Holds.t => SUCCESS: Tests pass 2. Apply this patch 3. Repeat 1 => SUCCESS: Tests still pass 4. Sign off :-D Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> Signed-off-by: Michal Urban <michalurban177@gmail.com> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Shouldn't we use it from Koha::Item->get_transfers as well?
(In reply to Jonathan Druart from comment #10) > Shouldn't we use it from Koha::Item->get_transfers as well? Yes! I forgot!
Pushed to master for 22.11. Nice work everyone, thanks!
Enhancement will not be backported to 22.05.x series unless requested