From b297299838bc5acbf083a5500b4a6ca73604eafb Mon Sep 17 00:00:00 2001 From: Maikel Linke Date: Thu, 11 Aug 2022 16:35:43 +1000 Subject: [PATCH] Simplify test of adjustments --- spec/helpers/checkout_helper_spec.rb | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/spec/helpers/checkout_helper_spec.rb b/spec/helpers/checkout_helper_spec.rb index 55d17ef7e9..cdb9918141 100644 --- a/spec/helpers/checkout_helper_spec.rb +++ b/spec/helpers/checkout_helper_spec.rb @@ -145,11 +145,8 @@ describe CheckoutHelper, type: :helper do adjustments = helper.checkout_adjustments_for(order) shipping_adjustment = order.shipment_adjustments.first - expect(adjustments).to include shipping_adjustment - admin_fee_summary = adjustments.reject { |a| a.id == shipping_adjustment.id }.first - expect(admin_fee_summary.label).to eq "Enterprise Fee" - expect(admin_fee_summary.amount).to eq 123 + expect(adjustments).to match_array [shipping_adjustment, fee_adjustment] end context "tax rate adjustments" do