Skip to content

Commit 7d3594e

Browse files
authored
ENGCOM-7660: MFTF: Sharing Wishlist with more than allowed emails qty test #28641
2 parents 8cf68cc + 2cfa3ec commit 7d3594e

File tree

1 file changed

+58
-0
lines changed

1 file changed

+58
-0
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,58 @@
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="StorefrontShareWishlistWithMoreThanMaximumAllowedEmailsQtyTest">
12+
<annotations>
13+
<features value="Wishlist"/>
14+
<stories value="Sharing wishlist with more than Maximum Allowed Emails qty"/>
15+
<title value="Sharing wishlist with more than Maximum Allowed Emails qty"/>
16+
<description value="Customer should not have a possibility share wishlist with more than maximum allowed emails qty"/>
17+
<testCaseId value="MC-35167"/>
18+
<group value="wishlist"/>
19+
<group value="configuration"/>
20+
</annotations>
21+
<before>
22+
<magentoCLI command="config:set wishlist/email/number_limit 1" stepKey="changeEmailsQtyLimit"/>
23+
<magentoCLI command="cache:clean config" stepKey="cleanCache"/>
24+
<createData entity="SimpleSubCategory" stepKey="createCategory"/>
25+
<createData entity="SimpleProduct" stepKey="createProduct">
26+
<requiredEntity createDataKey="createCategory"/>
27+
</createData>
28+
<magentoCLI command="cron:run --group=index" stepKey="runCronIndexer"/>
29+
<createData entity="Simple_US_Customer" stepKey="createCustomer"/>
30+
</before>
31+
<after>
32+
<magentoCLI command="config:set wishlist/email/number_limit 10" stepKey="returnDefaultValue"/>
33+
<magentoCLI command="cache:clean config" stepKey="cacheClean"/>
34+
<deleteData createDataKey="createCategory" stepKey="deleteCategory"/>
35+
<deleteData createDataKey="createProduct" stepKey="deleteProduct"/>
36+
<actionGroup ref="StorefrontCustomerLogoutActionGroup" stepKey="logoutCustomer"/>
37+
<deleteData createDataKey="createCustomer" stepKey="deleteCustomer"/>
38+
</after>
39+
40+
<actionGroup ref="LoginToStorefrontActionGroup" stepKey="loginToStorefrontAccount">
41+
<argument name="Customer" value="$createCustomer$"/>
42+
</actionGroup>
43+
<actionGroup ref="OpenStoreFrontProductPageActionGroup" stepKey="openProductPage">
44+
<argument name="productUrlKey" value="$$createProduct.custom_attributes[url_key]$$"/>
45+
</actionGroup>
46+
<actionGroup ref="StorefrontCustomerAddProductToWishlistActionGroup" stepKey="addToWishlistProduct">
47+
<argument name="productVar" value="$createProduct$"/>
48+
</actionGroup>
49+
<actionGroup ref="StorefrontShareCustomerWishlistActionGroup" stepKey="shareWishList">
50+
<argument name="email" value="{{Wishlist.shareInfo_emails}}"/>
51+
<argument name="message" value="{{Wishlist.shareInfo_message}}"/>
52+
</actionGroup>
53+
<actionGroup ref="AssertMessageCustomerChangeAccountInfoActionGroup" stepKey="assertMessage">
54+
<argument name="message" value="Maximum of 1 emails can be sent."/>
55+
<argument name="messageType" value="error"/>
56+
</actionGroup>
57+
</test>
58+
</tests>

0 commit comments

Comments
 (0)