Skip to content

Commit d846ca1

Browse files
committed
All requested changes are applied
1 parent fbb5eac commit d846ca1

File tree

7 files changed

+73
-40
lines changed

7 files changed

+73
-40
lines changed
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<!--
3+
/**
4+
* Copyright © Magento, Inc. All rights reserved.
5+
* See COPYING.txt for license details.z
6+
*/
7+
-->
8+
9+
<actionGroups xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
10+
xsi:noNamespaceSchemaLocation="urn:magento:mftf:Test/etc/actionGroupSchema.xsd">
11+
<actionGroup name="ClearShippingAddressActionGroup">
12+
<clearField selector="{{CheckoutShippingSection.firstName}}" stepKey="clearFieldFirstName"/>
13+
<clearField selector="{{CheckoutShippingSection.company}}" stepKey="clearFieldCompany"/>
14+
<clearField selector="{{CheckoutShippingSection.street}}" stepKey="clearFieldStreetAddress"/>
15+
<clearField selector="{{CheckoutShippingSection.city}}" stepKey="clearFieldCityName"/>
16+
<selectOption selector="{{CheckoutShippingSection.region}}" userInput="" stepKey="clearFieldRegion"/>
17+
<clearField selector="{{CheckoutShippingSection.postcode}}" stepKey="clearFieldZip"/>
18+
<selectOption selector="{{CheckoutShippingSection.country}}" userInput="" stepKey="clearFieldCounty"/>
19+
<clearField selector="{{CheckoutShippingSection.telephone}}" stepKey="clearFieldPhoneNumber"/>
20+
</actionGroup>
21+
</actionGroups>
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
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+
<actionGroups xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
10+
xsi:noNamespaceSchemaLocation="urn:magento:mftf:Test/etc/actionGroupSchema.xsd">
11+
<actionGroup name="FillShippingAddressOneStreetActionGroup">
12+
<arguments>
13+
<argument name="address" type="entity"/>
14+
</arguments>
15+
<fillField stepKey="fillFirstName" selector="{{CheckoutShippingSection.firstName}}" userInput="{{address.firstname}}"/>
16+
<fillField stepKey="fillLastName" selector="{{CheckoutShippingSection.lastName}}" userInput="{{address.lastname}}"/>
17+
<fillField stepKey="fillCompany" selector="{{CheckoutShippingSection.company}}" userInput="{{address.company}}"/>
18+
<fillField stepKey="fillPhoneNumber" selector="{{CheckoutShippingSection.telephone}}" userInput="{{address.telephone}}"/>
19+
<fillField stepKey="fillStreetAddress" selector="{{CheckoutShippingSection.street}}" userInput="{{address.street[0]}}"/>
20+
<fillField stepKey="fillCityName" selector="{{CheckoutShippingSection.city}}" userInput="{{address.city}}"/>
21+
<selectOption stepKey="selectCounty" selector="{{CheckoutShippingSection.country}}" userInput="{{address.country_id}}"/>
22+
<fillField stepKey="fillZip" selector="{{CheckoutShippingSection.postcode}}" userInput="{{address.postcode}}"/>
23+
</actionGroup>
24+
</actionGroups>

app/code/Magento/Checkout/Test/Mftf/ActionGroup/FillShippingZipFormActionGroup.xml

Lines changed: 0 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -20,27 +20,4 @@
2020
<fillField stepKey="fillPostCode" selector="{{CheckoutCartSummarySection.postcode}}" userInput="{{address.postcode}}"/>
2121
<waitForPageLoad stepKey="waitForFormUpdate"/>
2222
</actionGroup>
23-
<actionGroup name="FillShippingAddressOneStreetActionGroup">
24-
<arguments>
25-
<argument name="Address"/>
26-
</arguments>
27-
<fillField stepKey="fillFirstName" selector="{{CheckoutShippingSection.firstName}}" userInput="{{Address.firstname}}"/>
28-
<fillField stepKey="fillLastName" selector="{{CheckoutShippingSection.lastName}}" userInput="{{Address.lastname}}"/>
29-
<fillField stepKey="fillCompany" selector="{{CheckoutShippingSection.company}}" userInput="{{Address.company}}"/>
30-
<fillField stepKey="fillPhoneNumber" selector="{{CheckoutShippingSection.telephone}}" userInput="{{Address.telephone}}"/>
31-
<fillField stepKey="fillStreetAddress" selector="{{CheckoutShippingSection.street}}" userInput="{{Address.street[0]}}"/>
32-
<fillField stepKey="fillCityName" selector="{{CheckoutShippingSection.city}}" userInput="{{Address.city}}"/>
33-
<selectOption stepKey="selectCounty" selector="{{CheckoutShippingSection.country}}" userInput="{{Address.country_id}}"/>
34-
<fillField stepKey="fillZip" selector="{{CheckoutShippingSection.postcode}}" userInput="{{Address.postcode}}"/>
35-
</actionGroup>
36-
<actionGroup name="clearShippingAddressActionGroup">
37-
<clearField selector="{{CheckoutShippingSection.firstName}}" stepKey="clearFieldFirstName"/>
38-
<clearField selector="{{CheckoutShippingSection.company}}" stepKey="clearFieldCompany"/>
39-
<clearField selector="{{CheckoutShippingSection.street}}" stepKey="clearFieldStreetAddress"/>
40-
<clearField selector="{{CheckoutShippingSection.city}}" stepKey="clearFieldCityName"/>
41-
<selectOption selector="{{CheckoutShippingSection.region}}" userInput="" stepKey="clearFieldRegion"/>
42-
<clearField selector="{{CheckoutShippingSection.postcode}}" stepKey="clearFieldZip"/>
43-
<selectOption selector="{{CheckoutShippingSection.country}}" userInput="" stepKey="clearFieldCounty"/>
44-
<clearField selector="{{CheckoutShippingSection.telephone}}" stepKey="clearFieldPhoneNumber"/>
45-
</actionGroup>
4623
</actionGroups>
Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
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+
<actionGroups xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
10+
xsi:noNamespaceSchemaLocation="urn:magento:mftf:Test/etc/actionGroupSchema.xsd">
11+
<!-- Add Product to Cart from the category page and check message -->
12+
<actionGroup name="StorefrontAddSimpleProductToCartActionGroup">
13+
<arguments>
14+
<argument name="product" type="entity"/>
15+
</arguments>
16+
<moveMouseOver selector="{{StorefrontCategoryProductSection.ProductInfoByName(product.name)}}" stepKey="moveMouseOverProduct" />
17+
<click selector="{{StorefrontCategoryProductSection.ProductAddToCartByName(product.name)}}" stepKey="clickAddToCart" />
18+
<waitForElementVisible selector="{{StorefrontCategoryMainSection.SuccessMsg}}" stepKey="waitForSuccessMessage" />
19+
<see selector="{{StorefrontCategoryMainSection.SuccessMsg}}" userInput="You added {{product.name}} to your shopping cart." stepKey="assertSuccessMessage"/>
20+
</actionGroup>
21+
</actionGroups>
22+

app/code/Magento/Checkout/Test/Mftf/ActionGroup/StorefrontProductCartActionGroup.xml

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -112,14 +112,4 @@
112112
<fillField stepKey="fillZip" selector="{{CheckoutCartSummarySection.postcode}}" userInput="{{taxCode.zip}}"/>
113113
<waitForPageLoad stepKey="waitForFormUpdate"/>
114114
</actionGroup>
115-
<!-- Add Product to Cart from the category page and check message -->
116-
<actionGroup name="StorefrontAddCategorySimpleProductToCartActionGroup">
117-
<arguments>
118-
<argument name="product"/>
119-
</arguments>
120-
<moveMouseOver selector="{{StorefrontCategoryProductSection.ProductInfoByName(product.name)}}" stepKey="moveMouseOverProduct" />
121-
<click selector="{{StorefrontCategoryProductSection.ProductAddToCartByName(product.name)}}" stepKey="clickAddToCart" />
122-
<waitForElementVisible selector="{{StorefrontCategoryMainSection.SuccessMsg}}" stepKey="waitForSuccessMessage" />
123-
<see selector="{{StorefrontCategoryMainSection.SuccessMsg}}" userInput="You added {{product.name}} to your shopping cart." stepKey="assertSuccessMessage"/>
124-
</actionGroup>
125115
</actionGroups>
Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -8,14 +8,14 @@
88

99
<tests xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
1010
xsi:noNamespaceSchemaLocation="urn:magento:mftf:Test/etc/testSchema.xsd">
11-
<test name="EditShippingAddressOnePageCheckoutTestVariation1">
11+
<test name="EditShippingAddressOnePageCheckoutTest">
1212
<annotations>
1313
<features value="Checkout"/>
1414
<stories value="Edit Shipping Address"/>
1515
<title value="Edit Shipping Address on Checkout Page."/>
1616
<description value="Edit Shipping Address on Checkout Page."/>
1717
<severity value="MAJOR"/>
18-
<testCaseId value="MAGETWO-67837"/>
18+
<testCaseId value="MC-14680"/>
1919
<group value="shoppingCart"/>
2020
<group value="mtf_migrated"/>
2121
</annotations>
@@ -39,7 +39,7 @@
3939

4040
<!-- Add product to cart -->
4141
<amOnPage url="{{StorefrontCategoryPage.url($$createCategory.name$$)}}" stepKey="onCategoryPage"/>
42-
<actionGroup ref="StorefrontAddCategorySimpleProductToCartActionGroup" stepKey="addProductToCart">
42+
<actionGroup ref="StorefrontAddSimpleProductToCartActionGroup" stepKey="addProductToCart">
4343
<argument name="product" value="$$createProduct$$"/>
4444
</actionGroup>
4545

@@ -51,7 +51,7 @@
5151

5252
<!--Fill in required fields and click *Save address* button-->
5353
<actionGroup ref="FillShippingAddressOneStreetActionGroup" stepKey="changeAddress">
54-
<argument name="Address" value="UK_Not_Default_Address"/>
54+
<argument name="address" value="UK_Not_Default_Address"/>
5555
</actionGroup>
5656
<click selector="{{CheckoutShippingSection.saveAddress}}" stepKey="saveNewAddress"/>
5757

@@ -63,7 +63,7 @@
6363
<click selector="{{CheckoutShippingSection.editActiveAddress}}" stepKey="editNewAddress"/>
6464

6565
<!--Remove values from required fields and click *Cancel* button -->
66-
<actionGroup ref="clearShippingAddressActionGroup" stepKey="clearRequiredFields"/>
66+
<actionGroup ref="ClearShippingAddressActionGroup" stepKey="clearRequiredFields"/>
6767
<click selector="{{CheckoutShippingSection.cancelChangeAddress}}" stepKey="cancelEditAddress"/>
6868

6969
<!-- Go to *Next* -->

dev/tests/functional/tests/app/Magento/Checkout/Test/TestCase/EditShippingAddressOnePageCheckoutTest.xml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,7 @@
88
<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/etc/variations.xsd">
99
<testCase name="Magento\Checkout\Test\TestCase\EditShippingAddressOnePageCheckoutTest" summary="Customer can place order with new addresses that was edited during checkout with several conditions" ticketId="MAGETWO-67837">
1010
<variation name="EditShippingAddressOnePageCheckoutTestVariation1">
11-
<data name="tag" xsi:type="string">mftf_migrated:yes</data>
12-
<data name="tag" xsi:type="string">severity:S1</data>
11+
<data name="tag" xsi:type="string">severity:S1, mftf_migrated:yes</data>
1312
<data name="customer/dataset" xsi:type="string">johndoe_with_addresses</data>
1413
<data name="shippingAddress/dataset" xsi:type="string">UK_address_without_email</data>
1514
<data name="editShippingAddress/dataset" xsi:type="string">empty_UK_address_without_email</data>

0 commit comments

Comments
 (0)