Skip to content

Commit 4b82dac

Browse files
Merge remote-tracking branch 'remotes/github/MAGETWO-91639' into EPAM-PR-21
2 parents ae00d48 + aa3c7ae commit 4b82dac

20 files changed

+500
-1
lines changed
Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
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+
<actionGroups xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
10+
xsi:noNamespaceSchemaLocation="urn:magento:mftf:Test/etc/actionGroupSchema.xsd">
11+
<actionGroup name="SetGroupForValidVATIdIntraUnionActionGroup">
12+
<arguments>
13+
<argument name="value" type="string"/>
14+
</arguments>
15+
<amOnPage url="{{AdminStoresCustomerConfigurationPage.url}}" stepKey="navigateToCustomerConfigurationPage" />
16+
<waitForPageLoad stepKey="waitForPageLoad"/>
17+
<conditionalClick stepKey="expandCreateNewAccountOptionsTab" selector="{{AdminStoresCustomerConfigurationSection.createNewAccOpt}}" dependentSelector="{{AdminStoresCustomerConfigurationSection.enableAutoAssignCustomerGroup}}" visible="false"/>
18+
<waitForElementVisible selector="{{AdminStoresCustomerConfigurationSection.createNewAccOpt}}" stepKey="waitForElementsAppeared"/>
19+
<selectOption selector="{{AdminStoresCustomerConfigurationSection.groupForValidVATIdIntraUnion}}" userInput="{{value}}" stepKey="selectValue"/>
20+
<click selector="{{AdminStoresCustomerConfigurationSection.createNewAccOpt}}" stepKey="collapseTab" />
21+
<click selector="{{ContentManagementSection.Save}}" stepKey="saveConfig"/>
22+
<waitForPageLoad stepKey="waitForConfigSaved"/>
23+
<see userInput="You saved the configuration." stepKey="seeSuccessMessage"/>
24+
</actionGroup>
25+
</actionGroups>
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
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+
<pages xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:mftf:Page/etc/PageObject.xsd">
9+
<page name="AdminStoresCustomerConfigurationPage" url="admin/system_config/edit/section/customer/" area="admin" module="Magento_Config">
10+
<section name="AdminStoresCustomerConfigurationSection"/>
11+
</page>
12+
</pages>
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
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+
<sections xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:mftf:Page/etc/SectionObject.xsd">
9+
<section name="AdminStoresCustomerConfigurationSection">
10+
<element name="createNewAccOpt" type="button" selector="#customer_create_account-head"/>
11+
<element name="enableAutoAssignCustomerGroup" type="button" selector="#customer_create_account_auto_group_assign"/>
12+
<element name="groupForValidVATIdIntraUnion" type="select" selector="#customer_create_account_viv_intra_union_group"/>
13+
</section>
14+
</sections>
Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
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+
<actionGroups xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
9+
xsi:noNamespaceSchemaLocation="urn:magento:mftf:Test/etc/actionGroupSchema.xsd">
10+
<actionGroup name="AdminCreateCustomerGroupActionGroup">
11+
<arguments>
12+
<argument name="groupName" type="string"/>
13+
<argument name="taxClass" type="string"/>
14+
</arguments>
15+
<amOnPage url="{{AdminNewCustomerGroupPage.url}}" stepKey="goToNewCustomerGroupPage"/>
16+
<waitForPageLoad stepKey="waitForNewCustomerGroupPageLoad"/>
17+
18+
<!--Set tax class for customer group-->
19+
<fillField stepKey="fillGroupName" selector="{{AdminNewCustomerGroupSection.groupName}}" userInput="{{groupName}}"/>
20+
<selectOption selector="{{AdminNewCustomerGroupSection.taxClass}}" userInput="{{taxClass}}" stepKey="selectTaxClassOption"/>
21+
<click selector="{{AdminNewCustomerGroupSection.saveCustomerGroup}}" stepKey="clickToSaveCustomerGroup"/>
22+
<waitForPageLoad stepKey="waitForCustomerGroupSaved"/>
23+
<see stepKey="seeCustomerGroupSaveMessage" userInput="You saved the customer group."/>
24+
</actionGroup>
25+
</actionGroups>

app/code/Magento/Customer/Test/Mftf/ActionGroup/AdminDeleteCustomerGroupActionGroup.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
-->
88

99
<actionGroups xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
10-
xsi:noNamespaceSchemaLocation="../../../../../../../dev/tests/acceptance/vendor/magento/magento2-functional-testing-framework/src/Magento/FunctionalTestingFramework/Test/etc/actionGroupSchema.xsd">
10+
xsi:noNamespaceSchemaLocation="urn:magento:mftf:Test/etc/actionGroupSchema.xsd">
1111
<actionGroup name="AdminDeleteCustomerGroupActionGroup">
1212
<arguments>
1313
<argument name="customerGroupName" type="string"/>

app/code/Magento/Customer/Test/Mftf/ActionGroup/SignUpNewUserFromStorefrontActionGroup.xml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -46,4 +46,9 @@
4646

4747
<click stepKey="saveAddress" selector="{{StorefrontCustomerAddressSection.saveAddress}}"/>
4848
</actionGroup>
49+
50+
<actionGroup name="SignUpNewCustomerStorefrontActionGroup" extends="SignUpNewUserFromStorefrontActionGroup">
51+
<waitForPageLoad stepKey="waitForRegistered" after="clickCreateAccountButton"/>
52+
<remove keyForRemoval="seeThankYouMessage" after="waitForRegistered"/>
53+
</actionGroup>
4954
</actionGroups>

app/code/Magento/Customer/Test/Mftf/Data/AddressData.xml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -108,4 +108,11 @@
108108
<data key="country_id">GB</data>
109109
<data key="telephone">444-44-444-44</data>
110110
</entity>
111+
<entity name="UK_Simple_Address" extends="UK_Not_Default_Address">
112+
<array key="street">
113+
<item>172, Westminster Bridge Rd</item>
114+
<item>7700 xyz street</item>
115+
</array>
116+
<data key="state">California</data>
117+
</entity>
111118
</entities>
Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
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+
<entities xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
10+
xsi:noNamespaceSchemaLocation="urn:magento:mftf:DataGenerator/etc/dataProfileSchema.xsd">
11+
<entity name="SetCustomerCreateNewAccountOptionsConfig" type="customer_create_new_account_config">
12+
<requiredEntity type="auto_group_assign">EnableAutomaticAssignmentCustomerGroup</requiredEntity>
13+
<requiredEntity type="viv_on_each_transaction">EnableValidateEachTransaction</requiredEntity>
14+
<requiredEntity type="vat_frontend_visibility">EnableShowVATNumberStorefront</requiredEntity>
15+
</entity>
16+
<entity name="EnableAutomaticAssignmentCustomerGroup" type="auto_group_assign">
17+
<data key="value">1</data>
18+
</entity>
19+
<entity name="EnableValidateEachTransaction" type="viv_on_each_transaction">
20+
<data key="value">1</data>
21+
</entity>
22+
<entity name="EnableShowVATNumberStorefront" type="vat_frontend_visibility">
23+
<data key="value">1</data>
24+
</entity>
25+
26+
<entity name="SetCustomerCreateNewAccountOptionsDefaultConfig" type="customer_create_new_account_config">
27+
<requiredEntity type="auto_group_assign">DefaultAutomaticAssignmentCustomerGroup</requiredEntity>
28+
<requiredEntity type="viv_on_each_transaction">DefaultValidateEachTransaction</requiredEntity>
29+
<requiredEntity type="vat_frontend_visibility">DefaultShowVATNumberStorefront</requiredEntity>
30+
</entity>
31+
<entity name="DefaultAutomaticAssignmentCustomerGroup" type="auto_group_assign">
32+
<data key="value">0</data>
33+
</entity>
34+
<entity name="DefaultValidateEachTransaction" type="viv_on_each_transaction">
35+
<data key="value">0</data>
36+
</entity>
37+
<entity name="DefaultShowVATNumberStorefront" type="vat_frontend_visibility">
38+
<data key="value">0</data>
39+
</entity>
40+
</entities>
Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
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+
<operations xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
10+
xsi:noNamespaceSchemaLocation="urn:magento:mftf:DataGenerator/etc/dataOperation.xsd">
11+
<operation name="CustomerCreateNewAccountOptionsConfigState" dataType="customer_create_new_account_config" type="create" auth="adminFormKey" url="/admin/system_config/save/section/customer/" method="POST">
12+
<object key="groups" dataType="customer_create_new_account_config">
13+
<object key="create_account" dataType="customer_create_new_account_config">
14+
<object key="fields" dataType="customer_create_new_account_config">
15+
<object key="auto_group_assign" dataType="auto_group_assign">
16+
<field key="value">string</field>
17+
</object>
18+
<object key="viv_on_each_transaction" dataType="viv_on_each_transaction">
19+
<field key="value">string</field>
20+
</object>
21+
<object key="vat_frontend_visibility" dataType="vat_frontend_visibility">
22+
<field key="value">string</field>
23+
</object>
24+
</object>
25+
</object>
26+
</object>
27+
</operation>
28+
</operations>
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
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+
<pages xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
10+
xsi:noNamespaceSchemaLocation="urn:magento:mftf:Page/etc/PageObject.xsd">
11+
<page name="AdminCustomerGroupPage" url="/customer/group/" area="admin" module="Magento_Customer">
12+
<section name="AdminCustomerGroupMainSection"/>
13+
</page>
14+
</pages>

0 commit comments

Comments
 (0)