Skip to content

Commit e8bbe91

Browse files
Merge remote-tracking branch 'remotes/github/MC-17012' into EPAM-PR-69
2 parents 446d5b0 + bac4ab5 commit e8bbe91

File tree

3 files changed

+38
-24
lines changed

3 files changed

+38
-24
lines changed

app/code/Magento/CatalogSearch/Test/Mftf/Section/AdminCatalogSearchTermIndexSection.xml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,5 +21,6 @@
2121
<element name="emptyRecords" type="text" selector="//tr[@class='data-grid-tr-no-data even']/td[@class='empty-text']"/>
2222
<element name="gridRow" type="text" selector="//tr[@data-role='row']"/>
2323
<element name="numberOfSearchTermResults" type="text" selector="//tr[@data-role='row']/td[@data-column='num_results']"/>
24+
<element name="selectMassActionCheckbox" type="select" selector="//select[@id='search_term_grid_massaction-mass-select']"/>
2425
</section>
2526
</sections>

app/code/Magento/Search/Test/Mftf/ActionGroup/AdminSearchTermActionGroup.xml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,4 +36,12 @@
3636
<click selector="{{AdminCatalogSearchTermIndexSection.okButton}}" stepKey="clickOkButton"/>
3737
<waitForElementVisible selector="{{AdminCatalogSearchTermMessagesSection.successMessage}}" stepKey="waitForSuccessMessage"/>
3838
</actionGroup>
39+
40+
<!-- Delete all existing search terms -->
41+
<actionGroup name="DeleteAllSearchTerms">
42+
<selectOption userInput="selectAll" selector="{{AdminCatalogSearchTermIndexSection.selectMassActionCheckbox}}" stepKey="checkAllSearchTerms"/>
43+
<selectOption selector="{{AdminCatalogSearchTermIndexSection.massActions}}" userInput="delete" stepKey="selectDeleteOption"/>
44+
<click selector="{{AdminCatalogSearchTermIndexSection.submit}}" stepKey="clickSubmitButton"/>
45+
<click selector="{{AdminCatalogSearchTermIndexSection.okButton}}" stepKey="clickOkButton"/>
46+
</actionGroup>
3947
</actionGroups>

app/code/Magento/Search/Test/Mftf/Test/StorefrontVerifySearchSuggestionByProductDescriptionTest.xml

Lines changed: 29 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -16,64 +16,69 @@
1616
<severity value="CRITICAL"/>
1717
<testCaseId value="MC-14765"/>
1818
<group value="mtf_migrated"/>
19-
<skip>
20-
<issueId value="MC-17012"/>
21-
</skip>
2219
</annotations>
23-
2420
<before>
2521
<!-- Login as admin -->
22+
<comment userInput="Login as admin" stepKey="loginAsAdminComment"/>
2623
<actionGroup ref="LoginAsAdmin" stepKey="loginAsAdmin"/>
27-
24+
<!-- Go to the catalog search term page -->
25+
<comment userInput="Go to the catalog search term page" stepKey="goToSearchTermPageComment"/>
26+
<amOnPage url="{{AdminCatalogSearchTermIndexPage.url}}" stepKey="openAdminCatalogSearchTermIndexPage"/>
27+
<waitForPageLoad stepKey="waitForAdminCatalogSearchTermIndexPageLoad"/>
28+
<!-- Delete all search terms -->
29+
<comment userInput="Delete all search terms" stepKey="deleteAllSearchTermsComment"/>
30+
<actionGroup ref="DeleteAllSearchTerms" stepKey="deleteAllSearchTerms"/>
2831
<!-- Create product with description -->
32+
<comment userInput="Create product with description" stepKey="createProductWithDescriptionComment"/>
2933
<createData entity="SimpleProductWithDescription" stepKey="simpleProduct"/>
3034
</before>
3135
<after>
32-
<!--Delete create product -->
33-
<deleteData createDataKey="simpleProduct" stepKey="deleteProduct"/>
34-
35-
<!--Go to the catalog search term page -->
36+
<!-- Delete created product -->
37+
<comment userInput="Delete created product" stepKey="deleteCreatedProductComment"/>
38+
<deleteData createDataKey="simpleProduct" stepKey="deleteProduct"/>
39+
<!-- Go to the catalog search term page -->
40+
<comment userInput="Go to the catalog search term page" stepKey="goToSearchTermPageComment2"/>
3641
<amOnPage url="{{AdminCatalogSearchTermIndexPage.url}}" stepKey="openAdminCatalogSearchTermIndexPage"/>
3742
<waitForPageLoad stepKey="waitForAdminCatalogSearchTermIndexPageLoad"/>
38-
39-
<!--Filter the search term -->
43+
<!-- Filter the search term -->
44+
<comment userInput="Filter search term" stepKey="filterSearchTermComment"/>
4045
<actionGroup ref="searchTermFilterBySearchQuery" stepKey="filterByThirdSearchQuery">
4146
<argument name="searchQuery" value="{{ApiProductDescription.value}}"/>
4247
</actionGroup>
43-
4448
<!-- Delete created below search terms -->
49+
<comment userInput="Delete created below search terms" stepKey="deleteCreatedBelowSearchTermsComment"/>
4550
<actionGroup ref="deleteSearchTerm" stepKey="deleteSearchTerms"/>
4651
<actionGroup ref="logout" stepKey="logout"/>
4752
</after>
48-
4953
<!-- Go to storefront home page -->
54+
<comment userInput="Go to storefront home page" stepKey="goToStorefrontHomePageComment"/>
5055
<actionGroup ref="StorefrontOpenHomePageActionGroup" stepKey="openStoreFrontHomePage"/>
51-
52-
<!--Storefront quick search by product name -->
56+
<!-- Storefront quick search by product name -->
57+
<comment userInput="Storefront quick search by product name" stepKey="storefrontQuickSearchByProductNameComment"/>
5358
<actionGroup ref="StorefrontCheckQuickSearchStringActionGroup" stepKey="quickSearchByProductName">
5459
<argument name="phrase" value="{{ApiProductDescription.value}}"/>
5560
</actionGroup>
56-
57-
<!--Verify search suggestions and select the suggestion from dropdown options -->
61+
<!-- Verify search suggestions and select the suggestion from dropdown options -->
62+
<comment userInput="Verify search suggestions and select the suggestion from dropdown options" stepKey="verifySearchSuggestionsComment"/>
5863
<actionGroup ref="StoreFrontSelectDropDownSearchSuggestionActionGroup" stepKey="seeDropDownSearchSuggestion">
5964
<argument name="searchQuery" value="{{ApiProductDescription.value}}"/>
6065
</actionGroup>
61-
6266
<!-- Assert Product storefront main page -->
67+
<comment userInput="See product name" stepKey="seeProductNameComment"/>
6368
<actionGroup ref="StorefrontAssertProductNameOnProductMainPageActionGroup" stepKey="seeProductName">
6469
<argument name="productName" value="$$simpleProduct.name$$"/>
6570
</actionGroup>
66-
67-
<!--Go to the catalog search term page -->
71+
<!-- Go to the catalog search term page -->
72+
<comment userInput="Go to the catalog search term page" stepKey="goToSearchTermPageComment3"/>
6873
<amOnPage url="{{AdminCatalogSearchTermIndexPage.url}}" stepKey="openAdminCatalogSearchTermIndexPage"/>
6974
<waitForPageLoad stepKey="waitForAdminCatalogSearchTermIndexPageLoad"/>
70-
71-
<!--Filter the search term -->
75+
<!-- Filter the search term -->
76+
<comment userInput="Filter search term" stepKey="filterSearchTermComment2"/>
7277
<actionGroup ref="searchTermFilterBySearchQuery" stepKey="filterByThirdSearchQuery">
7378
<argument name="searchQuery" value="{{ApiProductDescription.value}}"/>
7479
</actionGroup>
75-
76-
<!--Assert Search Term in grid -->
80+
<!-- Assert Search Term in grid -->
81+
<comment userInput="Check is search term in grid or not" stepKey="isSearchTermInGridComment"/>
7782
<see stepKey="seeSearchTermInGrid" selector="{{AdminCatalogSearchTermIndexSection.gridRow}}" userInput="{{ApiProductDescription.value}}" />
7883
<see selector="{{AdminCatalogSearchTermIndexSection.numberOfSearchTermResults}}" userInput="1" stepKey="seeNumberOfSearchTermResultInGrid"/>
7984
</test>

0 commit comments

Comments
 (0)