|
| 1 | +<?xml version="1.0" encoding="UTF-8"?> |
| 2 | +<!-- |
| 3 | +/** |
| 4 | + * Copyright 2025 Adobe |
| 5 | + * All Rights Reserved. |
| 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="AdminMaxSessionSizeTest"> |
| 12 | + <annotations> |
| 13 | + <features value="Customer"/> |
| 14 | + <stories value="Validate max session size in admin."/> |
| 15 | + <title value="To check max session size in admin."/> |
| 16 | + <description value="Set admin max session size to 0 and verify admin and storefront logins."/> |
| 17 | + <testCaseId value="AC-3093"/> |
| 18 | + <severity value="MAJOR"/> |
| 19 | + <group value="customer"/> |
| 20 | + </annotations> |
| 21 | + <before> |
| 22 | + <!-- Precondition 1: Create Customer and login to storefront--> |
| 23 | + <createData entity="Simple_US_Customer" stepKey="customer"/> |
| 24 | + <actionGroup ref="LoginToStorefrontActionGroup" stepKey="loginCustomer"> |
| 25 | + <argument name="Customer" value="$customer$"/> |
| 26 | + </actionGroup> |
| 27 | + <!-- Step 1,2: Set max session size in admin to 0 --> |
| 28 | + <actionGroup ref="AdminSessionMaxSizeCliActionGroup" stepKey="setAdminMaxSessionSizeToZero"> |
| 29 | + <argument name="size" value="0"/> |
| 30 | + </actionGroup> |
| 31 | + </before> |
| 32 | + <after> |
| 33 | + <!-- Logout from storefront, delete customer, restore default max session size, check system value and logout from admin--> |
| 34 | + <actionGroup ref="StorefrontCustomerLogoutActionGroup" stepKey="logoutFromStorefront"/> |
| 35 | + <deleteData createDataKey="customer" stepKey="deleteCustomer"/> |
| 36 | + <actionGroup ref="AdminSessionMaxSizeCliActionGroup" stepKey="restoreDefaultMaxSessionSize"/> |
| 37 | + <actionGroup ref="AdminNavigateToConfigurationSystemSectionActionGroup" stepKey="navigateToAdminSessionMaxSize"> |
| 38 | + <argument name="section" value="{{AdminSessionMaxSizeUrl.urlName}}"/> |
| 39 | + </actionGroup> |
| 40 | + <checkOption selector="{{AdminSystemSecurityConfigSection.maxSessionSizeAdminInheritSystemValue}}" stepKey="checkUseSystemValue"/> |
| 41 | + <actionGroup ref="AdminLogoutActionGroup" stepKey="adminLogout"/> |
| 42 | + </after> |
| 43 | + <!-- Step 3: Logout and login to admin and verify User is able to login successfully --> |
| 44 | + <actionGroup ref="AdminLoginActionGroup" stepKey="adminLogin"/> |
| 45 | + <actionGroup ref="AssertAdminSuccessLoginActionGroup" stepKey="assertLoggedIn"/> |
| 46 | + <!-- Step 4: Logout and login to storefront and verify User is able to login successfully --> |
| 47 | + <actionGroup ref="StorefrontCustomerLogoutActionGroup" stepKey="logoutFromTheStorefront"/> |
| 48 | + <actionGroup ref="LoginToStorefrontActionGroup" stepKey="customerLogin"> |
| 49 | + <argument name="Customer" value="$customer$"/> |
| 50 | + </actionGroup> |
| 51 | + <actionGroup ref="AssertCustomerWelcomeMessageActionGroup" stepKey="assertCustomerLoggedIn"> |
| 52 | + <argument name="customerFullName" value="$$customer.firstname$$ $$customer.lastname$$" /> |
| 53 | + </actionGroup> |
| 54 | + </test> |
| 55 | +</tests> |
0 commit comments