|
| 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