Skip to content

Commit 069d343

Browse files
author
Alexey Yakimovich
committed
MC-10971: [Magento Cloud] - Unable to Scope Catalog Price rules by custom product attribute
- Fixed MFTF test;
1 parent d1c575b commit 069d343

File tree

2 files changed

+6
-2
lines changed

2 files changed

+6
-2
lines changed

app/code/Magento/CatalogRule/Test/Mftf/ActionGroup/CatalogPriceRuleActionGroup.xml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,6 @@
4545
<click stepKey="addNewRule" selector="{{AdminGridMainControls.add}}"/>
4646
<fillField selector="{{AdminNewCatalogPriceRule.ruleName}}" userInput="{{catalogRule.name}}" stepKey="fillName" />
4747
<fillField selector="{{AdminNewCatalogPriceRule.description}}" userInput="{{catalogRule.description}}" stepKey="fillDescription" />
48-
<click selector="{{AdminCategoryBasicFieldSection.enableCategoryLabel}}" stepKey="selectActive" />
4948
<selectOption selector="{{AdminNewCatalogPriceRule.websites}}" parameterArray="{{catalogRule.website_ids}}" stepKey="selectSite" />
5049
<click stepKey="openActionDropdown" selector="{{AdminNewCatalogPriceRule.actionsTab}}"/>
5150
<fillField stepKey="fillDiscountValue" selector="{{AdminNewCatalogPriceRuleActions.discountAmount}}" userInput="{{catalogRule.discount_amount}}"/>

app/code/Magento/CatalogRule/Test/Mftf/Test/AdminEnableAttributeIsUndefinedCatalogPriceRuleTest.xml

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -106,15 +106,20 @@
106106
</createData>
107107

108108
<!--Create new Catalog Price Rule-->
109+
<amOnPage url="{{CatalogRulePage.url}}" stepKey="goToPriceRulePage1"/>
110+
<waitForPageLoad stepKey="waitForPriceRulePage1"/>
109111
<actionGroup ref="createCatalogPriceRule" stepKey="createCatalogPriceRule1">
110112
<argument name="catalogRule" value="CatalogRuleWithAllCustomerGroups"/>
111113
</actionGroup>
114+
<actionGroup ref="selectNotLoggedInCustomerGroupActionGroup" stepKey="selectCustomerGroup1"/>
112115
<actionGroup ref="CreateCatalogPriceRuleConditionWithAttribute" stepKey="createCatalogPriceRuleCondition1">
113116
<argument name="attributeName" value="$$createSecondProductAttribute.attribute[frontend_labels][0][label]$$"/>
114117
<argument name="targetValue" value="is"/>
115118
<argument name="targetSelectValue" value="is undefined"/>
116119
</actionGroup>
117-
<click selector="{{AdminNewCatalogPriceRule.save}}" stepKey="saveRule1"/>
120+
<click selector="{{AdminNewCatalogPriceRule.saveAndApply}}" stepKey="clickSaveAndApplyRules1"/>
121+
<magentoCLI command="indexer:reindex" stepKey="reindex1"/>
122+
<magentoCLI command="cache:flush" stepKey="flushCache1"/>
118123

119124
<!--Check Catalog Price Rule for third product-->
120125
<amOnPage url="{{StorefrontProductPage.url($$createThirdProduct.custom_attributes[url_key]$$)}}" stepKey="navigateToThirdProductPage"/>

0 commit comments

Comments
 (0)