Skip to content

Commit 9cb846b

Browse files
Merge pull request #4698 from magento-epam/EPAM-PR-69
EPAM-PR-69
2 parents 0a92770 + 5816123 commit 9cb846b

18 files changed

+137
-25
lines changed

app/code/Magento/Catalog/Test/Mftf/Test/AdminSortingByWebsitesTest.xml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,8 @@
4040
<actionGroup ref="AdminDeleteWebsiteActionGroup" stepKey="deleteTestWebsite">
4141
<argument name="websiteName" value="{{customWebsite.name}}"/>
4242
</actionGroup>
43+
<actionGroup ref="GoToProductCatalogPage" stepKey="goToProductCatalogPage"/>
44+
<actionGroup ref="resetProductGridToDefaultView" stepKey="resetProductGridColumnsInitial"/>
4345
<actionGroup ref="ResetWebUrlOptions" stepKey="resetUrlOption"/>
4446
<magentoCLI command="indexer:reindex" stepKey="reindex"/>
4547
<magentoCLI command="cache:flush" stepKey="flushCache"/>

app/code/Magento/Catalog/Test/Mftf/Test/StorefrontPurchaseProductWithCustomOptionsWithLongValuesTitle.xml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,9 @@
1717
<description value="Admin should be able to see the full title of the selected custom option value in the order"/>
1818
<severity value="MAJOR"/>
1919
<testCaseId value="MC-3043"/>
20+
<skip>
21+
<issueId value="MQE-1128"/>
22+
</skip>
2023
</annotations>
2124
<before>
2225
<!--Create Simple Product with Custom Options-->

app/code/Magento/CatalogSearch/Test/Mftf/Section/AdminCatalogSearchTermIndexSection.xml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,5 +21,6 @@
2121
<element name="emptyRecords" type="text" selector="//tr[@class='data-grid-tr-no-data even']/td[@class='empty-text']"/>
2222
<element name="gridRow" type="text" selector="//tr[@data-role='row']"/>
2323
<element name="numberOfSearchTermResults" type="text" selector="//tr[@data-role='row']/td[@data-column='num_results']"/>
24+
<element name="selectMassActionCheckbox" type="select" selector="//select[@id='search_term_grid_massaction-mass-select']"/>
2425
</section>
2526
</sections>

app/code/Magento/Paypal/Test/Mftf/ActionGroup/OtherPayPalConfigurationActionGroup.xml

Lines changed: 15 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,21 @@
2828
<click selector="{{AdminConfigSection.saveButton}}" stepKey="saveConfig"/>
2929
<waitForPageLoad stepKey="waitForPageLoad2"/>
3030
</actionGroup>
31-
31+
<actionGroup name="EnablePayPalSolutionWithoutSave" >
32+
<annotations>
33+
<description>Expands the 'OTHER PAYPAL PAYMENT SOLUTIONS' tab on the Admin Configuration page. Enables the provided PayPal Config type for the provided Country Code without saving.</description>
34+
</annotations>
35+
<arguments>
36+
<argument name="payPalConfigType"/>
37+
<argument name="countryCode" type="string" defaultValue="us"/>
38+
</arguments>
39+
<waitForElementVisible selector="{{OtherPayPalPaymentsConfigSection.expandTab(countryCode)}}" stepKey="waitForOtherPayPalPaymentsSection"/>
40+
<conditionalClick selector="{{OtherPayPalPaymentsConfigSection.expandTab(countryCode)}}" dependentSelector="{{OtherPayPalPaymentsConfigSection.expandedTab(countryCode)}}" visible="false" stepKey="clickOtherPayPalPaymentsSection"/>
41+
<waitForElementVisible selector="{{payPalConfigType.configureBtn(countryCode)}}" stepKey="waitForWPSExpressConfigureBtn"/>
42+
<click selector="{{payPalConfigType.configureBtn(countryCode)}}" stepKey="clickWPSExpressConfigureBtn"/>
43+
<waitForElementVisible selector="{{payPalConfigType.enableSolution(countryCode)}}" stepKey="waitForWPSExpressEnable"/>
44+
<selectOption selector="{{payPalConfigType.enableSolution(countryCode)}}" userInput="Yes" stepKey="enableWPSExpressSolution"/>
45+
</actionGroup>
3246
<actionGroup name="CheckEnableOptionPayPalConfiguration">
3347
<annotations>
3448
<description>Expands the 'OTHER PAYPAL PAYMENT SOLUTIONS' tab on the Admin Configuration page. Enables the provided PayPal Config type for the provided Country Code.</description>
Lines changed: 59 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,59 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<!--
3+
/**
4+
* Copyright © Magento, Inc. All rights reserved.
5+
* See COPYING.txt for license details.
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="AdminOnePayPalSolutionsEnabledAtTheSameTimeTest">
12+
<annotations>
13+
<features value="Paypal"/>
14+
<stories value="Payment methods configuration"/>
15+
<title value="Only one PayPal solution enabled at the same time"/>
16+
<description value="Verify that only one PayPal solution can be enabled"/>
17+
<severity value="MAJOR"/>
18+
<testCaseId value="MC-17776"/>
19+
<useCaseId value=" MC-15140"/>
20+
<group value="paypal"/>
21+
</annotations>
22+
<before>
23+
<actionGroup ref="LoginAsAdmin" stepKey="loginAsAdmin"/>
24+
<!--Set PayPal Payments Standard Configs-->
25+
<comment userInput="Set PayPal Payments Standard Configs" stepKey="commentsetConfigs"/>
26+
<magentoCLI command="config:set paypal/wpp/api_authentication 0" stepKey="setApiAuthentication"/>
27+
<magentoCLI command="config:set paypal/wpp/api_username username" stepKey="setApiUserName"/>
28+
<magentoCLI command="config:set paypal/wpp/api_password password" stepKey="setApiPassword"/>
29+
<magentoCLI command="config:set paypal/wpp/api_signature signature" stepKey="setApiSignature"/>
30+
<magentoCLI command="config:set paypal/wpp/sandbox_flag 1" stepKey="setSandBox"/>
31+
<magentoCLI command="config:set paypal/wpp/use_proxy 0" stepKey="setUseProxy"/>
32+
<magentoCLI command="config:set payment/wps_express/active 1" stepKey="enableWPSExpress"/>
33+
</before>
34+
<after>
35+
<actionGroup ref="logout" stepKey="logout"/>
36+
<magentoCLI command="config:set payment/wps_express/active 0" stepKey="disableWPSExpress"/>
37+
<magentoCLI command="config:set payment/paypal_express/active 0" stepKey="disableExpressCheckout"/>
38+
</after>
39+
<!--Try to enable express checkout Solution-->
40+
<comment userInput="Try to enable express checkout Solution" stepKey="commentTryEnableExpressCheckout"/>
41+
<amOnPage url="{{AdminConfigPaymentMethodsPage.url}}" stepKey="navigateToPaymentConfigurationPage"/>
42+
<actionGroup ref="EnablePayPalSolutionWithoutSave" stepKey="enableExpressCheckout">
43+
<argument name="payPalConfigType" value="WPSExpressConfigSection"/>
44+
<argument name="countryCode" value="us"/>
45+
</actionGroup>
46+
<click selector="{{AdminConfigSection.saveButton}}" stepKey="saveConfig"/>
47+
<waitForPageLoad stepKey="waitForPageLoad2"/>
48+
<actionGroup ref="EnablePayPalSolutionWithoutSave" stepKey="enableExpressCheckout2">
49+
<argument name="payPalConfigType" value="PayPalExpressCheckoutConfigSection"/>
50+
<argument name="countryCode" value="us"/>
51+
</actionGroup>
52+
<seeInPopup userInput="There is already another PayPal solution enabled. Enable this solution instead?" stepKey="seeAlertMessage"/>
53+
<cancelPopup stepKey="cancelPopup"/>
54+
<!--Check only the correct solution is enabled -->
55+
<comment userInput="Check only the correct solution is enabled" stepKey="commentCheckOnlyTheCorrectSolutionIsEnabled"/>
56+
<conditionalClick selector="{{PayPalExpressCheckoutConfigSection.configureBtn('us')}}" dependentSelector="{{PayPalExpressCheckoutConfigSection.enableSolution('us')}}" visible="false" stepKey="clickPayPalExpressCheckoutSection"/>
57+
<seeOptionIsSelected selector="{{PayPalExpressCheckoutConfigSection.enableSolution('us')}}" userInput="No" stepKey="seeSelectedOption"/>
58+
</test>
59+
</tests>

app/code/Magento/Paypal/etc/adminhtml/rules/payment_ca.xml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -193,6 +193,7 @@
193193
<argument name="wps_other">wps_other</argument>
194194
<argument name="payflow_link_ca">payflow_link_ca</argument>
195195
</rule>
196+
<rule type="simpleDisable" event="deactivate-rule"/>
196197
<rule type="inContextEnable" event="activate-rule"/>
197198
<rule type="inContextDisable" event="deactivate-rule"/>
198199
<rule type="inContextShowMerchantId" event="activate-rule"/>

app/code/Magento/Paypal/etc/adminhtml/rules/payment_es.xml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -85,6 +85,7 @@
8585
<rule type="paypalExpressMarkDisable" event="deactivate-rule">
8686
<argument name="wps_other">wps_other</argument>
8787
</rule>
88+
<rule type="simpleDisable" event="deactivate-rule"/>
8889
<rule type="inContextEnable" event="activate-rule"/>
8990
<rule type="inContextDisable" event="deactivate-rule"/>
9091
<rule type="inContextShowMerchantId" event="activate-rule"/>

app/code/Magento/Paypal/etc/adminhtml/rules/payment_fr.xml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -85,6 +85,7 @@
8585
<rule type="paypalExpressMarkDisable" event="deactivate-rule">
8686
<argument name="wps_other">wps_other</argument>
8787
</rule>
88+
<rule type="simpleDisable" event="deactivate-rule"/>
8889
<rule type="inContextEnable" event="activate-rule"/>
8990
<rule type="inContextDisable" event="deactivate-rule"/>
9091
<rule type="inContextShowMerchantId" event="activate-rule"/>

app/code/Magento/Paypal/etc/adminhtml/rules/payment_gb.xml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -85,6 +85,7 @@
8585
<rule type="paypalExpressMarkDisable" event="deactivate-rule">
8686
<argument name="wps_express">wps_express</argument>
8787
</rule>
88+
<rule type="simpleDisable" event="deactivate-rule"/>
8889
<rule type="inContextEnable" event="activate-rule"/>
8990
<rule type="inContextDisable" event="deactivate-rule"/>
9091
<rule type="inContextShowMerchantId" event="activate-rule"/>

app/code/Magento/Paypal/etc/adminhtml/rules/payment_hk.xml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -85,6 +85,7 @@
8585
<rule type="paypalExpressMarkDisable" event="deactivate-rule">
8686
<argument name="wps_other">wps_other</argument>
8787
</rule>
88+
<rule type="simpleDisable" event="deactivate-rule"/>
8889
<rule type="inContextEnable" event="activate-rule"/>
8990
<rule type="inContextDisable" event="deactivate-rule"/>
9091
<rule type="inContextShowMerchantId" event="activate-rule"/>

0 commit comments

Comments
 (0)