Skip to content

Commit c9f6869

Browse files
Merge branch 'develop' into ACQE-4Version-functional-mainline-deployment
2 parents 0bbc60b + 04d82d8 commit c9f6869

File tree

6 files changed

+387
-23
lines changed

6 files changed

+387
-23
lines changed

InventoryAdminUi/Test/Mftf/Test/ConfigurableProductWithDropDownAttributeOnTestStockGetOutOfStockWhenAllItsChildProductsGetOutOfStockOrDisabledTest.xml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
<?xml version="1.0" encoding="UTF-8"?>
22
<!--
33
/**
4-
* Copyright © Magento, Inc. All rights reserved.
5-
* See COPYING.txt for license details.
4+
* Copyright 2025 Adobe
5+
* All Rights Reserved.
66
*/
77
-->
88

@@ -17,6 +17,8 @@
1717
<severity value="CRITICAL"/>
1818
<group value="msi"/>
1919
<group value="multi_mode"/>
20+
<!-- pr_exclude group is added as test is failed in builds because of xpath element not found error and will be fixed and removed in ACQE-7619 -->
21+
<group value="pr_exclude"/>
2022
</annotations>
2123

2224
<before>
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<!--
3+
/**
4+
* Copyright 2025 Adobe
5+
* All Rights Reserved.
6+
*/
7+
-->
8+
9+
<actionGroups xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:mftf:Test/etc/actionGroupSchema.xsd">
10+
<actionGroup name="StorefrontAssertNoStoreIsSelectedInPickInStoreActionGroup">
11+
<annotations>
12+
<description>Verify that no store is selected.</description>
13+
</annotations>
14+
<waitForElementNotVisible selector="{{StorefrontSelectStoreSection.selectedStoreName}}" stepKey="assertSelectedStoreNameIsNotPresent"/>
15+
<waitForElementClickable selector="{{StorefrontSelectStoreSection.selectStoreBtn}}" stepKey="waitForSelectStoreClickable" />
16+
</actionGroup>
17+
</actionGroups>
Lines changed: 150 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,150 @@
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="StorefrontGuestPickupInStorePreselectedTest">
12+
<annotations>
13+
<stories value="Simple Product Custom Stock."/>
14+
<title value="Nearest store should be selected if guest customer address is within the configured radius of an existing store"/>
15+
<description value="Nearest store should be selected if guest customer address is within the configured radius of an existing store"/>
16+
<testCaseId value="AC-14156"/>
17+
<useCaseId value="ACP2E-3728"/>
18+
<severity value="MINOR"/>
19+
<group value="msi"/>
20+
<group value="store_pickup"/>
21+
</annotations>
22+
<before>
23+
<!--Set Distance Provider for Distance Based SSA to offline-->
24+
<magentoCLI command="config:set {{OfflineDistanceProviderForDistanceBasedSSA.path}} {{OfflineDistanceProviderForDistanceBasedSSA.value}}" stepKey="setDistanceProviderToOffline"/>
25+
<!--Enable 'In Store Pickup' shipping method-->
26+
<magentoCLI command="config:set {{EnableInStorePickup.path}} {{EnableInStorePickup.value}}" stepKey="enableInStorePickupMethod"/>
27+
<!--Download tables for 'US'-->
28+
<magentoCLI command="{{ImportTables.path}} {{USTable.value}}" stepKey="downloadTables"/>
29+
<actionGroup ref="CliIndexerReindexActionGroup" stepKey="performReindex">
30+
<argument name="indices" value=""/>
31+
</actionGroup>
32+
<actionGroup ref="CliCacheFlushActionGroup" stepKey="cleanCache">
33+
<argument name="tags" value=""/>
34+
</actionGroup>
35+
<!--Create test data-->
36+
<createData entity="LosAngelesStorePickupEnabledSource" stepKey="losAngelesSource"/>
37+
<createData entity="AustinStorePickupEnabledSource" stepKey="austinSource"/>
38+
<createData entity="BasicMsiStockWithMainWebsite1" stepKey="stock"/>
39+
<createData entity="SourceStockLinked1" stepKey="sourceStockLink1">
40+
<requiredEntity createDataKey="stock"/>
41+
<requiredEntity createDataKey="losAngelesSource"/>
42+
</createData>
43+
<createData entity="SourceStockLinked1" stepKey="sourceStockLink2">
44+
<requiredEntity createDataKey="stock"/>
45+
<requiredEntity createDataKey="austinSource"/>
46+
</createData>
47+
<createData entity="_defaultCategory" stepKey="category"/>
48+
<createData entity="SimpleProduct" stepKey="product">
49+
<requiredEntity createDataKey="category"/>
50+
</createData>
51+
<actionGroup ref="AdminLoginActionGroup" stepKey="loginAsAdmin"/>
52+
<!--Assign product to sources-->
53+
<actionGroup ref="AdminProductPageOpenByIdActionGroup" stepKey="openProductEditPage">
54+
<argument name="productId" value="$$product.id$$"/>
55+
</actionGroup>
56+
<actionGroup ref="UnassignSourceFromProductActionGroup" stepKey="unassignDefaultSourceFromProduct">
57+
<argument name="sourceCode" value="{{_defaultSource.name}}"/>
58+
</actionGroup>
59+
<actionGroup ref="AdminAssignSourceToProductAndSetSourceQuantityActionGroup" stepKey="assignLosAngelesSourceAndSetQty">
60+
<argument name="sourceCode" value="$losAngelesSource.source[source_code]$"/>
61+
</actionGroup>
62+
<actionGroup ref="AdminAssignSourceToProductAndSetSourceQuantityActionGroup" stepKey="assignAustinSourceAndSetQty">
63+
<argument name="sourceCode" value="$austinSource.source[source_code]$"/>
64+
</actionGroup>
65+
<actionGroup ref="SaveProductFormActionGroup" stepKey="saveProduct"/>
66+
</before>
67+
<after>
68+
<!--Revert Distance Provider for Distance Based SSA to online-->
69+
<magentoCLI command="config:set {{OnlineDistanceProviderForDistanceBasedSSA.path}} {{OnlineDistanceProviderForDistanceBasedSSA.value}}" stepKey="setDistanceProviderToOffline"/>
70+
<!--Disable 'In Store Pickup' shipping method-->
71+
<magentoCLI command="config:set {{DisableInStorePickup.path}} {{DisableInStorePickup.value}}" stepKey="enableInStorePickupMethod"/>
72+
<deleteData createDataKey="category" stepKey="deleteCategory"/>
73+
<deleteData createDataKey="product" stepKey="deleteProduct"/>
74+
<!--Assign Default Stock to Default Website-->
75+
<actionGroup ref="AssignWebsiteToStockActionGroup" stepKey="assignMainWebsiteToDefaultStock">
76+
<argument name="stockName" value="{{_defaultStock.name}}"/>
77+
<argument name="websiteName" value="{{_defaultWebsite.name}}"/>
78+
</actionGroup>
79+
<deleteData createDataKey="stock" stepKey="deleteStock"/>
80+
<actionGroup ref="DisableAllSourcesActionGroup" stepKey="disableAllSources"/>
81+
<actionGroup ref="AdminLogoutActionGroup" stepKey="logoutOfAdmin"/>
82+
<actionGroup ref="CliIndexerReindexActionGroup" stepKey="reindex">
83+
<argument name="indices" value=""/>
84+
</actionGroup>
85+
</after>
86+
<!--Add product to cart-->
87+
<actionGroup ref="AddSimpleProductToCartActionGroup" stepKey="addProductToCart">
88+
<argument name="product" value="$product$"/>
89+
</actionGroup>
90+
<!--Navigate to checkout-->
91+
<actionGroup ref="GoToCheckoutFromMinicartActionGroup" stepKey="goToCheckoutFromMinicart"/>
92+
<!--Fill shipping information with Lost Angeles address-->
93+
<actionGroup ref="FillGuestCheckoutShippingAddressWithCountryAndStateActionGroup" stepKey="guestCheckoutFillingShipping">
94+
<argument name="customer" value="Simple_US_Customer_CA"/>
95+
<argument name="customerAddress" value="US_Address_California"/>
96+
</actionGroup>
97+
<!--Select flat rate shipping method-->
98+
<waitForElementClickable selector="{{CheckoutShippingMethodsSection.shippingMethodFlatRate}}" stepKey="waitForShippingMethod"/>
99+
<actionGroup ref="CheckoutSelectFlatRateShippingMethodActionGroup" stepKey="selectFlatRate"/>
100+
<!--Switch to In Pick In Store-->
101+
<actionGroup ref="StorefrontPickInStoreActionGroup" stepKey="pickInStore"/>
102+
<!--Verify that store is selected-->
103+
<actionGroup ref="StorefrontAssertSelectedStoreActionGroup" stepKey="verifyThatStoreIsSelected">
104+
<argument name="sourceName" value="$losAngelesSource.source[name]$"/>
105+
</actionGroup>
106+
<!--Refresh Page-->
107+
<actionGroup ref="ReloadPageActionGroup" stepKey="refreshPage"/>
108+
<!--Verify that store is pre-selected-->
109+
<actionGroup ref="StorefrontAssertSelectedStoreActionGroup" stepKey="verifyThatStoreIsSelectedAfterPageRefresh">
110+
<argument name="sourceName" value="$losAngelesSource.source[name]$"/>
111+
</actionGroup>
112+
<!--Click 'Shipping'-->
113+
<actionGroup ref="StorefrontSelectShippingActionGroup" stepKey="switchToShipping"/>
114+
<!--Verify that shipping address form is pre-filled with Lost Angeles address-->
115+
<actionGroup ref="AssertStorefrontGuestCheckoutShippingAddressFormPrefilledActionGroup" stepKey="verifyThatShippingAddressFormIsPrefilledAfterPageRefresh">
116+
<argument name="customer" value="Simple_US_Customer_CA"/>
117+
<argument name="address" value="US_Address_California"/>
118+
</actionGroup>
119+
<!--Refresh Page-->
120+
<actionGroup ref="ReloadPageActionGroup" stepKey="refreshPage2"/>
121+
<!--Switch to In Pick In Store-->
122+
<actionGroup ref="StorefrontPickInStoreActionGroup" stepKey="pickInStore2"/>
123+
<!--Verify that store is pre-selected-->
124+
<actionGroup ref="StorefrontAssertSelectedStoreActionGroup" stepKey="verifyThatStoreIsSelectedAfterPageRefresh2">
125+
<argument name="sourceName" value="$losAngelesSource.source[name]$"/>
126+
</actionGroup>
127+
<!--Click 'Shipping'-->
128+
<actionGroup ref="StorefrontSelectShippingActionGroup" stepKey="switchToShipping2"/>
129+
<!--Fill shipping information with NY address-->
130+
<actionGroup ref="FillGuestCheckoutShippingAddressWithCountryAndStateActionGroup" stepKey="guestCheckoutFillingShipping2">
131+
<argument name="customer" value="Simple_US_Customer_NY"/>
132+
<argument name="customerAddress" value="US_Address_NY"/>
133+
</actionGroup>
134+
<!--Switch to In Pick In Store-->
135+
<actionGroup ref="StorefrontPickInStoreActionGroup" stepKey="pickInStore3"/>
136+
<!--Verify that store is not pre-selected-->
137+
<actionGroup ref="StorefrontAssertNoStoreIsSelectedInPickInStoreActionGroup" stepKey="verifyThatStoreIsNotSelectedAfterChangingShippingAddress"/>
138+
<!--Refresh Page-->
139+
<actionGroup ref="ReloadPageActionGroup" stepKey="refreshPage3"/>
140+
<!--Verify that store is not pre-selected-->
141+
<actionGroup ref="StorefrontAssertNoStoreIsSelectedInPickInStoreActionGroup" stepKey="verifyThatStoreIsNotSelectedAfterChangingShippingAddressAfterPageRefresh"/>
142+
<!--Click 'Shipping'-->
143+
<actionGroup ref="StorefrontSelectShippingActionGroup" stepKey="switchToShipping3"/>
144+
<!--Verify that shipping address form is pre-filled with NY address-->
145+
<actionGroup ref="AssertStorefrontGuestCheckoutShippingAddressFormPrefilledActionGroup" stepKey="verifyThatShippingAddressFormIsPrefilledAfterPageRefresh2">
146+
<argument name="customer" value="Simple_US_Customer_NY"/>
147+
<argument name="address" value="US_Address_NY"/>
148+
</actionGroup>
149+
</test>
150+
</tests>

0 commit comments

Comments
 (0)