From 7f7f27557365d5ad7fc1e4741218e87c8aa84fd8 Mon Sep 17 00:00:00 2001 From: Alessandro Lepore Date: Thu, 3 Oct 2024 12:30:15 +0200 Subject: [PATCH 1/2] Format date with #to_fs The #to_s(format) method was deprecated and removed from Rails 7.1. This is causing `ActionView::Template::Error wrong number of arguments (given 1, expected 0)` when a tax rate with an expiration date is displayed. --- backend/app/views/spree/admin/tax_rates/index.html.erb | 2 +- backend/spec/features/admin/configuration/tax_rates_spec.rb | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/backend/app/views/spree/admin/tax_rates/index.html.erb b/backend/app/views/spree/admin/tax_rates/index.html.erb index 84c679e5685..be2b20094be 100644 --- a/backend/app/views/spree/admin/tax_rates/index.html.erb +++ b/backend/app/views/spree/admin/tax_rates/index.html.erb @@ -81,7 +81,7 @@ <%= tax_rate.amount %> <%= tax_rate.included_in_price? ? t('spree.say_yes') : t('spree.say_no') %> <%= tax_rate.show_rate_in_label? ? t('spree.say_yes') : t('spree.say_no') %> - <%= tax_rate.expires_at.to_date.to_s(:short_date) if tax_rate.expires_at %> + <%= tax_rate.expires_at.to_date.to_fs(:short_date) if tax_rate.expires_at %> <%= tax_rate.calculator && tax_rate.calculator.class.model_name.human %> <% if can?(:update, tax_rate) %> diff --git a/backend/spec/features/admin/configuration/tax_rates_spec.rb b/backend/spec/features/admin/configuration/tax_rates_spec.rb index 465728f4ede..713f6b7ca9d 100644 --- a/backend/spec/features/admin/configuration/tax_rates_spec.rb +++ b/backend/spec/features/admin/configuration/tax_rates_spec.rb @@ -25,6 +25,7 @@ click_link "Tax Rates" click_link "New Tax Rate" fill_in "Rate", with: "0.05" + fill_in "Expiration Date", with: "2050-01-01" click_button "Create" expect(page).to have_content("Tax Rate has been successfully created!") end From 4ca325ed7bbb367407aa4016fad5494e3b68f925 Mon Sep 17 00:00:00 2001 From: Martin Meyerhoff Date: Wed, 25 Sep 2024 15:43:29 +0200 Subject: [PATCH 2/2] Stop pinning Chrome We initially did this because of some Bug in Chrome, but now the download of the very specific version here doesn't work any longer. Let's see what happens if we don't pin. --- .circleci/config.yml | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 1efc7b70878..d49deb03c92 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -59,9 +59,7 @@ commands: setup: steps: - checkout - - browser-tools/install-chrome: - chrome-version: "118.0.5993.70" - replace-existing: true + - browser-tools/install-chrome - run: name: Check chrome version command: |