Skip to content
This repository has been archived by the owner on Dec 19, 2019. It is now read-only.

Commit

Permalink
Merge pull request #126 from magento-pangolin/MC-4558
Browse files Browse the repository at this point in the history
MC-4558
  • Loading branch information
tomreece authored May 20, 2019
2 parents 0125d0e + f1ccd1a commit 3e224f0
Show file tree
Hide file tree
Showing 4 changed files with 53 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -39,5 +39,6 @@
<element name="editActiveAddress" type="button" selector="//div[@class='shipping-address-item selected-item']//span[text()='Edit']" timeout="30"/>
<element name="loginButton" type="button" selector=".action.login" timeout="30"/>
<element name="shipHereButton" type="button" selector="//div[text()='{{street}}']/button[@class='action action-select-shipping-item']" parameterized="true" timeout="30"/>
<element name="textFieldAttribute" selector="[name*='custom_attributes[{{attribute}}]']" parameterized="true" timeout="30"/>
</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.
*/
-->
<actionGroups xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="urn:magento:mftf:Test/etc/actionGroupSchema.xsd">
<actionGroup name="AdminSaveCustomerAddressActionGroup">
<click selector="{{StorefrontCustomerAddressFormSection.saveAddress}}" stepKey="saveCustomerAddress"/>
<see selector="{{AdminMessagesSection.successMessage}}" userInput="You saved the address." stepKey="seeSuccessMessage"/>
</actionGroup>
</actionGroups>
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
/**
* Copyright © Magento, Inc. All rights reserved.
* 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="FillNewCustomerAddressRequiredFieldsActionGroup">
<arguments>
<argument name="address" type="entity"/>
</arguments>
<fillField selector="{{StorefrontCustomerAddressFormSection.firstName}}" userInput="{{address.firstname}}" stepKey="fillFirstName"/>
<fillField selector="{{StorefrontCustomerAddressFormSection.lastName}}" userInput="{{address.lastname}}" stepKey="fillLastName"/>
<fillField selector="{{StorefrontCustomerAddressFormSection.phoneNumber}}" userInput="{{address.telephone}}" stepKey="fillPhoneNumber"/>
<fillField selector="{{StorefrontCustomerAddressFormSection.streetAddress}}" userInput="{{address.street[0]}}" stepKey="fillStreetAddress"/>
<fillField selector="{{StorefrontCustomerAddressFormSection.city}}" userInput="{{address.city}}" stepKey="fillCity"/>
<selectOption selector="{{StorefrontCustomerAddressFormSection.state}}" userInput="{{address.state}}" stepKey="selectState"/>
<fillField selector="{{StorefrontCustomerAddressFormSection.zip}}" userInput="{{address.postcode}}" stepKey="fillZip"/>
<selectOption selector="{{StorefrontCustomerAddressFormSection.country}}" userInput="{{address.country}}" stepKey="selectCountry"/>
</actionGroup>
</actionGroups>
14 changes: 14 additions & 0 deletions app/code/Magento/Customer/Test/Mftf/Data/AddressData.xml
Original file line number Diff line number Diff line change
Expand Up @@ -284,4 +284,18 @@
<data key="telephone">333-33-333-33</data>
<data key="country">Germany</data>
</entity>
<entity name="US_Address_California">
<data key="firstname">John</data>
<data key="lastname">Doe</data>
<data key="company">Magento</data>
<array key="street">
<item>6161 West Centinela Avenue</item>
</array>
<data key="city">Culver City</data>
<data key="country_id">United States</data>
<data key="country">United States</data>
<data key="state">California</data>
<data key="postcode">90230</data>
<data key="telephone">555-55-555-55</data>
</entity>
</entities>

0 comments on commit 3e224f0

Please sign in to comment.