123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354 |
- <?xml version="1.0" encoding="UTF-8"?>
- <!--
- /**
- * Copyright © Magento, Inc. All rights reserved.
- * See COPYING.txt for license details.
- */
- -->
- <tests xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:mftf:Test/etc/testSchema.xsd">
- <test name="AdminDeleteCustomerAddressesFromTheGridViaMassActionsTest">
- <annotations>
- <title value="Admin delete customer addresses from the grid via mass actions"/>
- <description value="Admin delete customer addresses from the grid via mass actions"/>
- <features value="Module/ Customer"/>
- <severity value="MAJOR"/>
- <testCaseId value="MAGETWO-94951"/>
- <stories value="MAGETWO-94346: Implement handling of large number of addresses on admin edit customer page"/>
- <group value="customer"/>
- </annotations>
- <before>
- <createData entity="Simple_US_Customer_Multiple_Addresses" stepKey="createCustomer"/>
- <magentoCLI command="indexer:reindex" stepKey="reindex"/>
- <actionGroup ref="LoginAsAdmin" stepKey="login"/>
- </before>
- <after>
- <deleteData createDataKey="createCustomer" stepKey="deleteCustomer"/>
- <actionGroup ref="logout" stepKey="logout"/>
- </after>
- <!-- -
- Step1. Login to admin and go to Customers > All Customerts.
- Step2. On *Customers* page choose customer from preconditions and open it to edit
- Step3. On edit customer page open *Addresses* tab and find a grid with the additional addresses
- <!- -->
- <amOnPage url="{{AdminCustomerPage.url}}" stepKey="openCustomersGridPage"/>
- <actionGroup ref="OpenEditCustomerFromAdminActionGroup" stepKey="openEditCustomerPage">
- <argument name="customer" value="Simple_US_Customer_Multiple_Addresses"/>
- </actionGroup>
- <click selector="{{AdminEditCustomerInformationSection.addresses}}" stepKey="openAddressesTab"/>
- <conditionalClick selector="{{AdminCustomerAddressFiltersSection.clearAll}}" dependentSelector="{{AdminCustomerAddressFiltersSection.clearAll}}" visible="true" stepKey="clickOnButtonToRemoveFiltersIfPresent"/>
- <!-- -
- Step4. Check checkboxes for several addresses open *Actions* dropdown at the top of addresses grid and select action *Delete*
- Step5. Press *Ok* button on the pop-up
- <!- -->
- <click selector="{{AdminCustomerAddressesGridSection.firstRowCheckbox}}" stepKey="tickFirstRowCustomerAddressCheckbox"/>
- <click selector="{{AdminCustomerAddressesGridSection.secondRowCheckbox}}" stepKey="tickSecondRowCustomerAddressCheckbox"/>
- <click selector="{{AdminCustomerAddressesGridActionsSection.actions}}" stepKey="openActionsDropdown"/>
- <click selector="{{AdminCustomerAddressesGridActionsSection.delete}}" stepKey="chooseDeleteOption"/>
- <waitForPageLoad stepKey="waitForCustomerAddressesGridPageLoad1"/>
- <click selector="{{AdminCustomerAddressesGridActionsSection.ok}}" stepKey="clickOkOnPopup"/>
- <waitForPageLoad stepKey="waitForCustomerAddressesGridPageLoad2"/>
- <see userInput="We couldn't find any records." selector="{{AdminCustomerAddressesGridSection.customerAddressGrid}}" stepKey="checkThatCustomerAddressesGridHasNoRecords"/>
- </test>
- </tests>
|