From 0167357f8fcd595d4e2d206607bf3cafaa6c5e98 Mon Sep 17 00:00:00 2001 From: Gaetan Craig-Riou Date: Tue, 21 May 2024 13:55:09 +1000 Subject: [PATCH] Fic enterprise fee summary report system spec --- ...ry_fee_with_tax_report_by_producer_spec.rb | 19 ++++--------------- 1 file changed, 4 insertions(+), 15 deletions(-) diff --git a/spec/system/admin/reports/enterprise_summary_fees/enterprise_summary_fee_with_tax_report_by_producer_spec.rb b/spec/system/admin/reports/enterprise_summary_fees/enterprise_summary_fee_with_tax_report_by_producer_spec.rb index 3d16397453..002e0a7247 100644 --- a/spec/system/admin/reports/enterprise_summary_fees/enterprise_summary_fee_with_tax_report_by_producer_spec.rb +++ b/spec/system/admin/reports/enterprise_summary_fees/enterprise_summary_fee_with_tax_report_by_producer_spec.rb @@ -43,10 +43,10 @@ RSpec.describe "Enterprise Summary Fee with Tax Report By Producer" do create(:supplier_enterprise, name: 'Supplier2', charges_sales_tax: true, owner_id: supplier2_owner.id) } - let!(:product){ create(:simple_product, supplier: ) } - let!(:product2){ create(:simple_product, supplier: supplier2 ) } - let!(:variant){ create(:variant, product_id: product.id, tax_category:) } - let!(:variant2){ create(:variant, product_id: product2.id, tax_category:) } + let!(:product){ create(:simple_product) } + let!(:product2){ create(:simple_product) } + let!(:variant){ create(:variant, product_id: product.id, tax_category:, supplier:) } + let!(:variant2){ create(:variant, product_id: product2.id, tax_category:, supplier: supplier2) } let!(:distributor_owner) { create(:user, enterprise_limit: 1) } let!(:distributor){ distributor = create(:distributor_enterprise_with_tax, name: 'Distributor', @@ -169,17 +169,6 @@ RSpec.describe "Enterprise Summary Fee with Tax Report By Producer" do order2 } - before do - product.update!({ - tax_category_id: tax_category.id, - supplier_id: supplier.id - }) - product2.update!({ - tax_category_id: tax_category.id, - supplier_id: supplier2.id - }) - end - context 'added tax' do # 1 order cycle has: # - coordinator fees (20) 1.5% = 0.30, 2.5% = 0.50