Skip to content

Commit 89d3cda

Browse files
authored
Merge pull request #5933 from magento-tsg/2.4-develop-pr59
[TSG] TESTs Fixes for 2.4 (pr59) (2.4-develop)
2 parents de9332c + 83b5361 commit 89d3cda

14 files changed

+705
-5
lines changed
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+
<actionGroup name="AdminProductAttributeSaveActionGroup">
12+
<annotations>
13+
<description>Clicks on Save button to save the attribute and check success message.</description>
14+
</annotations>
15+
16+
<scrollToTopOfPage stepKey="scrollToTopOfThePage"/>
17+
<waitForElementVisible selector="{{AdminMainActionsSection.save}}" stepKey="waitForSaveButton"/>
18+
<click selector="{{AdminMainActionsSection.save}}" stepKey="clickSaveButton"/>
19+
<waitForElementVisible selector="{{AdminMessagesSection.success}}" stepKey="waitForSuccessMessage"/>
20+
<see selector="{{AdminMessagesSection.success}}" userInput="You saved the product attribute." stepKey="seeSuccessMessage"/>
21+
</actionGroup>
22+
</actionGroups>

app/code/Magento/Catalog/Test/Mftf/ActionGroup/AdminSaveProductAttributeActionGroup.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
xsi:noNamespaceSchemaLocation="urn:magento:mftf:Test/etc/actionGroupSchema.xsd">
1111
<actionGroup name="AdminSaveProductAttributeActionGroup">
1212
<annotations>
13-
<description>Clicks on Save button to save the attribute.</description>
13+
<description>DEPRECATED. Use AdminProductAttributeSaveActionGroup instead. Clicks on Save button to save the attribute.</description>
1414
</annotations>
1515

1616
<waitForElementVisible selector="{{AttributePropertiesSection.Save}}" stepKey="waitForSaveButton"/>
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
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="AdminSetProductAttributeUseInLayeredNavigationOptionActionGroup">
12+
<arguments>
13+
<argument name="useInLayeredNavigationValue" type="string" defaultValue="Filterable (with results)"/>
14+
</arguments>
15+
<conditionalClick selector="{{StorefrontPropertiesSection.StoreFrontPropertiesTab}}" dependentSelector="{{AttributePropertiesSection.useInLayeredNavigation}}" visible="false" stepKey="clickStoreFrontTab"/>
16+
<waitForElementVisible selector="{{AttributePropertiesSection.useInLayeredNavigation}}" stepKey="waitForStorefrontTabLoad"/>
17+
<selectOption selector="{{AttributePropertiesSection.useInLayeredNavigation}}" userInput="{{useInLayeredNavigationValue}}" stepKey="selectUseInLayeredNavigationOption"/>
18+
</actionGroup>
19+
</actionGroups>

app/code/Magento/Catalog/Test/Mftf/ActionGroup/SaveProductAttributeActionGroup.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
xsi:noNamespaceSchemaLocation="urn:magento:mftf:Test/etc/actionGroupSchema.xsd">
1111
<actionGroup name="SaveProductAttributeActionGroup">
1212
<annotations>
13-
<description>Clicks on Save. Validates that the Success Message is present.</description>
13+
<description>DEPRECATED. Use AdminProductAttributeSaveActionGroup instead. Clicks on Save. Validates that the Success Message is present.</description>
1414
</annotations>
1515

1616
<waitForElementVisible selector="{{AttributePropertiesSection.Save}}" stepKey="waitForSaveButton"/>

app/code/Magento/Catalog/Test/Mftf/ActionGroup/SaveProductAttributeInUseActionGroup.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
xsi:noNamespaceSchemaLocation="urn:magento:mftf:Test/etc/actionGroupSchema.xsd">
1111
<actionGroup name="SaveProductAttributeInUseActionGroup">
1212
<annotations>
13-
<description>Clicks on Save. Validates that the Success Message is present.</description>
13+
<description>DEPRECATED. Use AdminProductAttributeSaveActionGroup instead. Clicks on Save. Validates that the Success Message is present.</description>
1414
</annotations>
1515

1616
<waitForElementVisible selector="{{AttributePropertiesSection.Save}}" stepKey="waitForSaveButton"/>

app/code/Magento/Catalog/Test/Mftf/Data/ProductData.xml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -284,6 +284,9 @@
284284
<requiredEntity type="product_extension_attribute">EavStockItem</requiredEntity>
285285
<requiredEntity type="custom_attribute">CustomAttributeProductAttribute</requiredEntity>
286286
</entity>
287+
<entity name="ApiSimpleProductWithCategory" type="product2" extends="ApiSimpleOne">
288+
<requiredEntity type="custom_attribute">CustomAttributeCategoryIds</requiredEntity>
289+
</entity>
287290
<entity name="ApiSimpleProductWithShortSKU" type="product2" extends="ApiSimpleOne">
288291
<data key="sku" unique="suffix">pr</data>
289292
</entity>

app/code/Magento/Catalog/Test/Mftf/Section/StorefrontCategorySidebarSection/StorefrontCategorySidebarSection.xml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,5 +17,7 @@
1717
<element name="removeFilter" type="button" selector="div.filter-current .remove"/>
1818
<element name="activeFilterOptions" type="text" selector=".filter-options-item.active .items"/>
1919
<element name="activeFilterOptionItemByPosition" type="text" selector=".filter-options-item.active .items li:nth-child({{itemPosition}}) a" parameterized="true"/>
20+
<element name="enabledFilterOptionItemByLabel" type="text" selector="//div[@class='filter-options']//li[@class='item']//a[contains(text(), '{{optionLabel}}')]" parameterized="true"/>
21+
<element name="disabledFilterOptionItemByLabel" type="text" selector="//div[@class='filter-options']//li[@class='item' and contains(text(), '{{optionLabel}}')]" parameterized="true"/>
2022
</section>
2123
</sections>

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

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,12 +12,15 @@
1212
<annotations>
1313
<features value="Checkout"/>
1414
<stories value="Check customer information created by guest"/>
15-
<title value="Check Customer Information Created By Guest"/>
15+
<title value="Deprecated. Check Customer Information Created By Guest"/>
1616
<description value="Check customer information after placing the order as the guest who created an account"/>
1717
<severity value="MAJOR"/>
1818
<testCaseId value="MAGETWO-95932"/>
1919
<useCaseId value="MAGETWO-95820"/>
2020
<group value="checkout"/>
21+
<skip>
22+
<issueId value="DEPRECATED">Use StorefrontCheckCustomerInfoOnOrderPageCreatedByGuestTest instead.</issueId>
23+
</skip>
2124
</annotations>
2225

2326
<before>
Lines changed: 63 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,63 @@
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="StorefrontCheckCustomerInfoOnOrderPageCreatedByGuestTest">
12+
<annotations>
13+
<features value="Checkout"/>
14+
<stories value="Check customer information created by guest"/>
15+
<title value="Check Customer Information Created By Guest"/>
16+
<description value="Check customer information after placing the order as the guest who created an account"/>
17+
<severity value="MAJOR"/>
18+
<testCaseId value="MC-28550"/>
19+
<useCaseId value="MAGETWO-95820"/>
20+
<group value="checkout"/>
21+
</annotations>
22+
23+
<before>
24+
<createData entity="_defaultCategory" stepKey="createCategory"/>
25+
<createData entity="_defaultProduct" stepKey="createProduct">
26+
<requiredEntity createDataKey="createCategory"/>
27+
</createData>
28+
<actionGroup ref="AdminLoginActionGroup" stepKey="loginAsAdmin"/>
29+
</before>
30+
31+
<after>
32+
<deleteData createDataKey="createProduct" stepKey="deleteProduct"/>
33+
<deleteData createDataKey="createCategory" stepKey="deleteCategory"/>
34+
<actionGroup ref="AdminOrdersGridClearFiltersActionGroup" stepKey="clearOrdersGridFilter"/>
35+
<actionGroup ref="AdminLogoutActionGroup" stepKey="logoutFromAdmin"/>
36+
</after>
37+
38+
<actionGroup ref="StorefrontOpenProductPageActionGroup" stepKey="openProductPage">
39+
<argument name="productUrl" value="$createProduct.custom_attributes[url_key]$"/>
40+
</actionGroup>
41+
<actionGroup ref="AddToCartFromStorefrontProductPageActionGroup" stepKey="addToCartFromStorefrontProductPage">
42+
<argument name="productName" value="$createProduct.name$"/>
43+
</actionGroup>
44+
<actionGroup ref="GoToCheckoutFromMinicartActionGroup" stepKey="goToCheckoutFromMinicart"/>
45+
<actionGroup ref="GuestCheckoutFillingShippingSectionActionGroup" stepKey="fillShippingSectionAsGuest">
46+
<argument name="customerVar" value="CustomerEntityOne"/>
47+
<argument name="customerAddressVar" value="CustomerAddressSimple"/>
48+
</actionGroup>
49+
<actionGroup ref="CheckoutSelectCheckMoneyOrderPaymentActionGroup" stepKey="selectCheckMoneyPayment"/>
50+
<actionGroup ref="CheckoutPlaceOrderActionGroup" stepKey="placeOrder">
51+
<argument name="orderNumberMessage" value="CONST.successGuestCheckoutOrderNumberMessage"/>
52+
<argument name="emailYouMessage" value="CONST.successCheckoutEmailYouMessage"/>
53+
</actionGroup>
54+
<grabTextFrom selector="{{CheckoutSuccessRegisterSection.orderNumber}}" stepKey="grabOrderNumber"/>
55+
<actionGroup ref="StorefrontRegisterCustomerFromOrderSuccessPage" stepKey="createCustomerAfterPlaceOrder">
56+
<argument name="customer" value="CustomerEntityOne"/>
57+
</actionGroup>
58+
<actionGroup ref="OpenOrderByIdActionGroup" stepKey="filterOrdersGridById">
59+
<argument name="orderId" value="{$grabOrderNumber}"/>
60+
</actionGroup>
61+
<see userInput="{{CustomerEntityOne.firstname}}" selector="{{AdminShipmentOrderInformationSection.customerName}}" stepKey="seeCustomerName"/>
62+
</test>
63+
</tests>

app/code/Magento/ConfigurableProduct/Test/Mftf/Data/ConfigurableProductOptionData.xml

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,4 +26,23 @@
2626
<requiredEntity type="ValueIndex">ValueIndex2</requiredEntity>
2727
<requiredEntity type="ValueIndex">ValueIndex3</requiredEntity>
2828
</entity>
29+
<entity name="ConfigurableProduct15Options" type="ConfigurableProductOption">
30+
<var key="attribute_id" entityKey="attribute_id" entityType="ProductAttribute" />
31+
<data key="label">option</data>
32+
<requiredEntity type="ValueIndex">ValueIndex1</requiredEntity>
33+
<requiredEntity type="ValueIndex">ValueIndex1</requiredEntity>
34+
<requiredEntity type="ValueIndex">ValueIndex1</requiredEntity>
35+
<requiredEntity type="ValueIndex">ValueIndex1</requiredEntity>
36+
<requiredEntity type="ValueIndex">ValueIndex1</requiredEntity>
37+
<requiredEntity type="ValueIndex">ValueIndex1</requiredEntity>
38+
<requiredEntity type="ValueIndex">ValueIndex1</requiredEntity>
39+
<requiredEntity type="ValueIndex">ValueIndex1</requiredEntity>
40+
<requiredEntity type="ValueIndex">ValueIndex1</requiredEntity>
41+
<requiredEntity type="ValueIndex">ValueIndex1</requiredEntity>
42+
<requiredEntity type="ValueIndex">ValueIndex1</requiredEntity>
43+
<requiredEntity type="ValueIndex">ValueIndex1</requiredEntity>
44+
<requiredEntity type="ValueIndex">ValueIndex1</requiredEntity>
45+
<requiredEntity type="ValueIndex">ValueIndex1</requiredEntity>
46+
<requiredEntity type="ValueIndex">ValueIndex1</requiredEntity>
47+
</entity>
2948
</entities>
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
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+
<entities xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
10+
xsi:noNamespaceSchemaLocation="urn:magento:mftf:DataGenerator/etc/dataProfileSchema.xsd">
11+
<entity name="DisplayProductCountDefaultValue">
12+
<data key="path">catalog/layered_navigation/display_product_count</data>
13+
<data key="value">1</data>
14+
</entity>
15+
<entity name="PriceNavigationStepCalculationDefaultValue">
16+
<data key="path">catalog/layered_navigation/price_range_calculation</data>
17+
<data key="value">auto</data>
18+
</entity>
19+
</entities>

0 commit comments

Comments
 (0)