diff --git a/config/locales/en.yml b/config/locales/en.yml index 562227021af..76398dceefe 100644 --- a/config/locales/en.yml +++ b/config/locales/en.yml @@ -2711,7 +2711,7 @@ See the %{link} to find out more about %{sitename}'s features and to start using resolve_errors: Please resolve the following errors more_items: "+ %{count} More" default_card_updated: Default Card Updated - default_card_voids_auth: Changing your default card will remove shops' existing authorizations to charge it. You can re-authorize shops after updating the default card. Do you wish to change the default card?" + default_card_voids_auth: Changing your default card will remove shops' existing authorizations to charge it. You can re-authorize shops after updating the default card. Do you wish to change the default card? cart: add_to_cart_failed: > There was a problem adding this product to the cart. diff --git a/spec/features/consumer/account/cards_spec.rb b/spec/system/consumer/account/cards_spec.rb similarity index 90% rename from spec/features/consumer/account/cards_spec.rb rename to spec/system/consumer/account/cards_spec.rb index 55573be384f..91ce8427c88 100644 --- a/spec/features/consumer/account/cards_spec.rb +++ b/spec/system/consumer/account/cards_spec.rb @@ -1,6 +1,6 @@ # frozen_string_literal: true -require 'spec_helper' +require 'system_helper' describe "Credit Cards", js: true do include AuthenticationHelper @@ -62,9 +62,15 @@ end # Allows switching of default card + alert_text = <<~TEXT.strip + Changing your default card will remove shops' existing authorizations \ + to charge it. You can re-authorize shops after updating the default \ + card. Do you wish to change the default card? + TEXT within(".card#card#{non_default_card.id}") do - find_field('default_card').click - accept_alert + accept_alert(alert_text) do + find_field('default_card').click + end expect(find_field('default_card')).to be_checked end diff --git a/spec/features/consumer/account/payments_spec.rb b/spec/system/consumer/account/payments_spec.rb similarity index 98% rename from spec/features/consumer/account/payments_spec.rb rename to spec/system/consumer/account/payments_spec.rb index 8310d9e7d18..6553d0c08c1 100644 --- a/spec/features/consumer/account/payments_spec.rb +++ b/spec/system/consumer/account/payments_spec.rb @@ -1,6 +1,6 @@ # frozen_string_literal: true -require 'spec_helper' +require 'system_helper' describe "Payments requiring action", js: true do include AuthenticationHelper diff --git a/spec/features/consumer/account/settings_spec.rb b/spec/system/consumer/account/settings_spec.rb similarity index 98% rename from spec/features/consumer/account/settings_spec.rb rename to spec/system/consumer/account/settings_spec.rb index 9ba6bcee0e6..5607d280ba3 100644 --- a/spec/features/consumer/account/settings_spec.rb +++ b/spec/system/consumer/account/settings_spec.rb @@ -1,6 +1,6 @@ # frozen_string_literal: true -require 'spec_helper' +require 'system_helper' describe "Account Settings", js: true do include AuthenticationHelper