|
| 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="StorefrontStickyLoginAsCustomerNotificationBannerTest"> |
| 12 | + <annotations> |
| 13 | + <features value="Login as Customer"/> |
| 14 | + <useCaseId value="https://github.com/magento/magento2/issues/29354"/> |
| 15 | + <stories value="Availability of sticky UI elements if module enable/disable"/> |
| 16 | + <title value="Sticky Notification Banner is present on Storefront page"/> |
| 17 | + <description |
| 18 | + value="Verify that Sticky Notification Banner is present on page if 'Login as customer' functionality used"/> |
| 19 | + <testCaseId value=""/> |
| 20 | + <severity value="CRITICAL"/> |
| 21 | + </annotations> |
| 22 | + <before> |
| 23 | + <magentoCLI command="config:set {{LoginAsCustomerConfigDataEnabled.path}} 1" |
| 24 | + stepKey="enableLoginAsCustomer"/> |
| 25 | + <actionGroup ref="CliCacheFlushActionGroup" stepKey="flushConfigCache"> |
| 26 | + <argument name="tags" value="config"/> |
| 27 | + </actionGroup> |
| 28 | + <createData entity="Simple_US_Customer" stepKey="createCustomer"/> |
| 29 | + <actionGroup ref="AdminLoginActionGroup" stepKey="login"/> |
| 30 | + </before> |
| 31 | + |
| 32 | + <after> |
| 33 | + <deleteData createDataKey="createCustomer" stepKey="deleteCustomer"/> |
| 34 | + <magentoCLI command="config:set {{LoginAsCustomerConfigDataEnabled.path}} 0" |
| 35 | + stepKey="disableLoginAsCustomer"/> |
| 36 | + <actionGroup ref="CliCacheFlushActionGroup" stepKey="flushConfigCache"> |
| 37 | + <argument name="tags" value="config"/> |
| 38 | + </actionGroup> |
| 39 | + </after> |
| 40 | + |
| 41 | + <actionGroup ref="AdminLoginAsCustomerLoginFromCustomerPageActionGroup" stepKey="loginAsCustomerFromCustomerPage"> |
| 42 | + <argument name="customerId" value="$$createCustomer.id$$"/> |
| 43 | + </actionGroup> |
| 44 | + |
| 45 | + <actionGroup ref="StorefrontAssertStickyLoginAsCustomerNotificationBannerActionGroup" stepKey="assertStickyNotificationBanner"> |
| 46 | + <argument name="customerFullName" value="$$createCustomer.firstname$$ $$createCustomer.lastname$$"/> |
| 47 | + </actionGroup> |
| 48 | + |
| 49 | + <actionGroup ref="StorefrontSignOutNotificationBannerAndCloseTabActionGroup" stepKey="signOutAndCloseTab"/> |
| 50 | + </test> |
| 51 | +</tests> |
0 commit comments