|
| 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 | + |
| 9 | +<actionGroups xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" |
| 10 | + xsi:noNamespaceSchemaLocation="urn:magento:mftf:Test/etc/actionGroupSchema.xsd"> |
| 11 | + <actionGroup name="StorefrontAddCategoryBundleProductWithSingleChoiceToCartActionGroup"> |
| 12 | + <annotations> |
| 13 | + <description>Adds a Bundled Product with the single choice to the Cart from the Category page.</description> |
| 14 | + </annotations> |
| 15 | + <arguments> |
| 16 | + <argument name="product"/> |
| 17 | + <argument name="quantity" defaultValue="1" type="string"/> |
| 18 | + </arguments> |
| 19 | + |
| 20 | + <moveMouseOver selector="{{StorefrontCategoryProductSection.ProductInfoByName(product.name)}}" stepKey="moveMouseOverProduct"/> |
| 21 | + <click selector="{{StorefrontCategoryProductSection.ProductAddToCartByName(product.name)}}" stepKey="clickAddToCart"/> |
| 22 | + <waitForPageLoad stepKey="waitForPageLoad1"/> |
| 23 | + <waitForElementVisible selector="{{StorefrontMessagesSection.success}}" stepKey="waitForSuccessMessage"/> |
| 24 | + <see selector="{{StorefrontMessagesSection.success}}" userInput="You added {{productName}} to your shopping cart." stepKey="seeAddToCartSuccessMessage"/> |
| 25 | + |
| 26 | + |
| 27 | + <!--Open minicart and change Qty--> |
| 28 | + <actionGroup ref="StorefrontClickOnMiniCartActionGroup" stepKey="openMiniCart"/> |
| 29 | + <waitForElementVisible selector="{{StorefrontMinicartSection.quantity}}" stepKey="waitForElementQty"/> |
| 30 | + <pressKey selector="{{StorefrontMinicartSection.itemQuantity(product.name)}}" parameterArray="[\Facebook\WebDriver\WebDriverKeys::BACKSPACE]" stepKey="deleteFiled"/> |
| 31 | + <fillField selector="{{StorefrontMinicartSection.itemQuantity(product.name)}}" userInput="{{quantity}}" stepKey="changeQty"/> |
| 32 | + <click selector="{{StorefrontMinicartSection.itemQuantityUpdate(product.name)}}" stepKey="updateQty"/> |
| 33 | + <waitForAjaxLoad stepKey="waitForAjaxLoad"/> |
| 34 | + <waitForText userInput="{{quantity}}" selector="{{StorefrontMinicartSection.productCount}}" time="30" stepKey="assertProductCount"/> |
| 35 | + </actionGroup> |
| 36 | +</actionGroups> |
0 commit comments