From f8f57a31db7a27c43904bea42ed7c68cbb746b8d Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Bellet Date: Thu, 3 Mar 2022 14:14:39 +0100 Subject: [PATCH] Use the right selector In test env. we don't use the stripejs but a mock. Slightly different. --- spec/support/request/stripe_helper.rb | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/spec/support/request/stripe_helper.rb b/spec/support/request/stripe_helper.rb index 0c6e7da8e6..0b17a89522 100644 --- a/spec/support/request/stripe_helper.rb +++ b/spec/support/request/stripe_helper.rb @@ -15,10 +15,9 @@ module StripeHelper end def fill_out_card_details - expect(page).to have_css("input[name='cardnumber']") - fill_in 'Card number', with: '4242424242424242' - fill_in 'MM / YY', with: "01/#{DateTime.now.year + 1}" - fill_in 'CVC', with: '123' + fill_in "stripe-cardnumber", with: '4242424242424242' + fill_in "exp-date", with: "01/#{DateTime.now.year + 1}" + fill_in "cvc", with: "123" end def fill_in_card_details_in_backoffice