Skip to content

Commit 6642d5c

Browse files
Pavan-bjmohit-adobe
authored andcommitted
ACQE-6765:Admin create shipping label for usps shipping method with international address
- Changes are made as per latest comments related to data entity & few minorr comments
1 parent 3288bbd commit 6642d5c

File tree

3 files changed

+9
-9
lines changed

3 files changed

+9
-9
lines changed

app/code/Magento/Shipping/Test/Mftf/Data/USPSShippingMethodData.xml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -84,4 +84,7 @@
8484
<data key="path">carriers/usps/mmid</data>
8585
<data key="value">{{_CREDS.magento/carriers_usps_rest_mmid}}</data>
8686
</entity>
87+
<entity name="ShippingTypeUSPSConfigData" type="usps_config">
88+
<data key="value">Priority Mail International Flat Rate Envelope</data>
89+
</entity>
8790
</entities>

app/code/Magento/Shipping/Test/Mftf/Suite/USPSShippingForRestAPISuite.xml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@
2626
<conditionalClick selector="{{AdminShippingMethodUSPSSection.USPSTab}}" dependentSelector="{{AdminShippingMethodUSPSSection.carriersUSPSActive}}" visible="false" stepKey="expandUSPSTab"/>
2727
<scrollTo selector="{{AdminShippingMethodUSPSSection.allowedMethodsForRestAPICheckbox}}" stepKey="scrollToAllowedMethodsCheckbox"/>
2828
<checkOption selector="{{AdminShippingMethodUSPSSection.allowedMethodsForRestAPICheckbox}}" stepKey="checkOnAllowedMethodsCheckboxForRestAPIUSPSType"/>
29-
<waitForElementVisible selector="{{AdminConfigSection.saveButton}}" stepKey="waitForShippingMethodSaveButton"/>
29+
<waitForElementClickable selector="{{AdminConfigSection.saveButton}}" stepKey="waitForShippingMethodSaveButton"/>
3030
<click selector="{{AdminConfigSection.saveButton}}" stepKey="saveConfig"/>
3131
<!--Flush cache post configuration-->
3232
<actionGroup ref="CliCacheFlushActionGroup" stepKey="flushCachePostConfiguring">
@@ -46,7 +46,7 @@
4646
<conditionalClick selector="{{AdminShippingMethodUSPSSection.USPSTab}}" dependentSelector="{{AdminShippingMethodUSPSSection.carriersUSPSActive}}" visible="false" stepKey="expandUSPSTab"/>
4747
<scrollTo selector="{{AdminShippingMethodUSPSSection.carriersUSPSAllowedMethods}}" stepKey="scrollToAllowedMethodsCheckbox"/>
4848
<click selector="{{AdminShippingMethodUSPSSection.carriersUSPSAllowedMethods}}" stepKey="checkOnAllowedMethodsCheckboxForWebToolUSPSType"/>
49-
<waitForElementVisible selector="{{AdminConfigSection.saveButton}}" stepKey="waitForShippingMethodSaveButton"/>
49+
<waitForElementClickable selector="{{AdminConfigSection.saveButton}}" stepKey="waitForShippingMethodSaveButton"/>
5050
<click selector="{{AdminConfigSection.saveButton}}" stepKey="saveConfig"/>
5151
<actionGroup ref="AdminLogoutActionGroup" stepKey="logoutAdmin"/>
5252
</after>

app/code/Magento/Shipping/Test/Mftf/Test/AdminCreateShippingLabelForUSPSShippingMethodTest.xml

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -28,9 +28,9 @@
2828
<actionGroup ref="AdminLoginActionGroup" stepKey="loginAsAdmin"/>
2929
<!--Set Shipping settings origin data-->
3030
<actionGroup ref="AdminSetShippingOriginConfigActionGroup" stepKey="setShippingOriginConfigurationData">
31-
<argument name="country" value="United States"/>
32-
<argument name="state" value="Illinois"/>
33-
<argument name="postcode" value="60031"/>
31+
<argument name="country" value="{{US_Address_LI.country_id}}"/>
32+
<argument name="state" value="{{US_Address_LI.state}}"/>
33+
<argument name="postcode" value="{{US_Address_LI.postcode}}"/>
3434
</actionGroup>
3535
<magentoCLI command="config:set {{AdminShippingSettingsOriginCityConfigData.path}} '{{US_Address_LI.city}}'" stepKey="setOriginCity"/>
3636
<magentoCLI command="config:set {{AdminShippingSettingsOriginStreetAddressConfigData.path}} '{{US_Address_LI.street[0]}}'" stepKey="setOriginStreetAddress"/>
@@ -45,9 +45,6 @@
4545
<argument name="street" value="{{US_Address_LI.street[0]}}"/>
4646
</actionGroup>
4747
<magentoCLI command="config:set {{AdminGeneralSetStreetAddress2ConfigData.path}} '{{US_Address_LI.street[1]}}'" stepKey="setStoreInformationStreetAddress"/>
48-
<actionGroup ref="CliIndexerReindexActionGroup" stepKey="runIndexCronJobs">
49-
<argument name="indices" value=""/>
50-
</actionGroup>
5148
</before>
5249
<after>
5350
<!--delete product-->
@@ -91,7 +88,7 @@
9188
</actionGroup>
9289
<!-- Step 4:Select Any USPS Shipping method -->
9390
<actionGroup ref="StorefrontSetShippingMethodActionGroup" stepKey="setShippingMethodFlatRate">
94-
<argument name="shippingMethodName" value="Priority Mail International Flat Rate Envelope"/>
91+
<argument name="shippingMethodName" value="{{ShippingTypeUSPSConfigData.value}}"/>
9592
</actionGroup>
9693
<!-- Step 5:Place order -->
9794
<actionGroup ref="StorefrontCheckoutClickNextButtonActionGroup" stepKey="goToPaymentStep"/>

0 commit comments

Comments
 (0)