Skip to content

Commit

Permalink
Merge pull request #3557 from magento-pangolin/MQE-1393-New-Customer-…
Browse files Browse the repository at this point in the history
…Action-Group

[MFTF] MQE-1393 - Add new Customer action group
  • Loading branch information
okolesnyk authored Jan 31, 2019
2 parents 97fd70f + 13aad1f commit 8222455
Show file tree
Hide file tree
Showing 64 changed files with 264 additions and 97 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
-->

<pages xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="../../../../../../../dev/tests/acceptance/vendor/magento/magento2-functional-testing-framework/src/Magento/FunctionalTestingFramework/Page/etc/PageObject.xsd">
xsi:noNamespaceSchemaLocation="urn:magento:mftf:Page/etc/PageObject.xsd">
<page name="AdminDashboardPage" url="admin/dashboard/" area="admin" module="Magento_Backend">
<section name="AdminMenuSection"/>
</page>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@
* See COPYING.txt for license details.
*/
-->

<actionGroups xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="urn:magento:mftf:Test/etc/actionGroupSchema.xsd">

<actionGroup name="AdminOrderBraintreeFillActionGroup">
<!--Select Braintree Payment method on Admin Order Create Page-->
<click stepKey="chooseBraintree" selector="{{NewOrderSection.creditCardBraintree}}"/>
Expand Down Expand Up @@ -39,4 +39,4 @@
<wait stepKey="waitForFillCVV" time="1"/>
<switchToIFrame stepKey="switchBackFromCVV"/>
</actionGroup>
</actionGroups>
</actionGroups>
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@
* See COPYING.txt for license details.
*/
-->
<actionGroups xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="../../../../../../../dev/tests/acceptance/vendor/magento/magento2-functional-testing-framework/src/Magento/FunctionalTestingFramework/Test/etc/actionGroupSchema.xsd">

<actionGroups xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="urn:magento:mftf:Test/etc/actionGroupSchema.xsd">
<actionGroup name="GoToUserRoles">
<click selector="#menu-magento-backend-system" stepKey="clickOnSystemIcon"/>
<waitForPageLoad stepKey="waitForSystemsPageToOpen"/>
Expand All @@ -34,7 +34,6 @@
<see userInput="You saved the role." stepKey="seeSuccessMessage" />
</actionGroup>


<!--Delete role-->
<actionGroup name="AdminDeleteRoleActionGroup">
<arguments>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@
* See COPYING.txt for license details.
*/
-->
<actionGroups xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="../../../../../../../dev/tests/acceptance/vendor/magento/magento2-functional-testing-framework/src/Magento/FunctionalTestingFramework/Test/etc/actionGroupSchema.xsd">

<actionGroups xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="urn:magento:mftf:Test/etc/actionGroupSchema.xsd">
<!--Go to all users-->
<actionGroup name="GoToAllUsers">
<click selector="{{AdminCreateUserSection.system}}" stepKey="clickOnSystemIcon"/>
Expand Down Expand Up @@ -39,7 +39,6 @@
<see userInput="You saved the user." stepKey="seeSuccessMessage" />
</actionGroup>


<!--Delete User-->
<actionGroup name="AdminDeleteNewUserActionGroup">

Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
/**
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
-->

<sections xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="urn:magento:mftf:Page/etc/SectionObject.xsd">
<section name="AdminEditRoleInfoSection">
<element name="roleName" type="input" selector="#role_name"/>
<element name="password" type="input" selector="#current_password"/>
<element name="roleResourcesTab" type="button" selector="#role_info_tabs_account"/>
<element name="backButton" type="button" selector="button[title='Back']"/>
<element name="resetButton" type="button" selector="button[title='Reset']"/>
<element name="deleteButton" type="button" selector="button[title='Delete Role']"/>
<element name="saveButton" type="button" selector="button[title='Save Role']"/>
<element name="message" type="text" selector=".modal-popup.confirm div.modal-content"/>
<element name="cancel" type="button" selector=".modal-popup.confirm button.action-dismiss"/>
<element name="ok" type="button" selector=".modal-popup.confirm button.action-accept" timeout="60"/>
</section>
</sections>
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
/**
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
-->

<sections xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="urn:magento:mftf:Page/etc/SectionObject.xsd">
<section name="AdminEditUserRoleSection">
<element name="usernameTextField" type="input" selector="#user_username"/>
<element name="roleNameFilterTextField" type="input" selector="#permissionsUserRolesGrid_filter_role_name"/>
<element name="searchButton" type="button" selector=".admin__data-grid-header button[title=Search]"/>
<element name="resetButton" type="button" selector="button[title='Reset Filter']"/>
<element name="roleNameInFirstRow" type="text" selector=".col-role_name"/>
<element name="searchResultFirstRow" type="text" selector=".data-grid>tbody>tr"/>
</section>
</sections>
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
/**
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
-->

<sections xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="urn:magento:mftf:Page/etc/SectionObject.xsd">
<section name="AdminEditUserSection">
<element name="system" type="input" selector="#menu-magento-backend-system"/>
<element name="allUsers" type="input" selector="//span[contains(text(), 'All Users')]"/>
<element name="create" type="input" selector="#add"/>
<element name="usernameTextField" type="input" selector="#user_username"/>
<element name="firstNameTextField" type="input" selector="#user_firstname"/>
<element name="lastNameTextField" type="input" selector="#user_lastname"/>
<element name="emailTextField" type="input" selector="#user_email"/>
<element name="passwordTextField" type="input" selector="#user_password"/>
<element name="pwConfirmationTextField" type="input" selector="#user_confirmation"/>
<element name="currentPasswordField" type="input" selector="#user_current_password"/>
<element name="userRoleTab" type="button" selector="#page_tabs_roles_section"/>
<element name="roleNameFilterTextField" type="input" selector="#permissionsUserRolesGrid_filter_role_name"/>
<element name="searchButton" type="button" selector=".admin__data-grid-header button[title=Search]"/>
<element name="resetButton" type="button" selector="button[title='Reset Filter']"/>
<element name="roleNameInFirstRow" type="text" selector=".col-role_name"/>
<element name="searchResultFirstRow" type="text" selector=".data-grid>tbody>tr"/>
<element name="saveButton" type="button" selector="#save"/>
</section>
</sections>
23 changes: 23 additions & 0 deletions app/code/Magento/Braintree/Test/Mftf/Section/AdminMenuSection.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
/**
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
-->

<sections xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="urn:magento:mftf:Page/etc/SectionObject.xsd">
<section name="AdminMenuSection">
<element name="dashboard" type="button" selector="//li[@id='menu-magento-backend-dashboard']"/>
<element name="sales" type="button" selector="//li[@id='menu-magento-sales-sales']"/>
<element name="catalog" type="button" selector="//li[@id='menu-magento-catalog-catalog']"/>
<element name="customers" type="button" selector="//li[@id='menu-magento-customer-customer']"/>
<element name="marketing" type="button" selector="//li[@id='menu-magento-backend-marketing']"/>
<element name="content" type="button" selector="//li[@id='menu-magento-backend-content']"/>
<element name="reports" type="button" selector="//li[@id='menu-magento-reports-report']"/>
<element name="stores" type="button" selector="//li[@id='menu-magento-backend-stores']"/>
<element name="system" type="button" selector="//li[@id='menu-magento-backend-system']"/>
<element name="findPartners" type="button" selector="//li[@id='menu-magento-marketplace-partners']"/>
</section>
</sections>
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
/**
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
-->

<sections xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="urn:magento:mftf:Page/etc/SectionObject.xsd">
<section name="AdminRoleGridSection">
<element name="idFilterTextField" type="input" selector="#roleGrid_filter_role_id"/>
<element name="roleNameFilterTextField" type="input" selector="#roleGrid_filter_role_name"/>
<element name="searchButton" type="button" selector=".admin__data-grid-header button[title=Search]"/>
<element name="resetButton" type="button" selector="button[title='Reset Filter']"/>
<element name="roleNameInFirstRow" type="text" selector=".col-role_name"/>
<element name="searchResultFirstRow" type="text" selector=".data-grid>tbody>tr"/>
</section>
</sections>
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
* See COPYING.txt for license details.
*/
-->

<sections xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="urn:magento:mftf:Page/etc/SectionObject.xsd">
<section name="BraintreeConfiguraionSection">
Expand All @@ -30,6 +31,5 @@
<element name="actionAuthorize" type="text" selector="//select[@id='payment_us_braintree_section_braintree_braintree_paypal_payment_action']/option[text()='Authorize']"/>
<element name="save" type="button" selector="//span[text()='Save Config']"/>
<element name="successfulMessage" type="text" selector="//*[@data-ui-id='messages-message-success']"/>

</section>
</sections>
</sections>
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@

<sections xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="urn:magento:mftf:Page/etc/SectionObject.xsd">
<section name="ConfigurationPaymentSection">
<section name="ConfigurationPaymentSection">
<element name="configureButton" type="button" selector="//button[@id='payment_us_braintree_section_braintree-head']"/>
</section>
</sections>
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
/**
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
-->

<sections xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="urn:magento:mftf:Page/etc/SectionObject.xsd">
<section name="StoresSubmenuSection">
<element name="configuration" type="button" selector="//li[@id='menu-magento-backend-stores']//li[@data-ui-id='menu-magento-config-system-config']"/>
</section>
</sections>
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,10 @@
* See COPYING.txt for license details.
*/
-->

<actionGroups xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="urn:magento:mftf:Test/etc/actionGroupSchema.xsd">
<actionGroup name="CreateNewProductActionGroup">

<actionGroup name="CreateNewProductActionGroup">
<click stepKey="openCatalog" selector="{{AdminMenuSection.catalog}}"/>
<waitForPageLoad stepKey="waitForCatalogSubmenu" time="5"/>
<click stepKey="clickOnProducts" selector="{{CatalogSubmenuSection.products}}"/>
Expand All @@ -22,4 +22,4 @@
<waitForElementVisible stepKey="waitForSuccessfullyCreatedMessage" selector="{{NewProductPageSection.createdSuccessMessage}}" time="10"/>
<waitForPageLoad stepKey="waitForPageLoad" time="10"/>
</actionGroup>
</actionGroups>
</actionGroups>
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
* See COPYING.txt for license details.
*/
-->

<actionGroups xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="urn:magento:mftf:Test/etc/actionGroupSchema.xsd">
<actionGroup name="DeleteProductActionGroup">
Expand All @@ -23,4 +24,4 @@
<click stepKey="clickOnOk" selector="{{ProductsPageSection.ok}}"/>
<waitForElementVisible stepKey="waitForSuccessfullyDeletedMessage" selector="{{ProductsPageSection.deletedSuccessMessage}}" time="10"/>
</actionGroup>
</actionGroups>
</actionGroups>
3 changes: 1 addition & 2 deletions app/code/Magento/Catalog/Test/Mftf/Data/CatalogPriceData.xml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
-->

<entities xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="../../../../../../../dev/tests/acceptance/vendor/magento/magento2-functional-testing-framework/src/Magento/FunctionalTestingFramework/DataGenerator/etc/dataProfileSchema.xsd">
xsi:noNamespaceSchemaLocation="urn:magento:mftf:DataGenerator/etc/dataProfileSchema.xsd">
<entity name="CatalogPriceScopeWebsite" type="catalog_price_config_state">
<requiredEntity type="scope">scopeWebsite</requiredEntity>
<requiredEntity type="default_product_price">defaultProductPrice</requiredEntity>
Expand All @@ -29,5 +29,4 @@
<entity name="defaultProductPrice" type="default_product_price">
<data key="value"/>
</entity>

</entities>
1 change: 0 additions & 1 deletion app/code/Magento/Catalog/Test/Mftf/Data/NewProductData.xml
Original file line number Diff line number Diff line change
Expand Up @@ -13,5 +13,4 @@
<data key="Price">100</data>
<data key="Quantity">100</data>
</entity>

</entities>
2 changes: 1 addition & 1 deletion app/code/Magento/Catalog/Test/Mftf/Data/TierPriceData.xml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
-->

<entities xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="../../../../../../../dev/tests/acceptance/vendor/magento/magento2-functional-testing-framework/src/Magento/FunctionalTestingFramework/DataGenerator/etc/dataProfileSchema.xsd">
xsi:noNamespaceSchemaLocation="urn:magento:mftf:DataGenerator/etc/dataProfileSchema.xsd">
<entity name="testDataTierPrice" type="data">
<data key="goldenPrice1">$676.50</data>
<data key="goldenPrice2">$615.00</data>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,9 @@
* See COPYING.txt for license details.
*/
-->

<operations xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="../../../../../../../dev/tests/acceptance/vendor/magento/magento2-functional-testing-framework/src/Magento/FunctionalTestingFramework/DataGenerator/etc/dataOperation.xsd">
xsi:noNamespaceSchemaLocation="urn:magento:mftf:DataGenerator/etc/dataOperation.xsd">
<operation name="CatalogPriceConfigState" dataType="catalog_price_config_state" type="create" auth="adminFormKey" url="/admin/system_config/save/section/catalog/" method="POST">
<object key="groups" dataType="catalog_price_config_state">
<object key="price" dataType="catalog_price_config_state">
Expand All @@ -21,4 +22,4 @@
</object>
</object>
</operation>
</operations>
</operations>
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,5 @@
<element name="delete" type="button" selector="//*[contains(@class,'admin__data-grid-header-row row row-gutter')]//*[text()='Delete']"/>
<element name="ok" type="button" selector="//button[@data-role='action']//span[text()='OK']"/>
<element name="deletedSuccessMessage" type="button" selector="//*[@class='message message-success success']"/>

</section>
</sections>
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
-->

<sections xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="../../../../../../../dev/tests/acceptance/vendor/magento/magento2-functional-testing-framework/src/Magento/FunctionalTestingFramework/Page/etc/SectionObject.xsd">
xsi:noNamespaceSchemaLocation="urn:magento:mftf:Page/etc/SectionObject.xsd">
<section name="StorefrontMiniCartSection">
<element name="quantity" type="button" selector="span.counter-number"/>
<element name="show" type="button" selector="a.showcart"/>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
xsi:noNamespaceSchemaLocation="urn:magento:mftf:Test/etc/testSchema.xsd">
<test name="AdminFilteringCategoryProductsUsingScopeSelectorTest">
<annotations>
<features value="Catalog"/>
<stories value="Filtering Category Products"/>
<title value="Filtering Category Products using scope selector"/>
<description value="Filtering Category Products using scope selector"/>
<severity value="MAJOR"/>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
-->

<tests xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="../../../../../../../dev/tests/acceptance/vendor/magento/magento2-functional-testing-framework/src/Magento/FunctionalTestingFramework/Test/etc/testSchema.xsd">
xsi:noNamespaceSchemaLocation="urn:magento:mftf:Test/etc/testSchema.xsd">
<test name="TieredPricingAndQuantityIncrementsWorkWithDecimalinventoryTest">
<annotations>
<features value="Catalog"/>
Expand Down Expand Up @@ -84,4 +84,4 @@
<click selector="{{CheckoutCartProductSection.updateShoppingCartButton}}" stepKey="clickOnUpdateShoppingCartButton"/>
<seeInField userInput="5.5" selector="{{CheckoutCartProductSection.ProductQuantityByName(('$$createPreReqSimpleProduct.name$$'))}}" stepKey="seeInField2"/>
</test>
</tests>
</tests>
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@
* See COPYING.txt for license details.
*/
-->
<actionGroups xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="../../../../../../../dev/tests/acceptance/vendor/magento/magento2-functional-testing-framework/src/Magento/FunctionalTestingFramework/Test/etc/actionGroupSchema.xsd">

<actionGroups xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="urn:magento:mftf:Test/etc/actionGroupSchema.xsd">
<!--Assert That Shipping And Billing Address are the same-->
<actionGroup name="AssertThatShippingAndBillingAddressTheSame">
<!--Get shipping and billing addresses-->
Expand All @@ -18,5 +18,4 @@
<see userInput="Billing Address" stepKey="seeBillingAddress"/>
<assertEquals stepKey="assert" actual="$billingAddr" expected="$shippingAddr"/>
</actionGroup>

</actionGroups>
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
-->

<actionGroups xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="../../../../../../../dev/tests/acceptance/vendor/magento/magento2-functional-testing-framework/src/Magento/FunctionalTestingFramework/Test/etc/actionGroupSchema.xsd">
xsi:noNamespaceSchemaLocation="urn:magento:mftf:Test/etc/actionGroupSchema.xsd">
<!--Fill shipment form for free shipping-->
<actionGroup name="ShipmentFormFreeShippingActionGroup">
<fillField selector="{{CheckoutShippingSection.email}}" userInput="{{CustomerEntityOne.email}}" stepKey="setCustomerEmail"/>
Expand All @@ -26,4 +26,4 @@
<waitForPageLoad time="5" stepKey="waitForReviewAndPaymentsPageIsLoaded"/>
<seeInCurrentUrl url="payment" stepKey="reviewAndPaymentIsShown"/>
</actionGroup>
</actionGroups>
</actionGroups>
Loading

0 comments on commit 8222455

Please sign in to comment.