-
Notifications
You must be signed in to change notification settings - Fork 9.3k
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 #3654 from magento-tsg/2.3-develop-mftf-pr12
[TSG] MFTF for 2.3 (pr12) (2.3.1)
- Loading branch information
Showing
11 changed files
with
177 additions
and
16 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
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
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
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
117 changes: 117 additions & 0 deletions
117
...t/AdminCheckUrlRewritesCorrectlyGeneratedForMultipleStoreviewsDuringProductImportTest.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,117 @@ | ||
<?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="AdminCheckUrlRewritesCorrectlyGeneratedForMultipleStoreviewsDuringProductImportTest"> | ||
<annotations> | ||
<features value="Url Rewrite"/> | ||
<stories value="Url Rewrites for Multiple Storeviews"/> | ||
<title value="Url Rewrites Correctly Generated for Multiple Storeviews During Product Import"/> | ||
<description value="Check Url Rewrites Correctly Generated for Multiple Storeviews During Product Import."/> | ||
<severity value="CRITICAL"/> | ||
<testCaseId value="MAGETWO-68980"/> | ||
<group value="urlRewrite"/> | ||
</annotations> | ||
<before> | ||
<actionGroup ref="LoginAsAdmin" stepKey="loginAsAdmin"/> | ||
<!-- Create Store View EN --> | ||
<actionGroup ref="AdminCreateStoreViewActionGroup" stepKey="createStoreViewEn"> | ||
<argument name="customStore" value="customStoreENNotUnique"/> | ||
</actionGroup> | ||
<!-- Create Store View NL --> | ||
<actionGroup ref="AdminCreateStoreViewActionGroup" stepKey="createStoreViewNl"> | ||
<argument name="customStore" value="customStoreNLNotUnique"/> | ||
</actionGroup> | ||
<createData entity="ApiCategory" stepKey="createCategory"> | ||
<field key="name">category-admin</field> | ||
</createData> | ||
</before> | ||
<after> | ||
<deleteData createDataKey="createCategory" stepKey="deleteCategory"/> | ||
<actionGroup ref="deleteProductByName" stepKey="deleteImportedProduct"> | ||
<argument name="sku" value="productformagetwo68980"/> | ||
<argument name="name" value="productformagetwo68980"/> | ||
</actionGroup> | ||
<actionGroup ref="clearFiltersAdminDataGrid" stepKey="clearFiltersIfSet"/> | ||
<actionGroup ref="AdminDeleteStoreViewActionGroup" stepKey="deleteStoreViewEn"> | ||
<argument name="customStore" value="customStoreENNotUnique"/> | ||
</actionGroup> | ||
<actionGroup ref="AdminDeleteStoreViewActionGroup" stepKey="deleteStoreViewNl"> | ||
<argument name="customStore" value="customStoreNLNotUnique"/> | ||
</actionGroup> | ||
<actionGroup ref="logout" stepKey="logout"/> | ||
</after> | ||
<actionGroup ref="switchCategoryStoreView" stepKey="switchToStoreViewEn"> | ||
<argument name="Store" value="customStoreENNotUnique.name"/> | ||
<argument name="CatName" value="$$createCategory.name$$"/> | ||
</actionGroup> | ||
<uncheckOption selector="{{AdminCategoryBasicFieldSection.categoryNameUseDefault}}" stepKey="uncheckUseDefaultValueENStoreView"/> | ||
<fillField selector="{{AdminCategoryBasicFieldSection.CategoryNameInput}}" userInput="category-english" stepKey="changeNameField"/> | ||
<click selector="{{AdminCategorySEOSection.SectionHeader}}" stepKey="clickOnSectionHeader"/> | ||
<actionGroup ref="ChangeSeoUrlKeyForSubCategory" stepKey="changeSeoUrlKeyENStoreView"> | ||
<argument name="value" value="category-english"/> | ||
</actionGroup> | ||
<actionGroup ref="switchCategoryStoreView" stepKey="switchToStoreViewNl"> | ||
<argument name="Store" value="customStoreNLNotUnique.name"/> | ||
<argument name="CatName" value="$$createCategory.name$$"/> | ||
</actionGroup> | ||
<uncheckOption selector="{{AdminCategoryBasicFieldSection.categoryNameUseDefault}}" stepKey="uncheckUseDefaultValue1"/> | ||
<fillField selector="{{AdminCategoryBasicFieldSection.CategoryNameInput}}" userInput="category-dutch" stepKey="changeNameFieldNLStoreView"/> | ||
<click selector="{{AdminCategorySEOSection.SectionHeader}}" stepKey="clickOnSectionHeader2"/> | ||
<actionGroup ref="ChangeSeoUrlKeyForSubCategory" stepKey="changeSeoUrlKeyNLStoreView"> | ||
<argument name="value" value="category-dutch"/> | ||
</actionGroup> | ||
<amOnPage url="{{AdminImportIndexPage.url}}" stepKey="navigateToSystemImport"/> | ||
<selectOption selector="{{AdminImportMainSection.entityType}}" userInput="Products" stepKey="selectProductsOption"/> | ||
<waitForElementVisible selector="{{AdminImportMainSection.importBehavior}}" stepKey="waitForImportBehaviorElementVisible"/> | ||
<selectOption selector="{{AdminImportMainSection.importBehavior}}" userInput="Add/Update" stepKey="selectAddUpdateOption"/> | ||
<attachFile selector="{{AdminImportMainSection.selectFileToImport}}" userInput="import_updated.csv" stepKey="attachFileForImport"/> | ||
<click selector="{{AdminImportHeaderSection.checkDataButton}}" stepKey="clickCheckDataButton"/> | ||
<see selector="{{AdminMessagesSection.notice}}" userInput="Checked rows: 3, checked entities: 1, invalid rows: 0, total errors: 0" stepKey="assertNotice"/> | ||
<see selector="{{AdminMessagesSection.successMessage}}" userInput="File is valid! To start import process press "Import" button" stepKey="assertSuccessMessage"/> | ||
<click selector="{{AdminImportMainSection.importButton}}" stepKey="clickImportButton"/> | ||
<see selector="{{AdminMessagesSection.successMessage}}" userInput="Import successfully done" stepKey="assertSuccessMessage1"/> | ||
<see selector="{{AdminMessagesSection.notice}}" userInput="Created: 1, Updated: 0, Deleted: 0" stepKey="assertNotice1"/> | ||
<actionGroup ref="SearchForProductOnBackendByNameActionGroup" stepKey="searchForProductOnBackend"> | ||
<argument name="productName" value="productformagetwo68980"/> | ||
</actionGroup> | ||
<click selector="{{AdminProductGridSection.productRowBySku('productformagetwo68980')}}" stepKey="clickOnProductRow"/> | ||
<grabFromCurrentUrl regex="~/id/(\d+)/~" stepKey="grabProductIdFromUrl"/> | ||
<amOnPage url="{{AdminUrlRewriteIndexPage.url}}" stepKey="goToUrlRewritesIndexPage"/> | ||
|
||
<fillField selector="{{AdminUrlRewriteIndexSection.requestPathFilter}}" userInput="category-english.html" stepKey="inputCategoryUrlForENStoreView"/> | ||
<click selector="{{AdminDataGridHeaderSection.applyFilters}}" stepKey="clickSearchButton"/> | ||
<seeElement selector="{{AdminUrlRewriteIndexSection.requestPathColumnValue('category-english.html')}}" stepKey="seeUrlInRequestPathColumn"/> | ||
<seeElement selector="{{AdminUrlRewriteIndexSection.targetPathColumnValue(catalog/category/view/id/$$createCategory.id$$)}}" stepKey="seeUrlInTargetPathColumn"/> | ||
|
||
<fillField selector="{{AdminUrlRewriteIndexSection.requestPathFilter}}" userInput="category-dutch.html" stepKey="inputCategoryUrlForNLStoreView"/> | ||
<click selector="{{AdminDataGridHeaderSection.applyFilters}}" stepKey="clickSearchButton1"/> | ||
<seeElement selector="{{AdminUrlRewriteIndexSection.requestPathColumnValue('category-dutch.html')}}" stepKey="seeUrlInRequestPathColumn1"/> | ||
<seeElement selector="{{AdminUrlRewriteIndexSection.targetPathColumnValue(catalog/category/view/id/$$createCategory.id$$)}}" stepKey="seeUrlInTargetPathColumn1"/> | ||
|
||
<fillField selector="{{AdminUrlRewriteIndexSection.requestPathFilter}}" userInput="productformagetwo68980-english.html" stepKey="inputProductUrlForENStoreView"/> | ||
<click selector="{{AdminDataGridHeaderSection.applyFilters}}" stepKey="clickSearchButton2"/> | ||
<seeElement selector="{{AdminUrlRewriteIndexSection.requestPathColumnValue('productformagetwo68980-english.html')}}" stepKey="seeUrlInRequestPathColumn2"/> | ||
<seeElement selector="{{AdminUrlRewriteIndexSection.targetPathColumnValue('catalog/product/view/id/$grabProductIdFromUrl')}}" stepKey="seeUrlInTargetPathColumn2"/> | ||
|
||
<fillField selector="{{AdminUrlRewriteIndexSection.requestPathFilter}}" userInput="productformagetwo68980-dutch.html" stepKey="inputProductUrlForENStoreView1"/> | ||
<click selector="{{AdminDataGridHeaderSection.applyFilters}}" stepKey="clickSearchButton3"/> | ||
<seeElement selector="{{AdminUrlRewriteIndexSection.requestPathColumnValue('productformagetwo68980-dutch.html')}}" stepKey="seeUrlInRequestPathColumn3"/> | ||
<seeElement selector="{{AdminUrlRewriteIndexSection.targetPathColumnValue('catalog/product/view/id/$grabProductIdFromUrl')}}" stepKey="seeUrlInTargetPathColumn3"/> | ||
|
||
<fillField selector="{{AdminUrlRewriteIndexSection.requestPathFilter}}" userInput="category-english/productformagetwo68980-english.html" stepKey="inputProductUrlForENStoreView2"/> | ||
<click selector="{{AdminDataGridHeaderSection.applyFilters}}" stepKey="clickSearchButton4"/> | ||
<seeElement selector="{{AdminUrlRewriteIndexSection.requestPathColumnValue('category-english/productformagetwo68980-english.html')}}" stepKey="seeUrlInRequestPathColumn4"/> | ||
<seeElement selector="{{AdminUrlRewriteIndexSection.targetPathColumnValue(catalog/product/view/id/$grabProductIdFromUrl/category/$$createCategory.id$$)}}" stepKey="seeUrlInTargetPathColumn4"/> | ||
|
||
<fillField selector="{{AdminUrlRewriteIndexSection.requestPathFilter}}" userInput="category-dutch/productformagetwo68980-dutch.html" stepKey="inputProductUrlForENStoreView3"/> | ||
<click selector="{{AdminDataGridHeaderSection.applyFilters}}" stepKey="clickSearchButton5"/> | ||
<seeElement selector="{{AdminUrlRewriteIndexSection.requestPathColumnValue('category-dutch/productformagetwo68980-dutch.html')}}" stepKey="seeUrlInRequestPathColumn5"/> | ||
<seeElement selector="{{AdminUrlRewriteIndexSection.targetPathColumnValue(catalog/product/view/id/$grabProductIdFromUrl/category/$$createCategory.id$$)}}" stepKey="seeUrlInTargetPathColumn5"/> | ||
</test> | ||
</tests> |
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,4 @@ | ||
product_websites,store_view_code,attribute_set_code,product_type,categories,sku,price,name,url_key | ||
base,,Default,simple,Default Category/category-admin,productformagetwo68980,123,productformagetwo68980,productformagetwo68980 | ||
,en,Default,simple,,productformagetwo68980,,productformagetwo68980-english,productformagetwo68980-english | ||
,nl,Default,simple,,productformagetwo68980,,productformagetwo68980-dutch,productformagetwo68980-dutch |
Oops, something went wrong.