From a124f93b20353b8dd769e8ff18c58d445222c903 Mon Sep 17 00:00:00 2001 From: Pau Perez Date: Wed, 13 Jan 2021 17:33:50 +0100 Subject: [PATCH] Remove old commented out code --- spec/serializers/api/order_serializer_spec.rb | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/spec/serializers/api/order_serializer_spec.rb b/spec/serializers/api/order_serializer_spec.rb index 9b32b754e4..bc1115fc90 100644 --- a/spec/serializers/api/order_serializer_spec.rb +++ b/spec/serializers/api/order_serializer_spec.rb @@ -14,7 +14,6 @@ describe Api::OrderSerializer do end it "convert the state attributes to translatable keys" do - # byebug if serializer.to_json =~ /balance_due/ expect(serializer.to_json).to match "complete" expect(serializer.to_json).to match "balance_due" end @@ -42,10 +41,12 @@ describe Api::OrderSerializer do before do allow(OpenFoodNetwork::FeatureToggle) .to receive(:enabled?).with(:customer_balance, order.user) { false } + + allow(order).to receive(:outstanding_balance).and_return(123.0) end it 'calls #outstanding_balance on the object' do - expect(serializer.serializable_hash[:outstanding_balance]).to eq(1.0) + expect(serializer.serializable_hash[:outstanding_balance]).to eq(123.0) end end end