Skip to content

Commit e01c6ef

Browse files
MC-36965: Create automated test for "[ES] Search with Layered Navigation and different types of attribute products.
1 parent 0df8611 commit e01c6ef

File tree

5 files changed

+9
-9
lines changed

5 files changed

+9
-9
lines changed

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

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
<element name="filterOption" type="text" selector=".filter-options-content .item"/>
1515
<element name="optionQty" type="text" selector=".filter-options-content .item .count"/>
1616
<element name="filterOptionByLabel" type="button" selector=" div.filter-options-item div[data-option-label='{{optionLabel}}']" parameterized="true"/>
17-
<element name="removeFilter" type="button" selector="div.filter-current .remove"/>
17+
<element name="removeFilter" type="button" selector="div.filter-current .remove" timeout="30"/>
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"/>
2020
<element name="enabledFilterOptionItemByLabel" type="text" selector="//div[@class='filter-options']//li[@class='item']//a[contains(text(), '{{optionLabel}}')]" parameterized="true"/>

app/code/Magento/LayeredNavigation/Test/Mftf/ActionGroup/StorefrontAssertAppliedFilterActionGroup.xml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,8 @@
1313
<description>Asserts applied filter label and value on category page is layered navigation block.</description>
1414
</annotations>
1515
<arguments>
16-
<argument name="attributeLabel" type="string" defaultValue=""/>
17-
<argument name="attributeOptionLabel" type="string" defaultValue=""/>
16+
<argument name="attributeLabel" type="string"/>
17+
<argument name="attributeOptionLabel" type="string"/>
1818
</arguments>
1919
<see selector="{{StorefrontLayeredNavigationSection.appliedFilterLabel('1')}}" userInput="{{attributeLabel}}" stepKey="seeAppliedFilterLabel"/>
2020
<see selector="{{StorefrontLayeredNavigationSection.appliedFilterValue('1')}}" userInput="{{attributeOptionLabel}}" stepKey="seeAppliedFilterValue"/>

app/code/Magento/LayeredNavigation/Test/Mftf/ActionGroup/StorefrontFilterCategoryPageByAttributeOptionActionGroup.xml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,11 +13,12 @@
1313
<description>Filters category page by given filterable attribute and attribute option is layered navigation block.</description>
1414
</annotations>
1515
<arguments>
16-
<argument name="attributeLabel" type="string" defaultValue=""/>
17-
<argument name="attributeOptionLabel" type="string" defaultValue=""/>
16+
<argument name="attributeLabel" type="string"/>
17+
<argument name="attributeOptionLabel" type="string"/>
1818
</arguments>
1919
<waitForElementVisible selector="{{StorefrontCategorySidebarSection.filterOptionsTitle(attributeLabel)}}" stepKey="waitForFilterVisible"/>
2020
<conditionalClick selector="{{StorefrontCategorySidebarSection.filterOptionsTitle(attributeLabel)}}" dependentSelector="{{StorefrontCategorySidebarSection.activeFilterOptions}}" visible="false" stepKey="clickToExpandFilter"/>
2121
<click selector="{{StorefrontCategorySidebarSection.enabledFilterOptionItemByLabel(attributeOptionLabel)}}" stepKey="clickOnOption"/>
22+
<waitForPageLoad stepKey="waitForPageLoad"/>
2223
</actionGroup>
2324
</actionGroups>

app/code/Magento/LayeredNavigation/Test/Mftf/Section/LayeredNavigationSection/StorefrontLayeredNavigationSection.xml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
xsi:noNamespaceSchemaLocation="urn:magento:mftf:Page/etc/SectionObject.xsd">
1010
<section name="StorefrontLayeredNavigationSection">
1111
<element name="shoppingOptionsByName" type="button" selector="//*[text()='Shopping Options']/..//*[contains(text(),'{{arg}}')]" parameterized="true"/>
12-
<element name="appliedFilterLabel" type="text" selector=".filter-current .items > li.item:nth-of-type({{position}}) > span.filter-label" parameterized="true" timeout="30"/>
13-
<element name="appliedFilterValue" type="text" selector=".filter-current .items > li.item:nth-of-type({{position}}) > span.filter-value" parameterized="true" timeout="30"/>
12+
<element name="appliedFilterLabel" type="text" selector=".filter-current .items > li.item:nth-of-type({{position}}) > span.filter-label" parameterized="true"/>
13+
<element name="appliedFilterValue" type="text" selector=".filter-current .items > li.item:nth-of-type({{position}}) > span.filter-value" parameterized="true"/>
1414
</section>
1515
</sections>

app/code/Magento/LayeredNavigation/Test/Mftf/Test/StorefrontDropdownAttributeInLayeredNavigationTest.xml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
<title value="[ES] Search with Layered Navigation and different types of attribute products."/>
1616
<description value="Filtering by dropdown attribute in Layered navigation"/>
1717
<severity value="CRITICAL"/>
18-
<testCaseId value="MC-28963"/>
18+
<testCaseId value="MC-36326"/>
1919
<group value="layeredNavigation"/>
2020
<group value="catalog"/>
2121
<group value="SearchEngineElasticsearch"/>
@@ -83,7 +83,6 @@
8383
<argument name="productName" value="$createSecondProduct.name$"/>
8484
</actionGroup>
8585
<click selector="{{StorefrontCategorySidebarSection.removeFilter}}" stepKey="removeSideBarFilter"/>
86-
<waitForPageLoad stepKey="waitForPageLoad"/>
8786
<actionGroup ref="StorefrontFilterCategoryPageByAttributeOptionActionGroup" stepKey="filterCategoryBySecondOption">
8887
<argument name="attributeLabel" value="$createDropdownProductAttribute.attribute[frontend_labels][0][label]$"/>
8988
<argument name="attributeOptionLabel" value="$getSecondDropdownProductAttributeOption.label$"/>

0 commit comments

Comments
 (0)