Skip to content

Commit 1d94e59

Browse files
committed
ACQE-8185: To verify Cart price rule created for logged-in user incorrectly gets applied for not logged-in user
- Fixed review comments
1 parent e172db7 commit 1d94e59

File tree

1 file changed

+17
-17
lines changed

1 file changed

+17
-17
lines changed

app/code/Magento/Customer/Test/Mftf/Test/StorefrontVerifyCartPriceRuleForLoggedInUserShouldNotAffectGuestTest.xml

Lines changed: 17 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -13,25 +13,25 @@
1313
<annotations>
1414
<features value="Customer"/>
1515
<stories value="Cart discounts meant for logged-in users are not applied to guest users"/>
16-
<title value="User Specific Cart price rule Is Not Applied To Guest user"/>
17-
<description value="This test case verifies the Cart price rule created for logged in user doesnt apply for Not Logged in user"/>
16+
<title value="User specific cart price rule is not applied to guest user"/>
17+
<description value="This test case verifies the cart price rule created for logged-in user doesnt apply for guest user"/>
1818
<testCaseId value="AC-13440"/>
1919
<severity value="MAJOR"/>
2020
<group value="customer"/>
2121
</annotations>
2222
<before>
23-
<!-- Create Product, Customer -->
23+
<!-- Create product, customer -->
2424
<createData entity="defaultSimpleProduct" stepKey="initialSimpleProductWithPrice"/>
2525
<createData entity="Simple_US_Customer_NY" stepKey="customer"/>
26-
<!--Pre-condition 1:Login as Customer -->
26+
<!--Pre-condition 1:Login as customer -->
2727
<actionGroup ref="LoginToStorefrontActionGroup" stepKey="loginToStorefront">
2828
<argument name="Customer" value="$customer$"/>
2929
</actionGroup>
30-
<!-- Login as Admin-->
30+
<!-- Login as admin-->
3131
<actionGroup ref="AdminLoginActionGroup" stepKey="loginAsAdmin"/>
32-
<!--Step2:Enabled The Persistent Shopping Cart feature -->
32+
<!--Step 2:Enabled the persistent shopping cart feature -->
3333
<createData entity="PersistentConfigEnabled" stepKey="enablePersistent"/>
34-
<!--Step3:Set Cookie Life Time to 60 Seconds -->
34+
<!--Step 3:Set cookie lifetime to 60 seconds -->
3535
<actionGroup ref="AdminNavigateToDefaultCookieSettingsActionGroup" stepKey="navigateToDefaultCookieSettingsPage"/>
3636
<actionGroup ref="AdminUncheckUseSystemValueActionGroup" stepKey="uncheckUseSystemValue">
3737
<argument name="rowId" value="row_web_cookie_cookie_lifetime"/>
@@ -44,15 +44,15 @@
4444
</actionGroup>
4545
</before>
4646
<after>
47-
<!-- Delete Product, Cart Price Rule, Customer -->
47+
<!-- Delete product, cart price rule, customer -->
4848
<deleteData stepKey="deleteProduct" createDataKey="initialSimpleProductWithPrice"/>
4949
<actionGroup ref="DeleteCartPriceRuleByName" stepKey="deleteCreatedCartPriceRule">
5050
<argument name="ruleName" value="{{CartPriceRuleConditionAndFreeShippingApplied.name}}"/>
5151
</actionGroup>
5252
<deleteData createDataKey="customer" stepKey="deleteCustomer"/>
5353
<!--Revert persistent configuration to default -->
5454
<createData entity="PersistentConfigDefault" stepKey="setDefaultPersistentState"/>
55-
<!--Set Cookie Life Time to Default Value-->
55+
<!--Set cookie lifetime to default Value-->
5656
<actionGroup ref="AdminNavigateToDefaultCookieSettingsActionGroup" stepKey="navigateToDefaultCookieSettingsPageToReset"/>
5757
<actionGroup ref="AdminFillCookieLifetimeActionGroup" stepKey="fillCookieLifetimeFieldWithNumber">
5858
<argument name="cookieLifetime" value="3600"/>
@@ -65,9 +65,9 @@
6565
</actionGroup>
6666
<actionGroup ref="AdminLogoutActionGroup" stepKey="logout"/>
6767
</after>
68-
<!--Step1: Create cart price rule for LoggedIn user with 50% discount -->
68+
<!--Step 1: Create cart price rule for logged-in user with 50% discount -->
6969
<actionGroup ref="AdminOpenNewCartPriceRuleFormPageActionGroup" stepKey="amOnCartPriceList"/>
70-
<actionGroup ref="AdminCartPriceRuleFillMainInfoActionGroup" stepKey="editNVDAGroups">
70+
<actionGroup ref="AdminCartPriceRuleFillMainInfoActionGroup" stepKey="fillCartPriceRuleForm">
7171
<argument name="name" value="{{CartPriceRuleConditionAndFreeShippingApplied.name}}"/>
7272
<argument name="groups" value="General"/>
7373
</actionGroup>
@@ -83,26 +83,26 @@
8383
<argument name="rule" value="CartPriceRuleConditionAndFreeShippingApplied"/>
8484
</actionGroup>
8585
<actionGroup ref="AssertCartPriceRuleSuccessSaveMessageActionGroup" stepKey="seeAssertCartPriceRuleSuccessSaveMessage"/>
86-
<!-- Go to Product page-->
86+
<!-- Go to product page-->
8787
<actionGroup ref="StorefrontOpenProductPageActionGroup" stepKey="openProductPage">
8888
<argument name="productUrl" value="$$initialSimpleProductWithPrice.custom_attributes[url_key]$$"/>
8989
</actionGroup>
90-
<!--Click on Add Product to Cart -->
90+
<!--Click on add product to Cart -->
9191
<actionGroup ref="StorefrontAddToTheCartActionGroup" stepKey="clickOnAddToCartButton"/>
92-
<!-- Navigate to Cart page-->
92+
<!-- Navigate to cart page-->
9393
<actionGroup ref="StorefrontCartPageOpenActionGroup" stepKey="goToCartPage" />
94-
<!-- Step4: Verify the cart price rule is applied, and the user got 50% discount on the product-->
94+
<!-- Step 4: Verify the cart price rule is applied, and the user got 50% discount on the product-->
9595
<actionGroup ref="StorefrontCheckCartActionGroup" stepKey="cartAssert">
9696
<argument name="subtotal" value="$560.00"/>
9797
<argument name="shipping" value="$0.00"/>
9898
<argument name="shippingMethod" value="Flat Rate - Fixed"/>
9999
<argument name="total" value="$280.00"/>
100100
</actionGroup>
101-
<!-- Step5: Verify User will be log out according to the cookie lifetime -->
101+
<!-- Step 5: Verify user will be log out according to the cookie lifetime -->
102102
<wait time="60" stepKey="waitForCookieLifeTimeToComplete"/>
103103
<reloadPage stepKey="refreshPage"/>
104104
<waitForElementVisible selector="{{StorefrontPanelHeaderSection.customerLoginLink}}" stepKey="waitForSignInLink"/>
105-
<!--Step6: verify cart is empty-->
105+
<!--Step 6: Verify cart is empty-->
106106
<actionGroup ref="StorefrontOpenHomePageActionGroup" stepKey="goToStorefrontHomePage"/>
107107
<actionGroup ref="AssertMiniCartEmptyActionGroup" stepKey="seeCartEmpty"/>
108108
</test>

0 commit comments

Comments
 (0)