Skip to content

Commit c3cd7c5

Browse files
committed
Merge remote-tracking branch 'origin/MC-37820' into 2.4-develop-pr142
2 parents 16045c8 + 0d98c8a commit c3cd7c5

5 files changed

+64
-0
lines changed

app/code/Magento/Checkout/Test/Mftf/Test/OnePageCheckoutAsCustomerUsingDefaultAddressTest.xml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -77,6 +77,7 @@
7777

7878
<!-- Check order summary in checkout -->
7979
<waitForElement selector="{{CheckoutPaymentSection.paymentSectionTitle}}" stepKey="waitForPaymentSectionLoaded"/>
80+
<waitForElementVisible selector="{{CheckoutPaymentSection.placeOrder}}" stepKey="waitForPlaceOrderButton"/>
8081
<click selector="{{CheckoutPaymentSection.placeOrder}}" stepKey="clickPlaceOrderButton"/>
8182
<seeElement selector="{{CheckoutSuccessMainSection.success}}" stepKey="orderIsSuccessfullyPlaced"/>
8283
<grabTextFrom selector="{{CheckoutSuccessMainSection.orderNumber22}}" stepKey="grabOrderNumber"/>

app/code/Magento/Checkout/Test/Mftf/Test/OnePageCheckoutAsCustomerUsingNonExistentCustomerGroupTest.xml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -87,6 +87,7 @@
8787

8888
<!-- Check order summary in checkout -->
8989
<waitForElement selector="{{CheckoutPaymentSection.paymentSectionTitle}}" stepKey="waitForPaymentSectionLoaded"/>
90+
<waitForElementVisible selector="{{CheckoutPaymentSection.placeOrder}}" stepKey="waitForPlaceOrderButton"/>
9091
<click selector="{{CheckoutPaymentSection.placeOrder}}" stepKey="clickPlaceOrderButton"/>
9192
<seeElement selector="{{CheckoutSuccessMainSection.success}}" stepKey="orderIsSuccessfullyPlaced"/>
9293
<grabTextFrom selector="{{CheckoutSuccessMainSection.orderNumber22}}" stepKey="grabOrderNumber"/>

app/code/Magento/Checkout/Test/Mftf/Test/OnePageCheckoutUsingSignInLinkTest.xml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -71,6 +71,7 @@
7171

7272
<!-- Check order summary in checkout -->
7373
<waitForElement selector="{{CheckoutPaymentSection.paymentSectionTitle}}" stepKey="waitForPaymentSectionLoaded"/>
74+
<waitForElementVisible selector="{{CheckoutPaymentSection.placeOrder}}" stepKey="waitForPlaceOrderButton"/>
7475
<click selector="{{CheckoutPaymentSection.placeOrder}}" stepKey="clickPlaceOrderButton"/>
7576
<seeElement selector="{{CheckoutSuccessMainSection.success}}" stepKey="orderIsSuccessfullyPlaced"/>
7677
<grabTextFrom selector="{{CheckoutSuccessMainSection.orderNumber22}}" stepKey="grabOrderNumber"/>
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,60 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<!--
3+
/**
4+
* Copyright © Magento, Inc. All rights reserved.
5+
* See COPYING.txt for license details.
6+
*/
7+
-->
8+
9+
<tests xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
10+
xsi:noNamespaceSchemaLocation="urn:magento:mftf:Test/etc/testSchema.xsd">
11+
<test name="StorefrontGuestCheckoutWithDifferentShippingAndBillingAddressWithRestrictedCountriesForPaymentTest">
12+
<annotations>
13+
<features value="Checkout"/>
14+
<stories value="Check payment methods on checkout"/>
15+
<title value="Check payment methods update on checkout payment step"/>
16+
<description value="Check that payment methods will update on checkout payment step after updating customer billing address"/>
17+
<severity value="AVERAGE"/>
18+
<testCaseId value="MC-41743"/>
19+
<useCaseId value="MC-37820"/>
20+
<group value="checkout"/>
21+
</annotations>
22+
23+
<before>
24+
<magentoCLI command="config:set {{BankTransferEnableConfigData.path}} {{BankTransferEnableConfigData.value}}" stepKey="enableBankTransfer"/>
25+
<magentoCLI command="config:set payment/checkmo/allowspecific 1" stepKey="allowSpecificValue"/>
26+
<magentoCLI command="config:set payment/checkmo/specificcountry GB" stepKey="allowBankTransferOnlyForGB"/>
27+
<createData entity="SimpleProduct2" stepKey="createProduct"/>
28+
</before>
29+
30+
<after>
31+
<magentoCLI command="config:set {{BankTransferDisabledConfigData.path}} {{BankTransferDisabledConfigData.value}}" stepKey="disableBankTransfer"/>
32+
<magentoCLI command="config:set payment/checkmo/allowspecific 0" stepKey="disallowSpecificValue" />
33+
<magentoCLI command="config:set payment/checkmo/specificcountry ''" stepKey="defaultCountryValue"/>
34+
<deleteData createDataKey="createProduct" stepKey="deleteProduct"/>
35+
</after>
36+
37+
<actionGroup ref="StorefrontOpenProductPageActionGroup" stepKey="openProductPage">
38+
<argument name="productUrl" value="$createProduct.custom_attributes[url_key]$"/>
39+
</actionGroup>
40+
<actionGroup ref="AddToCartFromStorefrontProductPageActionGroup" stepKey="addToCartFromStorefrontProductPage">
41+
<argument name="productName" value="$createProduct.name$"/>
42+
</actionGroup>
43+
<actionGroup ref="GoToCheckoutFromMinicartActionGroup" stepKey="goToCheckoutFromMinicart"/>
44+
<actionGroup ref="GuestCheckoutFillingShippingSectionActionGroup" stepKey="fillShippingSectionAsGuest">
45+
<argument name="customerVar" value="CustomerEntityOne"/>
46+
<argument name="customerAddressVar" value="CustomerAddressSimple"/>
47+
</actionGroup>
48+
<dontSee selector="{{CheckoutPaymentSection.paymentMethodTitle}}" userInput="Check / Money order" stepKey="assertNoCheckMoneyOrderPaymentMethod"/>
49+
<waitForElementVisible selector="{{CheckoutPaymentSection.billingAddressNotSameBankTransferCheckbox}}" stepKey="waitForBillingAddressNotSameAsShippingCheckbox"/>
50+
<uncheckOption selector="{{CheckoutPaymentSection.billingAddressNotSameBankTransferCheckbox}}" stepKey="uncheckSameBillingAndShippingAddress"/>
51+
<conditionalClick selector="{{CheckoutPaymentSection.editAddress}}" dependentSelector="{{CheckoutShippingSection.editAddressButton}}" visible="true" stepKey="clickEditBillingAddressButton"/>
52+
<waitForLoadingMaskToDisappear stepKey="waitForBillingAddressFormLoads"/>
53+
54+
<!-- Fill Billing Address -->
55+
<actionGroup ref="StorefrontFillBillingAddressActionGroup" stepKey="fillBillingAddress"/>
56+
<click selector="{{CheckoutPaymentSection.update}}" stepKey="clickOnUpdateButton"/>
57+
<waitForLoadingMaskToDisappear stepKey="waitForLoadingMaskDisappear" />
58+
<see selector="{{CheckoutPaymentSection.paymentMethodTitle}}" userInput="Check / Money order" stepKey="sdadasdasdsdaasd"/>
59+
</test>
60+
</tests>

app/code/Magento/Checkout/view/frontend/web/js/view/billing-address.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -171,6 +171,7 @@ function (
171171
checkoutData.setNewCustomerBillingAddress(addressData);
172172
}
173173
}
174+
setBillingAddressAction(globalMessageList);
174175
this.updateAddresses();
175176
},
176177

0 commit comments

Comments
 (0)