Skip to content

Commit d75663f

Browse files
committed
ACQE-4048: [MFTF PR TESTS] AdminApplyChangePriceForConfigurableProductWithAssignedSimpleProductsTest
- Stabilizing AdminApplyChangePriceForConfigurableProductWithAssignedSimpleProductsTest
1 parent 54ddda1 commit d75663f

File tree

1 file changed

+24
-21
lines changed

1 file changed

+24
-21
lines changed

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

Lines changed: 24 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -19,21 +19,21 @@
1919

2020
<before>
2121
<actionGroup ref="AdminLoginActionGroup" stepKey="loginAsAdmin"/>
22-
<actionGroup ref="UpdateAllIndexerByScheduleActionGroup" stepKey="updateAnIndexerBySchedule"/>
23-
<magentoCLI command="config:set {{EnableFlatRateConfigData.path}} {{EnableFlatRateConfigData.value}}" stepKey="enableFlatRate"/>
24-
<magentoCLI command="indexer:reindex" stepKey="performReindex"/>
25-
<magentoCLI command="cache:flush" stepKey="cleanCache"/>
22+
<comment userInput="BIC workaround" stepKey="updateAnIndexerBySchedule"/>
23+
<comment userInput="BIC workaround" stepKey="enableFlatRate"/>
24+
<comment userInput="BIC workaround" stepKey="performReindex"/>
25+
<comment userInput="BIC workaround" stepKey="cleanCache"/>
2626
</before>
2727

2828
<after>
2929
<deleteData createDataKey="createFirstConfigProduct" stepKey="deleteConfigProduct"/>
3030
<deleteData createDataKey="createFirstConfigFirstChildProduct" stepKey="deleteFirstConfigFirstChildProduct"/>
3131
<deleteData createDataKey="firstSimpleCategory" stepKey="deleteCategory"/>
3232
<deleteData createDataKey="createFirstConfigProductAttribute" stepKey="deleteFirstConfigProductAttribute"/>
33-
<comment userInput="The test was moved to elasticsearch suite" stepKey="resetCatalogSearchConfiguration"/>
34-
<actionGroup ref="AdminAllIndexerSetUpdateOnSaveActionGroup" stepKey="resetIndexerBackToOriginalState"/>
35-
<magentoCLI command="indexer:reindex" stepKey="performReindex"/>
36-
<magentoCLI command="cache:flush" stepKey="cleanCache"/>
33+
<comment userInput="BIC workaround" stepKey="resetCatalogSearchConfiguration"/>
34+
<comment userInput="BIC workaround" stepKey="resetIndexerBackToOriginalState"/>
35+
<comment userInput="BIC workaround" stepKey="performReindex"/>
36+
<comment userInput="BIC workaround" stepKey="cleanCache"/>
3737
<actionGroup ref="AdminLogoutActionGroup" stepKey="logoutOfAdmin"/>
3838
</after>
3939

@@ -79,10 +79,14 @@
7979
<requiredEntity createDataKey="createFirstConfigFirstChildProduct"/>
8080
</createData>
8181

82-
<!-- Perform CLI reindex -->
82+
<!-- Reindex -->
8383
<actionGroup ref="CliIndexerReindexActionGroup" stepKey="reindex">
8484
<argument name="indices" value=""/>
8585
</actionGroup>
86+
<actionGroup ref="CliCacheCleanActionGroup" stepKey="cleanCache">
87+
<argument name="tags" value="full_page"/>
88+
</actionGroup>
89+
8690
<!-- Assert first product in category -->
8791
<amOnPage url="{{StorefrontCategoryPage.url($$firstSimpleCategory.custom_attributes[url_key]$$)}}" stepKey="goToFirstCategoryPageStorefront"/>
8892
<waitForPageLoad stepKey="waitForFirstCategoryPageLoad"/>
@@ -92,24 +96,23 @@
9296
<argument name="expectedPrice" value="$$createFirstConfigFirstChildProduct.price$$"/>
9397
</actionGroup>
9498

95-
<!-- Search default simple product in grid -->
96-
<actionGroup ref="AdminClearFiltersActionGroup" stepKey="openProductCatalogPage"/>
97-
<comment userInput="Comment is added to preserve the step key for backward compatibility" stepKey="filterProductGrid"/>
98-
<actionGroup ref="OpenEditProductOnBackendActionGroup" stepKey="clickFirstRowToOpenDefaultSimpleProduct">
99-
<argument name="product" value="$$createFirstConfigFirstChildProduct$$"/>
100-
</actionGroup>
101-
<comment userInput="Comment is added to preserve the step key for backward compatibility" stepKey="waitUntilProductIsOpened"/>
102-
10399
<!-- Update default simple product with price -->
100+
<comment userInput="BIC workaround" stepKey="openProductCatalogPage"/>
101+
<comment userInput="BIC workaround" stepKey="filterProductGrid"/>
102+
<comment userInput="BIC workaround" stepKey="clickFirstRowToOpenDefaultSimpleProduct"/>
103+
<comment userInput="BIC workaround" stepKey="waitUntilProductIsOpened"/>
104+
<actionGroup ref="AdminProductPageOpenByIdActionGroup" stepKey="openProductEditPage">
105+
<argument name="productId" value="$createFirstConfigFirstChildProduct.id$"/>
106+
</actionGroup>
104107
<fillField selector="{{AdminProductFormSection.productPrice}}" userInput="150" stepKey="fillSimpleProductPrice"/>
105-
<actionGroup ref="AdminProductFormSaveButtonClickActionGroup" stepKey="clickButtonSave"/>
108+
<actionGroup ref="AdminProductFormSaveActionGroup" stepKey="clickButtonSave"/>
106109

107110
<!-- Verify customer see success message -->
108-
<see selector="{{AdminProductFormSection.successMessage}}" userInput="You saved the product." stepKey="seeAssertSimpleProductSaveSuccessMessage"/>
111+
<waitForText selector="{{AdminProductFormSection.successMessage}}" userInput="You saved the product." stepKey="seeAssertSimpleProductSaveSuccessMessage"/>
109112

110113
<!-- Assert first product in category -->
111-
<magentoCLI command="cron:run" stepKey="runCron1"/>
112-
<wait time="60" stepKey="waitForUpdateStarts"/>
114+
<comment userInput="BIC workaround" stepKey="runCron1"/>
115+
<comment userInput="BIC workaround" stepKey="waitForUpdateStarts"/>
113116

114117
<amOnPage url="{{StorefrontCategoryPage.url($$firstSimpleCategory.custom_attributes[url_key]$$)}}" stepKey="goToFirstCategoryPageStorefront1"/>
115118
<waitForPageLoad stepKey="waitForFirstCategoryPageLoad1"/>

0 commit comments

Comments
 (0)