forked from magento/magento2
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request magento#1228 from magento-engcom/mftf_kis
Batch of MFTF tests.
- Loading branch information
Showing
20 changed files
with
1,479 additions
and
5 deletions.
There are no files selected for viewing
This file contains 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 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
185 changes: 185 additions & 0 deletions
185
...Test/Mftf/Test/AdminConfigurableProductDisabledManageStockOnProductPageForCustomStock.xml
Large diffs are not rendered by default.
Oops, something went wrong.
79 changes: 79 additions & 0 deletions
79
...ento/Inventory/Test/Mftf/Test/AdminManageSourceGridChangeColumnOrderByDragAndDropTest.xml
This file contains 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,79 @@ | ||
<?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="../../../../../../../dev/tests/acceptance/vendor/magento/magento2-functional-testing-framework/src/Magento/FunctionalTestingFramework/Test/etc/testSchema.xsd"> | ||
<test name="AdminManageSourceGridChangeColumnOrderByDragAndDropTest"> | ||
<annotations> | ||
<features value="Multi-Source Inventory"/> | ||
<stories value="Column drag and drop changed column order."/> | ||
<title value="Column drag and drop changed column order in Manage Sources grid by Admin user."/> | ||
<description value="Column drag and drop changed column order in Manage Sources grid by Admin user."/> | ||
<testCaseId value="932"/> | ||
<severity value="CRITICAL"/> | ||
<group value="msi"/> | ||
</annotations> | ||
|
||
<before> | ||
<createData entity="_minimalSource" stepKey="createCustomSource"/> | ||
<actionGroup ref="LoginAsAdmin" stepKey="loginAsAdmin"/> | ||
<waitForPageLoad stepKey="waitForPageLoadAfterLogin"/> | ||
|
||
<amOnPage url="{{AdminManageSourcePage.url}}" stepKey="amOnTheSourcesGridPage"/> | ||
<waitForPageLoad stepKey="waitForTheSourcesGridPageLoad"/> | ||
<click selector="{{AdminGridColumnsControls.columns}}" stepKey="clickOnTheColumnsButton"/> | ||
<click selector="{{AdminGridColumnsControls.reset}}" stepKey="clickOnResetToRestoreDefaultColumns"/> | ||
<click selector="{{AdminGridColumnsControls.cancel}}" stepKey="clickOnCancelToCloseDropdownMenu"/> | ||
</before> | ||
<after> | ||
<dragAndDrop selector1="{{AdminGridHeaders.headerByName('Is Enabled')}}" | ||
selector2="{{AdminGridHeaders.headerByName('Name')}}" | ||
stepKey="dragAndDropIsEnabledColumnToDefaultPosition"/> | ||
<waitForPageLoad time="30" stepKey="waitForMoveConfirmationAfterMoveIsEnabledColumnToDefaultPosition"/> | ||
|
||
<!-- Disable source as it can broke single source mode tests. --> | ||
<conditionalClick selector="{{AdminDataGridHeaderSection.clearFilters}}" dependentSelector="{{AdminDataGridHeaderSection.clearFilters}}" visible="true" stepKey="clickClearFiltersForSource"/> | ||
<actionGroup ref="AdminGridFilterSearchResultsByInput" stepKey="filterSearchResultsForSources"> | ||
<argument name="selector" value="AdminManageSourcesGridFilterControls.code"/> | ||
<argument name="value" value="$$createCustomSource.source[source_code]$$"/> | ||
</actionGroup> | ||
<click selector="{{AdminGridRow.editByValue($$createCustomSource.source[source_code]$$)}}" stepKey="clickOnEditCustomSource"/> | ||
<waitForPageLoad time="30" stepKey="waitForSourceEditPageLoad"/> | ||
<click selector="{{AdminEditSourceGeneralSection.isEnabledLabel}}" stepKey="clickIsEnabledToDisable"/> | ||
<actionGroup ref="AdminFormSaveAndClose" stepKey="saveAndCloseCustomSource"/> | ||
|
||
<actionGroup ref="logout" stepKey="logoutOfAdmin"/> | ||
</after> | ||
|
||
<grabMultiple selector="{{AdminGridHeaders.columnsNames}}" stepKey="grabColumnsDefaultOrder" /> | ||
<assertEquals stepKey="assertDefaultOrder"> | ||
<actualResult type="variable">grabColumnsDefaultOrder</actualResult> | ||
<expectedResult type="array">["Code", "Name", "Is Enabled", "Action"]</expectedResult> | ||
</assertEquals> | ||
|
||
<dragAndDrop selector1="{{AdminGridHeaders.headerByName('Code')}}" | ||
selector2="{{AdminGridHeaders.headerByName('Is Enabled')}}" | ||
stepKey="dragAndDroCodepColumn"/> | ||
<waitForPageLoad time="30" stepKey="waitForMoveConfirmationAfterCodeColumnMoved"/> | ||
<grabMultiple selector="{{AdminGridHeaders.columnsNames}}" stepKey="grabColumnsAfterCodeColumnMoved" /> | ||
<assertEquals stepKey="assertOrderAfterCodeColumnMoved"> | ||
<actualResult type="variable">grabColumnsAfterCodeColumnMoved</actualResult> | ||
<expectedResult type="array">["Name", "Is Enabled", "Code", "Action"]</expectedResult> | ||
</assertEquals> | ||
|
||
<dragAndDrop selector1="{{AdminGridHeaders.headerByName('Name')}}" | ||
selector2="{{AdminGridHeaders.headerByName('Is Enabled')}}" | ||
stepKey="dragAndDropNameColumn"/> | ||
<waitForPageLoad time="30" stepKey="waitForMoveConfirmationAfterNameColumnMoved"/> | ||
<grabMultiple selector="{{AdminGridHeaders.columnsNames}}" stepKey="grabColumnsAfterNameColumnMoved" /> | ||
<assertEquals stepKey="assertOrderAfterNameColumnMoved"> | ||
<actualResult type="variable">grabColumnsAfterNameColumnMoved</actualResult> | ||
<expectedResult type="array">["Is Enabled", "Name", "Code", "Action"]</expectedResult> | ||
</assertEquals> | ||
</test> | ||
</tests> |
119 changes: 119 additions & 0 deletions
119
app/code/Magento/Inventory/Test/Mftf/Test/AdminManageSourceGridColumnsSortingTest.xml
This file contains 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,119 @@ | ||
<?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="../../../../../../../dev/tests/acceptance/vendor/magento/magento2-functional-testing-framework/src/Magento/FunctionalTestingFramework/Test/etc/testSchema.xsd"> | ||
<test name="AdminManageSourceGridColumnsSortingTest"> | ||
<annotations> | ||
<features value="Multi-Source Inventory"/> | ||
<stories value="Columns sorting order changed by Admin user"/> | ||
<title value="Columns sorting order changed in Manage Source grid by Admin user"/> | ||
<description value="You should be able to Change Columns Sorting Order in Manage Source grid."/> | ||
<testCaseId value="935"/> | ||
<severity value="CRITICAL"/> | ||
<group value="msi"/> | ||
</annotations> | ||
|
||
<before> | ||
<createData entity="SourceForColumnsSortingOrderTestOnly" stepKey="createCustomSource1"/> | ||
<createData entity="SourceForColumnsSortingOrderTestOnly" stepKey="createCustomSource2"/> | ||
<createData entity="SourceForColumnsSortingOrderTestOnly" stepKey="createCustomSource3"/> | ||
<createData entity="SourceForColumnsSortingOrderTestOnly" stepKey="createCustomSource4"/> | ||
|
||
<actionGroup ref="LoginAsAdmin" stepKey="loginAsAdmin"/> | ||
</before> | ||
<after> | ||
<!-- Disable source as it can broke single source mode tests. --> | ||
<conditionalClick selector="{{AdminDataGridHeaderSection.clearFilters}}" dependentSelector="{{AdminDataGridHeaderSection.clearFilters}}" visible="true" stepKey="clickClearFiltersForSourceToDisableCustomSource1"/> | ||
<actionGroup ref="AdminGridFilterSearchResultsByInput" stepKey="filterSearchResultsForSourcesToDisableCustomSource1"> | ||
<argument name="selector" value="AdminManageSourcesGridFilterControls.code"/> | ||
<argument name="value" value="$$createCustomSource1.source[source_code]$$"/> | ||
</actionGroup> | ||
<click selector="{{AdminGridRow.editByValue($$createCustomSource1.source[source_code]$$)}}" stepKey="clickOnEditCustomSourceToDisableCustomSource1"/> | ||
<waitForPageLoad time="30" stepKey="waitForSourceEditPageLoadToDisableCustomSource1"/> | ||
<click selector="{{AdminEditSourceGeneralSection.isEnabledLabel}}" stepKey="clickIsEnabledToDisableCustomSource1"/> | ||
<actionGroup ref="AdminFormSaveAndClose" stepKey="saveAndCloseCustomSourceToDisableCustomSource1"/> | ||
|
||
<conditionalClick selector="{{AdminDataGridHeaderSection.clearFilters}}" dependentSelector="{{AdminDataGridHeaderSection.clearFilters}}" visible="true" stepKey="clickClearFiltersForSourceToDisableCustomSource2"/> | ||
<actionGroup ref="AdminGridFilterSearchResultsByInput" stepKey="filterSearchResultsForSourcesToDisableCustomSource2"> | ||
<argument name="selector" value="AdminManageSourcesGridFilterControls.code"/> | ||
<argument name="value" value="$$createCustomSource2.source[source_code]$$"/> | ||
</actionGroup> | ||
<click selector="{{AdminGridRow.editByValue($$createCustomSource2.source[source_code]$$)}}" stepKey="clickOnEditCustomSourceToDisableCustomSource2"/> | ||
<waitForPageLoad time="30" stepKey="waitForSourceEditPageLoadToDisableCustomSource2"/> | ||
<click selector="{{AdminEditSourceGeneralSection.isEnabledLabel}}" stepKey="clickIsEnabledToDisableCustomSource2"/> | ||
<actionGroup ref="AdminFormSaveAndClose" stepKey="saveAndCloseCustomSourceToDisableCustomSource2"/> | ||
|
||
<conditionalClick selector="{{AdminDataGridHeaderSection.clearFilters}}" dependentSelector="{{AdminDataGridHeaderSection.clearFilters}}" visible="true" stepKey="clickClearFiltersForSourceToDisableCustomSource3"/> | ||
<actionGroup ref="AdminGridFilterSearchResultsByInput" stepKey="filterSearchResultsForSourcesToDisableCustomSource3"> | ||
<argument name="selector" value="AdminManageSourcesGridFilterControls.code"/> | ||
<argument name="value" value="$$createCustomSource3.source[source_code]$$"/> | ||
</actionGroup> | ||
<click selector="{{AdminGridRow.editByValue($$createCustomSource3.source[source_code]$$)}}" stepKey="clickOnEditCustomSourceToDisableCustomSource3"/> | ||
<waitForPageLoad time="30" stepKey="waitForSourceEditPageLoadToDisableCustomSource3"/> | ||
<click selector="{{AdminEditSourceGeneralSection.isEnabledLabel}}" stepKey="clickIsEnabledToDisableCustomSource3"/> | ||
<actionGroup ref="AdminFormSaveAndClose" stepKey="saveAndCloseCustomSourceToDisableCustomSource3"/> | ||
|
||
<conditionalClick selector="{{AdminDataGridHeaderSection.clearFilters}}" dependentSelector="{{AdminDataGridHeaderSection.clearFilters}}" visible="true" stepKey="clickClearFiltersForSourceToDisableCustomSource4"/> <actionGroup ref="AdminGridFilterSearchResultsByInput" stepKey="filterSearchResultsForSourcesToDisableCustomSource4"> | ||
<argument name="selector" value="AdminManageSourcesGridFilterControls.code"/> | ||
<argument name="value" value="$$createCustomSource4.source[source_code]$$"/> | ||
</actionGroup> | ||
<click selector="{{AdminGridRow.editByValue($$createCustomSource4.source[source_code]$$)}}" stepKey="clickOnEditCustomSourceToDisableCustomSource4"/> | ||
<waitForPageLoad time="30" stepKey="waitForSourceEditPageLoadToDisableCustomSource4"/> | ||
<click selector="{{AdminEditSourceGeneralSection.isEnabledLabel}}" stepKey="clickIsEnabledToDisableCustomSource4"/> | ||
<actionGroup ref="AdminFormSaveAndClose" stepKey="saveAndCloseCustomSourceToDisableCustomSource4"/> | ||
|
||
<actionGroup ref="logout" stepKey="logoutOfAdmin"/> | ||
</after> | ||
|
||
<amOnPage url="{{AdminManageSourcePage.url}}" stepKey="amOnTheSourcesGridPage"/> | ||
<waitForPageLoad time="30" stepKey="waitForSourceGridPageLoad"/> | ||
|
||
<actionGroup ref="AdminGridFilterSearchResultsByInput" stepKey="filterSearchResults"> | ||
<argument name="selector" value="AdminManageSourcesGridFilterControls.code"/> | ||
<argument name="value" value="source_for_columns_sorting_test_only"/> | ||
</actionGroup> | ||
<waitForPageLoad time="30" stepKey="waitForFilterApplied"/> | ||
|
||
<comment userInput="Reset sorting for Code to avoid wrong behavior" stepKey="resetSortingForCodeComment"/> | ||
<click selector="{{AdminGridHeaders.headerByName('Name')}}" stepKey="clickOnNameHeaderToResetSorting"/> | ||
<waitForPageLoad time="10" stepKey="waitForSourceGridPageLoadAfterResetSorting"/> | ||
|
||
<comment userInput="Ascend sorting for Code" stepKey="ascendSortingForCodeComment"/> | ||
<click selector="{{AdminGridHeaders.headerByName('Code')}}" stepKey="clickOnCodeHeaderToSetAscendSorting"/> | ||
<waitForPageLoad time="10" stepKey="waitForSourceGridPageLoadAfterSettingAscendSortingForCode"/> | ||
<see userInput="$$createCustomSource1.source[return]$$" selector="{{AdminGridRow.rowByIndex('0')}}" stepKey="seeCustomSource1CodeInRow1WhenAscendSorting"/> | ||
<see userInput="$$createCustomSource2.source[return]$$" selector="{{AdminGridRow.rowByIndex('1')}}" stepKey="seeCustomSource2CodeInRow2WhenAscendSorting"/> | ||
<see userInput="$$createCustomSource3.source[return]$$" selector="{{AdminGridRow.rowByIndex('2')}}" stepKey="seeCustomSource3CodeInRow3WhenAscendSorting"/> | ||
<see userInput="$$createCustomSource4.source[return]$$" selector="{{AdminGridRow.rowByIndex('3')}}" stepKey="seeCustomSource4CodeInRow4WhenAscendSorting"/> | ||
|
||
<comment userInput="Descend sorting for Code" stepKey="descendSortingForCodeComment"/> | ||
<click selector="{{AdminGridHeaders.headerByName('Code')}}" stepKey="clickOnCodeHeaderToSetDescendSorting"/> | ||
<waitForPageLoad time="10" stepKey="waitForSourceGridPageLoadAfterSettingDescendSortingForCode"/> | ||
<see userInput="$$createCustomSource4.source[return]$$" selector="{{AdminGridRow.rowByIndex('0')}}" stepKey="seeCustomSource4CodeInRow1WhenDescendSorting"/> | ||
<see userInput="$$createCustomSource3.source[return]$$" selector="{{AdminGridRow.rowByIndex('1')}}" stepKey="seeCustomSource3CodeInRow2WhenDescendSorting"/> | ||
<see userInput="$$createCustomSource2.source[return]$$" selector="{{AdminGridRow.rowByIndex('2')}}" stepKey="seeCustomSource2CodeInRow3WhenDescendSorting"/> | ||
<see userInput="$$createCustomSource1.source[return]$$" selector="{{AdminGridRow.rowByIndex('3')}}" stepKey="seeCustomSource1CodeInRow4WhenDescendSorting"/> | ||
|
||
<comment userInput="Ascend sorting for Name" stepKey="ascendSortingForNameComment"/> | ||
<click selector="{{AdminGridHeaders.headerByName('Name')}}" stepKey="clickOnNameHeaderToSetAscendSorting"/> | ||
<waitForPageLoad time="10" stepKey="waitForSourceGridPageLoadAfterSettingAscendSortingForName"/> | ||
<see userInput="$$createCustomSource1.source[name]$$" selector="{{AdminGridRow.rowByIndex('0')}}" stepKey="seeCustomSource1NameInRow1WhenAscendSorting"/> | ||
<see userInput="$$createCustomSource2.source[name]$$" selector="{{AdminGridRow.rowByIndex('1')}}" stepKey="seeCustomSource2NameInRow2WhenAscendSorting"/> | ||
<see userInput="$$createCustomSource3.source[name]$$" selector="{{AdminGridRow.rowByIndex('2')}}" stepKey="seeCustomSource3NameInRow3WhenAscendSorting"/> | ||
<see userInput="$$createCustomSource4.source[name]$$" selector="{{AdminGridRow.rowByIndex('3')}}" stepKey="seeCustomSource4NameInRow4WhenAscendSorting"/> | ||
|
||
<comment userInput="Descend sorting for Name" stepKey="descendSortingForNameComment"/> | ||
<click selector="{{AdminGridHeaders.headerByName('Name')}}" stepKey="clickOnNameHeaderToSetDescendSorting"/> | ||
<waitForPageLoad time="10" stepKey="waitForSourceGridPageLoadAfterSettingDescendSortingForName"/> | ||
<see userInput="$$createCustomSource4.source[name]$$" selector="{{AdminGridRow.rowByIndex('0')}}" stepKey="seeCustomSource4NameInRow1WhenDescendSorting"/> | ||
<see userInput="$$createCustomSource3.source[name]$$" selector="{{AdminGridRow.rowByIndex('1')}}" stepKey="seeCustomSource3NameInRow2WhenDescendSorting"/> | ||
<see userInput="$$createCustomSource2.source[name]$$" selector="{{AdminGridRow.rowByIndex('2')}}" stepKey="seeCustomSource2NameInRow3WhenDescendSorting"/> | ||
<see userInput="$$createCustomSource1.source[name]$$" selector="{{AdminGridRow.rowByIndex('3')}}" stepKey="seeCustomSource1NameInRow4WhenDescendSorting"/> | ||
</test> | ||
</tests> |
Oops, something went wrong.