From ceadd386aaf9de1f7970f8cd94b4056b24aee1e6 Mon Sep 17 00:00:00 2001 From: Rob Harrington Date: Wed, 18 Oct 2017 17:23:42 +1100 Subject: [PATCH] Update order spec to test an order with a total > 0 This is necessary because the previous commit changed the logic around payment state, meaning that a complete order with a total of 0 and no complete paymnents is considered to have a payment state of 'paid'. I don't think this is problematic, since it is not possible to check out an order without line items. This way the spec tests an order modelled on the real world. --- spec/models/spree/order_spec.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/spec/models/spree/order_spec.rb b/spec/models/spree/order_spec.rb index 7b1f464dc8..c27acfe588 100644 --- a/spec/models/spree/order_spec.rb +++ b/spec/models/spree/order_spec.rb @@ -181,7 +181,7 @@ describe Spree::Order do end describe "an unpaid order with a shipment" do - let(:order) { create(:order, shipping_method: shipping_method) } + let(:order) { create(:order_with_totals, shipping_method: shipping_method) } let(:shipping_method) { create(:shipping_method) } before do