-
Notifications
You must be signed in to change notification settings - Fork 9.4k
Grid search selectall issue #29968
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
magento-engcom-team
merged 9 commits into
magento:2.4-develop
from
engcom-Hotel:grid_search_selectall_issue
Sep 19, 2020
Merged
Grid search selectall issue #29968
Changes from 4 commits
Commits
Show all changes
9 commits
Select commit
Hold shift + click to select a range
1f6e82f
Fix for multiselect with search on grid.
engcom-Hotel e837bdc
Fix for select all on page on grid.
engcom-Hotel 591e04e
Reformat for static test.
engcom-Hotel 8a9546f
Merge branch '2.4-develop' into grid_search_selectall_issue
engcom-Hotel f019712
Moved MFTF to the customer module.
engcom-Hotel 4a20d6e
Merge remote-tracking branch 'engcom-Hotel/grid_search_selectall_issu…
engcom-Hotel 70df4f0
add testCaseId
engcom-Charlie a85a63b
add testCaseId to AdminGridSelectAllOnPageTest
engcom-Charlie 462f123
Merge branch '2.4-develop' into grid_search_selectall_issue
engcom-Hotel File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
20 changes: 20 additions & 0 deletions
20
app/code/Magento/Ui/Test/Mftf/ActionGroup/AdminGridSelectAllActionGroup.xml
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
<?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="AdminGridSelectAllActionGroup"> | ||
<annotations> | ||
<description>Click on select all option on the grid</description> | ||
</annotations> | ||
|
||
<waitForElementVisible selector="{{AdminGridSelectRows.multicheckDropdown}}" stepKey="waitForElement"/> | ||
<click selector="{{AdminGridSelectRows.multicheckDropdown}}" stepKey="openMulticheckDropdown"/> | ||
<click selector="{{AdminGridSelectRows.multicheckOption('Select All')}}" stepKey="clickSelectAllCustomers"/> | ||
</actionGroup> | ||
</actionGroups> |
56 changes: 56 additions & 0 deletions
56
app/code/Magento/Ui/Test/Mftf/Test/AdminGridSearchSelectAllTest.xml
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,56 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<!-- | ||
/** | ||
* Copyright © Magento, Inc. All rights reserved. | ||
* See COPYING.txt for license details. | ||
*/ | ||
--> | ||
|
||
<tests xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:mftf:Test/etc/testSchema.xsd"> | ||
<test name="AdminGridSearchSelectAllTest"> | ||
<annotations> | ||
<stories value="Selection should be removed during search."/> | ||
<title value="Selection should be removed during search."/> | ||
<description value="Empty selected before and after search, like it works for filter"/> | ||
<testCaseId value=""/> | ||
gabrieldagama marked this conversation as resolved.
Show resolved
Hide resolved
|
||
<severity value="CRITICAL"/> | ||
<group value="uI"/> | ||
</annotations> | ||
<before> | ||
<actionGroup ref="AdminLoginActionGroup" stepKey="loginAsAdmin"/> | ||
<!--Create three customers--> | ||
<createData entity="Simple_US_Customer" stepKey="firstCustomer"/> | ||
<createData entity="Simple_US_Customer" stepKey="secondCustomer"/> | ||
<createData entity="Simple_US_Customer" stepKey="thirdCustomer"/> | ||
</before> | ||
<after> | ||
<!--Remove two created customers, third already deleted--> | ||
<deleteData createDataKey="firstCustomer" stepKey="deleteFirstCustomer"/> | ||
<deleteData createDataKey="secondCustomer" stepKey="deleteSecondCustomer"/> | ||
<actionGroup ref="AdminLogoutActionGroup" stepKey="logout"/> | ||
</after> | ||
<amOnPage url="{{AdminCustomerPage.url}}" stepKey="openCustomerPage"/> | ||
<!-- search Admin Data Grid By Keyword --> | ||
<conditionalClick selector="{{AdminDataGridHeaderSection.clearFilters}}" dependentSelector="{{AdminDataGridHeaderSection.clearFilters}}" visible="true" stepKey="clickClearFilters"/> | ||
<fillField selector="{{AdminDataGridHeaderSection.search}}" userInput="$$secondCustomer.email$$" stepKey="fillKeywordSearchFieldWithSecondCustomerEmail"/> | ||
<click selector="{{AdminDataGridHeaderSection.submitSearch}}" stepKey="clickKeywordSearch"/> | ||
<waitForPageLoad stepKey="waitForPageLoad"/> | ||
<!-- Select all from dropdown --> | ||
<actionGroup ref="AdminGridSelectAllActionGroup" stepKey="selectAllCustomers"/> | ||
<!-- Clear searching By Keyword--> | ||
<conditionalClick selector="{{AdminDataGridHeaderSection.clearFilters}}" dependentSelector="{{AdminDataGridHeaderSection.clearFilters}}" visible="true" stepKey="clickClearFiltersAfterSearch"/> | ||
<waitForPageLoad stepKey="waitForPageLoadAfterSearchRemoved"/> | ||
<!-- Check if selection has bee removed --> | ||
<dontSeeCheckboxIsChecked selector="{{AdminCustomerGridMainActionsSection.customerCheckbox($$secondCustomer.email$$)}}" stepKey="checkSecondCustomerCheckboxIsUnchecked"/> | ||
<!-- Check delete action --> | ||
<click selector="{{AdminCustomerGridMainActionsSection.customerCheckbox(($$thirdCustomer.email$$)}}" stepKey="selectThirdCustomer"/> | ||
<seeCheckboxIsChecked selector="{{AdminCustomerGridMainActionsSection.customerCheckbox($$thirdCustomer.email$$)}}" stepKey="checkThirdCustomerIsChecked"/> | ||
<!-- Use delete action for selected --> | ||
<click selector="{{AdminCustomerGridMainActionsSection.actions}}" stepKey="clickActions"/> | ||
<click selector="{{AdminCustomerGridMainActionsSection.delete}}" stepKey="clickDelete"/> | ||
<waitForAjaxLoad stepKey="waitForLoadConfirmation"/> | ||
<click selector="{{AdminConfirmationModalSection.ok}}" stepKey="confirmDelete"/> | ||
<!-- Check if only one record record has been deleted --> | ||
<see selector="{{AdminMessagesSection.success}}" userInput="A total of 1 record(s) were deleted" stepKey="seeSuccess"/> | ||
</test> | ||
</tests> |
55 changes: 55 additions & 0 deletions
55
app/code/Magento/Ui/Test/Mftf/Test/AdminGridSelectAllOnPageTest.xml
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,55 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<!-- | ||
/** | ||
* Copyright © Magento, Inc. All rights reserved. | ||
* See COPYING.txt for license details. | ||
*/ | ||
--> | ||
|
||
<tests xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:mftf:Test/etc/testSchema.xsd"> | ||
<test name="AdminGridSelectAllOnPageTest"> | ||
gabrieldagama marked this conversation as resolved.
Show resolved
Hide resolved
|
||
<annotations> | ||
<stories value="Toggle select page."/> | ||
<title value="Toggle select page."/> | ||
<description value="Empty selected before and after search, like it works for filter"/> | ||
<testCaseId value=""/> | ||
gabrieldagama marked this conversation as resolved.
Show resolved
Hide resolved
|
||
<severity value="CRITICAL"/> | ||
<group value="uI"/> | ||
</annotations> | ||
<before> | ||
<actionGroup ref="AdminLoginActionGroup" stepKey="loginAsAdmin"/> | ||
<!--Create three customers--> | ||
<createData entity="Simple_US_Customer" stepKey="firstCustomer"/> | ||
<createData entity="Simple_US_Customer" stepKey="secondCustomer"/> | ||
<createData entity="Simple_US_Customer" stepKey="thirdCustomer"/> | ||
</before> | ||
<after> | ||
<!--Remove created customers --> | ||
<deleteData createDataKey="firstCustomer" stepKey="deleteFirstCustomer"/> | ||
<deleteData createDataKey="secondCustomer" stepKey="deleteSecondCustomer"/> | ||
<deleteData createDataKey="thirdCustomer" stepKey="deleteThirdCustomer"/> | ||
<actionGroup ref="AdminLogoutActionGroup" stepKey="logout"/> | ||
</after> | ||
<amOnPage url="{{AdminCustomerPage.url}}" stepKey="openCustomerPage"/> | ||
<!-- Select all from dropdown --> | ||
<actionGroup ref="AdminGridSelectAllActionGroup" stepKey="selectAllCustomers"/> | ||
<!-- Deselect third customer --> | ||
<click selector="{{AdminCustomerGridMainActionsSection.customerCheckbox(($$thirdCustomer.email$$)}}" stepKey="selectThirdCustomer"/> | ||
<dontSeeCheckboxIsChecked selector="{{AdminCustomerGridMainActionsSection.customerCheckbox($$thirdCustomer.email$$)}}" stepKey="checkThirdCustomerCheckboxIsUnchecked"/> | ||
<!-- Click select all on page checkbox --> | ||
<actionGroup ref="AdminSelectAllCustomers" stepKey="selectAllCustomersOnPage"/> | ||
<seeElement selector="{{AdminCustomerGridMainActionsSection.multicheckTick}}" stepKey="waitForElement"/> | ||
<seeCheckboxIsChecked selector="{{AdminCustomerGridMainActionsSection.multicheckTick}}" stepKey="checkAllSelectedCheckBoxIsChecked"/> | ||
<!-- Check all created records selected --> | ||
<seeCheckboxIsChecked selector="{{AdminCustomerGridMainActionsSection.customerCheckbox($$firstCustomer.email$$)}}" stepKey="checkFirstCustomerIsCheckedAfterSelectPage"/> | ||
<seeCheckboxIsChecked selector="{{AdminCustomerGridMainActionsSection.customerCheckbox($$secondCustomer.email$$)}}" stepKey="checkSecondCustomerIsCheckedAfterSelectPage"/> | ||
<seeCheckboxIsChecked selector="{{AdminCustomerGridMainActionsSection.customerCheckbox($$thirdCustomer.email$$)}}" stepKey="checkThirdCustomerIsCheckedAfterSelectPage"/> | ||
<!-- Click deselect all on page checkbox --> | ||
<actionGroup ref="AdminSelectAllCustomers" stepKey="deselectAllCustomersCheckbox"/> | ||
<dontSeeCheckboxIsChecked selector="{{AdminCustomerGridMainActionsSection.multicheckTick}}" stepKey="checkAllSelectedCheckBoxUnchecked"/> | ||
<!-- Check all created records unselected --> | ||
<dontSeeCheckboxIsChecked selector="{{AdminCustomerGridMainActionsSection.customerCheckbox($$firstCustomer.email$$)}}" stepKey="checkFirstCustomerIsUncheckedAfterSelectPage"/> | ||
<dontSeeCheckboxIsChecked selector="{{AdminCustomerGridMainActionsSection.customerCheckbox($$secondCustomer.email$$)}}" stepKey="checkSecondCustomerIsUncheckedAfterSelectPage"/> | ||
<dontSeeCheckboxIsChecked selector="{{AdminCustomerGridMainActionsSection.customerCheckbox($$thirdCustomer.email$$)}}" stepKey="checkThirdCustomerIsUncheckedAfterSelectPage"/> | ||
</test> | ||
</tests> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.