Skip to content

Commit

Permalink
Merge pull request #6693 from magento-tsg/MQE-2538
Browse files Browse the repository at this point in the history
[Sidecar] MQE-2538: Create automated test for: "User uses pagination to navigate through the images in Standalone Media Gallery"
  • Loading branch information
zakdma authored Mar 19, 2021
2 parents 4559910 + 0bc55e4 commit 8b56d34
Show file tree
Hide file tree
Showing 4 changed files with 74 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
<?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="AdminAssertGridRecordsPerPageNumberActionGroup">
<annotations>
<description>Validates that the number of records per page on the Ui grid page is correct.</description>
</annotations>
<arguments>
<argument name="number" type="string" defaultValue="{{GridCountPerPageData.defaultCountPerPage}}"/>
</arguments>
<waitForElementVisible selector="{{AdminDataGridPaginationSection.perPageDropDownValue}}" stepKey="waitForDropdownVisible"/>
<seeInField selector="{{AdminDataGridPaginationSection.perPageDropDownValue}}" userInput="{{number}}" stepKey="seePerPageValueInDropDown"/>
</actionGroup>
</actionGroups>
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.
*/
-->
<actionGroups xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="urn:magento:mftf:Test/etc/actionGroupSchema.xsd">
<actionGroup name="AdminGridGoToCustomPageNumberActionGroup">
<annotations>
<description>Go to custom page of the admin grid.</description>
</annotations>
<arguments>
<argument name="pageNumber" defaultValue="15"/>
</arguments>
<waitForElementVisible selector="{{AdminDataGridPaginationSection.currentPage}}" stepKey="waitForInputVisible"/>
<clearField selector="{{AdminDataGridPaginationSection.currentPage}}" stepKey="clearInput"/>
<fillField selector="{{AdminDataGridPaginationSection.currentPage}}" userInput="{{pageNumber}}" stepKey="fillPageNumber"/>
<pressKey selector="{{AdminDataGridPaginationSection.currentPage}}" parameterArray="[\Facebook\WebDriver\WebDriverKeys::TAB]" stepKey="unFocusField"/>
<waitForPageLoad stepKey="waitForPageLoad" />
</actionGroup>
</actionGroups>
15 changes: 15 additions & 0 deletions app/code/Magento/Ui/Test/Mftf/Data/GridCountPerPageData.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
/**
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
-->

<entities xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="urn:magento:mftf:DataGenerator/etc/dataProfileSchema.xsd">
<entity name="GridCountPerPageData">
<data key="customCountPerPage">1</data>
<data key="defaultCountPerPage">32</data>
</entity>
</entities>
15 changes: 15 additions & 0 deletions app/code/Magento/Ui/Test/Mftf/Data/GridPageNumberData.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
/**
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
-->

<entities xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="urn:magento:mftf:DataGenerator/etc/dataProfileSchema.xsd">
<entity name="GridPageNumberData">
<data key="page2">2</data>
<data key="page4">4</data>
</entity>
</entities>

0 comments on commit 8b56d34

Please sign in to comment.