|
| 1 | +<?xml version="1.0" encoding="UTF-8"?> |
| 2 | +<!-- |
| 3 | + /** |
| 4 | + * Copyright © Magento, Inc. All rights reserved. |
| 5 | + * See COPYING.txt for license details. |
| 6 | + */ |
| 7 | +--> |
| 8 | +<tests xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" |
| 9 | + xsi:noNamespaceSchemaLocation="urn:magento:mftf:Test/etc/testSchema.xsd"> |
| 10 | + <test name="AutoCompleteSearchTermsAndPhrasesWhileUserIsTypingTest"> |
| 11 | + <annotations> |
| 12 | + <stories value="Search Terms"/> |
| 13 | + <title value="In this test-case we need to verify that previously used earlier search terms are auto-complete"/> |
| 14 | + <description value="search terms are auto-complete for Customer when he tries to input the same search term in quick search on Storefront"/> |
| 15 | + <severity value="CRITICAL"/> |
| 16 | + <testCaseId value="AC-5003"/> |
| 17 | + <group value="mtf_migrated"/> |
| 18 | + </annotations> |
| 19 | + <before> |
| 20 | + <!-- Login as admin --> |
| 21 | + <actionGroup ref="AdminLoginActionGroup" stepKey="loginAsAdmin"/> |
| 22 | + <!--Create Simple Product --> |
| 23 | + <createData entity="defaultSimpleProduct" stepKey="simpleProduct"/> |
| 24 | + <magentoCron groups="index" stepKey="reindex"/> |
| 25 | + <comment userInput="Adding the comment to replace CliCacheFlushActionGroup action group ('cache:flush' command) for preserving Backward Compatibility" stepKey="flushCache"/> |
| 26 | + </before> |
| 27 | + <after> |
| 28 | + <!-- Delete create product --> |
| 29 | + <deleteData createDataKey="simpleProduct" stepKey="deleteProduct"/> |
| 30 | + <!-- Go to the catalog search term page --> |
| 31 | + <actionGroup ref="AdminOpenCatalogSearchTermIndexPageActionGroup" stepKey="openAdminCatalogSearchTermIndexPage"/> |
| 32 | + <!--Filter the search term --> |
| 33 | + <actionGroup ref="AdminSearchTermFilterBySearchQueryActionGroup" stepKey="filterByThirdSearchQuery"> |
| 34 | + <argument name="searchQuery" value="$$simpleProduct.name$$"/> |
| 35 | + </actionGroup> |
| 36 | + <!--Filter the search term --> |
| 37 | + <actionGroup ref="AdminSearchTermFilterBySearchQueryActionGroup" stepKey="filterByThirdSearchQuerySku"> |
| 38 | + <argument name="searchQuery" value="$$simpleProduct.sku$$"/> |
| 39 | + </actionGroup> |
| 40 | + <!-- Delete created below search terms --> |
| 41 | + <actionGroup ref="AdminDeleteSearchTermActionGroup" stepKey="deleteSearchTerms"/> |
| 42 | + <actionGroup ref="AdminLogoutActionGroup" stepKey="logout"/> |
| 43 | + </after> |
| 44 | + <!-- Go to storefront home page --> |
| 45 | + <actionGroup ref="StorefrontOpenHomePageActionGroup" stepKey="openStoreFrontHomePage"/> |
| 46 | + <!--Storefront quick search by product name --> |
| 47 | + <actionGroup ref="StorefrontCheckQuickSearchStringActionGroup" stepKey="quickSearchByProductName"> |
| 48 | + <argument name="phrase" value="$$simpleProduct.name$$"/> |
| 49 | + </actionGroup> |
| 50 | + <!--Verify search suggestions and select the suggestion from dropdown options --> |
| 51 | + <actionGroup ref="StoreFrontSelectDropDownSearchSuggestionActionGroup" stepKey="seeDropDownSearchSuggestion"> |
| 52 | + <argument name="searchQuery" value="$$simpleProduct.name$$"/> |
| 53 | + </actionGroup> |
| 54 | + <!-- Assert Product storefront main page --> |
| 55 | + <actionGroup ref="StorefrontAssertProductNameOnProductMainPageActionGroup" stepKey="seeProductName"> |
| 56 | + <argument name="productName" value="$$simpleProduct.name$$"/> |
| 57 | + </actionGroup> |
| 58 | + <!--Storefront quick search by product name --> |
| 59 | + <actionGroup ref="StorefrontCheckQuickSearchStringActionGroup" stepKey="quickSearchByProductNameSku"> |
| 60 | + <argument name="phrase" value="$$simpleProduct.sku$$"/> |
| 61 | + </actionGroup> |
| 62 | + <!--Verify search suggestions and select the suggestion from dropdown options --> |
| 63 | + <actionGroup ref="StoreFrontSelectDropDownSearchSuggestionActionGroup" stepKey="seeDropDownSearchSuggestionSku"> |
| 64 | + <argument name="searchQuery" value="$$simpleProduct.sku$$"/> |
| 65 | + </actionGroup> |
| 66 | + <!-- Assert Product storefront main page --> |
| 67 | + <actionGroup ref="StorefrontAssertProductNameOnProductMainPageActionGroup" stepKey="seeProductNameSku"> |
| 68 | + <argument name="productName" value="$$simpleProduct.name$$"/> |
| 69 | + </actionGroup> |
| 70 | + </test> |
| 71 | +</tests> |
0 commit comments