Skip to content

Commit 08fa249

Browse files
authored
Merge branch '2.4-develop' into Arrows_Delivery_07022024
2 parents 1e7687f + c3ab314 commit 08fa249

File tree

33 files changed

+966
-1
lines changed

33 files changed

+966
-1
lines changed

app/code/Magento/Backend/Test/Mftf/Section/AdminMessagesSection.xml

+2
Original file line numberDiff line numberDiff line change
@@ -23,5 +23,7 @@
2323
<element name="errorMessage" type="text" selector=".message.message-error.error"/>
2424
<element name="warningMessage" type="text" selector=".message-warning"/>
2525
<element name="noticeMessage" type="text" selector=".message-notice"/>
26+
<element name="assertCacheManagementConfigurationStatus" type="button" selector="//td[@data-column='tags' and contains(text(),'CONFIG')]/following-sibling::td//span[@class='grid-severity-notice']//span"/>
27+
<element name="assertCacheManagementLayoutsStatus" type="button" selector="//td[@data-column='tags' and contains(text(),'LAYOUT_GENERAL_CACHE_TAG')]/following-sibling::td//span[@class='grid-severity-notice']//span"/>
2628
</section>
2729
</sections>
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,78 @@
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+
<tests xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
9+
xsi:noNamespaceSchemaLocation="urn:magento:mftf:Test/etc/testSchema.xsd">
10+
<test name="AdminValidateLayoutConfigurationTest">
11+
<annotations>
12+
<features value="Cache"/>
13+
<stories value="Cache Management"/>
14+
<title value="Validate Configuration Cache Type"/>
15+
<description value="Validate Configuration Cache Type After Cache Management"/>
16+
<severity value="CRITICAL"/>
17+
<testCaseId value="AC-4231"/>
18+
</annotations>
19+
<before>
20+
<actionGroup ref="AdminLoginActionGroup" stepKey="loginAsAdmin"/>
21+
<createData entity="_defaultCategory" stepKey="createPreReqCategory"/>
22+
<createData entity="_defaultProduct" stepKey="createProduct">
23+
<requiredEntity createDataKey="createPreReqCategory"/>
24+
</createData>
25+
<actionGroup ref="AdminGoToCacheManagementPageActionGroup" stepKey="goToCacheManagementPage"/>
26+
<waitForText selector="{{AdminMessagesSection.assertCacheManagementConfigurationStatus}}" userInput="ENABLED" stepKey="verifyCacheTypeConfigurationIsENABLED"/>
27+
</before>
28+
<after>
29+
<!-- Delete category -->
30+
<deleteData createDataKey="createPreReqCategory" stepKey="deleteCategory"/>
31+
<!-- Delete product -->
32+
<deleteData createDataKey="createProduct" stepKey="deleteProduct"/>
33+
<!--Restore currency symbols to default-->
34+
<actionGroup ref="AdminNavigateToCurrencySymbolsPageActionGroup" stepKey="navigateToCurrencySymbolsPageToRestore"/>
35+
<checkOption selector="{{AdminCurrencySymbolsGridSection.currencyCheckBox}}" stepKey="checkConfigSettingsMessage"/>
36+
<waitForElementClickable selector="{{AdminCurrencySymbolsGridSection.saveCurrencySymbols}}" stepKey="waitForSaveCurrencySymbolAgain"/>
37+
<click selector="{{AdminCurrencySymbolsGridSection.saveCurrencySymbols}}" stepKey="clickSaveCurrencySymbolsToRestore"/>
38+
<!-- Flush Cache-->
39+
<actionGroup ref="CliCacheCleanActionGroup" stepKey="cleanCachesAfterRevokingTheChangesToDefault">
40+
<argument name="tags" value="" />
41+
</actionGroup>
42+
<!-- Log out -->
43+
<actionGroup ref="AdminLogoutActionGroup" stepKey="logout"/>
44+
</after>
45+
<!-- Validate Storefront -->
46+
<actionGroup ref="NavigateToStorefrontForCreatedPageActionGroup" stepKey="navigateToProductStorefront">
47+
<argument name="page" value="$$createProduct.name$$.html"/>
48+
</actionGroup>
49+
<!--Assert Currency symbol-->
50+
<waitForText selector="{{AdminCurrencySymbolsGridSection.currencySymbolOfProduct}}" userInput="$" stepKey="waitForCurrencySymbolInStoreFront"/>
51+
<!-- Navigate To Currency Symbol-->
52+
<actionGroup ref="AdminNavigateToCurrencySymbolsPageActionGroup" stepKey="navigateToCurrencySymbolsPage"/>
53+
<!--Replace standard currency symbol by custom currency symbol-->
54+
<uncheckOption selector="{{AdminCurrencySymbolsGridSection.currencyCheckBox}}" stepKey="uncheckConfigSettingsMessage"/>
55+
<fillField selector="{{AdminCurrencySymbolsGridSection.inputCurrencySymbol}}" userInput="£" stepKey="fillDefaultLabel"/>
56+
<!--Save custom currency symbol-->
57+
<waitForElementClickable selector="{{AdminCurrencySymbolsGridSection.saveCurrencySymbols}}" stepKey="waitForSaveCurrencySymbol"/>
58+
<click selector="{{AdminCurrencySymbolsGridSection.saveCurrencySymbols}}" stepKey="clickSaveCurrencySymbols"/>
59+
<waitForText selector="{{AdminMessagesSection.success}}" userInput="{{AdminSaveCurrencySymbolMessageData.success}}" stepKey="seeSuccessMessage"/>
60+
<!--Navigate To Product Storefront-->
61+
<actionGroup ref="NavigateToStorefrontForCreatedPageActionGroup" stepKey="navigateToProductStorefront1">
62+
<argument name="page" value="$$createProduct.name$$.html"/>
63+
</actionGroup>
64+
<!--Assert Currency symbol is not changed-->
65+
<waitForText selector="{{AdminCurrencySymbolsGridSection.currencySymbolOfProduct}}" userInput="$" stepKey="verifyCurrencySymbolIsNotChangedBeforeFlushingTheChangesInStoreFront"/>
66+
<!--Navigate to Cache Management-->
67+
<actionGroup ref="AdminGoToCacheManagementPageActionGroup" stepKey="goToCacheManagementPage1"/>
68+
<!-- Flush Cache-->
69+
<actionGroup ref="CliCacheCleanActionGroup" stepKey="cleanCachesAfterChangesMade">
70+
<argument name="tags" value="" />
71+
</actionGroup>
72+
<!--Navigate To Product Storefront-->
73+
<actionGroup ref="NavigateToStorefrontForCreatedPageActionGroup" stepKey="navigateToProductStorefront2">
74+
<argument name="page" value="$$createProduct.name$$.html"/>
75+
</actionGroup>
76+
<waitForText selector="{{AdminCurrencySymbolsGridSection.currencySymbolOfProduct}}" userInput="£" stepKey="verifyCurrencySymbolIsChangedAfterFlushingTheChangesInStoreFront"/>
77+
</test>
78+
</tests>
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,74 @@
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+
<tests xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
9+
xsi:noNamespaceSchemaLocation="urn:magento:mftf:Test/etc/testSchema.xsd">
10+
<test name="AdminValidateLayoutsCacheTypeTest">
11+
<annotations>
12+
<features value="Cache"/>
13+
<stories value="Cache Management"/>
14+
<title value="Validate layouts Cache Type"/>
15+
<description value="Validate layouts Cache Type After Cache Management"/>
16+
<severity value="CRITICAL"/>
17+
<testCaseId value="AC-4221"/>
18+
</annotations>
19+
<before>
20+
<actionGroup ref="AdminLoginActionGroup" stepKey="loginAsAdmin"/>
21+
<createData entity="_defaultCategory" stepKey="createPreReqCategory"/>
22+
<createData entity="_defaultProduct" stepKey="createProduct">
23+
<requiredEntity createDataKey="createPreReqCategory"/>
24+
</createData>
25+
</before>
26+
<after>
27+
<!-- Delete category -->
28+
<deleteData createDataKey="createPreReqCategory" stepKey="deleteCategory"/>
29+
<!-- Delete product -->
30+
<deleteData createDataKey="createProduct" stepKey="deleteProduct"/>
31+
<!--Restore currency symbols to default-->
32+
<actionGroup ref="AdminNavigateToCurrencySymbolsPageActionGroup" stepKey="navigateToCurrencySymbolsPageToRestore"/>
33+
<checkOption selector="{{AdminCurrencySymbolsGridSection.currencyCheckBox}}" stepKey="checkConfigSettingsMessage"/>
34+
<waitForElementClickable selector="{{AdminCurrencySymbolsGridSection.saveCurrencySymbols}}" stepKey="waitForSaveCurrencySymbolAgain"/>
35+
<click selector="{{AdminCurrencySymbolsGridSection.saveCurrencySymbols}}" stepKey="clickSaveCurrencySymbolsToRestore"/>
36+
<!-- Flush Cache-->
37+
<actionGroup ref="CliCacheCleanActionGroup" stepKey="cleanCachesAfterRevokingTheChangesToDefault">
38+
<argument name="tags" value="" />
39+
</actionGroup>
40+
<!-- Log out -->
41+
<actionGroup ref="AdminLogoutActionGroup" stepKey="logout"/>
42+
</after>
43+
<!-- Validate Storefront -->
44+
<actionGroup ref="NavigateToStorefrontForCreatedPageActionGroup" stepKey="navigateToProductStorefront">
45+
<argument name="page" value="$$createProduct.name$$.html"/>
46+
</actionGroup>
47+
<!--Assert Currency symbol-->
48+
<waitForText selector="{{AdminCurrencySymbolsGridSection.currencySymbolOfProduct}}" userInput="$" stepKey="waitForCurrencySymbolInStoreFront"/>
49+
<!-- Navigate To Currency Symbol-->
50+
<actionGroup ref="AdminNavigateToCurrencySymbolsPageActionGroup" stepKey="navigateToCurrencySymbolsPage"/>
51+
<!--Replace standard currency symbol by custom currency symbol-->
52+
<uncheckOption selector="{{AdminCurrencySymbolsGridSection.currencyCheckBox}}" stepKey="uncheckConfigSettingsMessage"/>
53+
<fillField selector="{{AdminCurrencySymbolsGridSection.inputCurrencySymbol}}" userInput="£" stepKey="fillDefaultLabel"/>
54+
<!--Save custom currency symbol-->
55+
<waitForElementClickable selector="{{AdminCurrencySymbolsGridSection.saveCurrencySymbols}}" stepKey="waitForSaveCurrencySymbol"/>
56+
<click selector="{{AdminCurrencySymbolsGridSection.saveCurrencySymbols}}" stepKey="clickSaveCurrencySymbols"/>
57+
<waitForText selector="{{AdminMessagesSection.success}}" userInput="{{AdminSaveCurrencySymbolMessageData.success}}" stepKey="seeSuccessMessage"/>
58+
<!--Navigate To Product Storefront-->
59+
<actionGroup ref="NavigateToStorefrontForCreatedPageActionGroup" stepKey="navigateToProductStorefront1">
60+
<argument name="page" value="$$createProduct.name$$.html"/>
61+
</actionGroup>
62+
<!--Assert Currency symbol is not changed-->
63+
<waitForText selector="{{AdminCurrencySymbolsGridSection.currencySymbolOfProduct}}" userInput="$" stepKey="verifyCurrencySymbolIsNotChangedBeforeFlushingTheChangesInStoreFront"/>
64+
<!-- Flush Cache-->
65+
<actionGroup ref="CliCacheCleanActionGroup" stepKey="cleanCachesAfterChangesMade">
66+
<argument name="tags" value="" />
67+
</actionGroup>
68+
<!--Navigate To Product Storefront-->
69+
<actionGroup ref="NavigateToStorefrontForCreatedPageActionGroup" stepKey="navigateToProductStorefront2">
70+
<argument name="page" value="$$createProduct.name$$.html"/>
71+
</actionGroup>
72+
<waitForText selector="{{AdminCurrencySymbolsGridSection.currencySymbolOfProduct}}" userInput="£" stepKey="verifyCurrencySymbolIsChangedAfterFlushingTheChangesInStoreFront"/>
73+
</test>
74+
</tests>

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

+10
Original file line numberDiff line numberDiff line change
@@ -1538,4 +1538,14 @@
15381538
<requiredEntity type="product_option">ProductOptionCheckboxFor2</requiredEntity>
15391539
<requiredEntity type="product_option">ProductOptionNewField</requiredEntity>
15401540
</entity>
1541+
<entity name="SimpleProductWithQty1" type="product" extends="_defaultProduct">
1542+
<data key="name" unique="suffix">Simple Product 3</data>
1543+
<data key="price">1.00</data>
1544+
<data key="urlKey" unique="suffix">Simple Product 3</data>
1545+
<data key="status">1</data>
1546+
<data key="quantity">1</data>
1547+
<data key="weight">1</data>
1548+
<requiredEntity type="product_extension_attribute">EavStock1</requiredEntity>
1549+
<requiredEntity type="custom_attribute_array">CustomAttributeCategoryIds</requiredEntity>
1550+
</entity>
15411551
</entities>

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

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
<argument name="shipping" type="string"/>
1717
</arguments>
1818

19-
<waitForElementClickable selector="{{CheckoutCartSummarySection.shipping}}" time="60" after="assertSubtotal" stepKey="waitForShippingElementToBeVisible"/>
19+
<waitForElementVisible selector="{{CheckoutCartSummarySection.shipping}}" time="60" after="assertSubtotal" stepKey="waitForShippingElementToBeVisible"/>
2020
<waitForText userInput="{{shipping}}" selector="{{CheckoutCartSummarySection.shipping}}" time="30" after="waitForShippingElementToBeVisible" stepKey="assertShipping"/>
2121
</actionGroup>
2222
</actionGroups>

app/code/Magento/CheckoutAgreements/Test/Mftf/Data/TermData.xml

+9
Original file line numberDiff line numberDiff line change
@@ -53,4 +53,13 @@
5353
<data key="checkboxText" unique="suffix">test_checkbox</data>
5454
<data key="content" unique="suffix">TestMessage</data>
5555
</entity>
56+
<entity name="termAndCondition" type="term">
57+
<data key="name" unique="suffix">Test Condition</data>
58+
<data key="isActive">Enabled</data>
59+
<data key="isHtml">Text</data>
60+
<data key="mode">Automatically</data>
61+
<data key="storeView">All Store Views</data>
62+
<data key="checkboxText" unique="suffix">Terms and Conditions</data>
63+
<data key="content" unique="suffix">TestMessage</data>
64+
</entity>
5665
</entities>

app/code/Magento/CheckoutAgreements/Test/Mftf/Section/StorefrontCheckoutAgreementsSection.xml

+2
Original file line numberDiff line numberDiff line change
@@ -13,5 +13,7 @@
1313
<element name="checkoutAgreementButton" type="button" selector="div.checkout-agreements-block > div > div > div > label > button > span"/>
1414
<element name="checkoutAgreementErrorMessage" type="button" selector="div.checkout-agreement.field.choice.required > div.mage-error"/>
1515
<element name="checkoutAgreementCheckboxcheck" type="checkbox" selector="//span[text()='{{agreementname}}']/../../../input[@type='checkbox']" parameterized="true"/>
16+
<element name="checkoutAgreementLink" type="button" selector="//div[@id='checkout-payment-method-load']//label//span[contains(., '{{paymentName}}')]//ancestor::div[contains(@class, 'payment-method _active')]//div[contains(@class, 'checkout-agreements-block')]//span" parameterized="true"/>
17+
<element name="agreementClose" type="button" selector=".agreements-modal._show .action-close"/>
1618
</section>
1719
</sections>

0 commit comments

Comments
 (0)