|
| 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="CreateConfigurableProductWithSamePriceActionGroup"> |
| 12 | + <annotations> |
| 13 | + <description>Goes to the Admin Product grid page. |
| 14 | + Create a Configurable Product using the default Product Options with identical pricing.</description> |
| 15 | + </annotations> |
| 16 | + <arguments> |
| 17 | + <argument name="product" defaultValue="_defaultProduct"/> |
| 18 | + <argument name="category" defaultValue="_defaultCategory"/> |
| 19 | + </arguments> |
| 20 | + |
| 21 | + <!-- fill in basic configurable product values --> |
| 22 | + <amOnPage url="{{AdminProductIndexPage.url}}" stepKey="amOnProductGridPage"/> |
| 23 | + <waitForPageLoad time="30" stepKey="wait1"/> |
| 24 | + <click selector="{{AdminProductGridActionSection.addProductToggle}}" stepKey="clickOnAddProductToggle"/> |
| 25 | + <click selector="{{AdminProductGridActionSection.addConfigurableProduct}}" |
| 26 | + stepKey="clickOnAddConfigurableProduct"/> |
| 27 | + <fillField userInput="{{product.name}}" selector="{{AdminProductFormSection.productName}}" stepKey="fillName"/> |
| 28 | + <fillField userInput="{{product.sku}}" selector="{{AdminProductFormSection.productSku}}" stepKey="fillSKU"/> |
| 29 | + <fillField userInput="{{product.price}}" selector="{{AdminProductFormSection.productPrice}}" |
| 30 | + stepKey="fillPrice"/> |
| 31 | + <fillField userInput="{{product.quantity}}" selector="{{AdminProductFormSection.productQuantity}}" |
| 32 | + stepKey="fillQuantity"/> |
| 33 | + <searchAndMultiSelectOption selector="{{AdminProductFormSection.categoriesDropdown}}" |
| 34 | + parameterArray="[{{category.name}}]" stepKey="fillCategory"/> |
| 35 | + <selectOption userInput="{{product.visibility}}" selector="{{AdminProductFormSection.visibility}}" |
| 36 | + stepKey="fillVisibility"/> |
| 37 | + <click selector="{{AdminProductSEOSection.sectionHeader}}" stepKey="openSeoSection"/> |
| 38 | + <fillField userInput="{{product.urlKey}}" selector="{{AdminProductSEOSection.urlKeyInput}}" |
| 39 | + stepKey="fillUrlKey"/> |
| 40 | + |
| 41 | + <!-- create configurations for colors the product is available in --> |
| 42 | + <click selector="{{AdminProductFormConfigurationsSection.createConfigurations}}" |
| 43 | + stepKey="clickOnCreateConfigurations"/> |
| 44 | + <click selector="{{AdminCreateProductConfigurationsPanel.createNewAttribute}}" stepKey="clickOnNewAttribute"/> |
| 45 | + <waitForPageLoad stepKey="waitForIFrame"/> |
| 46 | + <switchToIFrame selector="{{AdminNewAttributePanel.newAttributeIFrame}}" stepKey="switchToNewAttributeIFrame"/> |
| 47 | + <fillField selector="{{AdminNewAttributePanel.defaultLabel}}" |
| 48 | + userInput="{{colorProductAttribute.default_label}}" |
| 49 | + stepKey="fillDefaultLabel"/> |
| 50 | + <click selector="{{AdminNewAttributePanel.saveAttribute}}" stepKey="clickOnNewAttributePanel"/> |
| 51 | + <waitForPageLoad stepKey="waitForSaveAttribute"/> |
| 52 | + <switchToIFrame stepKey="switchOutOfIFrame"/> |
| 53 | + <waitForPageLoad stepKey="waitForFilters"/> |
| 54 | + <click selector="{{AdminCreateProductConfigurationsPanel.filters}}" stepKey="clickOnFilters"/> |
| 55 | + <fillField userInput="{{colorProductAttribute.default_label}}" |
| 56 | + selector="{{AdminCreateProductConfigurationsPanel.attributeCode}}" |
| 57 | + stepKey="fillFilterAttributeCodeField"/> |
| 58 | + <click selector="{{AdminCreateProductConfigurationsPanel.applyFilters}}" stepKey="clickApplyFiltersButton"/> |
| 59 | + <click selector="{{AdminCreateProductConfigurationsPanel.firstCheckbox}}" stepKey="clickOnFirstCheckbox"/> |
| 60 | + <click selector="{{AdminCreateProductConfigurationsPanel.next}}" stepKey="clickOnNextButton1"/> |
| 61 | + <waitForElementVisible selector="{{AdminCreateProductConfigurationsPanel.createNewValue}}" |
| 62 | + stepKey="waitCreateNewValueAppears"/> |
| 63 | + <click selector="{{AdminCreateProductConfigurationsPanel.createNewValue}}" stepKey="clickOnCreateNewValue1"/> |
| 64 | + <fillField userInput="{{colorProductAttribute1.name}}" |
| 65 | + selector="{{AdminCreateProductConfigurationsPanel.attributeName}}" |
| 66 | + stepKey="fillFieldForNewAttribute1"/> |
| 67 | + <click selector="{{AdminCreateProductConfigurationsPanel.saveAttribute}}" stepKey="clickOnSaveNewAttribute1"/> |
| 68 | + <click selector="{{AdminCreateProductConfigurationsPanel.createNewValue}}" stepKey="clickOnCreateNewValue2"/> |
| 69 | + <fillField userInput="{{colorProductAttribute2.name}}" |
| 70 | + selector="{{AdminCreateProductConfigurationsPanel.attributeName}}" |
| 71 | + stepKey="fillFieldForNewAttribute2"/> |
| 72 | + <click selector="{{AdminCreateProductConfigurationsPanel.saveAttribute}}" stepKey="clickOnSaveNewAttribute2"/> |
| 73 | + <click selector="{{AdminCreateProductConfigurationsPanel.createNewValue}}" stepKey="clickOnCreateNewValue3"/> |
| 74 | + <fillField userInput="{{colorProductAttribute3.name}}" |
| 75 | + selector="{{AdminCreateProductConfigurationsPanel.attributeName}}" |
| 76 | + stepKey="fillFieldForNewAttribute3"/> |
| 77 | + <click selector="{{AdminCreateProductConfigurationsPanel.saveAttribute}}" stepKey="clickOnSaveNewAttribute3"/> |
| 78 | + <click selector="{{AdminCreateProductConfigurationsPanel.selectAll}}" stepKey="clickOnSelectAll"/> |
| 79 | + <click selector="{{AdminCreateProductConfigurationsPanel.next}}" stepKey="clickOnNextButton2"/> |
| 80 | + <click selector="{{AdminCreateProductConfigurationsPanel.applyUniquePricesByAttributeToEachSku}}" |
| 81 | + stepKey="clickOnApplyUniquePricesByAttributeToEachSku"/> |
| 82 | + <selectOption selector="{{AdminCreateProductConfigurationsPanel.selectAttribute}}" |
| 83 | + userInput="{{colorProductAttribute.default_label}}" stepKey="selectAttributes"/> |
| 84 | + <fillField selector="{{AdminCreateProductConfigurationsPanel.attribute1}}" |
| 85 | + userInput="{{colorProductAttribute1.price}}" stepKey="fillAttributePrice1"/> |
| 86 | + <fillField selector="{{AdminCreateProductConfigurationsPanel.attribute2}}" |
| 87 | + userInput="{{colorProductAttribute1.price}}" stepKey="fillAttributePrice2"/> |
| 88 | + <fillField selector="{{AdminCreateProductConfigurationsPanel.attribute3}}" |
| 89 | + userInput="{{colorProductAttribute1.price}}" stepKey="fillAttributePrice3"/> |
| 90 | + <click selector="{{AdminCreateProductConfigurationsPanel.applySingleQuantityToEachSkus}}" |
| 91 | + stepKey="clickOnApplySingleQuantityToEachSku"/> |
| 92 | + <fillField selector="{{AdminCreateProductConfigurationsPanel.quantity}}" |
| 93 | + userInput="1" stepKey="enterAttributeQuantity"/> |
| 94 | + <click selector="{{AdminCreateProductConfigurationsPanel.next}}" stepKey="clickOnNextButton3"/> |
| 95 | + <click selector="{{AdminCreateProductConfigurationsPanel.next}}" stepKey="clickOnNextButton4"/> |
| 96 | + <click selector="{{AdminProductFormActionSection.saveButton}}" stepKey="clickOnSaveButton2"/> |
| 97 | + <click selector="{{AdminChooseAffectedAttributeSetPopup.confirm}}" stepKey="clickOnConfirmInPopup"/> |
| 98 | + <seeElement selector="{{AdminProductMessagesSection.successMessage}}" stepKey="seeSaveProductMessage"/> |
| 99 | + <seeInTitle userInput="{{product.name}}" stepKey="seeProductNameInTitle"/> |
| 100 | + </actionGroup> |
| 101 | +</actionGroups> |
0 commit comments