12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576 |
- <?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="AdminRemoveDefaultImageDownloadableProductTest">
- <annotations>
- <features value="Downloadable"/>
- <stories value="Add/remove images and videos for all product types and category"/>
- <title value="Admin should be able to remove default images from a Downloadable Product"/>
- <description value="Admin should be able to remove default images from a Downloadable Product"/>
- <severity value="MAJOR"/>
- <testCaseId value="MC-201"/>
- <group value="Downloadable"/>
- </annotations>
- <before>
- <actionGroup ref="LoginAsAdmin" stepKey="loginAsAdmin"/>
- </before>
- <after>
- <amOnPage url="{{AdminLogoutPage.url}}" stepKey="amOnLogoutPage"/>
- </after>
- <!-- Create product -->
- <amOnPage url="{{AdminProductIndexPage.url}}" stepKey="adminProductIndexPageAdd"/>
- <waitForPageLoad stepKey="waitForProductIndexPageLoad"/>
- <actionGroup ref="goToCreateProductPage" stepKey="goToCreateProductPage">
- <argument name="product" value="DownloadableProduct"/>
- </actionGroup>
- <actionGroup ref="fillMainProductFormNoWeight" stepKey="fillMainProductForm">
- <argument name="product" value="DownloadableProduct"/>
- </actionGroup>
- <!-- Add image to product -->
- <actionGroup ref="addProductImage" stepKey="addImageForProduct">
- <argument name="image" value="MagentoLogo"/>
- </actionGroup>
- <!-- Add downloadable links -->
- <click selector="{{AdminProductDownloadableSection.sectionHeader}}" stepKey="openDownloadableSection"/>
- <checkOption selector="{{AdminProductDownloadableSection.isDownloadableProduct}}" stepKey="checkIsDownloadable"/>
- <fillField userInput="{{downloadableData.link_title}}" selector="{{AdminProductDownloadableSection.linksTitleInput}}" stepKey="fillDownloadableLinkTitle"/>
- <checkOption selector="{{AdminProductDownloadableSection.isLinksPurchasedSeparately}}" stepKey="checkLinksPurchasedSeparately"/>
- <fillField userInput="{{downloadableData.sample_title}}" selector="{{AdminProductDownloadableSection.samplesTitleInput}}" stepKey="fillDownloadableSampleTitle"/>
- <actionGroup ref="addDownloadableProductLinkWithMaxDownloads" stepKey="addDownloadableLinkWithMaxDownloads">
- <argument name="link" value="downloadableLinkWithMaxDownloads"/>
- </actionGroup>
- <actionGroup ref="addDownloadableProductLink" stepKey="addDownloadableLink">
- <argument name="link" value="downloadableLink"/>
- </actionGroup>
- <!--Save product-->
- <actionGroup ref="saveProductForm" stepKey="saveProduct"/>
- <!-- Remove image from product -->
- <actionGroup ref="removeProductImage" stepKey="removeProductImage"/>
- <actionGroup ref="saveProductForm" stepKey="saveProductFormAfterRemove"/>
- <!-- Assert product image not in admin product form -->
- <actionGroup ref="assertProductImageNotInAdminProductPage" stepKey="assertProductImageNotInAdminProductPage"/>
- <!-- Assert product in storefront product page -->
- <actionGroup ref="AssertProductNameAndSkuInStorefrontProductPage" stepKey="AssertProductInStorefrontProductPageAfterRemove">
- <argument name="product" value="DownloadableProduct"/>
- </actionGroup>
- <!-- Assert product image not in storefront product page -->
- <actionGroup ref="assertProductImageNotInStorefrontProductPage" stepKey="assertProductImageNotInStorefrontProductPage">
- <argument name="product" value="DownloadableProduct"/>
- </actionGroup>
- </test>
- </tests>
|