mirror of
https://github.com/openfoodfoundation/openfoodnetwork
synced 2026-02-27 01:43:22 +00:00
Adds included_in_price trait on broken specs
This commit is contained in:
@@ -424,7 +424,7 @@ describe '
|
||||
end
|
||||
let!(:order) do
|
||||
create(:order_with_taxes, distributor: distributor1, ship_address: create(:address),
|
||||
product_price: 110, tax_rate_amount: 0.1,
|
||||
product_price: 110, tax_rate_amount: 0.1, included_in_price: true,
|
||||
tax_rate_name: "Tax 1").tap do |order|
|
||||
order.create_tax_charge!
|
||||
order.update_shipping_fees!
|
||||
|
||||
@@ -208,8 +208,13 @@ describe '
|
||||
create(:order, order_cycle: order_cycle, distributor: user1.enterprises.first,
|
||||
ship_address: address, bill_address: address)
|
||||
}
|
||||
let(:product1) { create(:taxed_product, zone: zone, price: 12.54, tax_rate_amount: 0) }
|
||||
let(:product2) { create(:taxed_product, zone: zone, price: 500.15, tax_rate_amount: 0.2) }
|
||||
let(:product1) {
|
||||
create(:taxed_product, zone: zone, price: 12.54, tax_rate_amount: 0, included_in_price: true)
|
||||
}
|
||||
let(:product2) {
|
||||
create(:taxed_product, zone: zone, price: 500.15, tax_rate_amount: 0.2,
|
||||
included_in_price: true)
|
||||
}
|
||||
|
||||
let!(:line_item1) {
|
||||
create(:line_item, variant: product1.variants.first, price: 12.54, quantity: 1, order: order1)
|
||||
|
||||
@@ -22,7 +22,7 @@ describe "full-page cart", js: true do
|
||||
create(:enterprise_fee, amount: 11.00, tax_category: product_with_tax.tax_category)
|
||||
}
|
||||
let(:product_with_tax) {
|
||||
create(:taxed_product, supplier: supplier, zone: zone, price: 110.00, tax_rate_amount: 0.1)
|
||||
create(:taxed_product, supplier: supplier, zone: zone, price: 110.00, tax_rate_amount: 0.1, included_in_price: true)
|
||||
}
|
||||
let(:product_with_fee) {
|
||||
create(:simple_product, supplier: supplier, price: 0.86, on_hand: 100)
|
||||
|
||||
@@ -21,7 +21,7 @@ describe "As a consumer I want to check out my cart", js: true do
|
||||
let(:fee_tax_rate) { create(:tax_rate, amount: 0.10, zone: zone, included_in_price: true) }
|
||||
let(:fee_tax_category) { create(:tax_category, tax_rates: [fee_tax_rate]) }
|
||||
let(:product) {
|
||||
create(:taxed_product, supplier: supplier, price: 10, zone: zone, tax_rate_amount: 0.1)
|
||||
create(:taxed_product, supplier: supplier, price: 10, zone: zone, tax_rate_amount: 0.1, included_in_price: true)
|
||||
}
|
||||
let(:variant) { product.variants.first }
|
||||
let(:order) {
|
||||
|
||||
Reference in New Issue
Block a user