Skip to content

Commit

Permalink
Fixes case on assertions
Browse files Browse the repository at this point in the history
  • Loading branch information
filipefurtad0 committed Oct 15, 2023
1 parent e27e307 commit 6f3aff0
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 8 deletions.
2 changes: 1 addition & 1 deletion spec/support/features/datepicker_helper.rb
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ module Features
module DatepickerHelper
def choose_today_from_datepicker
within(".flatpickr-calendar.open") do
find("button", text: "TODAY").click
find("button", text: "Today").click
end
end

Expand Down
2 changes: 1 addition & 1 deletion spec/system/admin/configuration/general_settings_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@

context 'editing currency symbol position' do
it 'updates its position' do
expect(page).to have_content('CURRENCY SETTINGS')
expect(page).to have_content('Currency Settings')

within('.currency') do
find("[for='currency_symbol_position_after']").click
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
"Last Name",
"Code",
"Email"
].join(" ").upcase
].join(" ")
}
let!(:state_zone){ create(:zone_with_state_member) }
let!(:country_zone){ create(:zone_with_member) }
Expand Down
10 changes: 5 additions & 5 deletions spec/system/admin/subscriptions/crud_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,7 @@
accept_alert 'Are you sure?' do
find("a.cancel-order").click
end
expect(page).to have_content 'CANCELLED'
expect(page).to have_content 'CANCELLED'.upcase
expect(proxy_order.reload.canceled_at).to be_within(5.seconds).of Time.zone.now

# Resuming an order
Expand All @@ -147,7 +147,7 @@
end
click_button "Yes, I'm sure"
within "tr#so_#{subscription.id}" do
expect(page).to have_selector ".state.paused", text: "PAUSED"
expect(page).to have_selector ".state.paused", text: "Paused"
expect(subscription.reload.paused_at).to be_within(5.seconds).of Time.zone.now
end

Expand All @@ -157,7 +157,7 @@
end
click_button "Yes, I'm sure"
within "tr#so_#{subscription.id}" do
expect(page).to have_selector ".state.active", text: "ACTIVE"
expect(page).to have_selector ".state.active", text: "Active"
expect(subscription.reload.paused_at).to be nil
end

Expand All @@ -167,7 +167,7 @@
end
click_button "Yes, I'm sure"
within "tr#so_#{subscription.id}" do
expect(page).to have_selector ".state.canceled", text: "CANCELLED"
expect(page).to have_selector ".state.canceled", text: "Cancelled"
expect(subscription.reload.canceled_at).to be_within(5.seconds).of Time.zone.now
end
end
Expand Down Expand Up @@ -260,7 +260,7 @@ def open_subscription_products_panel
choose_today_from_datepicker
click_button('Next')

expect(page).to have_content 'BILLING ADDRESS'
expect(page).to have_content 'Billing Address'
# Customer bill address has been pre-loaded
expect(page).to have_input "bill_address_firstname", with: address.firstname
expect(page).to have_input "bill_address_lastname", with: address.lastname
Expand Down

0 comments on commit 6f3aff0

Please sign in to comment.