Skip to content

Commit 884582a

Browse files
committed
ACQE-8327: Cart Sidebar synchronization with Customer Data Lifetime through customer login/logout
- Replace manual page reloads with ReloadPageActionGroup
1 parent 08418ef commit 884582a

File tree

1 file changed

+9
-14
lines changed

1 file changed

+9
-14
lines changed

app/code/Magento/Checkout/Test/Mftf/Test/StorefrontCartSidebarSynchronizationWithCustomerLoginTest.xml

Lines changed: 9 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -56,12 +56,10 @@
5656
<argument name="productName" value="$createSimpleProduct.name$"/>
5757
</actionGroup>
5858
<!-- Step 2: Reload product page several times to ensure caching -->
59-
<reloadPage stepKey="reloadPage1"/>
60-
<waitForPageLoad stepKey="waitForPageReload1"/>
61-
<reloadPage stepKey="reloadPage2"/>
62-
<waitForPageLoad stepKey="waitForPageReload2"/>
63-
<reloadPage stepKey="reloadPage3"/>
64-
<waitForPageLoad stepKey="waitForPageReload3"/>
59+
<!-- Please check if ReloadPageActionGroup can be used here -->
60+
<actionGroup ref="ReloadPageActionGroup" stepKey="reloadPage1"/>
61+
<actionGroup ref="ReloadPageActionGroup" stepKey="reloadPage2"/>
62+
<actionGroup ref="ReloadPageActionGroup" stepKey="reloadPage3"/>
6563
<!-- Step 3: Open Cart Sidebar and verify initial values -->
6664
<actionGroup ref="StorefrontClickOnMiniCartActionGroup" stepKey="openMiniCart"/>
6765
<waitForElementVisible selector="{{StorefrontMinicartSection.productLinkByName($createSimpleProduct.name$)}}" stepKey="verifyAppleProductInMiniCart"/>
@@ -83,7 +81,6 @@
8381
<argument name="product" value="$createSimpleProduct$"/>
8482
</actionGroup>
8583
<actionGroup ref="ReloadPageActionGroup" stepKey="reloadProductPageAfterFirstAdminChange"/>
86-
<waitForPageLoad stepKey="waitForReloadAfterFirstChange"/>
8784
<actionGroup ref="StorefrontClickOnMiniCartActionGroup" stepKey="openMiniCartAfterProductChange"/>
8885
<waitForElementVisible selector="{{StorefrontMinicartSection.productLinkByName($createSimpleProduct.name$)}}" stepKey="verifyAppleProductInMiniCartAfterChange"/>
8986
<waitForText userInput="$10.00" selector="{{StorefrontMinicartSection.productPriceByName($createSimpleProduct.name$)}}" stepKey="verifyCachedProductPrice"/>
@@ -99,10 +96,9 @@
9996
<waitForText userInput="$20.00" selector="{{StorefrontMinicartSection.productPriceByName($createSimpleProduct.name$)}}" stepKey="verifyUpdatedProductPriceAfterLogin"/>
10097
<actionGroup ref="StorefrontClickOnMiniCartActionGroup" stepKey="closeMiniCartAfterLogin"/>
10198
<!-- Step 8: Reload page several times to ensure caching -->
102-
<reloadPage stepKey="reloadPageAfterLogin1"/>
103-
<waitForPageLoad stepKey="waitForPageReloadAfterLogin1"/>
104-
<reloadPage stepKey="reloadPageAfterLogin2"/>
105-
<waitForPageLoad stepKey="waitForPageReloadAfterLogin2"/>
99+
<!-- Please check if ReloadPageActionGroup can be used here -->
100+
<actionGroup ref="ReloadPageActionGroup" stepKey="reloadPageAfterLogin1"/>
101+
<actionGroup ref="ReloadPageActionGroup" stepKey="reloadPageAfterLogin2"/>
106102
<!-- Step 9: Change product details again in admin -->
107103
<switchToNextTab stepKey="switchToAdminTab"/>
108104
<actionGroup ref="AdminProductPageOpenByIdActionGroup" stepKey="openProductEditPageAgain">
@@ -118,16 +114,15 @@
118114
<argument name="product" value="$createSimpleProduct$"/>
119115
</actionGroup>
120116
<actionGroup ref="ReloadPageActionGroup" stepKey="reloadProductPageAfterSecondAdminChange"/>
121-
<waitForPageLoad stepKey="waitForReloadAfterSecondChange"/>
122117
<actionGroup ref="StorefrontClickOnMiniCartActionGroup" stepKey="openMiniCartAfterSecondChange"/>
123118
<waitForElementVisible selector="{{StorefrontMinicartSection.productLinkByName('Apple-X')}}" stepKey="verifyAppleProductInMiniCartAfterSecondChange"/>
124119
<waitForText userInput="$20.00" selector="{{StorefrontMinicartSection.productPriceByName('Apple-X')}}" stepKey="verifyCachedProductPriceAfterSecondChange"/>
125120
<actionGroup ref="StorefrontClickOnMiniCartActionGroup" stepKey="closeMiniCartAfterSecondChange"/>
126121
<!-- Step 11: Wait for Customer Data Lifetime to expire (6 minutes) -->
127122
<wait time="120" stepKey="waitForCustomerDataLifetimeExpiration"/>
128123
<!-- Step 12: Reload page and verify updated values -->
129-
<reloadPage stepKey="reloadPageAfterWait"/>
130-
<waitForPageLoad stepKey="waitForPageReloadAfterWait"/>
124+
<!-- Please check if ReloadPageActionGroup can be used here -->
125+
<actionGroup ref="ReloadPageActionGroup" stepKey="reloadPageAfterWait"/>
131126
<actionGroup ref="StorefrontClickOnMiniCartActionGroup" stepKey="openMiniCartAfterWait"/>
132127
<waitForElementVisible selector="{{StorefrontMinicartSection.productLinkByName('Apple-X-Y')}}" stepKey="verifyAppleProductInMiniCartAfterWait"/>
133128
<waitForText userInput="$30.00" selector="{{StorefrontMinicartSection.productPriceByName('Apple-X-Y')}}" stepKey="verifyUpdatedProductPriceAfterWait"/>

0 commit comments

Comments
 (0)