|
| 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 | +<tests xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" |
| 10 | + xsi:noNamespaceSchemaLocation="urn:magento:mftf:Test/etc/testSchema.xsd"> |
| 11 | + <test name="AdminCreateOrderAddProductCheckboxTest"> |
| 12 | + <annotations> |
| 13 | + <title value="Create Order in Admin and Add Product"/> |
| 14 | + <stories value="Create order and add product using checkbox"/> |
| 15 | + <description value="Create order in Admin panel, add product by clicking checkbox, and verify it is checked"/> |
| 16 | + <features value="Sales"/> |
| 17 | + <severity value="AVERAGE"/> |
| 18 | + <group value="Sales"/> |
| 19 | + </annotations> |
| 20 | + |
| 21 | + <before> |
| 22 | + <!-- Create simple customer --> |
| 23 | + <createData entity="Simple_US_Customer_CA" stepKey="createSimpleCustomer"/> |
| 24 | + |
| 25 | + <!-- Create simple product --> |
| 26 | + <createData entity="ApiProductWithDescription" stepKey="createSimpleProduct"/> |
| 27 | + |
| 28 | + <!-- Login to Admin Panel --> |
| 29 | + <actionGroup ref="LoginAsAdmin" stepKey="loginAsAdmin"/> |
| 30 | + </before> |
| 31 | + |
| 32 | + <!-- Initiate create new order --> |
| 33 | + <actionGroup ref="navigateToNewOrderPageExistingCustomer" stepKey="navigateToNewOrderWithExistingCustomer"> |
| 34 | + <argument name="customer" value="$$createSimpleCustomer$$"/> |
| 35 | + </actionGroup> |
| 36 | + |
| 37 | + <click selector="{{AdminOrderFormItemsSection.addProducts}}" stepKey="clickAddProducts"/> |
| 38 | + <fillField selector="{{AdminOrderFormItemsSection.skuFilter}}" userInput="$$createSimpleProduct.sku$$" stepKey="fillSkuFilterBundle"/> |
| 39 | + <click selector="{{AdminOrderFormItemsSection.search}}" stepKey="clickSearchBundle"/> |
| 40 | + <scrollTo selector="{{AdminOrderFormItemsSection.rowCheck('1')}}" x="0" y="-100" stepKey="scrollToCheckColumn"/> |
| 41 | + <checkOption selector="{{AdminOrderFormItemsSection.rowCheck('1')}}" stepKey="selectProduct"/> |
| 42 | + <seeCheckboxIsChecked selector="{{AdminOrderFormItemsSection.rowCheck('1')}}" stepKey="verifyProductChecked"/> |
| 43 | + |
| 44 | + <after> |
| 45 | + <actionGroup ref="logout" stepKey="logout"/> |
| 46 | + <deleteData createDataKey="createSimpleProduct" stepKey="deleteSimpleProduct"/> |
| 47 | + <deleteData createDataKey="createSimpleCustomer" stepKey="deleteSimpleCustomer"/> |
| 48 | + </after> |
| 49 | + </test> |
| 50 | +</tests> |
0 commit comments