diff --git a/backend/spec/features/admin/configuration/shipping_methods_spec.rb b/backend/spec/features/admin/configuration/shipping_methods_spec.rb index 9bc314d7c0d..312d2b2a3d7 100644 --- a/backend/spec/features/admin/configuration/shipping_methods_spec.rb +++ b/backend/spec/features/admin/configuration/shipping_methods_spec.rb @@ -18,7 +18,7 @@ within_row(1) do expect(column_text(1)).to eq(shipping_method.name) expect(column_text(2)).to eq(zone.name) - expect(column_text(3)).to eq("Flat rate") + expect(column_text(3)).to eq("Flat Rate") expect(column_text(4)).to eq("Yes") end end @@ -99,7 +99,7 @@ def self.description click_icon :edit end - select 'Flexible Rate per package item', from: 'Base Calculator' + select 'Flexible Rate per Package Item', from: 'Base Calculator' fill_in 'First Item', with: 10 fill_in 'Additional Item', with: 20 diff --git a/backend/spec/features/admin/orders/listing_spec.rb b/backend/spec/features/admin/orders/listing_spec.rb index b3e0619f1d1..a7b30de71d0 100644 --- a/backend/spec/features/admin/orders/listing_spec.rb +++ b/backend/spec/features/admin/orders/listing_spec.rb @@ -47,7 +47,7 @@ within_row(1) { expect(page).to have_content("R100") } within_row(2) { expect(page).to have_content("R200") } - click_link "Completed At", exact: false + click_link "Completed at", exact: false # Completed at desc within_row(1) { expect(page).to have_content("R200") } diff --git a/backend/spec/features/admin/orders/order_details_spec.rb b/backend/spec/features/admin/orders/order_details_spec.rb index 92c55419724..e0cc461d443 100644 --- a/backend/spec/features/admin/orders/order_details_spec.rb +++ b/backend/spec/features/admin/orders/order_details_spec.rb @@ -415,7 +415,7 @@ it 'should not allow a shipment to split stock to itself' do visit spree.edit_admin_order_path(order) within('tr', text: line_item.sku) { click_icon 'arrows-h' } - click_on 'Choose location' + click_on 'Choose Location' within '.select2-results' do expect(page).to have_content(shipment2.number) expect(page).not_to have_content(shipment1.number) diff --git a/backend/spec/features/admin/products/stock_management_spec.rb b/backend/spec/features/admin/products/stock_management_spec.rb index 52cfa2122f2..2da44f4b102 100644 --- a/backend/spec/features/admin/products/stock_management_spec.rb +++ b/backend/spec/features/admin/products/stock_management_spec.rb @@ -62,7 +62,7 @@ def adjust_count_on_hand(count_on_hand) find(:css, "input[type='number']").set(count_on_hand) click_icon :check end - expect(page).to have_content('Updated successfully') + expect(page).to have_content('Updated Successfully') end context "with stock locations that don't have stock items for variant yet" do diff --git a/backend/spec/features/admin/promotion_adjustments_spec.rb b/backend/spec/features/admin/promotion_adjustments_spec.rb index 6d1d6cf6100..82f06bf6abf 100644 --- a/backend/spec/features/admin/promotion_adjustments_spec.rb +++ b/backend/spec/features/admin/promotion_adjustments_spec.rb @@ -18,7 +18,7 @@ click_button "Create" expect(page).to have_title("SAVE SAVE SAVE - Promotions") - select "Item total", from: "Discount rules" + select "Item Total", from: "Discount Rules" within('#rule_fields') { click_button "Add" } find('[id$=_preferred_amount]').set(30) @@ -81,7 +81,7 @@ click_button "Create" expect(page).to have_title("SAVE SAVE SAVE - Promotions") - select "Item total", from: "Discount rules" + select "Item Total", from: "Discount Rules" within('#rule_fields') { click_button "Add" } find('[id$=_preferred_amount]').set(30) @@ -118,7 +118,7 @@ click_button "Create" expect(page).to have_title("SAVE SAVE SAVE - Promotions") - select "Product(s)", from: "Discount rules" + select "Product(s)", from: "Discount Rules" within("#rule_fields") { click_button "Add" } select2_search "RoR Mug", from: "Choose products" within('#rule_fields') { click_button "Update" } @@ -152,12 +152,12 @@ click_button "Create" expect(page).to have_title("SAVE SAVE SAVE - Promotions") - select "Item total", from: "Discount rules" + select "Item Total", from: "Discount Rules" within('#rule_fields') { click_button "Add" } find('[id$=_preferred_amount]').set(30) within('#rule_fields') { click_button "Update" } - select "Free shipping", from: "Adjustment type" + select "Free Shipping", from: "Adjustment type" within('#action_fields') { click_button "Add" } expect(page).to have_content('Makes all shipments for the order free') @@ -205,7 +205,7 @@ click_button "Create" expect(page).to have_title("SAVE SAVE SAVE - Promotions") - select "Item total", from: "Discount rules" + select "Item Total", from: "Discount Rules" within('#rule_fields') { click_button "Add" } find('[id$=_preferred_amount]').set(50) within('#rule_fields') { click_button "Update" } diff --git a/backend/spec/features/admin/promotions/option_value_rule_spec.rb b/backend/spec/features/admin/promotions/option_value_rule_spec.rb index aa0bc787748..59412b5e7e0 100644 --- a/backend/spec/features/admin/promotions/option_value_rule_spec.rb +++ b/backend/spec/features/admin/promotions/option_value_rule_spec.rb @@ -16,7 +16,7 @@ end scenario "adding an option value rule", js: true do - select "Option Value(s)", from: "Discount rules" + select "Option Value(s)", from: "Discount Rules" within("#rules_container") { click_button "Add" } within("#rules_container .promotion-block") do @@ -46,7 +46,7 @@ option_value.update!(name: xss_string) end scenario "adding an option value rule", js: true do - select "Option Value(s)", from: "Discount rules" + select "Option Value(s)", from: "Discount Rules" within("#rules_container") { click_button "Add" } within("#rules_container .promotion-block") do diff --git a/backend/spec/features/admin/promotions/product_rule_spec.rb b/backend/spec/features/admin/promotions/product_rule_spec.rb index 3a844ca58d9..2b6d909c352 100644 --- a/backend/spec/features/admin/promotions/product_rule_spec.rb +++ b/backend/spec/features/admin/promotions/product_rule_spec.rb @@ -12,7 +12,7 @@ given(:promotion) { create :promotion } def add_promotion_rule_of_type(type) - select type, from: "Discount rules" + select type, from: "Discount Rules" within("#rules_container") { click_button "Add" } end diff --git a/backend/spec/features/admin/promotions/user_rule_spec.rb b/backend/spec/features/admin/promotions/user_rule_spec.rb index 7489f127c3b..6c750ca6814 100644 --- a/backend/spec/features/admin/promotions/user_rule_spec.rb +++ b/backend/spec/features/admin/promotions/user_rule_spec.rb @@ -16,7 +16,7 @@ let!(:other_user) { create(:user, email: 'bar@example.com') } scenario "searching a user" do - select "User", from: "Discount rules" + select "User", from: "Discount Rules" within("#rules_container") { click_button "Add" } select2_search "foo", from: "Choose users", select: false @@ -31,7 +31,7 @@ given!(:user) { create(:user, email: xss_string) } scenario "adding an option value rule" do - select "User", from: "Discount rules" + select "User", from: "Discount Rules" within("#rules_container") { click_button "Add" } select2_search "