<?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="LoginAsCustomerUsingSignInLinkActionGroup">
        <annotations>
            <description>Clicks on 'Sign In' on the Storefront Checkout page. Fills in the provided Customer details (Email and Password). Clicks on Sign In.</description>
        </annotations>
        <arguments>
            <argument name="customer" type="entity"/>
        </arguments>
        
        <click selector="{{StorefrontCustomerSignInLinkSection.signInLink}}" stepKey="clickOnCustomizeAndAddToCartButton"/>
        <fillField selector="{{StorefrontCustomerSignInLinkSection.email}}" userInput="{{customer.email}}" stepKey="fillEmail"/>
        <fillField selector="{{StorefrontCustomerSignInLinkSection.password}}" userInput="{{customer.password}}" stepKey="fillPassword"/>
        <click selector="{{StorefrontCustomerSignInLinkSection.signInBtn}}" stepKey="clickSignInBtn"/>
    </actionGroup>
</actionGroups>
