mirror of
https://github.com/openfoodfoundation/openfoodnetwork
synced 2026-01-24 20:36:49 +00:00
Add distributor to shipping method in factory completed_order_with_fees so that shipping method is not discarded during order processing in package.shipping_methods
This commit is contained in:
@@ -427,7 +427,7 @@ FactoryBot.define do
|
||||
payment_method = create(:payment_method, calculator: payment_calculator)
|
||||
create(:payment, order: order, amount: order.total, payment_method: payment_method, state: 'checkout')
|
||||
|
||||
create(:shipping_method_with, :shipping_fee, shipping_fee: evaluator.shipping_fee)
|
||||
create(:shipping_method_with, :shipping_fee, shipping_fee: evaluator.shipping_fee, distributors: [order.distributor])
|
||||
|
||||
order.reload
|
||||
while !order.completed? do break unless order.next! end
|
||||
|
||||
Reference in New Issue
Block a user