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.
- Loading branch information
1 parent
6ad372a
commit a070cf3
Showing
2 changed files
with
73 additions
and
0 deletions.
There are no files selected for viewing
70 changes: 70 additions & 0 deletions
70
app/code/Magento/BundleImportExport/Test/Mftf/Test/UpdateBundleProductViaImportTest.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,70 @@ | ||
<?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="UpdateBundleProductViaImportTest"> | ||
<annotations> | ||
<features value="Import/Export"/> | ||
<title value="Update Bundle product via import"/> | ||
<description | ||
value="Check that Bundle products are displaying on the storefront after updating product via importing CSV"/> | ||
<severity value="MAJOR"/> | ||
<group value="importExport"/> | ||
</annotations> | ||
<before> | ||
<actionGroup ref="LoginAsAdmin" stepKey="loginAsAdmin"/> | ||
</before> | ||
<after> | ||
<!-- Delete products created via import --> | ||
<actionGroup ref="DeleteProductBySkuActionGroup" stepKey="deleteBundleProduct"> | ||
<argument name="sku" value="Bundle"/> | ||
</actionGroup> | ||
<actionGroup ref="DeleteProductBySkuActionGroup" stepKey="deleteSimpleProduct"> | ||
<argument name="sku" value="Simple"/> | ||
</actionGroup> | ||
<actionGroup ref="logout" stepKey="logoutFromAdmin"/> | ||
</after> | ||
|
||
<!-- Create Bundle product via import --> | ||
<actionGroup ref="AdminImportProductsActionGroup" stepKey="adminImportProductsCreate"> | ||
<argument name="behavior" value="Add/Update"/> | ||
<argument name="importFile" value="catalog_product_import_bundle.csv"/> | ||
<argument name="importNoticeMessage" value="Created: 2, Updated: 0, Deleted: 0"/> | ||
</actionGroup> | ||
<magentoCLI command="cache:flush" arguments="full_page" stepKey="flushCacheAfterCreate"/> | ||
<magentoCLI command="indexer:reindex" stepKey="indexerReindexAfterCreate"/> | ||
|
||
<!-- Check Bundle product is visible on the storefront--> | ||
<actionGroup ref="StorefrontGoToCategoryPageActionGroup" stepKey="openCategoryPageAfterCreation"> | ||
<argument name="categoryName" value="New"/> | ||
</actionGroup> | ||
<actionGroup ref="AssertStorefrontProductIsPresentOnCategoryPageActionGroup" | ||
stepKey="assertBundleProductInStockAfterCreation"> | ||
<argument name="productName" value="Bundle"/> | ||
</actionGroup> | ||
|
||
<!-- Update Bundle product via import --> | ||
<actionGroup ref="AdminImportProductsActionGroup" stepKey="adminImportProductsUpdate"> | ||
<argument name="behavior" value="Add/Update"/> | ||
<argument name="importFile" value="catalog_product_import_bundle.csv"/> | ||
<argument name="importNoticeMessage" value="Created: 0, Updated: 2, Deleted: 0"/> | ||
</actionGroup> | ||
<magentoCLI command="cache:flush" arguments="full_page" stepKey="flushCacheAfterUpdate"/> | ||
<magentoCLI command="indexer:reindex" stepKey="indexerReindexAfterUpdate"/> | ||
|
||
<!-- Check Bundle product is still visible on the storefront--> | ||
<actionGroup ref="StorefrontGoToCategoryPageActionGroup" stepKey="openCategoryPageAfterUpdate"> | ||
<argument name="categoryName" value="New"/> | ||
</actionGroup> | ||
<actionGroup ref="AssertStorefrontProductIsPresentOnCategoryPageActionGroup" | ||
stepKey="assertBundleProductInStockAfterUpdate"> | ||
<argument name="productName" value="Bundle"/> | ||
</actionGroup> | ||
</test> | ||
</tests> |
3 changes: 3 additions & 0 deletions
3
dev/tests/acceptance/tests/_data/catalog_product_import_bundle.csv
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,3 @@ | ||
sku,store_view_code,attribute_set_code,product_type,categories,product_websites,name,description,short_description,weight,product_online,tax_class_name,visibility,price,special_price,special_price_from_date,special_price_to_date,url_key,meta_title,meta_keywords,meta_description,base_image,base_image_label,small_image,small_image_label,thumbnail_image,thumbnail_image_label,swatch_image,swatch_image_label,created_at,updated_at,new_from_date,new_to_date,display_product_options_in,map_price,msrp_price,map_enabled,gift_message_available,custom_design,custom_design_from,custom_design_to,custom_layout_update,page_layout,product_options_container,msrp_display_actual_price_type,country_of_manufacture,additional_attributes,qty,out_of_stock_qty,use_config_min_qty,is_qty_decimal,allow_backorders,use_config_backorders,min_cart_qty,use_config_min_sale_qty,max_cart_qty,use_config_max_sale_qty,is_in_stock,notify_on_stock_below,use_config_notify_stock_qty,manage_stock,use_config_manage_stock,use_config_qty_increments,qty_increments,use_config_enable_qty_inc,enable_qty_increments,is_decimal_divided,website_id,related_skus,related_position,crosssell_skus,crosssell_position,upsell_skus,upsell_position,additional_images,additional_image_labels,hide_from_product_page,custom_options,bundle_price_type,bundle_sku_type,bundle_price_view,bundle_weight_type,bundle_values,bundle_shipment_type,associated_skus,downloadable_links,downloadable_samples,configurable_variations,configurable_variation_labels | ||
Simple,,Default,simple,"Default Category/New",base,Simple,,,1.000000,1,"Taxable Goods","Catalog, Search",100.000000,,,,simple,Simple,Simple,"Simple ",,,,,,,,,"3/18/20, 6:56 AM","3/18/20, 6:56 AM",,,"Block after Info Column",,,,"Use config",,,,,,,"Use config",,,1000.0000,0.0000,1,0,0,1,1.0000,1,10000.0000,1,1,1.0000,1,1,1,1,1.0000,1,0,0,0,,,,,,,,,,,,,,,,,,,,, | ||
Bundle,,Default,bundle,"Default Category/New",base,Bundle,,,,1,"Taxable Goods","Catalog, Search",,,,,bundle,Bundle,Bundle,"Bundle ",,,,,,,,,"3/18/20, 6:57 AM","3/18/20, 6:57 AM",,,"Block after Info Column",,,,"Use config",,,,,,,"Use config",,,0.0000,0.0000,1,0,0,1,1.0000,1,10000.0000,1,1,1.0000,1,1,1,1,1.0000,1,0,0,0,,,,,,,,,,,dynamic,dynamic,"Price range",dynamic,"name=Test Option,type=select,required=1,sku=Simple,price=0.0000,default=1,default_qty=1.0000,price_type=fixed,can_change_qty=0",together,,,,, |