Skip to content

Commit 703dadb

Browse files
committed
ACQE-8176: [Sorting] Check whether customer/guest is able to sort the product in the frontend when Remember Category Pagination is enabled
- Removed reindex step in testfile
1 parent e194cf7 commit 703dadb

File tree

1 file changed

+16
-14
lines changed

1 file changed

+16
-14
lines changed

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

Lines changed: 16 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@
4040
<requiredEntity createDataKey="category"/>
4141
</createData>
4242
<createData entity="Simple_US_Customer" stepKey="customer"/>
43-
<!-- Precondition Step.2: "Remember Category Pagination" should be enabled in the configuration -->
43+
<!-- Precondition Step.2: Enable Remember Category Pagination in configuration -->
4444
<actionGroup ref="AdminEnableRememberCategoryPaginationActionGroup" stepKey="enableRememberCategoryPagination"/>
4545
</before>
4646
<after>
@@ -60,6 +60,9 @@
6060
<actionGroup ref="LoginToStorefrontActionGroup" stepKey="customerLogin">
6161
<argument name="Customer" value="$$customer$$"/>
6262
</actionGroup>
63+
<actionGroup ref="CliIndexerReindexActionGroup" stepKey="reindex">
64+
<argument name="indices" value=""/>
65+
</actionGroup>
6366
<!-- Step 2: Search for the product Bag -->
6467
<actionGroup ref="StoreFrontQuickSearchActionGroup" stepKey="searchByCreatedTerm">
6568
<argument name="query" value="Bag"/>
@@ -72,59 +75,58 @@
7275
<actionGroup ref="StorefrontCategoryPageSortProductActionGroup" stepKey="sortProductByPriceAscending"/>
7376
<!-- Step 4: Click the arrow to sort by price desc/asc by clicking on UP/Down arrow. -->
7477
<actionGroup ref="StorefrontCategoryPageSortDescendingActionGroup" stepKey="setDescendingDirection"/>
75-
<actionGroup ref="StorefrontCategoryPageSortAscendingActionGroup" stepKey="setAscendingDirection"/>
76-
<selectOption selector="{{StorefrontCategoryTopToolbarSection.showDropdown}}" userInput="24" stepKey="selectShowProducts"/>
78+
7779
<actionGroup ref="AssertStorefrontElementVisibleActionGroup" stepKey="seeProductFirstPosition">
7880
<argument name="selector" value="{{StorefrontCategoryMainSection.lineProductName('1')}}"/>
79-
<argument name="userInput" value="$$product3.name$$"/>
81+
<argument name="userInput" value="$$product1.name$$"/>
8082
</actionGroup>
8183
<actionGroup ref="AssertStorefrontElementVisibleActionGroup" stepKey="seeProductSecondPosition">
8284
<argument name="selector" value="{{StorefrontCategoryMainSection.lineProductName('2')}}"/>
8385
<argument name="userInput" value="$$product2.name$$"/>
8486
</actionGroup>
8587
<actionGroup ref="AssertStorefrontElementVisibleActionGroup" stepKey="seeProductThirdPosition">
8688
<argument name="selector" value="{{StorefrontCategoryMainSection.lineProductName('3')}}"/>
87-
<argument name="userInput" value="$$product1.name$$"/>
89+
<argument name="userInput" value="$$product3.name$$"/>
8890
</actionGroup>
8991
<!-- Step 5: Try clicking multiple times on arrow. -->
90-
<actionGroup ref="StorefrontCategoryPageSortDescendingActionGroup" stepKey="setDescendingDirection1"/>
92+
<actionGroup ref="StorefrontCategoryPageSortAscendingActionGroup" stepKey="setAscendingDirection"/>
9193
<actionGroup ref="AssertStorefrontElementVisibleActionGroup" stepKey="seeProductFirstPosition1">
9294
<argument name="selector" value="{{StorefrontCategoryMainSection.lineProductName('1')}}"/>
93-
<argument name="userInput" value="$$product1.name$$"/>
95+
<argument name="userInput" value="$$product3.name$$"/>
9496
</actionGroup>
9597
<actionGroup ref="AssertStorefrontElementVisibleActionGroup" stepKey="seeProductSecondPosition1">
9698
<argument name="selector" value="{{StorefrontCategoryMainSection.lineProductName('2')}}"/>
9799
<argument name="userInput" value="$$product2.name$$"/>
98100
</actionGroup>
99101
<actionGroup ref="AssertStorefrontElementVisibleActionGroup" stepKey="seeProductThirdPosition1">
100102
<argument name="selector" value="{{StorefrontCategoryMainSection.lineProductName('3')}}"/>
101-
<argument name="userInput" value="$$product3.name$$"/>
103+
<argument name="userInput" value="$$product1.name$$"/>
102104
</actionGroup>
103-
<actionGroup ref="StorefrontCategoryPageSortAscendingActionGroup" stepKey="setDescendingDirection2"/>
105+
<actionGroup ref="StorefrontCategoryPageSortDescendingActionGroup" stepKey="setDescendingDirection2"/>
104106
<actionGroup ref="AssertStorefrontElementVisibleActionGroup" stepKey="seeProductFirstPosition2">
105107
<argument name="selector" value="{{StorefrontCategoryMainSection.lineProductName('1')}}"/>
106-
<argument name="userInput" value="$$product3.name$$"/>
108+
<argument name="userInput" value="$$product1.name$$"/>
107109
</actionGroup>
108110
<actionGroup ref="AssertStorefrontElementVisibleActionGroup" stepKey="seeProductSecondPosition2">
109111
<argument name="selector" value="{{StorefrontCategoryMainSection.lineProductName('2')}}"/>
110112
<argument name="userInput" value="$$product2.name$$"/>
111113
</actionGroup>
112114
<actionGroup ref="AssertStorefrontElementVisibleActionGroup" stepKey="seeProductThirdPosition2">
113115
<argument name="selector" value="{{StorefrontCategoryMainSection.lineProductName('3')}}"/>
114-
<argument name="userInput" value="$$product1.name$$"/>
116+
<argument name="userInput" value="$$product3.name$$"/>
115117
</actionGroup>
116-
<actionGroup ref="StorefrontCategoryPageSortDescendingActionGroup" stepKey="setDescendingDirection3"/>
118+
<actionGroup ref="StorefrontCategoryPageSortAscendingActionGroup" stepKey="setAscendingDirection3"/>
117119
<actionGroup ref="AssertStorefrontElementVisibleActionGroup" stepKey="seeProductFirstPosition3">
118120
<argument name="selector" value="{{StorefrontCategoryMainSection.lineProductName('1')}}"/>
119-
<argument name="userInput" value="$$product1.name$$"/>
121+
<argument name="userInput" value="$$product3.name$$"/>
120122
</actionGroup>
121123
<actionGroup ref="AssertStorefrontElementVisibleActionGroup" stepKey="seeProductSecondPosition3">
122124
<argument name="selector" value="{{StorefrontCategoryMainSection.lineProductName('2')}}"/>
123125
<argument name="userInput" value="$$product2.name$$"/>
124126
</actionGroup>
125127
<actionGroup ref="AssertStorefrontElementVisibleActionGroup" stepKey="seeProductThirdPosition3">
126128
<argument name="selector" value="{{StorefrontCategoryMainSection.lineProductName('3')}}"/>
127-
<argument name="userInput" value="$$product3.name$$"/>
129+
<argument name="userInput" value="$$product1.name$$"/>
128130
</actionGroup>
129131
</test>
130132
</tests>

0 commit comments

Comments
 (0)