|
| 1 | +<?xml version="1.0" encoding="UTF-8"?> |
| 2 | +<!-- |
| 3 | + /** |
| 4 | + * Copyright 2025 Adobe |
| 5 | + * All Rights Reserved. |
| 6 | + */ |
| 7 | +--> |
| 8 | + |
| 9 | +<tests xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" |
| 10 | + xsi:noNamespaceSchemaLocation="urn:magento:mftf:Test/etc/testSchema.xsd"> |
| 11 | + <test name="AdminCheckBundleProductInCustomerActivitiesShoppingCartTest"> |
| 12 | + <annotations> |
| 13 | + <features value="Sales"/> |
| 14 | + <stories value="Admin Check Bundle Product In Customer Activities Shopping Cart"/> |
| 15 | + <title value="Admin check bundle product in customer activities shopping cart test"/> |
| 16 | + <description value="Admin check bundle product in customer activities shopping cart"/> |
| 17 | + <severity value="MINOR"/> |
| 18 | + <testCaseId value="AC-14596"/> |
| 19 | + <useCaseId value="ACP2E-3872"/> |
| 20 | + <group value="sales"/> |
| 21 | + </annotations> |
| 22 | + <before> |
| 23 | + <createData entity="Simple_US_Customer" stepKey="createCustomer"/> |
| 24 | + <comment userInput="Create the category" stepKey="createCategoryComment"/> |
| 25 | + <createData entity="ApiCategory" stepKey="createCategory"/> |
| 26 | + <createData entity="SimpleProduct2" stepKey="createFirstProduct"/> |
| 27 | + <createData entity="SimpleProduct2" stepKey="createSecondProduct"/> |
| 28 | + <createData entity="ApiBundleProduct" stepKey="createBundleProduct"/> |
| 29 | + <createData entity="DropDownBundleOption" stepKey="createBundleOption"> |
| 30 | + <requiredEntity createDataKey="createBundleProduct"/> |
| 31 | + </createData> |
| 32 | + <createData entity="ApiBundleLink" stepKey="LinkOptionToFirstProduct"> |
| 33 | + <requiredEntity createDataKey="createBundleProduct"/> |
| 34 | + <requiredEntity createDataKey="createBundleOption"/> |
| 35 | + <requiredEntity createDataKey="createFirstProduct"/> |
| 36 | + </createData> |
| 37 | + <createData entity="ApiBundleLink" stepKey="LinkOptionToSecondProduct"> |
| 38 | + <requiredEntity createDataKey="createBundleProduct"/> |
| 39 | + <requiredEntity createDataKey="createBundleOption"/> |
| 40 | + <requiredEntity createDataKey="createSecondProduct"/> |
| 41 | + </createData> |
| 42 | + </before> |
| 43 | + <after> |
| 44 | + <actionGroup ref="StorefrontCustomerLogoutActionGroup" stepKey="customerLogout"/> |
| 45 | + <deleteData createDataKey="createCustomer" stepKey="deleteCustomer"/> |
| 46 | + <deleteData createDataKey="createFirstProduct" stepKey="deleteFirstProduct"/> |
| 47 | + <deleteData createDataKey="createSecondProduct" stepKey="deleteSecondProduct"/> |
| 48 | + <deleteData createDataKey="createBundleProduct" stepKey="deleteBundleProduct"/> |
| 49 | + <deleteData createDataKey="createCategory" stepKey="deleteCategory"/> |
| 50 | + <actionGroup ref="AdminLogoutActionGroup" stepKey="logout"/> |
| 51 | + <actionGroup ref="CliIndexerReindexActionGroup" stepKey="reindexInvalidatedIndices"> |
| 52 | + <argument name="indices" value=""/> |
| 53 | + </actionGroup> |
| 54 | + </after> |
| 55 | + <!-- Login as customer --> |
| 56 | + <actionGroup ref="LoginToStorefrontActionGroup" stepKey="loginToStorefrontAccount"> |
| 57 | + <argument name="Customer" value="$$createCustomer$$"/> |
| 58 | + </actionGroup> |
| 59 | + <!-- Add Bundle Product to Cart --> |
| 60 | + <actionGroup ref="StorefrontOpenProductPageActionGroup" stepKey="openBundleProductPage"> |
| 61 | + <argument name="productUrl" value="$$createBundleProduct.custom_attributes[url_key]$$" /> |
| 62 | + </actionGroup> |
| 63 | + <actionGroup ref="StorefrontAddBundleProductToTheCartActionGroup" stepKey="addBundleProductToCart"> |
| 64 | + <argument name="productName" value="$createSecondProduct.name$"/> |
| 65 | + <argument name="quantity" value="1"/> |
| 66 | + </actionGroup> |
| 67 | + <actionGroup ref="AdminLoginActionGroup" stepKey="loginAsAdmin"/> |
| 68 | + <!-- Search and open customer --> |
| 69 | + <actionGroup ref="AdminNavigateMenuActionGroup" stepKey="navigateToCustomerGridPage"> |
| 70 | + <argument name="menuUiId" value="magento-customer-customer"/> |
| 71 | + <argument name="submenuUiId" value="magento-customer-customer-manage"/> |
| 72 | + </actionGroup> |
| 73 | + <actionGroup ref="AdminOpenCustomerEditPageActionGroup" stepKey="openCustomerEditPage"> |
| 74 | + <argument name="customerId" value="$createCustomer.id$"/> |
| 75 | + </actionGroup> |
| 76 | + <comment userInput="Filter customer" stepKey="filterCreatedCustomer"/> |
| 77 | + <comment userInput="Click edit button" stepKey="clickEditButton"/> |
| 78 | + <!-- Click create order --> |
| 79 | + <click selector="{{AdminCustomerMainActionsSection.createOrderBtn}}" stepKey="clickCreateOrder"/> |
| 80 | + <!-- Check bundle product in customer's activities in shopping cart section --> |
| 81 | + <see selector="{{AdminCustomerActivitiesShoppingCartSection.productName}}" userInput="$$createBundleProduct.name$$" stepKey="seeProductName"/> |
| 82 | + <see selector="{{AdminCustomerActivitiesShoppingCartSection.productQty}}" userInput="{{ApiSimpleSingleQty.quantity}}" stepKey="assertProductQty"/> |
| 83 | + </test> |
| 84 | +</tests> |
0 commit comments