|
| 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="AdminCheckDoubleImportOfProductsTest"> |
| 12 | + <annotations> |
| 13 | + <description value="Checking double Import of products CSV file"/> |
| 14 | + <stories value="Import Products"/> |
| 15 | + <features value="Import/Export"/> |
| 16 | + <title value="Admin check double import of products test"/> |
| 17 | + <severity value="CRITICAL"/> |
| 18 | + <testCaseId value="MC-6311"/> |
| 19 | + <group value="importExport"/> |
| 20 | + </annotations> |
| 21 | + <before> |
| 22 | + <!-- Login as admin --> |
| 23 | + <actionGroup ref="LoginAsAdmin" stepKey="loginAsAdmin"/> |
| 24 | + |
| 25 | + <!-- Create additional store views --> |
| 26 | + <actionGroup ref="AdminCreateStoreViewActionGroup" stepKey="createFirstStoreView"> |
| 27 | + <argument name="customStore" value="secondStoreView"/> |
| 28 | + </actionGroup> |
| 29 | + <actionGroup ref="AdminCreateStoreViewActionGroup" stepKey="createSecondStoreView"> |
| 30 | + <argument name="customStore" value="thirdStoreView"/> |
| 31 | + </actionGroup> |
| 32 | + </before> |
| 33 | + <after> |
| 34 | + <!-- Delete all imported products --> |
| 35 | + <actionGroup ref="AdminOpenProductIndexPageActionGroup" stepKey="openProductIndexPage"/> |
| 36 | + <actionGroup ref="clearFiltersAdminDataGrid" stepKey="clearGridFilter"/> |
| 37 | + <actionGroup ref="adminDataGridSelectPerPage" stepKey="selectNumberOfProductsPerPage"> |
| 38 | + <argument name="perPage" value="100"/> |
| 39 | + </actionGroup> |
| 40 | + <actionGroup ref="deleteProductsIfTheyExist" stepKey="deleteAllProducts"/> |
| 41 | + |
| 42 | + <!-- Delete additional store views --> |
| 43 | + <actionGroup ref="AdminDeleteStoreViewActionGroup" stepKey="deleteFirstStoreView"> |
| 44 | + <argument name="customStore" value="secondStoreView"/> |
| 45 | + </actionGroup> |
| 46 | + <actionGroup ref="AdminDeleteStoreViewActionGroup" stepKey="deleteSecondStoreView"> |
| 47 | + <argument name="customStore" value="thirdStoreView"/> |
| 48 | + </actionGroup> |
| 49 | + |
| 50 | + <!-- Delete category --> |
| 51 | + <actionGroup ref="DeleteCategory" stepKey="deleteCategory"> |
| 52 | + <argument name="categoryEntity" value="Gear"/> |
| 53 | + </actionGroup> |
| 54 | + |
| 55 | + <!-- Log out --> |
| 56 | + <actionGroup ref="logout" stepKey="logout"/> |
| 57 | + </after> |
| 58 | + |
| 59 | + <!-- Import products with add/update behavior --> |
| 60 | + <actionGroup ref="AdminImportProductsActionGroup" stepKey="adminImportProductsFirstTime"> |
| 61 | + <argument name="behavior" value="Add/Update"/> |
| 62 | + <argument name="importFile" value="prepared-for-sample-data.csv"/> |
| 63 | + <argument name="importMessage" value="Created: 100, Updated: 3, Deleted: 0"/> |
| 64 | + </actionGroup> |
| 65 | + |
| 66 | + <!-- Import products with add/update behavior again --> |
| 67 | + <actionGroup ref="AdminImportProductsActionGroup" stepKey="adminImportProductsSecondTime"> |
| 68 | + <argument name="behavior" value="Add/Update"/> |
| 69 | + <argument name="importFile" value="prepared-for-sample-data.csv"/> |
| 70 | + <argument name="importMessage" value="Created: 0, Updated: 300, Deleted: 0"/> |
| 71 | + </actionGroup> |
| 72 | + </test> |
| 73 | +</tests> |
0 commit comments