From f8b8298fbe9f2762f7a3e1f8ebc07ca678e71883 Mon Sep 17 00:00:00 2001 From: filipefurtad0 Date: Mon, 21 Mar 2022 13:23:59 +0000 Subject: [PATCH] Adds spec on billing address checkbox --- spec/system/consumer/split_checkout_spec.rb | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/spec/system/consumer/split_checkout_spec.rb b/spec/system/consumer/split_checkout_spec.rb index 0a5b589e47..902f176dce 100644 --- a/spec/system/consumer/split_checkout_spec.rb +++ b/spec/system/consumer/split_checkout_spec.rb @@ -162,12 +162,23 @@ describe "As a consumer, I want to checkout my order", js: true do context "on the 'details' step" do before do visit checkout_step_path(:details) + click_on "Checkout as guest" end it "should allow visit '/checkout/details'" do expect(page).to have_current_path("/checkout/details") end + it 'does not show the save as default bill address checkbox' do + expect(page).not_to have_content "Save as default billing address" + end + + it 'does not show the save as default ship address checkbox' do + choose free_shipping_with_required_address.name + uncheck "ship_address_same_as_billing" + expect(page).not_to have_content "Save as default shipping address" + end + it_behaves_like "when I have an out of stock product in my cart" end