Skip to content

Commit 5e182e8

Browse files
committed
Merge remote-tracking branch 'origin/MC-34987-236-Serhii' into MC-34987-236
2 parents 5e57a67 + 82bec87 commit 5e182e8

File tree

6 files changed

+106
-87
lines changed

6 files changed

+106
-87
lines changed

app/code/Magento/Bundle/Test/Mftf/Test/AdminShouldBeAbleToMassUpdateAttributesForBundleProductsTest.xml

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -55,9 +55,11 @@
5555
<actionGroup ref="AdminUpdateProductNameAndDescriptionAttributes" stepKey="updateProductAttribute">
5656
<argument name="product" value="UpdateAttributeNameAndDescription"/>
5757
</actionGroup>
58-
<!--Run cron twice-->
59-
<magentoCLI command="cron:run" stepKey="cronRun"/>
60-
<magentoCLI command="cron:run" stepKey="cronRunTwice"/>
58+
<comment userInput="Apply changes" stepKey="cronRun"/>
59+
<actionGroup ref="CliConsumerStartActionGroup" stepKey="cronRunTwice">
60+
<argument name="consumerName" value="{{AdminProductAttributeUpdateMessageConsumerData.consumerName}}"/>
61+
<argument name="maxMessages" value="{{AdminProductAttributeUpdateMessageConsumerData.messageLimit}}"/>
62+
</actionGroup>
6163
<!-- Search for a product with a new name and Open Product -->
6264
<actionGroup ref="filterProductGridByName" stepKey="searchWithNewProductName">
6365
<argument name="product" value="UpdateAttributeNameAndDescription"/>

app/code/Magento/Catalog/Test/Mftf/Test/AdminMassUpdateProductAttributesStoreViewScopeTest.xml

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -133,9 +133,11 @@
133133
<click selector="{{AdminEditProductAttributesSection.Save}}" stepKey="save"/>
134134
<see selector="{{AdminProductMessagesSection.successMessage}}" userInput="Message is added to queue" stepKey="seeAttributeUpateSuccessMsg"/>
135135

136-
<!-- Run cron twice -->
137-
<magentoCLI command="cron:run" stepKey="runCron1"/>
138-
<magentoCLI command="cron:run" stepKey="runCron2"/>
136+
<comment userInput="Apply changes" stepKey="runCron1"/>
137+
<actionGroup ref="CliConsumerStartActionGroup" stepKey="runCron2">
138+
<argument name="consumerName" value="{{AdminProductAttributeUpdateMessageConsumerData.consumerName}}"/>
139+
<argument name="maxMessages" value="{{AdminProductAttributeUpdateMessageConsumerData.messageLimit}}"/>
140+
</actionGroup>
139141
<reloadPage stepKey="refreshPage"/>
140142
<waitForPageLoad stepKey="waitFormToReload1"/>
141143

Lines changed: 86 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,86 @@
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="AdminConfigurableProductBulkUpdateTest">
11+
<annotations>
12+
<features value="ConfigurableProduct"/>
13+
<stories value="Create, Read, Update, Delete"/>
14+
<title value="Admin should be able to bulk update attributes of configurable products"/>
15+
<description value="Admin should be able to bulk update attributes of configurable products"/>
16+
<testCaseId value="MC-88"/>
17+
<group value="ConfigurableProduct"/>
18+
<severity value="AVERAGE"/>
19+
</annotations>
20+
21+
<before>
22+
<createData entity="ApiCategory" stepKey="createCategory"/>
23+
<createData entity="ApiConfigurableProduct" stepKey="createProduct1">
24+
<requiredEntity createDataKey="createCategory"/>
25+
</createData>
26+
<createData entity="ApiConfigurableProduct" stepKey="createProduct2">
27+
<requiredEntity createDataKey="createCategory"/>
28+
</createData>
29+
<createData entity="ApiConfigurableProduct" stepKey="createProduct3">
30+
<requiredEntity createDataKey="createCategory"/>
31+
</createData>
32+
<actionGroup ref="LoginAsAdmin" stepKey="login"/>
33+
</before>
34+
35+
<after>
36+
<deleteData createDataKey="createCategory" stepKey="deleteCategory"/>
37+
<deleteData createDataKey="createProduct1" stepKey="deleteFirstProduct"/>
38+
<deleteData createDataKey="createProduct2" stepKey="deleteSecondProduct"/>
39+
<deleteData createDataKey="createProduct3" stepKey="deleteThirdProduct"/>
40+
<amOnPage url="{{AdminProductIndexPage.url}}" stepKey="goToProductList"/>
41+
<waitForPageLoad stepKey="waitForPageLoad"/>
42+
<actionGroup ref="clearFiltersAdminDataGrid" stepKey="clearProductsGridFilters"/>
43+
<actionGroup ref="logout" stepKey="logout"/>
44+
</after>
45+
46+
<!-- Search for prefix of the 3 products we created via api -->
47+
<amOnPage url="{{AdminProductIndexPage.url}}" stepKey="goToProductList"/>
48+
<waitForPageLoad stepKey="wait1"/>
49+
<conditionalClick selector="{{AdminProductGridFilterSection.clearAll}}" dependentSelector="{{AdminProductGridFilterSection.clearAll}}" visible="true" stepKey="clearAll"/>
50+
<actionGroup ref="searchProductGridByKeyword" stepKey="searchForProduct">
51+
<argument name="keyword" value="ApiConfigurableProduct.name"/>
52+
</actionGroup>
53+
54+
<!-- Select all, then start the bulk update attributes flow -->
55+
<click selector="{{AdminProductGridSection.multicheckDropdown}}" stepKey="openMulticheckDropdown"/>
56+
<click selector="{{AdminProductGridSection.multicheckOption('Select All')}}" stepKey="selectAllProductInFilteredGrid"/>
57+
<click selector="{{AdminProductGridSection.bulkActionDropdown}}" stepKey="clickActionDropdown"/>
58+
<click selector="{{AdminProductGridSection.bulkActionOption('Update attributes')}}" stepKey="clickBulkUpdate"/>
59+
<waitForPageLoad stepKey="wait2"/>
60+
61+
<!-- Update the description -->
62+
<click selector="{{AdminUpdateAttributesSection.toggleDescription}}" stepKey="clickToggleDescription"/>
63+
<fillField selector="{{AdminUpdateAttributesSection.description}}" userInput="MFTF automation!" stepKey="fillDescription"/>
64+
<click selector="{{AdminEditProductAttributesSection.Save}}" stepKey="clickSave"/>
65+
<waitForElementVisible selector="{{AdminProductMessagesSection.successMessage}}" time="60" stepKey="waitForSuccessMessage"/>
66+
<see selector="{{AdminProductMessagesSection.successMessage}}" userInput="Message is added to queue" stepKey="seeAttributeUpdateSuccessMsg"/>
67+
68+
<comment userInput="Apply changes" stepKey="runCron1"/>
69+
<comment userInput="Run consumer to apply changes" stepKey="runCron2"/>
70+
<actionGroup ref="CliConsumerStartActionGroup" stepKey="reindex">
71+
<argument name="consumerName" value="{{AdminProductAttributeUpdateMessageConsumerData.consumerName}}"/>
72+
<argument name="maxMessages" value="{{AdminProductAttributeUpdateMessageConsumerData.messageLimit}}"/>
73+
</actionGroup>
74+
75+
<!-- Check storefront for description -->
76+
<amOnPage url="{{StorefrontProductPage.url($$createProduct1.custom_attributes[url_key]$$)}}" stepKey="goToFirstProductPageOnStorefront"/>
77+
<waitForPageLoad stepKey="waitForFirstProductPageLoad"/>
78+
<see selector="{{StorefrontProductInfoMainSection.productDescription}}" userInput="MFTF automation!" stepKey="seeFirstDescription"/>
79+
<amOnPage url="{{StorefrontProductPage.url($$createProduct2.custom_attributes[url_key]$$)}}" stepKey="goToSecondProductPageOnStorefront"/>
80+
<waitForPageLoad stepKey="waitForSecondProductPageLoad"/>
81+
<see selector="{{StorefrontProductInfoMainSection.productDescription}}" userInput="MFTF automation!" stepKey="seeSecondDescription"/>
82+
<amOnPage url="{{StorefrontProductPage.url($$createProduct3.custom_attributes[url_key]$$)}}" stepKey="goToThirdProductPageOnStorefront"/>
83+
<waitForPageLoad stepKey="waitForThirdProductPageLoad"/>
84+
<see selector="{{StorefrontProductInfoMainSection.productDescription}}" userInput="MFTF automation!" stepKey="seeThirdDescription"/>
85+
</test>
86+
</tests>

app/code/Magento/ConfigurableProduct/Test/Mftf/Test/AdminConfigurableProductUpdateTest.xml

Lines changed: 0 additions & 75 deletions
Original file line numberDiff line numberDiff line change
@@ -8,81 +8,6 @@
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="AdminConfigurableProductBulkUpdateTest">
12-
<annotations>
13-
<features value="ConfigurableProduct"/>
14-
<stories value="Create, Read, Update, Delete"/>
15-
<title value="admin should be able to bulk update attributes of configurable products"/>
16-
<description value="admin should be able to bulk update attributes of configurable products"/>
17-
<testCaseId value="MC-88"/>
18-
<group value="ConfigurableProduct"/>
19-
<severity value="AVERAGE"/>
20-
</annotations>
21-
22-
<before>
23-
<createData entity="ApiCategory" stepKey="createCategory"/>
24-
<createData entity="ApiConfigurableProduct" stepKey="createProduct1">
25-
<requiredEntity createDataKey="createCategory"/>
26-
</createData>
27-
<createData entity="ApiConfigurableProduct" stepKey="createProduct2">
28-
<requiredEntity createDataKey="createCategory"/>
29-
</createData>
30-
<createData entity="ApiConfigurableProduct" stepKey="createProduct3">
31-
<requiredEntity createDataKey="createCategory"/>
32-
</createData>
33-
<actionGroup ref="LoginAsAdmin" stepKey="login"/>
34-
</before>
35-
36-
<after>
37-
<deleteData createDataKey="createCategory" stepKey="deleteCategory"/>
38-
<deleteData createDataKey="createProduct1" stepKey="deleteFirstProduct"/>
39-
<deleteData createDataKey="createProduct2" stepKey="deleteSecondProduct"/>
40-
<deleteData createDataKey="createProduct3" stepKey="deleteThirdProduct"/>
41-
<amOnPage url="{{AdminProductIndexPage.url}}" stepKey="goToProductList"/>
42-
<waitForPageLoad stepKey="waitForPageLoad"/>
43-
<actionGroup ref="clearFiltersAdminDataGrid" stepKey="clearProductsGridFilters"/>
44-
<actionGroup ref="logout" stepKey="logout"/>
45-
</after>
46-
47-
<!-- Search for prefix of the 3 products we created via api -->
48-
<amOnPage url="{{AdminProductIndexPage.url}}" stepKey="goToProductList"/>
49-
<waitForPageLoad stepKey="wait1"/>
50-
<conditionalClick selector="{{AdminProductGridFilterSection.clearAll}}" dependentSelector="{{AdminProductGridFilterSection.clearAll}}" visible="true" stepKey="clearAll"/>
51-
<actionGroup ref="searchProductGridByKeyword" stepKey="searchForProduct">
52-
<argument name="keyword" value="ApiConfigurableProduct.name"/>
53-
</actionGroup>
54-
55-
<!-- Select all, then start the bulk update attributes flow -->
56-
<click selector="{{AdminProductGridSection.multicheckDropdown}}" stepKey="openMulticheckDropdown"/>
57-
<click selector="{{AdminProductGridSection.multicheckOption('Select All')}}" stepKey="selectAllProductInFilteredGrid"/>
58-
<click selector="{{AdminProductGridSection.bulkActionDropdown}}" stepKey="clickActionDropdown"/>
59-
<click selector="{{AdminProductGridSection.bulkActionOption('Update attributes')}}" stepKey="clickBulkUpdate"/>
60-
<waitForPageLoad stepKey="wait2"/>
61-
62-
<!-- Update the description -->
63-
<click selector="{{AdminUpdateAttributesSection.toggleDescription}}" stepKey="clickToggleDescription"/>
64-
<fillField selector="{{AdminUpdateAttributesSection.description}}" userInput="MFTF automation!" stepKey="fillDescription"/>
65-
<click selector="{{AdminEditProductAttributesSection.Save}}" stepKey="clickSave"/>
66-
<waitForElementVisible selector="{{AdminProductMessagesSection.successMessage}}" time="60" stepKey="waitForSuccessMessage"/>
67-
<see selector="{{AdminProductMessagesSection.successMessage}}" userInput="Message is added to queue" stepKey="seeAttributeUpdateSuccessMsg"/>
68-
69-
<!-- Run cron twice -->
70-
<magentoCLI command="cron:run" arguments="--group=consumers" stepKey="runCron1"/>
71-
<magentoCLI command="cron:run" arguments="--group=consumers" stepKey="runCron2"/>
72-
<magentoCLI command="indexer:reindex" stepKey="reindex"/>
73-
74-
<!-- Check storefront for description -->
75-
<amOnPage url="{{StorefrontProductPage.url($$createProduct1.custom_attributes[url_key]$$)}}" stepKey="goToFirstProductPageOnStorefront"/>
76-
<waitForPageLoad stepKey="waitForFirstProductPageLoad"/>
77-
<see selector="{{StorefrontProductInfoMainSection.productDescription}}" userInput="MFTF automation!" stepKey="seeFirstDescription"/>
78-
<amOnPage url="{{StorefrontProductPage.url($$createProduct2.custom_attributes[url_key]$$)}}" stepKey="goToSecondProductPageOnStorefront"/>
79-
<waitForPageLoad stepKey="waitForSecondProductPageLoad"/>
80-
<see selector="{{StorefrontProductInfoMainSection.productDescription}}" userInput="MFTF automation!" stepKey="seeSecondDescription"/>
81-
<amOnPage url="{{StorefrontProductPage.url($$createProduct3.custom_attributes[url_key]$$)}}" stepKey="goToThirdProductPageOnStorefront"/>
82-
<waitForPageLoad stepKey="waitForThirdProductPageLoad"/>
83-
<see selector="{{StorefrontProductInfoMainSection.productDescription}}" userInput="MFTF automation!" stepKey="seeThirdDescription"/>
84-
</test>
85-
8611
<test name="AdminConfigurableProductRemoveAnOptionTest">
8712
<annotations>
8813
<features value="ConfigurableProduct"/>

app/code/Magento/SalesRule/Test/Mftf/Test/AdminCreateCartPriceRuleForGeneratedCouponTest.xml

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -55,9 +55,11 @@
5555
<click selector="{{AdminCartPriceRulesFormSection.generateCouponsButton}}" stepKey="clickGenerate"/>
5656
<see selector="{{AdminCartPriceRulesFormSection.successMessage}}" userInput="Message is added to queue, wait to get your coupons soon" stepKey="seeGenerationSuccess"/>
5757

58-
<!-- Run cron twice -->
59-
<magentoCLI command="cron:run" stepKey="runCron1"/>
60-
<magentoCLI command="cron:run" stepKey="runCron2"/>
58+
<comment userInput="Apply changes" stepKey="runCron1"/>
59+
<actionGroup ref="CliConsumerStartActionGroup" stepKey="runCron2">
60+
<argument name="consumerName" value="{{AdminCodeGeneratorMessageConsumerData.consumerName}}"/>
61+
<argument name="maxMessages" value="{{AdminCodeGeneratorMessageConsumerData.messageLimit}}"/>
62+
</actionGroup>
6163
<reloadPage stepKey="refreshPage"/>
6264
<waitForPageLoad stepKey="waitFormToReload1"/>
6365
<click selector="{{AdminCartPriceRulesFormSection.manageCouponCodesHeader}}" stepKey="expandCouponSection2"/>

app/code/Magento/SalesRule/Test/Mftf/Test/StorefrontAutoGeneratedCouponCodeTest.xml

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -59,9 +59,11 @@
5959
<see selector="{{AdminCartPriceRulesFormSection.successMessage}}" userInput="Message is added to queue, wait to get your coupons soon"
6060
stepKey="seeSuccessMessage"/>
6161

62-
<!-- Run cron twice -->
63-
<magentoCLI command="cron:run" stepKey="runCron1"/>
64-
<magentoCLI command="cron:run" stepKey="runCron2"/>
62+
<comment userInput="Apply changes" stepKey="runCron1"/>
63+
<actionGroup ref="CliConsumerStartActionGroup" stepKey="runCron2">
64+
<argument name="consumerName" value="{{AdminCodeGeneratorMessageConsumerData.consumerName}}"/>
65+
<argument name="maxMessages" value="{{AdminCodeGeneratorMessageConsumerData.messageLimit}}"/>
66+
</actionGroup>
6567
<reloadPage stepKey="refreshPage"/>
6668
<waitForPageLoad stepKey="waitFormToReload1"/>
6769
<conditionalClick selector="{{AdminCartPriceRulesFormSection.manageCouponCodesHeader}}"

0 commit comments

Comments
 (0)