<?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="AdminAdobeStockImsPopupSignInFillUserDataActionGroup">
        <arguments>
            <argument name="email" type="string" defaultValue="{{AdobeStockLogin.email}}"/>
            <argument name="password" type="string" defaultValue="{{AdobeStockLogin.password}}"/>
        </arguments>
        <executeJS function="return window.name;" stepKey="rootWindow"/>
        <switchToWindow userInput="authorization_widnow" stepKey="switchToNewTab"/>
        <fillField selector="{{AdminAdobeStockSection.adobeImsPopupUserEmail}}" userInput="{{email}}" stepKey="fillUserEmail" />
        <click selector="{{AdminAdobeStockSection.adobeImsPopUpUserPassword}}" stepKey="clickPasswordField" />
        <waitForPageLoad stepKey="waitForUserEmailToLoad"/>
        <fillField selector="{{AdminAdobeStockSection.adobeImsPopUpUserPassword}}" userInput="{{password}}" stepKey="fillUserPassword" />
    </actionGroup>
</actionGroups>
