Skip to content

Commit 5fdf987

Browse files
authored
ENGCOM-9268: MFTF: Customer Automatic Redirect To Account Dashboard Test #32999
2 parents 299368b + b7f5ad3 commit 5fdf987

File tree

2 files changed

+58
-0
lines changed

2 files changed

+58
-0
lines changed
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
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+
<actionGroups xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
10+
xsi:noNamespaceSchemaLocation="urn:magento:mftf:Test/etc/actionGroupSchema.xsd">
11+
<actionGroup name="AssertStorefrontCustomerAccountLinkInUrlActionGroup">
12+
<seeInCurrentUrl url="{{StorefrontCustomerDashboardPage.url}}" stepKey="seeInUrlCustomerDashboardPage"/>
13+
</actionGroup>
14+
</actionGroups>
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
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="StorefrontCustomerRedirectToAccountDashboardAfterLoggingInTest">
12+
<annotations>
13+
<features value="Customer"/>
14+
<stories value="Customer logs in and redirected to account dashboard"/>
15+
<title value="Redirect to account dashboard"/>
16+
<description value="Customer should be automatically redirected to account dashboard after login"/>
17+
<severity value="MINOR"/>
18+
<group value="customer"/>
19+
</annotations>
20+
<before>
21+
<createData entity="Simple_US_Customer" stepKey="createCustomer"/>
22+
<magentoCLI command="config:set {{EnableCustomerRedirectToDashboardConfigData.path}} {{EnableCustomerRedirectToDashboardConfigData.value}}" stepKey="enableRedirectAfterLogin"/>
23+
<actionGroup ref="CliCacheCleanActionGroup" stepKey="cleanInvalidatedCaches">
24+
<argument name="tags" value="config full_page"/>
25+
</actionGroup>
26+
</before>
27+
<after>
28+
<actionGroup ref="StorefrontCustomerLogoutActionGroup" stepKey="logoutCustomer"/>
29+
<deleteData createDataKey="createCustomer" stepKey="deleteCustomer"/>
30+
<magentoCLI command="config:set {{DisableCustomerRedirectToDashboardConfigData.path}} {{DisableCustomerRedirectToDashboardConfigData.value}}" stepKey="disableRedirectAfterLogin"/>
31+
<actionGroup ref="CliCacheCleanActionGroup" stepKey="cleanInvalidatedCaches">
32+
<argument name="tags" value="config full_page"/>
33+
</actionGroup>
34+
</after>
35+
36+
<actionGroup ref="LoginToStorefrontActionGroup" stepKey="loginToStorefrontAccount">
37+
<argument name="Customer" value="$createCustomer$"/>
38+
</actionGroup>
39+
<actionGroup ref="AssertCustomerAccountPageTitleActionGroup" stepKey="assertAccountPageTitle">
40+
<argument name="pageTitle" value="My Account"/>
41+
</actionGroup>
42+
<actionGroup ref="AssertStorefrontCustomerAccountLinkInUrlActionGroup" stepKey="assertAccountLinkInUrl"/>
43+
</test>
44+
</tests>

0 commit comments

Comments
 (0)