Add i18n for payment state key

+ update spec
This commit is contained in:
Jean-Baptiste Bellet
2023-04-06 10:01:03 +02:00
parent 6abd652251
commit e74328f1d7
2 changed files with 2 additions and 2 deletions

View File

@@ -15,7 +15,7 @@ module Reporting
protected
def payment_state(order)
order.payment_state
I18n.t "spree.payment_states.#{order.payment_state}"
end
end
end

View File

@@ -86,7 +86,7 @@ describe "Payments Reports" do
].join(" ").upcase)
expect(page.find("table.report__table tbody tr").text).to have_content([
order.payment_state,
"credit owed",
order.distributor.name,
order.item_total.to_f + other_order.item_total.to_f,
order.ship_total.to_f + other_order.ship_total.to_f,