diff --git a/app/code/Magento/Catalog/Model/Product/Image.php b/app/code/Magento/Catalog/Model/Product/Image.php index 7d8b464db3b34cd116d2c8c7adae86113040e67f..34e1ad30ad434add33508bb63c7b8b1a78ddc9fb 100644 --- a/app/code/Magento/Catalog/Model/Product/Image.php +++ b/app/code/Magento/Catalog/Model/Product/Image.php @@ -498,8 +498,7 @@ class Image extends \Magento\Framework\Model\AbstractModel $path = [ $this->_catalogProductMediaConfig->getBaseMediaPath(), 'cache', - $this->_storeManager->getStore()->getId(), - $path[] = $this->getDestinationSubdir(), + $this->getDestinationSubdir(), ]; if (!empty($this->_width) || !empty($this->_height)) { $path[] = "{$this->_width}x{$this->_height}"; diff --git a/app/code/Magento/Catalog/Test/Unit/Model/Product/ImageTest.php b/app/code/Magento/Catalog/Test/Unit/Model/Product/ImageTest.php index a032ffa33b37561117fac3f6e603cb77dd34152d..44f7f87cc2c62afc2c09d262bbd2721683fcfea3 100644 --- a/app/code/Magento/Catalog/Test/Unit/Model/Product/ImageTest.php +++ b/app/code/Magento/Catalog/Test/Unit/Model/Product/ImageTest.php @@ -180,7 +180,7 @@ class ImageTest extends \PHPUnit_Framework_TestCase $this->image->setBaseFile('/somefile.png'); $this->assertEquals('catalog/product/somefile.png', $this->image->getBaseFile()); $this->assertEquals( - 'catalog/product/cache/1//beff4985b56e3afdbeabfc89641a4582/somefile.png', + 'catalog/product/cache//beff4985b56e3afdbeabfc89641a4582/somefile.png', $this->image->getNewFile() ); } @@ -302,7 +302,7 @@ class ImageTest extends \PHPUnit_Framework_TestCase $this->testSetGetBaseFile(); $url = $this->image->getUrl(); $this->assertEquals( - 'http://magento.com/media/catalog/product/cache/1//beff4985b56e3afdbeabfc89641a4582/somefile.png', + 'http://magento.com/media/catalog/product/cache//beff4985b56e3afdbeabfc89641a4582/somefile.png', $url ); } diff --git a/app/code/Magento/Catalog/Test/Unit/Ui/DataProvider/Product/Form/Modifier/ImagesTest.php b/app/code/Magento/Catalog/Test/Unit/Ui/DataProvider/Product/Form/Modifier/ImagesTest.php index 2172e184a9a2ed400d80eb89314855c69fb2c7c1..7a55bd31e3deef64ddeaf5b452cc1b7eb389517c 100644 --- a/app/code/Magento/Catalog/Test/Unit/Ui/DataProvider/Product/Form/Modifier/ImagesTest.php +++ b/app/code/Magento/Catalog/Test/Unit/Ui/DataProvider/Product/Form/Modifier/ImagesTest.php @@ -24,7 +24,9 @@ class ImagesTest extends AbstractModifierTest public function testModifyData() { - $this->assertSame($this->getSampleData(), $this->getModel()->modifyData($this->getSampleData())); + $this->productMock->expects($this->once())->method('getId')->willReturn(2051); + $actualResult = $this->getModel()->modifyData($this->getSampleData()); + $this->assertSame("", $actualResult[2051]['product']['media_gallery']['images'][0]['label']); } public function testModifyMeta() @@ -40,4 +42,24 @@ class ImagesTest extends AbstractModifierTest $this->assertSame([], $this->getModel()->modifyMeta($meta)); } + + /** + * {@inheritdoc} + */ + protected function getSampleData() + { + return [ + 2051 => [ + 'product' => [ + 'media_gallery' => [ + 'images' => [ + [ + 'label' => null + ] + ] + ] + ] + ] + ]; + } } diff --git a/app/code/Magento/Catalog/Ui/DataProvider/Product/Form/Modifier/Images.php b/app/code/Magento/Catalog/Ui/DataProvider/Product/Form/Modifier/Images.php index 810a06df4a42f76392ee54525eb5bf6ffc5f489f..a8536cacc79668797ac961e1082c7b8c0f020e76 100644 --- a/app/code/Magento/Catalog/Ui/DataProvider/Product/Form/Modifier/Images.php +++ b/app/code/Magento/Catalog/Ui/DataProvider/Product/Form/Modifier/Images.php @@ -51,6 +51,21 @@ class Images extends AbstractModifier */ public function modifyData(array $data) { + /** @var \Magento\Catalog\Api\Data\ProductInterface $product */ + $product = $this->locator->getProduct(); + $modelId = $product->getId(); + if ( + isset($data[$modelId][self::DATA_SOURCE_DEFAULT]['media_gallery']) + && !empty($data[$modelId][self::DATA_SOURCE_DEFAULT]['media_gallery']) + && !empty($data[$modelId][self::DATA_SOURCE_DEFAULT]['media_gallery']['images']) + ) { + foreach ($data[$modelId][self::DATA_SOURCE_DEFAULT]['media_gallery']['images'] as $index => $image) { + if (!isset($image['label'])) { + $data[$modelId][self::DATA_SOURCE_DEFAULT]['media_gallery']['images'][$index]['label'] = ""; + } + } + }; + return $data; } } diff --git a/app/code/Magento/CatalogInventory/Setup/UpgradeData.php b/app/code/Magento/CatalogInventory/Setup/UpgradeData.php index db3408c01b77f9fc620ee0862f2f71f2eec232c5..1741ffce9cdfa1bc0374666a704386241e935f67 100644 --- a/app/code/Magento/CatalogInventory/Setup/UpgradeData.php +++ b/app/code/Magento/CatalogInventory/Setup/UpgradeData.php @@ -54,7 +54,7 @@ class UpgradeData implements UpgradeDataInterface public function upgrade(ModuleDataSetupInterface $setup, ModuleContextInterface $context) { $setup->startSetup(); - if (version_compare($context->getVersion(), '2.0.2') < 0) { + if (version_compare($context->getVersion(), '2.2.0') < 0) { $this->upgradeCatalogInventoryStockItem($setup); } $setup->endSetup(); diff --git a/app/code/Magento/CatalogInventory/etc/module.xml b/app/code/Magento/CatalogInventory/etc/module.xml index 711d18bead9c9ece376e74f3b13aced3419b7806..7aff70e2258312c49a6a6cde35bb87c5cb0e8400 100644 --- a/app/code/Magento/CatalogInventory/etc/module.xml +++ b/app/code/Magento/CatalogInventory/etc/module.xml @@ -6,7 +6,7 @@ */ --> <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:Module/etc/module.xsd"> - <module name="Magento_CatalogInventory" setup_version="2.0.2"> + <module name="Magento_CatalogInventory" setup_version="2.2.0"> <sequence> <module name="Magento_Catalog"/> </sequence> diff --git a/app/code/Magento/CatalogWidget/view/frontend/templates/product/widget/content/grid.phtml b/app/code/Magento/CatalogWidget/view/frontend/templates/product/widget/content/grid.phtml index 080714bd228de24f0aa69cae014cb554ef814c53..212846aaa01d7efd067eb14a546b8dcb3467fc1f 100644 --- a/app/code/Magento/CatalogWidget/view/frontend/templates/product/widget/content/grid.phtml +++ b/app/code/Magento/CatalogWidget/view/frontend/templates/product/widget/content/grid.phtml @@ -15,7 +15,6 @@ $mode = 'grid'; $image = 'new_products_content_widget_grid'; - $title = $block->getTitle() ? __($block->getTitle()) : ''; $items = $block->getProductCollection()->getItems(); $showWishlist = true; @@ -25,9 +24,9 @@ $description = false; ?> <div class="block widget block-products-list <?php /* @noEscape */ echo $mode; ?>"> - <?php if ($title): ?> + <?php if ($block->getTitle()): ?> <div class="block-title"> - <strong><?php echo $block->escapeHtml($title); ?></strong> + <strong><?php echo $block->escapeHtml(__($block->getTitle())); ?></strong> </div> <?php endif ?> <div class="block-content"> @@ -64,27 +63,23 @@ <div class="actions-primary"> <?php if ($_item->isSaleable()): ?> <?php if ($_item->getTypeInstance()->hasRequiredOptions($_item)): ?> - <button class="action tocart primary" - data-mage-init='{"redirectUrl":{"url":"<?php echo $block->escapeUrl($block->getAddToCartUrl($_item)) ?>"}}' - type="button" title="<?php /* @escapeNotVerified */ echo __('Add to Cart') ?>"> - <span><?php /* @escapeNotVerified */ echo __('Add to Cart') ?></span> + <button class="action tocart primary" data-mage-init='{"redirectUrl":{"url":"<?php echo $block->escapeUrl($block->getAddToCartUrl($_item)) ?>"}}' type="button" title="<?php echo $block->escapeHtmlAttr(__('Add to Cart')) ?>"> + <span><?php echo $block->escapeHtml(__('Add to Cart')) ?></span> </button> <?php else: ?> <?php $postDataHelper = $this->helper('Magento\Framework\Data\Helper\PostHelper'); $postData = $postDataHelper->getPostData($block->getAddToCartUrl($_item), ['product' => $_item->getEntityId()]) ?> - <button class="action tocart primary" - data-post='<?php /* @noEscape */ echo $postData; ?>' - type="button" title="<?php /* @escapeNotVerified */ echo __('Add to Cart') ?>"> - <span><?php /* @escapeNotVerified */ echo __('Add to Cart') ?></span> + <button class="action tocart primary" data-post='<?php /* @noEscape */ echo $postData; ?>' type="button" title="<?php echo $block->escapeHtmlAttr(__('Add to Cart')) ?>"> + <span><?php echo $block->escapeHtml(__('Add to Cart')) ?></span> </button> <?php endif; ?> <?php else: ?> <?php if ($_item->getIsSalable()): ?> - <div class="stock available"><span><?php /* @escapeNotVerified */ echo __('In stock') ?></span></div> + <div class="stock available"><span><?php echo $block->escapeHtml(__('In stock')) ?></span></div> <?php else: ?> - <div class="stock unavailable"><span><?php /* @escapeNotVerified */ echo __('Out of stock') ?></span></div> + <div class="stock unavailable"><span><?php echo $block->escapeHtml(__('Out of stock')) ?></span></div> <?php endif; ?> <?php endif; ?> </div> @@ -93,18 +88,14 @@ <div class="actions-secondary" data-role="add-to-links"> <?php if ($this->helper('Magento\Wishlist\Helper\Data')->isAllow() && $showWishlist): ?> <a href="#" - data-post='<?php /* @noEscape */ echo $block->getAddToWishlistParams($_item); ?>' - class="action towishlist" data-action="add-to-wishlist" - title="<?php /* @escapeNotVerified */ echo __('Add to Wish List') ?>"> - <span><?php /* @escapeNotVerified */ echo __('Add to Wish List') ?></span> + data-post='<?php /* @noEscape */ echo $block->getAddToWishlistParams($_item); ?>' class="action towishlist" data-action="add-to-wishlist" title="<?php echo $block->escapeHtmlAttr(__('Add to Wish List')) ?>"> + <span><?php echo $block->escapeHtml(__('Add to Wish List')) ?></span> </a> <?php endif; ?> <?php if ($block->getAddToCompareUrl() && $showCompare): ?> <?php $compareHelper = $this->helper('Magento\Catalog\Helper\Product\Compare');?> - <a href="#" class="action tocompare" - data-post='<?php /* @noEscape */ echo $compareHelper->getPostDataParams($_item);?>' - title="<?php /* @escapeNotVerified */ echo __('Add to Compare') ?>"> - <span><?php /* @escapeNotVerified */ echo __('Add to Compare') ?></span> + <a href="#" class="action tocompare" data-post='<?php /* @noEscape */ echo $compareHelper->getPostDataParams($_item);?>' title="<?php echo $block->escapeHtmlAttr(__('Add to Compare')) ?>"> + <span><?php echo $block->escapeHtml(__('Add to Compare')) ?></span> </a> <?php endif; ?> </div> diff --git a/app/code/Magento/Cms/view/adminhtml/templates/browser/content/files.phtml b/app/code/Magento/Cms/view/adminhtml/templates/browser/content/files.phtml index a6185c454189770f39d00ae0c54c95086dc1fcf1..827f2ee938e41378a158090c16a383e62fa9e74e 100644 --- a/app/code/Magento/Cms/view/adminhtml/templates/browser/content/files.phtml +++ b/app/code/Magento/Cms/view/adminhtml/templates/browser/content/files.phtml @@ -21,11 +21,11 @@ $_height = $block->getImagesHeight(); <?php endif; ?> </p> <?php if ($block->getFileWidth($file)): ?> - <small><?php echo $block->escapeHtml($block->getFileWidth($file)) ?>x<?php echo $block->escapeHtml($block->getFileHeight($file)) ?> <?php /* @escapeNotVerified */ echo __('px.') ?></small><br/> + <small><?php echo $block->escapeHtml($block->getFileWidth($file)) ?>x<?php echo $block->escapeHtml($block->getFileHeight($file)) ?> <?php echo $block->escapeHtml(__('px.')) ?></small><br/> <?php endif; ?> <small><?php echo $block->escapeHtml($block->getFileShortName($file)); ?></small> </div> <?php endforeach; ?> <?php else: ?> - <div class="empty"><?php /* @escapeNotVerified */ echo __('No files found') ?></div> + <div class="empty"><?php echo $block->escapeHtml(__('No files found')) ?></div> <?php endif; ?> diff --git a/app/code/Magento/Cms/view/adminhtml/templates/browser/content/uploader.phtml b/app/code/Magento/Cms/view/adminhtml/templates/browser/content/uploader.phtml index 6a29cb1497175d418723af26a041c6bb80a990f8..3233bb17c09a319f27a987e47cb4cdd16661c20d 100644 --- a/app/code/Magento/Cms/view/adminhtml/templates/browser/content/uploader.phtml +++ b/app/code/Magento/Cms/view/adminhtml/templates/browser/content/uploader.phtml @@ -11,7 +11,7 @@ <div id="<?php echo $block->getHtmlId() ?>" class="uploader"> <span class="fileinput-button form-buttons"> - <span><?php /* @escapeNotVerified */ echo __('Browse Files...') ?></span> + <span><?php echo $block->escapeHtml(__('Browse Files...')) ?></span> <input class="fileupload" type="file" name="<?php echo $block->escapeHtmlAttr($block->getConfig()->getFileField()) ?>" data-url="<?php echo $block->escapeUrl($block->getConfig()->getUrl()) ?>" multiple> </span> <div class="clear"></div> diff --git a/app/code/Magento/Cms/view/adminhtml/templates/browser/tree.phtml b/app/code/Magento/Cms/view/adminhtml/templates/browser/tree.phtml index 90a00c32015b7733b54e08cda63217c897f0bf58..2e6204496eba453a40c8288ed041db7781ec27e7 100644 --- a/app/code/Magento/Cms/view/adminhtml/templates/browser/tree.phtml +++ b/app/code/Magento/Cms/view/adminhtml/templates/browser/tree.phtml @@ -11,9 +11,9 @@ <div class="tree-panel" > <div class="categories-side-col"> <div class="tree-actions"> - <a onclick="jQuery('[data-role=tree]').jstree('close_all');"><?php /* @escapeNotVerified */ echo __('Collapse All'); ?></a> + <a onclick="jQuery('[data-role=tree]').jstree('close_all');"><?php echo $block->escapeHtml(__('Collapse All')) ?></a> <span class="separator">|</span> - <a onclick="jQuery('[data-role=tree]').jstree('open_all');"><?php /* @escapeNotVerified */ echo __('Expand All'); ?></a> + <a onclick="jQuery('[data-role=tree]').jstree('open_all');"><?php echo $block->escapeHtml(__('Expand All')) ?></a> </div> </div> <div data-role="tree" data-mage-init='<?php echo $block->escapeHtml($this->helper('Magento\Framework\Json\Helper\Data')->jsonEncode($block->getTreeWidgetOptions())); ?>'> diff --git a/app/code/Magento/Cms/view/frontend/templates/widget/link/link_block.phtml b/app/code/Magento/Cms/view/frontend/templates/widget/link/link_block.phtml index 55c1b02be8797a45a9f4b27914e3195d7695da61..82a27c7aa0d78f1b44f44c9ca9f108d8df1ae586 100644 --- a/app/code/Magento/Cms/view/frontend/templates/widget/link/link_block.phtml +++ b/app/code/Magento/Cms/view/frontend/templates/widget/link/link_block.phtml @@ -3,9 +3,13 @@ * Copyright © 2016 Magento. All rights reserved. * See COPYING.txt for license details. */ + +/** + * @var \Magento\Cms\Block\Widget\Page\Link $block + */ ?> <div class="widget block block-cms-link"> - <a <?php /* @escapeNotVerified */ echo $block->getLinkAttributes() ?>> + <a <?php /* @noEscape */ echo $block->getLinkAttributes() ?>> <span><?php echo $block->escapeHtml($block->getLabel()) ?></span> </a> </div> diff --git a/app/code/Magento/Cms/view/frontend/templates/widget/link/link_inline.phtml b/app/code/Magento/Cms/view/frontend/templates/widget/link/link_inline.phtml index 382b492db3da5c815530d87f13ee959d82e2c083..d906826507d73b50f1c8cbf50a85f8ae2e09c5c8 100644 --- a/app/code/Magento/Cms/view/frontend/templates/widget/link/link_inline.phtml +++ b/app/code/Magento/Cms/view/frontend/templates/widget/link/link_inline.phtml @@ -3,9 +3,13 @@ * Copyright © 2016 Magento. All rights reserved. * See COPYING.txt for license details. */ + +/** + * @var \Magento\Cms\Block\Widget\Page\Link $block + */ ?> <span class="widget block block-cms-link-inline"> - <a <?php /* @escapeNotVerified */ echo $block->getLinkAttributes() ?>> + <a <?php /* @noEscape */ echo $block->getLinkAttributes() ?>> <span><?php echo $block->escapeHtml($block->getLabel()) ?></span> </a> </span> diff --git a/app/code/Magento/Customer/Controller/Adminhtml/Index/Save.php b/app/code/Magento/Customer/Controller/Adminhtml/Index/Save.php index 59e12d72ded6c6cd4de5aaf323acd5f1ffbbd122..fd2ceaf09695bfb4a413bc6f680f254ca4edca4c 100644 --- a/app/code/Magento/Customer/Controller/Adminhtml/Index/Save.php +++ b/app/code/Magento/Customer/Controller/Adminhtml/Index/Save.php @@ -72,6 +72,7 @@ class Save extends \Magento\Customer\Controller\Adminhtml\Index ) { $metadataForm = $this->getMetadataForm($entityType, $formCode, $scope); $formData = $metadataForm->extractData($this->getRequest(), $scope); + $formData = $metadataForm->compactData($formData); // Initialize additional attributes /** @var \Magento\Framework\DataObject $object */ @@ -81,11 +82,6 @@ class Save extends \Magento\Customer\Controller\Adminhtml\Index $formData[$attributeCode] = isset($requestData[$attributeCode]) ? $requestData[$attributeCode] : false; } - $result = $metadataForm->compactData($formData); - - // Re-initialize additional attributes - $formData = array_replace($result, $formData); - // Unset unused attributes $formAttributes = $metadataForm->getAttributes(); foreach ($formAttributes as $attribute) { diff --git a/app/code/Magento/Customer/Test/Unit/Controller/Adminhtml/Index/SaveTest.php b/app/code/Magento/Customer/Test/Unit/Controller/Adminhtml/Index/SaveTest.php index 8fb48fe9f87e76dcf4f5d489a830bb15bf910c79..11fd1b5a7fc3356f54cc1e72b76e111b22446383 100644 --- a/app/code/Magento/Customer/Test/Unit/Controller/Adminhtml/Index/SaveTest.php +++ b/app/code/Magento/Customer/Test/Unit/Controller/Adminhtml/Index/SaveTest.php @@ -304,33 +304,28 @@ class SaveTest extends \PHPUnit_Framework_TestCase ], 'subscription' => $subscription, ]; - $filteredData = [ + $extractedData = [ 'entity_id' => $customerId, 'code' => 'value', 'coolness' => false, 'disable_auto_group_change' => 'false', ]; - $dataToCompact = [ + $compactedData = [ 'entity_id' => $customerId, 'code' => 'value', 'coolness' => false, 'disable_auto_group_change' => 'false', - CustomerInterface::DEFAULT_BILLING => false, - CustomerInterface::DEFAULT_SHIPPING => false, - 'confirmation' => false, - 'sendemail_store_id' => false, - 'extension_attributes' => false, + CustomerInterface::DEFAULT_BILLING => 2, + CustomerInterface::DEFAULT_SHIPPING => 2 ]; - $addressFilteredData = [ + $addressExtractedData = [ 'entity_id' => $addressId, - 'default_billing' => 'true', - 'default_shipping' => 'true', 'code' => 'value', 'coolness' => false, 'region' => 'region', 'region_id' => 'region_id', ]; - $addressDataToCompact = [ + $addressCompactedData = [ 'entity_id' => $addressId, 'default_billing' => 'true', 'default_shipping' => 'true', @@ -430,11 +425,11 @@ class SaveTest extends \PHPUnit_Framework_TestCase $customerFormMock->expects($this->once()) ->method('extractData') ->with($this->requestMock, 'customer') - ->willReturn($filteredData); + ->willReturn($extractedData); $customerFormMock->expects($this->once()) ->method('compactData') - ->with($dataToCompact) - ->willReturn($filteredData); + ->with($extractedData) + ->willReturn($compactedData); $customerFormMock->expects($this->once()) ->method('getAttributes') ->willReturn($attributes); @@ -445,11 +440,11 @@ class SaveTest extends \PHPUnit_Framework_TestCase $customerAddressFormMock->expects($this->once()) ->method('extractData') ->with($this->requestMock, 'address/' . $addressId) - ->willReturn($addressFilteredData); + ->willReturn($addressExtractedData); $customerAddressFormMock->expects($this->once()) ->method('compactData') - ->with($addressDataToCompact) - ->willReturn($addressFilteredData); + ->with($addressExtractedData) + ->willReturn($addressCompactedData); $customerAddressFormMock->expects($this->once()) ->method('getAttributes') ->willReturn($attributes); @@ -625,8 +620,6 @@ class SaveTest extends \PHPUnit_Framework_TestCase '_template_' => '_template_', $addressId => [ 'entity_id' => $addressId, - 'default_billing' => 'false', - 'default_shipping' => 'false', 'code' => 'value', 'coolness' => false, 'region' => 'region', @@ -635,32 +628,12 @@ class SaveTest extends \PHPUnit_Framework_TestCase ], 'subscription' => $subscription, ]; - $filteredData = [ + $extractedData = [ 'coolness' => false, 'disable_auto_group_change' => 'false', ]; - $dataToCompact = [ - 'coolness' => false, - 'disable_auto_group_change' => 'false', - CustomerInterface::DEFAULT_BILLING => false, - CustomerInterface::DEFAULT_SHIPPING => false, - 'confirmation' => false, - 'sendemail_store_id' => false, - 'extension_attributes' => false, - ]; - $addressFilteredData = [ + $addressExtractedData = [ 'entity_id' => $addressId, - 'default_billing' => 'false', - 'default_shipping' => 'false', - 'code' => 'value', - 'coolness' => false, - 'region' => 'region', - 'region_id' => 'region_id', - ]; - $addressDataToCompact = [ - 'entity_id' => $addressId, - 'default_billing' => 'false', - 'default_shipping' => 'false', 'code' => 'value', 'coolness' => false, 'region' => 'region', @@ -739,11 +712,11 @@ class SaveTest extends \PHPUnit_Framework_TestCase $customerFormMock->expects($this->once()) ->method('extractData') ->with($this->requestMock, 'customer') - ->willReturn($filteredData); + ->willReturn($extractedData); $customerFormMock->expects($this->once()) ->method('compactData') - ->with($dataToCompact) - ->willReturn($filteredData); + ->with($extractedData) + ->willReturn($extractedData); $customerFormMock->expects($this->once()) ->method('getAttributes') ->willReturn($attributes); @@ -754,11 +727,11 @@ class SaveTest extends \PHPUnit_Framework_TestCase $customerAddressFormMock->expects($this->once()) ->method('extractData') ->with($this->requestMock, 'address/' . $addressId) - ->willReturn($addressFilteredData); + ->willReturn($addressExtractedData); $customerAddressFormMock->expects($this->once()) ->method('compactData') - ->with($addressDataToCompact) - ->willReturn($addressFilteredData); + ->with($addressExtractedData) + ->willReturn($addressExtractedData); $customerAddressFormMock->expects($this->once()) ->method('getAttributes') ->willReturn($attributes); @@ -910,19 +883,10 @@ class SaveTest extends \PHPUnit_Framework_TestCase ], 'subscription' => $subscription, ]; - $filteredData = [ + $extractedData = [ 'coolness' => false, 'disable_auto_group_change' => 'false', ]; - $dataToCompact = [ - 'coolness' => false, - 'disable_auto_group_change' => 'false', - CustomerInterface::DEFAULT_BILLING => false, - CustomerInterface::DEFAULT_SHIPPING => false, - 'confirmation' => false, - 'sendemail_store_id' => false, - 'extension_attributes' => false, - ]; /** @var AttributeMetadataInterface|\PHPUnit_Framework_MockObject_MockObject $customerFormMock */ $attributeMock = $this->getMockBuilder( @@ -971,11 +935,11 @@ class SaveTest extends \PHPUnit_Framework_TestCase $customerFormMock->expects($this->once()) ->method('extractData') ->with($this->requestMock, 'customer') - ->willReturn($filteredData); + ->willReturn($extractedData); $customerFormMock->expects($this->once()) ->method('compactData') - ->with($dataToCompact) - ->willReturn($filteredData); + ->with($extractedData) + ->willReturn($extractedData); $customerFormMock->expects($this->once()) ->method('getAttributes') ->willReturn($attributes); @@ -1062,19 +1026,10 @@ class SaveTest extends \PHPUnit_Framework_TestCase ], 'subscription' => $subscription, ]; - $filteredData = [ + $extractedData = [ 'coolness' => false, 'disable_auto_group_change' => 'false', ]; - $dataToCompact = [ - 'coolness' => false, - 'disable_auto_group_change' => 'false', - CustomerInterface::DEFAULT_BILLING => false, - CustomerInterface::DEFAULT_SHIPPING => false, - 'confirmation' => false, - 'sendemail_store_id' => false, - 'extension_attributes' => false, - ]; /** @var AttributeMetadataInterface|\PHPUnit_Framework_MockObject_MockObject $customerFormMock */ $attributeMock = $this->getMockBuilder( @@ -1124,11 +1079,11 @@ class SaveTest extends \PHPUnit_Framework_TestCase $customerFormMock->expects($this->once()) ->method('extractData') ->with($this->requestMock, 'customer') - ->willReturn($filteredData); + ->willReturn($extractedData); $customerFormMock->expects($this->once()) ->method('compactData') - ->with($dataToCompact) - ->willReturn($filteredData); + ->with($extractedData) + ->willReturn($extractedData); $customerFormMock->expects($this->once()) ->method('getAttributes') ->willReturn($attributes); @@ -1214,18 +1169,9 @@ class SaveTest extends \PHPUnit_Framework_TestCase ], 'subscription' => $subscription, ]; - $filteredData = [ - 'coolness' => false, - 'disable_auto_group_change' => 'false', - ]; - $dataToCompact = [ + $extractedData = [ 'coolness' => false, 'disable_auto_group_change' => 'false', - CustomerInterface::DEFAULT_BILLING => false, - CustomerInterface::DEFAULT_SHIPPING => false, - 'confirmation' => false, - 'sendemail_store_id' => false, - 'extension_attributes' => false, ]; /** @var AttributeMetadataInterface|\PHPUnit_Framework_MockObject_MockObject $customerFormMock */ @@ -1275,11 +1221,11 @@ class SaveTest extends \PHPUnit_Framework_TestCase $customerFormMock->expects($this->once()) ->method('extractData') ->with($this->requestMock, 'customer') - ->willReturn($filteredData); + ->willReturn($extractedData); $customerFormMock->expects($this->once()) ->method('compactData') - ->with($dataToCompact) - ->willReturn($filteredData); + ->with($extractedData) + ->willReturn($extractedData); $customerFormMock->expects($this->once()) ->method('getAttributes') ->willReturn($attributes); diff --git a/app/code/Magento/Customer/Test/Unit/Model/AccountManagementTest.php b/app/code/Magento/Customer/Test/Unit/Model/AccountManagementTest.php index 9eed3d2b044ca166d35703d35e1fd1995e181108..28697fa5cf85faf8bb33dd61c9f5816fc0b60eed 100644 --- a/app/code/Magento/Customer/Test/Unit/Model/AccountManagementTest.php +++ b/app/code/Magento/Customer/Test/Unit/Model/AccountManagementTest.php @@ -1146,7 +1146,7 @@ class AccountManagementTest extends \PHPUnit_Framework_TestCase $storeId = 1; - mt_srand(mt_rand() + (100000000 * microtime()) % PHP_INT_MAX); + mt_srand(mt_rand() + (100000000 * (float)microtime()) % PHP_INT_MAX); $hash = md5(uniqid(microtime() . mt_rand(0, mt_getrandmax()), true)); $this->emailNotificationMock->expects($this->once()) @@ -1168,7 +1168,7 @@ class AccountManagementTest extends \PHPUnit_Framework_TestCase $templateIdentifier = 'Template Identifier'; $sender = 'Sender'; - mt_srand(mt_rand() + (100000000 * microtime()) % PHP_INT_MAX); + mt_srand(mt_rand() + (100000000 * (float)microtime()) % PHP_INT_MAX); $hash = md5(uniqid(microtime() . mt_rand(0, mt_getrandmax()), true)); $this->emailNotificationMock->expects($this->once()) @@ -1194,7 +1194,7 @@ class AccountManagementTest extends \PHPUnit_Framework_TestCase $templateIdentifier = 'Template Identifier'; $sender = 'Sender'; - mt_srand(mt_rand() + (100000000 * microtime()) % PHP_INT_MAX); + mt_srand(mt_rand() + (100000000 * (float)microtime()) % PHP_INT_MAX); $hash = md5(uniqid(microtime() . mt_rand(0, mt_getrandmax()), true)); $this->prepareInitiatePasswordReset($email, $templateIdentifier, $sender, $storeId, $customerId, $hash); diff --git a/app/code/Magento/Integration/Model/Config.php b/app/code/Magento/Integration/Model/Config.php index 70795cae0035034a7801c6a21cc3bb90ab566e1f..3cea4d33743198988c44d8c8aae9bf6e9f247efa 100644 --- a/app/code/Magento/Integration/Model/Config.php +++ b/app/code/Magento/Integration/Model/Config.php @@ -5,6 +5,8 @@ */ namespace Magento\Integration\Model; +use Magento\Framework\App\ObjectManager; +use Magento\Framework\Serialize\SerializerInterface; use Magento\Integration\Model\Cache\Type; /** @@ -34,14 +36,24 @@ class Config */ protected $_integrations; + /** + * @var SerializerInterface + */ + private $serializer; + /** * @param Cache\Type $configCacheType * @param Config\Reader $configReader + * @param SerializerInterface $serializer */ - public function __construct(Cache\Type $configCacheType, Config\Reader $configReader) - { + public function __construct( + Cache\Type $configCacheType, + Config\Reader $configReader, + SerializerInterface $serializer = null + ) { $this->_configCacheType = $configCacheType; $this->_configReader = $configReader; + $this->serializer = $serializer ?: ObjectManager::getInstance()->get(SerializerInterface::class); } /** @@ -55,10 +67,14 @@ class Config if (null === $this->_integrations) { $integrations = $this->_configCacheType->load(self::CACHE_ID); if ($integrations && is_string($integrations)) { - $this->_integrations = unserialize($integrations); + $this->_integrations = $this->serializer->unserialize($integrations); } else { $this->_integrations = $this->_configReader->read(); - $this->_configCacheType->save(serialize($this->_integrations), self::CACHE_ID, [Type::CACHE_TAG]); + $this->_configCacheType->save( + $this->serializer->serialize($this->_integrations), + self::CACHE_ID, + [Type::CACHE_TAG] + ); } } return $this->_integrations; diff --git a/app/code/Magento/Integration/Model/ConsolidatedConfig.php b/app/code/Magento/Integration/Model/ConsolidatedConfig.php index 9027bf774bc30a9a5b7cb6a427057efc45971742..9208d19e7028f8f753d6e20c2d43765163cb9bec 100644 --- a/app/code/Magento/Integration/Model/ConsolidatedConfig.php +++ b/app/code/Magento/Integration/Model/ConsolidatedConfig.php @@ -5,6 +5,8 @@ */ namespace Magento\Integration\Model; +use Magento\Framework\App\ObjectManager; +use Magento\Framework\Serialize\SerializerInterface; use Magento\Integration\Model\Cache\TypeConsolidated; /** @@ -31,14 +33,24 @@ class ConsolidatedConfig */ protected $integrations; + /** + * @var SerializerInterface + */ + private $serializer; + /** * @param Cache\TypeConsolidated $configCacheType * @param Config\Consolidated\Reader $configReader + * @param SerializerInterface $serializer */ - public function __construct(Cache\TypeConsolidated $configCacheType, Config\Consolidated\Reader $configReader) - { + public function __construct( + Cache\TypeConsolidated $configCacheType, + Config\Consolidated\Reader $configReader, + SerializerInterface $serializer = null + ) { $this->configCacheType = $configCacheType; $this->configReader = $configReader; + $this->serializer = $serializer ?: ObjectManager::getInstance()->get(SerializerInterface::class); } /** @@ -51,11 +63,11 @@ class ConsolidatedConfig if (null === $this->integrations) { $integrations = $this->configCacheType->load(self::CACHE_ID); if ($integrations && is_string($integrations)) { - $this->integrations = unserialize($integrations); + $this->integrations = $this->serializer->unserialize($integrations); } else { $this->integrations = $this->configReader->read(); $this->configCacheType->save( - serialize($this->integrations), + $this->serializer->serialize($this->integrations), self::CACHE_ID, [TypeConsolidated::CACHE_TAG] ); diff --git a/app/code/Magento/Integration/Model/IntegrationConfig.php b/app/code/Magento/Integration/Model/IntegrationConfig.php index 647bff70efe4afdffd35e5294251e0fe9e98aa98..cde4fc20d22351ff4b9dedd9d93254f8d838438a 100644 --- a/app/code/Magento/Integration/Model/IntegrationConfig.php +++ b/app/code/Magento/Integration/Model/IntegrationConfig.php @@ -6,6 +6,8 @@ namespace Magento\Integration\Model; +use Magento\Framework\App\ObjectManager; +use Magento\Framework\Serialize\SerializerInterface; use Magento\Integration\Model\Cache\TypeIntegration; use Magento\Integration\Model\Config\Integration\Reader; @@ -36,14 +38,24 @@ class IntegrationConfig */ protected $_integrations; + /** + * @var SerializerInterface + */ + private $serializer; + /** * @param TypeIntegration $configCacheType * @param Reader $configReader + * @param SerializerInterface $serializer */ - public function __construct(TypeIntegration $configCacheType, Reader $configReader) - { + public function __construct( + TypeIntegration $configCacheType, + Reader $configReader, + SerializerInterface $serializer = null + ) { $this->_configCacheType = $configCacheType; $this->_configReader = $configReader; + $this->serializer = $serializer ?: ObjectManager::getInstance()->get(SerializerInterface::class); } /** @@ -57,11 +69,11 @@ class IntegrationConfig if (null === $this->_integrations) { $integrations = $this->_configCacheType->load(self::CACHE_ID); if ($integrations && is_string($integrations)) { - $this->_integrations = unserialize($integrations); + $this->_integrations = $this->serializer->unserialize($integrations); } else { $this->_integrations = $this->_configReader->read(); $this->_configCacheType->save( - serialize($this->_integrations), + $this->serializer->serialize($this->_integrations), self::CACHE_ID, [TypeIntegration::CACHE_TAG] ); diff --git a/app/code/Magento/Integration/Test/Unit/Model/ConsolidatedConfigTest.php b/app/code/Magento/Integration/Test/Unit/Model/ConsolidatedConfigTest.php index 0b75592782773d504061e4e6f9a56c67ebe5982e..22b50a8aef8d070c479ca2a28b499308a6a95c80 100644 --- a/app/code/Magento/Integration/Test/Unit/Model/ConsolidatedConfigTest.php +++ b/app/code/Magento/Integration/Test/Unit/Model/ConsolidatedConfigTest.php @@ -5,6 +5,7 @@ */ namespace Magento\Integration\Test\Unit\Model; +use Magento\Framework\Serialize\SerializerInterface; use Magento\Integration\Model\ConsolidatedConfig as Config; use Magento\Integration\Model\Cache\TypeConsolidated as Type; @@ -18,17 +19,22 @@ class ConsolidatedConfigTest extends \PHPUnit_Framework_TestCase * * @var Config */ - protected $configModel; + private $configModel; /** * @var Type|\PHPUnit_Framework_MockObject_MockObject */ - protected $configCacheTypeMock; + private $configCacheTypeMock; /** * @var \Magento\Integration\Model\Config\Consolidated\Reader|\PHPUnit_Framework_MockObject_MockObject */ - protected $configReaderMock; + private $configReaderMock; + + /** + * @var SerializerInterface|\PHPUnit_Framework_MockObject_MockObject + */ + private $serializer; protected function setUp() { @@ -38,12 +44,16 @@ class ConsolidatedConfigTest extends \PHPUnit_Framework_TestCase $this->configReaderMock = $this->getMockBuilder(\Magento\Integration\Model\Config\Consolidated\Reader::class) ->disableOriginalConstructor() ->getMock(); + $this->serializer = $this->getMockBuilder(SerializerInterface::class) + ->disableOriginalConstructor() + ->getMock(); $objectManagerHelper = new \Magento\Framework\TestFramework\Unit\Helper\ObjectManager($this); $this->configModel = $objectManagerHelper->getObject( \Magento\Integration\Model\ConsolidatedConfig::class, [ 'configCacheType' => $this->configCacheTypeMock, - 'configReader' => $this->configReaderMock + 'configReader' => $this->configReaderMock, + 'serializer' => $this->serializer, ] ); } @@ -51,10 +61,15 @@ class ConsolidatedConfigTest extends \PHPUnit_Framework_TestCase public function testGetIntegrationsFromConfigCacheType() { $integrations = ['foo', 'bar', 'baz']; + $serializedIntegrations = '["foo","bar","baz"]'; $this->configCacheTypeMock->expects($this->once()) ->method('load') ->with(Config::CACHE_ID) - ->will($this->returnValue(serialize($integrations))); + ->will($this->returnValue($serializedIntegrations)); + $this->serializer->expects($this->once()) + ->method('unserialize') + ->with($serializedIntegrations) + ->willReturn($integrations); $this->assertEquals($integrations, $this->configModel->getIntegrations()); } @@ -62,17 +77,21 @@ class ConsolidatedConfigTest extends \PHPUnit_Framework_TestCase public function testGetIntegrationsFromConfigReader() { $integrations = ['foo', 'bar', 'baz']; + $serializedIntegrations = '["foo","bar","baz"]'; $this->configCacheTypeMock->expects($this->once()) ->method('load') ->with(Config::CACHE_ID) ->will($this->returnValue(null)); - $this->configCacheTypeMock->expects($this->once()) - ->method('save') - ->with(serialize($integrations), Config::CACHE_ID, [Type::CACHE_TAG]) - ->will($this->returnValue(null)); $this->configReaderMock->expects($this->once()) ->method('read') ->will($this->returnValue($integrations)); + $this->serializer->expects($this->once()) + ->method('serialize') + ->with($integrations) + ->willReturn($serializedIntegrations); + $this->configCacheTypeMock->expects($this->once()) + ->method('save') + ->with($serializedIntegrations, Config::CACHE_ID, [Type::CACHE_TAG]); $this->assertEquals($integrations, $this->configModel->getIntegrations()); } diff --git a/app/code/Magento/Integration/Test/Unit/Model/IntegrationConfigTest.php b/app/code/Magento/Integration/Test/Unit/Model/IntegrationConfigTest.php index aed4e02453dc435fa5ff87f30931560bace8721e..14871420a621aceec2d5dcb79f209c60fac1f9f6 100644 --- a/app/code/Magento/Integration/Test/Unit/Model/IntegrationConfigTest.php +++ b/app/code/Magento/Integration/Test/Unit/Model/IntegrationConfigTest.php @@ -5,6 +5,7 @@ */ namespace Magento\Integration\Test\Unit\Model; +use Magento\Framework\Serialize\SerializerInterface; use Magento\Integration\Model\IntegrationConfig; use Magento\Integration\Model\Cache\TypeIntegration; @@ -16,17 +17,22 @@ class IntegrationConfigTest extends \PHPUnit_Framework_TestCase /** * @var IntegrationConfig */ - protected $integrationConfigModel; + private $integrationConfigModel; /** * @var TypeIntegration|\PHPUnit_Framework_MockObject_MockObject */ - protected $configCacheTypeMock; + private $configCacheTypeMock; /** * @var \Magento\Integration\Model\Config\Integration\Reader|\PHPUnit_Framework_MockObject_MockObject */ - protected $configReaderMock; + private $configReaderMock; + + /** + * @var SerializerInterface|\PHPUnit_Framework_MockObject_MockObject + */ + private $serializer; protected function setUp() { @@ -36,19 +42,28 @@ class IntegrationConfigTest extends \PHPUnit_Framework_TestCase $this->configReaderMock = $this->getMockBuilder(\Magento\Integration\Model\Config\Integration\Reader::class) ->disableOriginalConstructor() ->getMock(); + $this->serializer = $this->getMockBuilder(SerializerInterface::class) + ->disableOriginalConstructor() + ->getMock(); $this->integrationConfigModel = new IntegrationConfig( $this->configCacheTypeMock, - $this->configReaderMock + $this->configReaderMock, + $this->serializer ); } public function testGetIntegrationsFromConfigCacheType() { $integrations = ['foo', 'bar', 'baz']; + $serializedIntegrations = '["foo","bar","baz"]'; $this->configCacheTypeMock->expects($this->once()) ->method('load') ->with(IntegrationConfig::CACHE_ID) - ->will($this->returnValue(serialize($integrations))); + ->will($this->returnValue($serializedIntegrations)); + $this->serializer->expects($this->once()) + ->method('unserialize') + ->with($serializedIntegrations) + ->willReturn($integrations); $this->assertEquals($integrations, $this->integrationConfigModel->getIntegrations()); } @@ -56,17 +71,22 @@ class IntegrationConfigTest extends \PHPUnit_Framework_TestCase public function testGetIntegrationsFromConfigReader() { $integrations = ['foo', 'bar', 'baz']; + $serializedIntegrations = '["foo","bar","baz"]'; $this->configCacheTypeMock->expects($this->once()) ->method('load') ->with(IntegrationConfig::CACHE_ID) ->will($this->returnValue(null)); - $this->configCacheTypeMock->expects($this->once()) - ->method('save') - ->with(serialize($integrations), IntegrationConfig::CACHE_ID, [TypeIntegration::CACHE_TAG]) - ->will($this->returnValue(null)); $this->configReaderMock->expects($this->once()) ->method('read') ->will($this->returnValue($integrations)); + $this->serializer->expects($this->once()) + ->method('serialize') + ->with($integrations) + ->willReturn($serializedIntegrations); + $this->configCacheTypeMock->expects($this->once()) + ->method('save') + ->with($serializedIntegrations, IntegrationConfig::CACHE_ID, [TypeIntegration::CACHE_TAG]) + ->will($this->returnValue(null)); $this->assertEquals($integrations, $this->integrationConfigModel->getIntegrations()); } diff --git a/app/code/Magento/Marketplace/Helper/Cache.php b/app/code/Magento/Marketplace/Helper/Cache.php index 1cb5fb9c710e67885f0e7266d57873ca29cb3e21..a0a4ce73e0373ac7d057777160c7ac5028321e8c 100644 --- a/app/code/Magento/Marketplace/Helper/Cache.php +++ b/app/code/Magento/Marketplace/Helper/Cache.php @@ -6,7 +6,8 @@ namespace Magento\Marketplace\Helper; -use Magento\Framework\Filesystem; +use Magento\Framework\App\ObjectManager; +use Magento\Framework\Serialize\SerializerInterface; /** * Cache helper @@ -25,15 +26,23 @@ class Cache extends \Magento\Framework\App\Helper\AbstractHelper */ protected $cache; + /** + * @var SerializerInterface + */ + private $serializer; + /** * @param \Magento\Framework\App\Helper\Context $context * @param \Magento\Framework\Config\CacheInterface $cache + * @param SerializerInterface $serializer */ public function __construct( \Magento\Framework\App\Helper\Context $context, - \Magento\Framework\Config\CacheInterface $cache + \Magento\Framework\Config\CacheInterface $cache, + SerializerInterface $serializer = null ) { $this->cache = $cache; + $this->serializer = $serializer ?: ObjectManager::getInstance()->get(SerializerInterface::class); parent::__construct($context); } @@ -46,7 +55,7 @@ class Cache extends \Magento\Framework\App\Helper\AbstractHelper { $data = $this->getCache()->load($this->pathToCacheFile); if (false !== $data) { - $data = unserialize($data); + $data = $this->serializer->unserialize($data); } return $data; } @@ -59,7 +68,7 @@ class Cache extends \Magento\Framework\App\Helper\AbstractHelper */ public function savePartnersToCache($partners) { - return $this->getCache()->save(serialize($partners), $this->pathToCacheFile); + return $this->getCache()->save($this->serializer->serialize($partners), $this->pathToCacheFile); } /** diff --git a/app/code/Magento/Marketplace/Test/Unit/Helper/CacheTest.php b/app/code/Magento/Marketplace/Test/Unit/Helper/CacheTest.php index 75c6e6110389c5a920c3053aa451a6d0deab3775..00b78a47eb4b0be4c5b89cf3383dac80028dc899 100644 --- a/app/code/Magento/Marketplace/Test/Unit/Helper/CacheTest.php +++ b/app/code/Magento/Marketplace/Test/Unit/Helper/CacheTest.php @@ -6,70 +6,79 @@ namespace Magento\Marketplace\Test\Unit\Helper; +use Magento\Framework\Serialize\SerializerInterface; + class CacheTest extends \PHPUnit_Framework_TestCase { /** - * @var \PHPUnit_Framework_MockObject_MockObject|\Magento\Marketplace\Helper\Cache + * @var \Magento\Framework\Config\CacheInterface|\PHPUnit_Framework_MockObject_MockObject + */ + private $cache; + + /** + * @var SerializerInterface|\PHPUnit_Framework_MockObject_MockObject */ - private $cacheHelperMock; + private $serializer; + + /** + * @var \Magento\Marketplace\Helper\Cache + */ + private $cacheHelper; protected function setUp() { - $this->cacheHelperMock = $this->getCacheHelperMock(['getCache']); + $this->cache = $this->getMockForAbstractClass(\Magento\Framework\Config\CacheInterface::class); + $this->serializer = $this->getMockForAbstractClass(SerializerInterface::class); + $objectManagerHelper = new \Magento\Framework\TestFramework\Unit\Helper\ObjectManager($this); + $this->cacheHelper = $objectManagerHelper->getObject( + \Magento\Marketplace\Helper\Cache::class, + [ + 'cache' => $this->cache, + 'serializer' => $this->serializer, + ] + ); } - /** - * @covers \Magento\Marketplace\Helper\Cache::loadPartnersFromCache - */ public function testLoadPartnersFromCache() { - $cache = $this->getCacheMock(); - $this->cacheHelperMock - ->expects($this->once()) - ->method('getCache') - ->will($this->returnValue($cache)); - $cache->expects($this->once()) + $partners = ['partner1', 'partner2']; + $serializedPartners = '["partner1", "partner2"]'; + $this->cache->expects($this->once()) ->method('load') - ->will($this->returnValue('')); + ->with('partners') + ->willReturn($serializedPartners); + $this->serializer->expects($this->once()) + ->method('unserialize') + ->with($serializedPartners) + ->willReturn($partners); - $this->cacheHelperMock->loadPartnersFromCache(); + $this->assertSame($partners, $this->cacheHelper->loadPartnersFromCache()); } - /** - * @covers \Magento\Marketplace\Helper\Cache::savePartnersToCache - */ - public function testSavePartnersToCache() + public function testLoadPartnersFromCacheNoCachedData() { - $cache = $this->getCacheMock(); - $this->cacheHelperMock - ->expects($this->once()) - ->method('getCache') - ->will($this->returnValue($cache)); - $cache->expects($this->once()) - ->method('save') - ->will($this->returnValue(true)); + $this->cache->expects($this->once()) + ->method('load') + ->with('partners') + ->willReturn(false); + $this->serializer->expects($this->never()) + ->method('unserialize'); - $this->cacheHelperMock->savePartnersToCache([]); + $this->assertSame(false, $this->cacheHelper->loadPartnersFromCache()); } - /** - * Gets cache helper mock - * - * @param null $methods - * @return \PHPUnit_Framework_MockObject_MockObject|\Magento\Marketplace\Helper\Cache - */ - public function getCacheHelperMock($methods = null) + public function testSavePartnersToCache() { - return $this->getMock(\Magento\Marketplace\Helper\Cache::class, $methods, [], '', false); - } + $partners = ['partner1', 'partner2']; + $serializedPartners = '["partner1", "partner2"]'; + $this->serializer->expects($this->once()) + ->method('serialize') + ->with($partners) + ->willReturn($serializedPartners); + $this->cache->expects($this->once()) + ->method('save') + ->with($serializedPartners); - /** - * Gets Filesystem mock - * - * @return \PHPUnit_Framework_MockObject_MockObject|\Magento\Framework\Config\CacheInterface - */ - public function getCacheMock() - { - return $this->getMockForAbstractClass(\Magento\Framework\Config\CacheInterface::class); + $this->cacheHelper->savePartnersToCache($partners); } } diff --git a/app/code/Magento/Newsletter/view/frontend/templates/subscribe.phtml b/app/code/Magento/Newsletter/view/frontend/templates/subscribe.phtml index fb6989716cd2dfc64d1e97c487e77f3b47afeb35..0ee371c32817649669fe2bc20d88b08e132a9a11 100644 --- a/app/code/Magento/Newsletter/view/frontend/templates/subscribe.phtml +++ b/app/code/Magento/Newsletter/view/frontend/templates/subscribe.phtml @@ -10,7 +10,7 @@ ?> <div class="block newsletter"> - <div class="title"><strong>Newsletter</strong></div> + <div class="title"><strong><?php /* @escapeNotVerified */ echo __('Newsletter') ?></strong></div> <div class="content"> <form class="form subscribe" novalidate diff --git a/app/code/Magento/PageCache/Model/Config.php b/app/code/Magento/PageCache/Model/Config.php index 222d9d57e467a31988fd6b6ac221f7ce640c06c5..786165728406f0162be0da04f869a10020d9d3bb 100644 --- a/app/code/Magento/PageCache/Model/Config.php +++ b/app/code/Magento/PageCache/Model/Config.php @@ -148,12 +148,17 @@ class Config ), '/* {{ ips }} */' => $this->_getAccessList(), '/* {{ design_exceptions_code }} */' => $this->_getDesignExceptions(), - // http headers get transformed by php `X-Forwarded-Proto: https` becomes $SERVER['HTTP_X_FORWARDED_PROTO'] = 'https' + // http headers get transformed by php `X-Forwarded-Proto: https` + // becomes $SERVER['HTTP_X_FORWARDED_PROTO'] = 'https' // Apache and Nginx drop all headers with underlines by default. - '/* {{ ssl_offloaded_header }} */' => str_replace('_', '-', $this->_scopeConfig->getValue( - \Magento\Framework\HTTP\PhpEnvironment\Request::XML_PATH_OFFLOADER_HEADER, - \Magento\Store\Model\ScopeInterface::SCOPE_STORE)) - + '/* {{ ssl_offloaded_header }} */' => str_replace( + '_', + '-', + $this->_scopeConfig->getValue( + \Magento\Framework\HTTP\PhpEnvironment\Request::XML_PATH_OFFLOADER_HEADER, + \Magento\Store\Model\ScopeInterface::SCOPE_STORE + ) + ) ]; } @@ -176,6 +181,7 @@ class Config \Magento\Store\Model\ScopeInterface::SCOPE_STORE ); if (!empty($accessList)) { + $result = []; $ips = explode(',', $accessList); foreach ($ips as $ip) { $result[] = sprintf($tpl, trim($ip)); diff --git a/app/code/Magento/Quote/Model/QueryResolver.php b/app/code/Magento/Quote/Model/QueryResolver.php index cfc1480feb66386a122b21a6484107a205cad566..04d83bab85b2bf4b31c5d57e8c2b742614a4694b 100644 --- a/app/code/Magento/Quote/Model/QueryResolver.php +++ b/app/code/Magento/Quote/Model/QueryResolver.php @@ -5,8 +5,10 @@ */ namespace Magento\Quote\Model; +use Magento\Framework\App\ObjectManager; use Magento\Framework\Config\CacheInterface; use Magento\Framework\App\ResourceConnection\ConfigInterface; +use Magento\Framework\Serialize\SerializerInterface; class QueryResolver { @@ -37,19 +39,27 @@ class QueryResolver */ private $cacheTags = []; + /** + * @var SerializerInterface + */ + private $serializer; + /** * @param ConfigInterface $config * @param CacheInterface $cache * @param string $cacheId + * @param SerializerInterface $serializer */ public function __construct( ConfigInterface $config, CacheInterface $cache, - $cacheId = 'connection_config_cache' + $cacheId = 'connection_config_cache', + SerializerInterface $serializer = null ) { $this->config = $config; $this->cache = $cache; $this->cacheId = $cacheId; + $this->serializer = $serializer ?: ObjectManager::getInstance()->get(SerializerInterface::class); } /** @@ -75,9 +85,9 @@ class QueryResolver if (false === $data) { $singleQuery = $this->config->getConnectionName('checkout_setup') == 'default' ? true : false; $data['checkout'] = $singleQuery; - $this->cache->save(serialize($data), $this->cacheId, $this->cacheTags); + $this->cache->save($this->serializer->serialize($data), $this->cacheId, $this->cacheTags); } else { - $data = unserialize($data); + $data = $this->serializer->unserialize($data); } $this->merge($data); } diff --git a/app/code/Magento/Quote/Model/Quote/Address/Total/Collector.php b/app/code/Magento/Quote/Model/Quote/Address/Total/Collector.php index 8e62d1b942f1e2a5808e76ac293c94abd9830cad..d430bf3acc6cd08d22b0f352efde6b9dc7774fed 100644 --- a/app/code/Magento/Quote/Model/Quote/Address/Total/Collector.php +++ b/app/code/Magento/Quote/Model/Quote/Address/Total/Collector.php @@ -5,6 +5,8 @@ */ namespace Magento\Quote\Model\Quote\Address\Total; +use Magento\Framework\Serialize\SerializerInterface; + /** * Address Total Collector model */ @@ -69,6 +71,7 @@ class Collector extends \Magento\Sales\Model\Config\Ordered * @param \Magento\Quote\Model\Quote\Address\TotalFactory $totalFactory * @param mixed $sourceData * @param mixed $store + * @param SerializerInterface $serializer */ public function __construct( \Magento\Framework\App\Cache\Type\Config $configCacheType, @@ -78,11 +81,12 @@ class Collector extends \Magento\Sales\Model\Config\Ordered \Magento\Store\Model\StoreManagerInterface $storeManager, \Magento\Quote\Model\Quote\Address\TotalFactory $totalFactory, $sourceData = null, - $store = null + $store = null, + SerializerInterface $serializer = null ) { $this->_scopeConfig = $scopeConfig; $this->_totalFactory = $totalFactory; - parent::__construct($configCacheType, $logger, $salesConfig, $sourceData); + parent::__construct($configCacheType, $logger, $salesConfig, $sourceData, $serializer); $this->_store = $store ?: $storeManager->getStore(); $this->_initModels()->_initCollectors()->_initRetrievers(); } diff --git a/app/code/Magento/Quote/Test/Unit/Model/QueryResolverTest.php b/app/code/Magento/Quote/Test/Unit/Model/QueryResolverTest.php index a2075b1161fc2a9cde83ba9af7bd2729244aa9a3..eb6828afff4edc79f0fb32bea383515ebacdcf86 100644 --- a/app/code/Magento/Quote/Test/Unit/Model/QueryResolverTest.php +++ b/app/code/Magento/Quote/Test/Unit/Model/QueryResolverTest.php @@ -6,83 +6,100 @@ namespace Magento\Quote\Test\Unit\Model; +use Magento\Framework\Serialize\SerializerInterface; + class QueryResolverTest extends \PHPUnit_Framework_TestCase { /** * @var \Magento\Quote\Model\QueryResolver */ - protected $quoteResolver; + private $quoteResolver; /** * @var \PHPUnit_Framework_MockObject_MockObject */ - protected $configMock; + private $configMock; /** * @var \PHPUnit_Framework_MockObject_MockObject */ - protected $cacheMock; + private $cacheMock; + + /** + * @var SerializerInterface|\PHPUnit_Framework_MockObject_MockObject + */ + private $serializer; protected function setUp() { $this->configMock = $this->getMock(\Magento\Framework\App\ResourceConnection\ConfigInterface::class); $this->cacheMock = $this->getMock(\Magento\Framework\Config\CacheInterface::class); + $this->serializer = $this->getMockForAbstractClass(SerializerInterface::class); $this->quoteResolver = new \Magento\Quote\Model\QueryResolver( $this->configMock, $this->cacheMock, - 'connection_config_cache' + 'connection_config_cache', + $this->serializer ); - } public function testIsSingleQueryWhenDataWereCached() { - $queryData['checkout'] = true; + $serializedData = '{"checkout":true}'; + $data = ['checkout' => true]; $this->cacheMock ->expects($this->once()) ->method('load') ->with('connection_config_cache') - ->willReturn(serialize($queryData)); + ->willReturn($serializedData); + $this->serializer->expects($this->once()) + ->method('unserialize') + ->with($serializedData) + ->willReturn($data); $this->assertTrue($this->quoteResolver->isSingleQuery()); } - public function testIsSingleQueryWhenDataNotCached() + /** + * @param string $connectionName + * @param bool $isSingleQuery + * + * @dataProvider isSingleQueryWhenDataNotCachedDataProvider + */ + public function testIsSingleQueryWhenDataNotCached($connectionName, $isSingleQuery) { - $queryData['checkout'] = true; + $data = ['checkout' => $isSingleQuery]; + $serializedData = '{"checkout":true}'; $this->cacheMock ->expects($this->once()) ->method('load') ->with('connection_config_cache') ->willReturn(false); + $this->serializer->expects($this->never()) + ->method('unserialize'); $this->configMock ->expects($this->once()) ->method('getConnectionName') ->with('checkout_setup') - ->willReturn('default'); + ->willReturn($connectionName); + $this->serializer->expects($this->once()) + ->method('serialize') + ->with($data) + ->willReturn($serializedData); $this->cacheMock ->expects($this->once()) ->method('save') - ->with(serialize($queryData), 'connection_config_cache', []); - $this->assertTrue($this->quoteResolver->isSingleQuery()); + ->with($serializedData, 'connection_config_cache', []); + $this->assertEquals($isSingleQuery, $this->quoteResolver->isSingleQuery()); } - public function testIsSingleQueryWhenSeveralConnectionsExist() + /** + * @return array + */ + public function isSingleQueryWhenDataNotCachedDataProvider() { - $queryData['checkout'] = false; - $this->cacheMock - ->expects($this->once()) - ->method('load') - ->with('connection_config_cache') - ->willReturn(false); - $this->configMock - ->expects($this->once()) - ->method('getConnectionName') - ->with('checkout_setup') - ->willReturn('checkout'); - $this->cacheMock - ->expects($this->once()) - ->method('save') - ->with(serialize($queryData), 'connection_config_cache', []); - $this->assertFalse($this->quoteResolver->isSingleQuery()); + return [ + ['default', true], + ['checkout', false], + ]; } } diff --git a/app/code/Magento/Sales/Model/Config/Ordered.php b/app/code/Magento/Sales/Model/Config/Ordered.php index 7ea7d1f8cc5fae05277754e033c9a4cb9fac37f6..806a7b522c189f495e080307981bf8fd95f3d420 100644 --- a/app/code/Magento/Sales/Model/Config/Ordered.php +++ b/app/code/Magento/Sales/Model/Config/Ordered.php @@ -5,6 +5,9 @@ */ namespace Magento\Sales\Model\Config; +use Magento\Framework\App\ObjectManager; +use Magento\Framework\Serialize\SerializerInterface; + /** * Configuration class for ordered items * @@ -69,22 +72,30 @@ abstract class Ordered extends \Magento\Framework\App\Config\Base */ protected $_salesConfig; + /** + * @var SerializerInterface + */ + private $serializer; + /** * @param \Magento\Framework\App\Cache\Type\Config $configCacheType * @param \Psr\Log\LoggerInterface $logger * @param \Magento\Sales\Model\Config $salesConfig * @param \Magento\Framework\Simplexml\Element $sourceData + * @param SerializerInterface $serializer */ public function __construct( \Magento\Framework\App\Cache\Type\Config $configCacheType, \Psr\Log\LoggerInterface $logger, \Magento\Sales\Model\Config $salesConfig, - $sourceData = null + $sourceData = null, + SerializerInterface $serializer = null ) { parent::__construct($sourceData); $this->_configCacheType = $configCacheType; $this->_logger = $logger; $this->_salesConfig = $salesConfig; + $this->serializer = $serializer ?: ObjectManager::getInstance()->get(SerializerInterface::class); } /** @@ -179,11 +190,11 @@ abstract class Ordered extends \Magento\Framework\App\Config\Base $sortedCodes = []; $cachedData = $this->_configCacheType->load($this->_collectorsCacheKey); if ($cachedData) { - $sortedCodes = unserialize($cachedData); + $sortedCodes = $this->serializer->unserialize($cachedData); } if (!$sortedCodes) { $sortedCodes = $this->_getSortedCollectorCodes($this->_modelsConfig); - $this->_configCacheType->save(serialize($sortedCodes), $this->_collectorsCacheKey); + $this->_configCacheType->save($this->serializer->serialize($sortedCodes), $this->_collectorsCacheKey); } foreach ($sortedCodes as $code) { $this->_collectors[$code] = $this->_models[$code]; diff --git a/app/code/Magento/Sales/Model/Order/Total/Config/Base.php b/app/code/Magento/Sales/Model/Order/Total/Config/Base.php index 22c71f48b6f35189bf532362a8647e53069a39a5..d96591118b82296a937445256e01e75ee942a569 100644 --- a/app/code/Magento/Sales/Model/Order/Total/Config/Base.php +++ b/app/code/Magento/Sales/Model/Order/Total/Config/Base.php @@ -5,6 +5,8 @@ */ namespace Magento\Sales\Model\Order\Total\Config; +use Magento\Framework\Serialize\SerializerInterface; + /** * Configuration class for totals */ @@ -42,15 +44,17 @@ class Base extends \Magento\Sales\Model\Config\Ordered * @param \Magento\Sales\Model\Config $salesConfig * @param \Magento\Sales\Model\Order\TotalFactory $orderTotalFactory * @param mixed $sourceData + * @param SerializerInterface $serializer */ public function __construct( \Magento\Framework\App\Cache\Type\Config $configCacheType, \Psr\Log\LoggerInterface $logger, \Magento\Sales\Model\Config $salesConfig, \Magento\Sales\Model\Order\TotalFactory $orderTotalFactory, - $sourceData = null + $sourceData = null, + SerializerInterface $serializer = null ) { - parent::__construct($configCacheType, $logger, $salesConfig, $sourceData); + parent::__construct($configCacheType, $logger, $salesConfig, $sourceData, $serializer); $this->_orderTotalFactory = $orderTotalFactory; } diff --git a/app/code/Magento/Sales/Test/Unit/Model/Order/Total/Config/BaseTest.php b/app/code/Magento/Sales/Test/Unit/Model/Order/Total/Config/BaseTest.php index ed44331f577d06ebdbe4df00401f85f34c59284d..bd519e76585ba452bb066ccac2cfbd27c5d58d7f 100644 --- a/app/code/Magento/Sales/Test/Unit/Model/Order/Total/Config/BaseTest.php +++ b/app/code/Magento/Sales/Test/Unit/Model/Order/Total/Config/BaseTest.php @@ -5,24 +5,28 @@ */ namespace Magento\Sales\Test\Unit\Model\Order\Total\Config; +use Magento\Framework\Serialize\SerializerInterface; use Magento\Framework\TestFramework\Unit\Helper\ObjectManager; class BaseTest extends \PHPUnit_Framework_TestCase { /** @var \Magento\Sales\Model\Order\Total\Config\Base */ - protected $object; + private $object; + + /** @var SerializerInterface|\PHPUnit_Framework_MockObject_MockObject */ + private $serializer; /** @var \Magento\Framework\App\Cache\Type\Config|\PHPUnit_Framework_MockObject_MockObject */ - protected $configCacheType; + private $configCacheType; /** @var \Psr\Log\LoggerInterface|\PHPUnit_Framework_MockObject_MockObject */ - protected $logger; + private $logger; /** @var \Magento\Sales\Model\Config|\PHPUnit_Framework_MockObject_MockObject */ - protected $salesConfig; + private $salesConfig; /** @var \Magento\Sales\Model\Order\TotalFactory|\PHPUnit_Framework_MockObject_MockObject */ - protected $orderTotalFactory; + private $orderTotalFactory; protected function setUp() { @@ -30,6 +34,7 @@ class BaseTest extends \PHPUnit_Framework_TestCase $this->logger = $this->getMock(\Psr\Log\LoggerInterface::class); $this->salesConfig = $this->getMock(\Magento\Sales\Model\Config::class, [], [], '', false); $this->orderTotalFactory = $this->getMock(\Magento\Sales\Model\Order\TotalFactory::class, [], [], '', false); + $this->serializer = $this->getMockForAbstractClass(SerializerInterface::class); $objectManager = new ObjectManager($this); $this->object = $objectManager->getObject( @@ -39,6 +44,7 @@ class BaseTest extends \PHPUnit_Framework_TestCase 'logger' => $this->logger, 'salesConfig' => $this->salesConfig, 'orderTotalFactory' => $this->orderTotalFactory, + 'serializer' => $this->serializer, ] ); } @@ -59,8 +65,14 @@ class BaseTest extends \PHPUnit_Framework_TestCase ->with(\Magento\Sales\Model\Order\Total\AbstractTotal::class) ->will($this->returnValue($total)); + $sortedCodes = ['other_code', 'some_code']; + $serializedCodes = '["other_code", "some_code"]'; + $this->serializer->expects($this->once()) + ->method('serialize') + ->with($sortedCodes) + ->willReturn($serializedCodes); $this->configCacheType->expects($this->once())->method('save') - ->with('a:2:{i:0;s:10:"other_code";i:1;s:9:"some_code";}', 'sorted_collectors'); + ->with($serializedCodes, 'sorted_collectors'); $this->assertSame( ['other_code' => $total, 'some_code' => $total], @@ -106,8 +118,14 @@ class BaseTest extends \PHPUnit_Framework_TestCase ->with(\Magento\Sales\Model\Order\Total\AbstractTotal::class) ->will($this->returnValue($total)); + $sortedCodes = ['other_code', 'some_code']; + $serializedCodes = '["other_code", "some_code"]'; $this->configCacheType->expects($this->once())->method('load')->with('sorted_collectors') - ->will($this->returnValue('a:2:{i:0;s:10:"other_code";i:1;s:9:"some_code";}')); + ->will($this->returnValue($serializedCodes)); + $this->serializer->expects($this->once()) + ->method('unserialize') + ->with($serializedCodes) + ->willReturn($sortedCodes); $this->configCacheType->expects($this->never())->method('save'); $this->assertSame( diff --git a/app/code/Magento/Sales/view/adminhtml/layout/sales_order_create_index.xml b/app/code/Magento/Sales/view/adminhtml/layout/sales_order_create_index.xml index b2e779e330fe0582f855f17ee57e6f648f61a001..6acb23ab0910ea3e8dc1e8bd5e87c28900e19da5 100644 --- a/app/code/Magento/Sales/view/adminhtml/layout/sales_order_create_index.xml +++ b/app/code/Magento/Sales/view/adminhtml/layout/sales_order_create_index.xml @@ -16,7 +16,7 @@ <referenceBlock name="page.title"> <action method="setTitleId"> - <argument translate="true" name="id" xsi:type="string">order-header</argument> + <argument translate="false" name="id" xsi:type="string">order-header</argument> </action> </referenceBlock> <referenceContainer name="after.body.start"> diff --git a/app/code/Magento/UrlRewrite/view/adminhtml/templates/categories.phtml b/app/code/Magento/UrlRewrite/view/adminhtml/templates/categories.phtml index 7aa02ab019c46b9ad7094764118a9f5d07519293..d0f9678602707ff2950b8b051b8dd50f0b4c7df0 100644 --- a/app/code/Magento/UrlRewrite/view/adminhtml/templates/categories.phtml +++ b/app/code/Magento/UrlRewrite/view/adminhtml/templates/categories.phtml @@ -9,7 +9,7 @@ /** @var \Magento\UrlRewrite\Block\Catalog\Category\Tree $block */ ?> <fieldset class="admin__fieldset" data-ui-id="category-selector"> - <legend class="admin__legend"><span><?php /* @escapeNotVerified */ echo __('Select Category') ?></span></legend> + <legend class="admin__legend"><span><?php echo $block->escapeHtml(__('Select Category')) ?></span></legend> <div class="content content-category-tree"> <input type="hidden" name="categories" id="product_categories" value="" /> <?php if ($block->getRoot()): ?> diff --git a/app/code/Magento/Webapi/Model/Config.php b/app/code/Magento/Webapi/Model/Config.php index 45d29bc59cf0d6a1c9c1be78ff84343f50b1029d..fb6dc894e3c0ae87915f12bdf38311a5be541874 100644 --- a/app/code/Magento/Webapi/Model/Config.php +++ b/app/code/Magento/Webapi/Model/Config.php @@ -8,6 +8,8 @@ namespace Magento\Webapi\Model; use Magento\Webapi\Model\Cache\Type\Webapi as WebapiCache; use Magento\Webapi\Model\Config\Reader; +use Magento\Framework\App\ObjectManager; +use Magento\Framework\Serialize\SerializerInterface; /** * Web API Config Model. @@ -40,16 +42,26 @@ class Config */ protected $services; + /** + * @var SerializerInterface + */ + private $serializer; + /** * Initialize dependencies. * * @param WebapiCache $cache * @param Reader $configReader + * @param SerializerInterface|null $serializer */ - public function __construct(WebapiCache $cache, Reader $configReader) - { + public function __construct( + WebapiCache $cache, + Reader $configReader, + SerializerInterface $serializer = null + ) { $this->cache = $cache; $this->configReader = $configReader; + $this->serializer = $serializer ?: ObjectManager::getInstance()->get(SerializerInterface::class); } /** @@ -62,10 +74,10 @@ class Config if (null === $this->services) { $services = $this->cache->load(self::CACHE_ID); if ($services && is_string($services)) { - $this->services = unserialize($services); + $this->services = $this->serializer->unserialize($services); } else { $this->services = $this->configReader->read(); - $this->cache->save(serialize($this->services), self::CACHE_ID); + $this->cache->save($this->serializer->serialize($this->services), self::CACHE_ID); } } return $this->services; diff --git a/app/code/Magento/Webapi/Model/ServiceMetadata.php b/app/code/Magento/Webapi/Model/ServiceMetadata.php index b75d10f9a271f7a3f39fff2ac9494f020b5cf660..14e45ccb409db24df2dd2f1c4f8d5693a55d3126 100644 --- a/app/code/Magento/Webapi/Model/ServiceMetadata.php +++ b/app/code/Magento/Webapi/Model/ServiceMetadata.php @@ -7,6 +7,8 @@ namespace Magento\Webapi\Model; use Magento\Webapi\Model\Config\Converter; use Magento\Webapi\Model\Cache\Type\Webapi as WebApiCache; +use Magento\Framework\App\ObjectManager; +use Magento\Framework\Serialize\SerializerInterface; /** * Service Metadata Model @@ -74,6 +76,11 @@ class ServiceMetadata */ protected $typeProcessor; + /** + * @var SerializerInterface + */ + private $serializer; + /** * Initialize dependencies. * @@ -81,17 +88,20 @@ class ServiceMetadata * @param WebApiCache $cache * @param \Magento\Webapi\Model\Config\ClassReflector $classReflector * @param \Magento\Framework\Reflection\TypeProcessor $typeProcessor + * @param SerializerInterface|null $serializer */ public function __construct( \Magento\Webapi\Model\Config $config, WebApiCache $cache, \Magento\Webapi\Model\Config\ClassReflector $classReflector, - \Magento\Framework\Reflection\TypeProcessor $typeProcessor + \Magento\Framework\Reflection\TypeProcessor $typeProcessor, + SerializerInterface $serializer = null ) { $this->config = $config; $this->cache = $cache; $this->classReflector = $classReflector; $this->typeProcessor = $typeProcessor; + $this->serializer = $serializer ?: ObjectManager::getInstance()->get(SerializerInterface::class); } /** @@ -142,12 +152,18 @@ class ServiceMetadata $servicesConfig = $this->cache->load(self::SERVICES_CONFIG_CACHE_ID); $typesData = $this->cache->load(self::REFLECTED_TYPES_CACHE_ID); if ($servicesConfig && is_string($servicesConfig) && $typesData && is_string($typesData)) { - $this->services = unserialize($servicesConfig); - $this->typeProcessor->setTypesData(unserialize($typesData)); + $this->services = $this->serializer->unserialize($servicesConfig); + $this->typeProcessor->setTypesData($this->serializer->unserialize($typesData)); } else { $this->services = $this->initServicesMetadata(); - $this->cache->save(serialize($this->services), self::SERVICES_CONFIG_CACHE_ID); - $this->cache->save(serialize($this->typeProcessor->getTypesData()), self::REFLECTED_TYPES_CACHE_ID); + $this->cache->save( + $this->serializer->serialize($this->services), + self::SERVICES_CONFIG_CACHE_ID + ); + $this->cache->save( + $this->serializer->serialize($this->typeProcessor->getTypesData()), + self::REFLECTED_TYPES_CACHE_ID + ); } } return $this->services; @@ -256,12 +272,18 @@ class ServiceMetadata $routesConfig = $this->cache->load(self::ROUTES_CONFIG_CACHE_ID); $typesData = $this->cache->load(self::REFLECTED_TYPES_CACHE_ID); if ($routesConfig && is_string($routesConfig) && $typesData && is_string($typesData)) { - $this->routes = unserialize($routesConfig); - $this->typeProcessor->setTypesData(unserialize($typesData)); + $this->routes = $this->serializer->unserialize($routesConfig); + $this->typeProcessor->setTypesData($this->serializer->unserialize($typesData)); } else { $this->routes = $this->initRoutesMetadata(); - $this->cache->save(serialize($this->routes), self::ROUTES_CONFIG_CACHE_ID); - $this->cache->save(serialize($this->typeProcessor->getTypesData()), self::REFLECTED_TYPES_CACHE_ID); + $this->cache->save( + $this->serializer->serialize($this->routes), + self::ROUTES_CONFIG_CACHE_ID + ); + $this->cache->save( + $this->serializer->serialize($this->typeProcessor->getTypesData()), + self::REFLECTED_TYPES_CACHE_ID + ); } } return $this->routes; diff --git a/app/code/Magento/Webapi/Test/Unit/Model/ConfigTest.php b/app/code/Magento/Webapi/Test/Unit/Model/ConfigTest.php new file mode 100644 index 0000000000000000000000000000000000000000..74280f61916d7182e90bdf1e9b6125da55a6c31b --- /dev/null +++ b/app/code/Magento/Webapi/Test/Unit/Model/ConfigTest.php @@ -0,0 +1,96 @@ +<?php +/** + * Copyright © 2016 Magento. All rights reserved. + * See COPYING.txt for license details. + */ +namespace Magento\Webapi\Test\Unit\Model; + +use Magento\Framework\Serialize\SerializerInterface; +use Magento\Webapi\Model\Config; +use Magento\Webapi\Model\Config\Reader; +use Magento\Webapi\Model\Cache\Type\Webapi; + +class ConfigTest extends \PHPUnit_Framework_TestCase +{ + /** + * @var Config + */ + private $config; + + /** + * @var Webapi|\PHPUnit_Framework_MockObject_MockObject + */ + private $webapiCacheMock; + + /** + * @var Reader|\PHPUnit_Framework_MockObject_MockObject + */ + private $configReaderMock; + + /** + * @var SerializerInterface|\PHPUnit_Framework_MockObject_MockObject + */ + private $serializerMock; + + protected function setUp() + { + $objectManager = new \Magento\Framework\TestFramework\Unit\Helper\ObjectManager($this); + + $this->webapiCacheMock = $this->getMock(\Magento\Webapi\Model\Cache\Type\Webapi::class, [], [], '', false); + $this->configReaderMock = $this->getMock(\Magento\Webapi\Model\Config\Reader::class, [], [], '', false); + $this->serializerMock = $this->getMock(SerializerInterface::class); + + $this->config = $objectManager->getObject( + Config::class, + [ + 'cache' => $this->webapiCacheMock, + 'configReader' => $this->configReaderMock, + 'serializer' => $this->serializerMock + ] + ); + } + + public function testGetServices() + { + $data = ['foo' => 'bar']; + $serializedData = 'serialized data'; + $this->webapiCacheMock->expects($this->once()) + ->method('load') + ->with(Config::CACHE_ID) + ->willReturn($serializedData); + $this->serializerMock->expects($this->once()) + ->method('unserialize') + ->with($serializedData) + ->willReturn($data); + $this->config->getServices(); + $this->assertEquals($data, $this->config->getServices()); + } + + public function testGetServicesNoCache() + { + $data = ['foo' => 'bar']; + $serializedData = 'serialized data'; + $this->webapiCacheMock->expects($this->once()) + ->method('load') + ->with(Config::CACHE_ID) + ->willReturn(false); + $this->serializerMock->expects($this->never()) + ->method('unserialize'); + $this->configReaderMock->expects($this->once()) + ->method('read') + ->willReturn($data); + $this->serializerMock->expects($this->once()) + ->method('serialize') + ->with($data) + ->willReturn($serializedData); + $this->webapiCacheMock->expects($this->once()) + ->method('save') + ->with( + $serializedData, + Config::CACHE_ID + ); + + $this->config->getServices(); + $this->assertEquals($data, $this->config->getServices()); + } +} diff --git a/app/code/Magento/Webapi/Test/Unit/Model/ServiceMetadataTest.php b/app/code/Magento/Webapi/Test/Unit/Model/ServiceMetadataTest.php index 29c1bf90402ebe36d6ca91c5585cacb03f739cc3..4125f82b7923ffb30a3bfc0d86f3414255498231 100644 --- a/app/code/Magento/Webapi/Test/Unit/Model/ServiceMetadataTest.php +++ b/app/code/Magento/Webapi/Test/Unit/Model/ServiceMetadataTest.php @@ -1,187 +1,450 @@ <?php /** - * ServiceMetadata Unit tests. - * * Copyright © 2016 Magento. All rights reserved. * See COPYING.txt for license details. */ - -/** - * Class implements tests for \Magento\Webapi\Model\ServiceMetadata class. - */ namespace Magento\Webapi\Test\Unit\Model; +use Magento\Framework\Serialize\SerializerInterface; +use Magento\Webapi\Model\Config; +use Magento\Webapi\Model\Cache\Type\Webapi; +use Magento\Webapi\Model\Config\ClassReflector; +use Magento\Framework\Reflection\TypeProcessor; +use Magento\Webapi\Model\ServiceMetadata; +use Magento\Customer\Api\CustomerRepositoryInterface; + class ServiceMetadataTest extends \PHPUnit_Framework_TestCase { - /** @var \Magento\Webapi\Model\ServiceMetadata */ - protected $serviceMetadata; + /** + * @var ServiceMetadata + */ + private $serviceMetadata; /** - * Set up helper. - * @SuppressWarnings(PHPMD.ExcessiveMethodLength) + * @var Webapi|\PHPUnit_Framework_MockObject_MockObject + */ + private $cacheMock; + + /** + * @var Config|\PHPUnit_Framework_MockObject_MockObject + */ + private $configMock; + + /** + * @var ClassReflector|\PHPUnit_Framework_MockObject_MockObject + */ + private $classReflectorMock; + + /** + * @var TypeProcessor|\PHPUnit_Framework_MockObject_MockObject + */ + private $typeProcessorMock; + + /** + * @var SerializerInterface|\PHPUnit_Framework_MockObject_MockObject */ + private $serializerMock; + protected function setUp() { - $interfaceParameters = [ - 'activateById' => [ + $objectManager = new \Magento\Framework\TestFramework\Unit\Helper\ObjectManager($this); + + $this->configMock = $this->getMock(Config::class, [], [], '', false); + $this->cacheMock = $this->getMock(Webapi::class, [], [], '', false); + $this->classReflectorMock = $this->getMock(ClassReflector::class, [], [], '', false); + $this->typeProcessorMock = $this->getMock(TypeProcessor::class, [], [], '', false); + $this->serializerMock = $this->getMock(SerializerInterface::class); + + $this->serviceMetadata = $objectManager->getObject( + ServiceMetadata::class, + [ + 'config' => $this->configMock, + 'cache' => $this->cacheMock, + 'classReflector' => $this->classReflectorMock, + 'typeProcessor' => $this->typeProcessorMock, + 'serializer' => $this->serializerMock + ] + ); + } + + public function testGetServicesConfig() + { + $servicesConfig = ['foo' => 'bar']; + $typeData = ['bar' => 'foo']; + $serializedServicesConfig = 'serialized services config'; + $serializedTypeData = 'serialized type data'; + $this->cacheMock->expects($this->at(0)) + ->method('load') + ->with(ServiceMetadata::SERVICES_CONFIG_CACHE_ID) + ->willReturn($serializedServicesConfig); + $this->cacheMock->expects($this->at(1)) + ->method('load') + ->with(ServiceMetadata::REFLECTED_TYPES_CACHE_ID) + ->willReturn($serializedTypeData); + $this->serializerMock->expects($this->at(0)) + ->method('unserialize') + ->with($serializedServicesConfig) + ->willReturn($servicesConfig); + $this->serializerMock->expects($this->at(1)) + ->method('unserialize') + ->with($serializedTypeData) + ->willReturn($typeData); + $this->typeProcessorMock->expects($this->once()) + ->method('setTypesData') + ->with($typeData); + $this->serviceMetadata->getServicesConfig(); + $this->assertEquals($servicesConfig, $this->serviceMetadata->getServicesConfig()); + } + + /** + * @SuppressWarnings(PHPMD.ExcessiveMethodLength) + */ + public function testGetServicesConfigNoCache() + { + $servicesConfig = [ + 'services' => [ + CustomerRepositoryInterface::class => [ + 'V1' => [ + 'methods' => [ + 'getById' => [ + 'resources' => [ + [ + 'Magento_Customer::customer', + ] + ], + 'secure' => false + ] + ] + ] + ] + ] + ]; + $methodsReflectionData = [ + 'getById' => [ + 'documentation' => 'Get customer by customer ID.', 'interface' => [ 'in' => [ 'parameters' => [ 'customerId' => [ - 'force' => true, - 'value' => '%customer_id%', - ], - 'requiredInputParameter' => [ + 'type' => 'int', 'required' => true, - ], - ], + 'documentation' => null + ] + ] ], 'out' => [ 'parameters' => [ - 'outputParameter' => [ - 'type' => 'string', + 'result' => [ + 'type' => 'CustomerDataCustomerInterface', + 'required' => true, + 'documentation' => null + ] + ] + ] + ] + ] + ]; + $servicesMetadata = [ + 'customerCustomerRepositoryV1' => [ + 'methods' => array_merge_recursive( + [ + 'getById' => [ + 'resources' => [ + [ + 'Magento_Customer::customer', + ], ], - ], + 'method' => 'getById', + 'inputRequired' => false, + 'isSecure' => false, + ] ], - ], - ], + $methodsReflectionData + ), + 'class' => CustomerRepositoryInterface::class, + 'description' => 'Customer CRUD interface.' + ] ]; - $classReflection = $this->getMock( - \Magento\Webapi\Model\Config\ClassReflector::class, - ['reflectClassMethods', 'extractClassDescription'], - [], - '', - false - ); - $classReflection->expects($this->any()) + $typeData = [ + 'CustomerDataCustomerInterface' => [ + 'documentation' => 'Customer interface.', + 'parameters' => [ + 'id' => [ + 'type' => 'int', + 'required' => false, + 'documentation' => 'Customer id' + ] + ] + ] + ]; + $serializedServicesConfig = 'serialized services config'; + $serializedTypeData = 'serialized type data'; + $this->cacheMock->expects($this->at(0)) + ->method('load') + ->with(ServiceMetadata::SERVICES_CONFIG_CACHE_ID) + ->willReturn(false); + $this->cacheMock->expects($this->at(1)) + ->method('load') + ->with(ServiceMetadata::REFLECTED_TYPES_CACHE_ID) + ->willReturn(false); + $this->serializerMock->expects($this->never()) + ->method('unserialize'); + $this->configMock->expects($this->once()) + ->method('getServices') + ->willReturn($servicesConfig); + $this->classReflectorMock->expects($this->once()) ->method('reflectClassMethods') - ->will($this->returnValue($interfaceParameters)); - $classReflection->expects($this->any()) + ->willReturn($methodsReflectionData); + $this->classReflectorMock->expects($this->once()) ->method('extractClassDescription') - ->will($this->returnValue('classDescription')); + ->with(CustomerRepositoryInterface::class) + ->willReturn('Customer CRUD interface.'); + $this->typeProcessorMock->expects($this->once()) + ->method('getTypesData') + ->willReturn($typeData); + $this->serializerMock->expects($this->at(0)) + ->method('serialize') + ->with($servicesMetadata) + ->willReturn($serializedServicesConfig); + $this->serializerMock->expects($this->at(1)) + ->method('serialize') + ->with($typeData) + ->willReturn($serializedTypeData); + $this->cacheMock->expects($this->at(2)) + ->method('save') + ->with( + $serializedServicesConfig, + ServiceMetadata::SERVICES_CONFIG_CACHE_ID + ); + $this->cacheMock->expects($this->at(3)) + ->method('save') + ->with( + $serializedTypeData, + ServiceMetadata::REFLECTED_TYPES_CACHE_ID + ); + $this->serviceMetadata->getServicesConfig(); + $this->assertEquals($servicesMetadata, $this->serviceMetadata->getServicesConfig()); + } + + public function testGetRoutesConfig() + { + $routesConfig = ['foo' => 'bar']; + $typeData = ['bar' => 'foo']; + $serializedRoutesConfig = 'serialized routes config'; + $serializedTypeData = 'serialized type data'; + $this->cacheMock->expects($this->at(0)) + ->method('load') + ->with(ServiceMetadata::ROUTES_CONFIG_CACHE_ID) + ->willReturn($serializedRoutesConfig); + $this->cacheMock->expects($this->at(1)) + ->method('load') + ->with(ServiceMetadata::REFLECTED_TYPES_CACHE_ID) + ->willReturn($serializedTypeData); + $this->serializerMock->expects($this->at(0)) + ->method('unserialize') + ->with($serializedRoutesConfig) + ->willReturn($routesConfig); + $this->serializerMock->expects($this->at(1)) + ->method('unserialize') + ->with($serializedTypeData) + ->willReturn($typeData); + $this->typeProcessorMock->expects($this->once()) + ->method('setTypesData') + ->with($typeData); + $this->serviceMetadata->getRoutesConfig(); + $this->assertEquals($routesConfig, $this->serviceMetadata->getRoutesConfig()); + } + /** + * @SuppressWarnings(PHPMD.ExcessiveMethodLength) + */ + public function testGetRoutesConfigNoCache() + { $servicesConfig = [ - 'services' => [\Magento\Customer\Api\AccountManagementInterface::class => [ - 'V1' => [ - 'methods' => [ - 'activateById' => [ - 'resources' => [ - [ - 'Magento_Customer::manage', - ], - ], - 'secure' => false, - ], - ], - ], - ], \Magento\Customer\Api\CustomerRepositoryInterface::class => [ + 'services' => [ + CustomerRepositoryInterface::class => [ 'V1' => [ 'methods' => [ 'getById' => [ 'resources' => [ [ 'Magento_Customer::customer', - ], + ] ], - 'secure' => false, - ], - ], - ], - ], + 'secure' => false + ] + ] + ] + ] ], 'routes' => [ - '/V1/customers/me/activate' => [ - 'PUT' => [ + '/V1/customers/:customerId' => [ + 'GET' => [ 'secure' => false, 'service' => [ - 'class' => \Magento\Customer\Api\AccountManagementInterface::class, - 'method' => 'activateById', + 'class' => CustomerRepositoryInterface::class, + 'method' => 'getById' ], 'resources' => [ - 'self' => true, + 'Magento_Customer::customer' => true ], + 'parameters' => [] + ] + ] + ], + 'class' => CustomerRepositoryInterface::class, + 'description' => 'Customer CRUD interface.', + ]; + $methodsReflectionData = [ + 'getById' => [ + 'documentation' => 'Get customer by customer ID.', + 'interface' => [ + 'in' => [ 'parameters' => [ 'customerId' => [ - 'force' => true, - 'value' => '%customer_id%', - ], - ], + 'type' => 'int', + 'required' => true, + 'documentation' => null + ] + ] ], - ], - '/V1/customers/:customerId' => [ - 'GET' => [ - 'secure' => false, - 'service' => [ - 'class' => \Magento\Customer\Api\CustomerRepositoryInterface::class, - 'method' => 'getById', - ], - 'resources' => [ - 'Magento_Customer::customer' => true, - ], + 'out' => [ 'parameters' => [ - ], + 'result' => [ + 'type' => 'CustomerDataCustomerInterface', + 'required' => true, + 'documentation' => null + ] + ] + ] + ] + ] + ]; + $routesMetadata = [ + 'customerCustomerRepositoryV1' => [ + 'methods' => array_merge_recursive( + [ + 'getById' => [ + 'resources' => [ + [ + 'Magento_Customer::customer', + ] + ], + 'method' => 'getById', + 'inputRequired' => false, + 'isSecure' => false, + ] ], + $methodsReflectionData + ), + 'routes' => [ + '/V1/customers/:customerId' => [ + 'GET' => [ + 'method' => 'getById', + 'parameters' => [] + ] + ] ], + 'class' => CustomerRepositoryInterface::class, + 'description' => 'Customer CRUD interface.' ] ]; - - /** - * @var $cacheMock \Magento\Webapi\Model\Cache\Type\Webapi - */ - $cacheMock = $this->getMockBuilder(\Magento\Webapi\Model\Cache\Type\Webapi::class) - ->disableOriginalConstructor() - ->getMock(); - - /** @var $readerMock \Magento\Webapi\Model\Config\Reader */ - $readerMock = $this->getMockBuilder(\Magento\Webapi\Model\Config\Reader::class) - ->disableOriginalConstructor() - ->getMock(); - $readerMock->expects($this->any())->method('read')->will($this->returnValue($servicesConfig)); - - /** @var $config \Magento\Webapi\Model\Config */ - $config = new \Magento\Webapi\Model\Config($cacheMock, $readerMock); - - $objectManager = new \Magento\Framework\TestFramework\Unit\Helper\ObjectManager($this); - $typeProcessor = $objectManager->getObject(\Magento\Framework\Reflection\TypeProcessor::class); - - /** @var $config \Magento\Webapi\Model\ServiceMetadata */ - $this->serviceMetadata = new \Magento\Webapi\Model\ServiceMetadata( - $config, - $cacheMock, - $classReflection, - $typeProcessor - ); - - parent::setUp(); + $typeData = [ + 'CustomerDataCustomerInterface' => [ + 'documentation' => 'Customer interface.', + 'parameters' => [ + 'id' => [ + 'type' => 'int', + 'required' => false, + 'documentation' => 'Customer id' + ] + ] + ] + ]; + $serializedRoutesConfig = 'serialized routes config'; + $serializedTypeData = 'serialized type data'; + $this->cacheMock->expects($this->at(0)) + ->method('load') + ->with(ServiceMetadata::ROUTES_CONFIG_CACHE_ID) + ->willReturn(false); + $this->cacheMock->expects($this->at(1)) + ->method('load') + ->with(ServiceMetadata::REFLECTED_TYPES_CACHE_ID) + ->willReturn(false); + $this->serializerMock->expects($this->never()) + ->method('unserialize'); + $this->configMock->expects($this->exactly(2)) + ->method('getServices') + ->willReturn($servicesConfig); + $this->classReflectorMock->expects($this->once()) + ->method('reflectClassMethods') + ->willReturn($methodsReflectionData); + $this->classReflectorMock->expects($this->once()) + ->method('extractClassDescription') + ->with(CustomerRepositoryInterface::class) + ->willReturn('Customer CRUD interface.'); + $this->typeProcessorMock->expects($this->exactly(2)) + ->method('getTypesData') + ->willReturn($typeData); + $this->serializerMock->expects($this->at(2)) + ->method('serialize') + ->with($routesMetadata) + ->willReturn($serializedRoutesConfig); + $this->serializerMock->expects($this->at(3)) + ->method('serialize') + ->with($typeData) + ->willReturn($serializedTypeData); + $this->cacheMock->expects($this->at(6)) + ->method('save') + ->with( + $serializedRoutesConfig, + ServiceMetadata::ROUTES_CONFIG_CACHE_ID + ); + $this->cacheMock->expects($this->at(7)) + ->method('save') + ->with( + $serializedTypeData, + ServiceMetadata::REFLECTED_TYPES_CACHE_ID + ); + $this->serviceMetadata->getRoutesConfig(); + $this->assertEquals($routesMetadata, $this->serviceMetadata->getRoutesConfig()); } /** - * Test identifying service name including subservices using class name. - * - * @dataProvider serviceNameDataProvider + * @dataProvider getServiceNameDataProvider */ public function testGetServiceName($className, $version, $preserveVersion, $expected) { - $actual = $this->serviceMetadata->getServiceName($className, $version, $preserveVersion); - $this->assertEquals($expected, $actual); + $this->assertEquals( + $expected, + $this->serviceMetadata->getServiceName($className, $version, $preserveVersion) + ); } /** - * Dataprovider for testGetServiceName - * * @return string */ - public function serviceNameDataProvider() + public function getServiceNameDataProvider() { return [ - [\Magento\Customer\Api\AccountManagementInterface::class, 'V1', false, 'customerAccountManagement'], - [\Magento\Customer\Api\AddressRepositoryInterface::class, 'V1', true, 'customerAddressRepositoryV1'], + [ + \Magento\Customer\Api\AccountManagementInterface::class, + 'V1', + false, + 'customerAccountManagement' + ], + [ + \Magento\Customer\Api\AddressRepositoryInterface::class, + 'V1', + true, + 'customerAddressRepositoryV1' + ], ]; } /** * @expectedException \InvalidArgumentException - * @dataProvider dataProviderForTestGetServiceNameInvalidName + * @dataProvider getServiceNameInvalidNameDataProvider */ public function testGetServiceNameInvalidName($interfaceClassName, $version) { @@ -189,111 +452,18 @@ class ServiceMetadataTest extends \PHPUnit_Framework_TestCase } /** - * Dataprovider for testGetServiceNameInvalidName - * * @return string */ - public function dataProviderForTestGetServiceNameInvalidName() + public function getServiceNameInvalidNameDataProvider() { return [ - ['BarV1Interface', 'V1'], // Missed vendor, module, 'Service' + ['BarV1Interface', 'V1'], // Missed vendor, module and Service ['Service\\V1Interface', 'V1'], // Missed vendor and module ['Magento\\Foo\\Service\\BarVxInterface', 'V1'], // Version number should be a number - ['Magento\\Foo\\Service\\BarInterface', 'V1'], // Version missed - ['Magento\\Foo\\Service\\BarV1', 'V1'], // 'Interface' missed - ['Foo\\Service\\BarV1Interface', 'V1'], // Module missed - ['Foo\\BarV1Interface', 'V1'] // Module and 'Service' missed - ]; - } - - public function testGetServiceMetadata() - { - $expectedResult = [ - 'methods' => [ - 'activateById' => [ - 'method' => 'activateById', - 'inputRequired' => '', - 'isSecure' => '', - 'resources' => [['Magento_Customer::manage']], - 'interface' => [ - 'in' => [ - 'parameters' => [ - 'customerId' => [ - 'force' => true, - 'value' => '%customer_id%', - ], - 'requiredInputParameter' => [ - 'required' => true, - ], - ], - ], - 'out' => [ - 'parameters' => [ - 'outputParameter' => [ - 'type' => 'string', - ], - ], - ], - ], - ], - ], - 'class' => \Magento\Customer\Api\AccountManagementInterface::class, - 'description' => 'classDescription', + ['Magento\\Foo\\Service\\BarInterface', 'V1'], // Missed version + ['Magento\\Foo\\Service\\BarV1', 'V1'], // Missed Interface + ['Foo\\Service\\BarV1Interface', 'V1'], // Missed module + ['Foo\\BarV1Interface', 'V1'] // Missed module and Service ]; - $result = $this->serviceMetadata->getServiceMetadata('customerAccountManagementV1'); - $this->assertEquals($expectedResult, $result); - } - - public function testGetRouteMetadata() - { - $expectedResult = [ - 'methods' => [ - 'activateById' => [ - 'method' => 'activateById', - 'inputRequired' => '', - 'isSecure' => '', - 'resources' => [['Magento_Customer::manage']], - 'interface' => [ - 'in' => [ - 'parameters' => [ - 'customerId' => [ - 'force' => true, - 'value' => '%customer_id%', - ], - 'requiredInputParameter' => [ - 'required' => true, - ], - ], - ], - 'out' => [ - 'parameters' => [ - 'outputParameter' => [ - 'type' => 'string', - ], - ], - ], - ], - ], - ], - 'class' => \Magento\Customer\Api\AccountManagementInterface::class, - 'description' => 'classDescription', - 'routes' => [ - '/V1/customers/me/activate' => [ - 'PUT' => [ - 'method' => 'activateById', - 'parameters' => [ - 'customerId' => [ - 'force' => true, - 'value' => '%customer_id%' - ] - ] - ] - ] - ] - ]; - $result = $this->serviceMetadata->getRouteMetadata('customerAccountManagementV1'); - $this->assertEquals($expectedResult, $result); } } - -require_once realpath(__DIR__ . '/../_files/test_interfaces.php'); diff --git a/app/code/Magento/Webapi/Test/Unit/Model/Soap/ConfigTest.php b/app/code/Magento/Webapi/Test/Unit/Model/Soap/ConfigTest.php deleted file mode 100644 index aa5d1a7bfab7e5a1858ae9b321d41a1accba3955..0000000000000000000000000000000000000000 --- a/app/code/Magento/Webapi/Test/Unit/Model/Soap/ConfigTest.php +++ /dev/null @@ -1,166 +0,0 @@ -<?php -/** - * Config helper Unit tests. - * - * Copyright © 2016 Magento. All rights reserved. - * See COPYING.txt for license details. - */ - -// @codingStandardsIgnoreFile - -/** - * Class implements tests for \Magento\Webapi\Model\Soap\Config class. - */ -namespace Magento\Webapi\Test\Unit\Model\Soap; - -class ConfigTest extends \PHPUnit_Framework_TestCase -{ - /** @var \Magento\Webapi\Model\Soap\Config */ - protected $_soapConfig; - - /** @var \Magento\Framework\TestFramework\Unit\Helper\ObjectManager */ - protected $objectManager; - - /** - * Set up helper. - */ - protected function setUp() - { - $this->objectManager = new \Magento\Framework\TestFramework\Unit\Helper\ObjectManager($this); - - $typeProcessor = $this->objectManager->getObject(\Magento\Framework\Reflection\TypeProcessor::class); - - $objectManagerMock = $this->getMockBuilder( - \Magento\Framework\App\ObjectManager::class - )->disableOriginalConstructor()->getMock(); - - $classReflection = $this->getMock( - \Magento\Webapi\Model\Config\ClassReflector::class, - ['reflectClassMethods'], - ['_typeProcessor' => $typeProcessor], - '' - ); - $classReflection->expects($this->any())->method('reflectClassMethods')->will($this->returnValue([])); - - $servicesConfig = [ - 'services' => [\Magento\Customer\Api\AccountManagementInterface::class => [ - 'V1' => [ - 'methods' => [ - 'activate' => [ - 'resources' => [ - [ - 'Magento_Customer::manage', - ], - ], - 'secure' => false, - ], - ], - ], - ], \Magento\Customer\Api\CustomerRepositoryInterface::class => [ - 'V1' => [ - 'methods' => [ - 'getById' => [ - 'resources' => [ - [ - 'Magento_Customer::customer', - ], - ], - 'secure' => false, - ], - ], - ], - ], - ], - ]; - - /** - * @var $registryMock \Magento\Framework\Registry - */ - $registryMock = $this->getMockBuilder(\Magento\Framework\Registry::class) - ->disableOriginalConstructor() - ->getMock(); - - /** - * @var $cacheMock \Magento\Webapi\Model\Cache\Type\Webapi - */ - $cacheMock = $this->getMockBuilder(\Magento\Webapi\Model\Cache\Type\Webapi::class) - ->disableOriginalConstructor() - ->getMock(); - - /** @var $readerMock \Magento\Webapi\Model\Config\Reader */ - $readerMock = $this->getMockBuilder(\Magento\Webapi\Model\Config\Reader::class) - ->disableOriginalConstructor() - ->getMock(); - $readerMock->expects($this->any())->method('read')->will($this->returnValue($servicesConfig)); - - /** @var $config \Magento\Webapi\Model\Config */ - $config = new \Magento\Webapi\Model\Config($cacheMock, $readerMock); - - /** @var $config \Magento\Webapi\Model\ServiceMetadata */ - $serviceMetadata = new \Magento\Webapi\Model\ServiceMetadata( - $config, - $cacheMock, - $classReflection, - $typeProcessor); - - $this->_soapConfig = $this->objectManager->getObject( - \Magento\Webapi\Model\Soap\Config::class, - [ - 'objectManager' => $objectManagerMock, - 'registry' => $registryMock, - 'serviceMetadata' => $serviceMetadata, - ] - ); - parent::setUp(); - } - - public function testGetRequestedSoapServices() - { - $expectedResult = [ - 'customerAccountManagementV1' => - [ - 'methods' => [ - 'activate' => [ - 'method' => 'activate', - 'inputRequired' => '', - 'isSecure' => '', - 'resources' => [['Magento_Customer::manage']], - ], - ], - 'class' => \Magento\Customer\Api\AccountManagementInterface::class, - 'description' => 'Interface for managing customers accounts.', - ], - ]; - - $result = $this->_soapConfig->getRequestedSoapServices( - ['customerAccountManagementV1', 'moduleBarV2', 'moduleBazV1'] - ); - - $this->assertEquals($expectedResult, $result); - } - - public function testGetServiceMethodInfo() - { - $expectedResult = [ - 'class' => \Magento\Customer\Api\CustomerRepositoryInterface::class, - 'method' => 'getById', - 'isSecure' => false, - 'resources' => [['Magento_Customer::customer']], - ]; - $methodInfo = $this->_soapConfig->getServiceMethodInfo( - 'customerCustomerRepositoryV1GetById', - ['customerCustomerRepositoryV1', 'moduleBazV1'] - ); - $this->assertEquals($expectedResult, $methodInfo); - } - - public function testGetSoapOperation() - { - $expectedResult = 'customerAccountManagementV1Activate'; - $soapOperation = $this->_soapConfig - ->getSoapOperation(\Magento\Customer\Api\AccountManagementInterface::class, 'activate', 'V1'); - $this->assertEquals($expectedResult, $soapOperation); - } -} - -require_once realpath(__DIR__ . '/../../_files/test_interfaces.php'); diff --git a/app/code/Magento/Webapi/Test/Unit/_files/test_interfaces.php b/app/code/Magento/Webapi/Test/Unit/_files/test_interfaces.php deleted file mode 100644 index 288a747cefd89cec4182de66890127eebd552806..0000000000000000000000000000000000000000 --- a/app/code/Magento/Webapi/Test/Unit/_files/test_interfaces.php +++ /dev/null @@ -1,31 +0,0 @@ -<?php -/** - * Copyright © 2016 Magento. All rights reserved. - * See COPYING.txt for license details. - */ - -// @codingStandardsIgnoreFile - -namespace Magento\Framework\Module\Service; - -/** - * The list of test interfaces. - */ -interface FooV1Interface -{ - public function someMethod(); -} -interface BarV1Interface -{ - public function someMethod(); -} -interface FooBarV1Interface -{ - public function someMethod(); -} -namespace Magento\Framework\Module\Service\Foo; - -interface BarV1Interface -{ - public function someMethod(); -} diff --git a/app/code/Magento/Widget/view/adminhtml/templates/catalog/category/widget/tree.phtml b/app/code/Magento/Widget/view/adminhtml/templates/catalog/category/widget/tree.phtml index 4e240770b04622e4ec6c68bfa796a6a83da006e1..94ee88698111f72c81cbd86eb16adef0e9b94317 100644 --- a/app/code/Magento/Widget/view/adminhtml/templates/catalog/category/widget/tree.phtml +++ b/app/code/Magento/Widget/view/adminhtml/templates/catalog/category/widget/tree.phtml @@ -79,7 +79,7 @@ jQuery(function() // Add empty node to reset category filter if(!emptyNodeAdded) { var empty = Object.clone(_node); - empty.text = '<?php /* @escapeNotVerified */ echo __('None') ?>'; + empty.text = '<?php echo $block->escapeJs($block->escapeHtml(__('None'))); ?>'; empty.children = []; empty.id = 'none'; empty.path = '1/none'; diff --git a/app/code/Magento/Widget/view/adminhtml/templates/instance/edit/layout.phtml b/app/code/Magento/Widget/view/adminhtml/templates/instance/edit/layout.phtml index 62d92ac38aecdbc22f13de959eba3f419b47c431..5d55ba4035873d028f27e5662814cc838b7e18a8 100644 --- a/app/code/Magento/Widget/view/adminhtml/templates/instance/edit/layout.phtml +++ b/app/code/Magento/Widget/view/adminhtml/templates/instance/edit/layout.phtml @@ -10,7 +10,7 @@ ?> <fieldset class="fieldset"> - <legend class="legend"><span><?php /* @escapeNotVerified */ echo __('Layout Updates') ?></span></legend> + <legend class="legend"><span><?php echo $block->escapeHtml(__('Layout Updates')); ?></span></legend> <br /> <div class="widget-layout-updates"> <div id="page_group_container"></div> diff --git a/app/etc/di.xml b/app/etc/di.xml index 643390068a5e3e857ccb0e0d2d07fb5e26b8ea81..e430c15729d3d0cced20bf2b326d40f152b174e6 100755 --- a/app/etc/di.xml +++ b/app/etc/di.xml @@ -154,6 +154,7 @@ <preference for="Magento\Framework\EntityManager\MapperInterface" type="Magento\Framework\EntityManager\CompositeMapper"/> <preference for="Magento\Framework\Console\CommandListInterface" type="Magento\Framework\Console\CommandList"/> <preference for="Magento\Framework\DataObject\IdentityGeneratorInterface" type="Magento\Framework\DataObject\IdentityService" /> + <preference for="Magento\Framework\Serialize\SerializerInterface" type="Magento\Framework\Serialize\Serializer\Json" /> <type name="Magento\Framework\Model\ResourceModel\Db\TransactionManager" shared="false" /> <type name="Magento\Framework\Logger\Handler\Base"> <arguments> diff --git a/dev/tests/functional/tests/app/Magento/Backend/Test/TestCase/GlobalSearchEntityTest.xml b/dev/tests/functional/tests/app/Magento/Backend/Test/TestCase/GlobalSearchEntityTest.xml index 269bff796c7bc618e4c257046426e35ab7a25eaa..accacc60fc5c07c386d02fdd4b038c15f6dcc166 100644 --- a/dev/tests/functional/tests/app/Magento/Backend/Test/TestCase/GlobalSearchEntityTest.xml +++ b/dev/tests/functional/tests/app/Magento/Backend/Test/TestCase/GlobalSearchEntityTest.xml @@ -8,26 +8,31 @@ <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/etc/variations.xsd"> <testCase name="Magento\Backend\Test\TestCase\GlobalSearchEntityTest" summary="Global Search Backend " ticketId="MAGETWO-28457"> <variation name="GlobalSearchEntityTestVariation1"> + <data name="tag" xsi:type="string">stable:no</data> <data name="description" xsi:type="string">search shows admin preview</data> <data name="search/data/query" xsi:type="string">Some search term</data> <constraint name="Magento\Backend\Test\Constraint\AssertGlobalSearchPreview" /> </variation> <variation name="GlobalSearchEntityTestVariation2"> + <data name="tag" xsi:type="string">stable:no</data> <data name="description" xsi:type="string">search with 2 sign return no results</data> <data name="search/data/query" xsi:type="string">:)</data> <constraint name="Magento\Backend\Test\Constraint\AssertGlobalSearchNoRecordsFound" /> </variation> <variation name="GlobalSearchEntityTestVariation3"> + <data name="tag" xsi:type="string">stable:no</data> <data name="description" xsi:type="string">search product by sku</data> <data name="search/data/query" xsi:type="string">orderInjectable::default::product::sku</data> <constraint name="Magento\Backend\Test\Constraint\AssertGlobalSearchProductName" /> </variation> <variation name="GlobalSearchEntityTestVariation4"> + <data name="tag" xsi:type="string">stable:no</data> <data name="description" xsi:type="string">search existed customer</data> <data name="search/data/query" xsi:type="string">customer::johndoe_unique::lastname</data> <constraint name="Magento\Backend\Test\Constraint\AssertGlobalSearchCustomerName" /> </variation> <variation name="GlobalSearchEntityTestVariation5"> + <data name="tag" xsi:type="string">stable:no</data> <data name="description" xsi:type="string">search order (by order id)</data> <data name="search/data/query" xsi:type="string">orderInjectable::default::id</data> <constraint name="Magento\Backend\Test\Constraint\AssertGlobalSearchOrderId" /> diff --git a/dev/tests/functional/tests/app/Magento/Braintree/Test/TestCase/CreateOrderWithPayPalBraintreeVaultBackendTest.xml b/dev/tests/functional/tests/app/Magento/Braintree/Test/TestCase/CreateOrderWithPayPalBraintreeVaultBackendTest.xml index 03e0ba330fa3b74e2a33c2983655ced95cf3dbfe..86b5ff79d648c0807a2bc346e3431fc2a7c975a2 100644 --- a/dev/tests/functional/tests/app/Magento/Braintree/Test/TestCase/CreateOrderWithPayPalBraintreeVaultBackendTest.xml +++ b/dev/tests/functional/tests/app/Magento/Braintree/Test/TestCase/CreateOrderWithPayPalBraintreeVaultBackendTest.xml @@ -8,7 +8,7 @@ <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/etc/variations.xsd"> <testCase name="Magento\Braintree\Test\TestCase\CreateOrderWithPayPalBraintreeVaultBackendTest" summary="Checkout with PayPal Braintree Vault token from Admin"> <variation name="CreateOrderWithPayPalBraintreeVaultBackendTestVariation1" summary="Checkout with PayPal Braintree Vault token from Admin" ticketId="MAGETWO-59259"> - <data name="tag" xsi:type="string">est_type:3rd_party_test, severity:S0</data> + <data name="tag" xsi:type="string">test_type:3rd_party_test, severity:S0</data> <data name="products/0" xsi:type="string">catalogProductSimple::product_10_dollar</data> <data name="customer/dataset" xsi:type="string">default</data> <data name="shippingAddress/dataset" xsi:type="string">US_address_1_without_email</data> diff --git a/dev/tests/functional/tests/app/Magento/Bundle/Test/TestCase/CreateBundleProductEntityTest.xml b/dev/tests/functional/tests/app/Magento/Bundle/Test/TestCase/CreateBundleProductEntityTest.xml index 211e09861995f27e22a446b93e465a7197936965..7d4ccea704ec7664c9c7da086c8367104b5fa677 100644 --- a/dev/tests/functional/tests/app/Magento/Bundle/Test/TestCase/CreateBundleProductEntityTest.xml +++ b/dev/tests/functional/tests/app/Magento/Bundle/Test/TestCase/CreateBundleProductEntityTest.xml @@ -8,6 +8,7 @@ <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/etc/variations.xsd"> <testCase name="Magento\Bundle\Test\TestCase\CreateBundleProductEntityTest" summary="Create Bundle Product" ticketId="MAGETWO-24118"> <variation name="CreateBundleProductEntityTestVariation1"> + <data name="tag" xsi:type="string">stable:no</data> <data name="description" xsi:type="string">Create default bundle with dynamic options</data> <data name="product/data/url_key" xsi:type="string">bundle-product-%isolation%</data> <data name="product/data/name" xsi:type="string">BundleProduct %isolation%</data> @@ -44,7 +45,7 @@ <constraint name="Magento\Catalog\Test\Constraint\AssertProductNotSearchableBySku" /> </variation> <variation name="CreateBundleProductEntityTestVariation3"> - <data name="tag" xsi:type="string">test_type:extended_acceptance_test</data> + <data name="tag" xsi:type="string">test_type:extended_acceptance_test, to_maintain:yes</data> <data name="description" xsi:type="string">Create dynamic bundle with price randle and all types options</data> <data name="product/data/url_key" xsi:type="string">bundle-product-%isolation%</data> <data name="product/data/name" xsi:type="string">BundleProduct %isolation%</data> @@ -74,6 +75,7 @@ <constraint name="Magento\Bundle\Test\Constraint\AssertBundlePriceType" /> </variation> <variation name="CreateBundleProductEntityTestVariation4"> + <data name="tag" xsi:type="string">stable:no</data> <data name="description" xsi:type="string">Create fixed bundle</data> <data name="product/data/url_key" xsi:type="string">bundle-product-%isolation%</data> <data name="product/data/name" xsi:type="string">BundleProduct %isolation%</data> @@ -97,6 +99,7 @@ <constraint name="Magento\Bundle\Test\Constraint\AssertBundleItemsOnProductPage" /> </variation> <variation name="CreateBundleProductEntityTestVariation5"> + <data name="tag" xsi:type="string">stable:no</data> <data name="description" xsi:type="string">Create fixed bundle with all types options</data> <data name="product/data/url_key" xsi:type="string">bundle-product-%isolation%</data> <data name="product/data/name" xsi:type="string">BundleProduct %isolation%</data> @@ -161,6 +164,7 @@ <constraint name="Magento\Bundle\Test\Constraint\AssertBundlePriceView" /> </variation> <variation name="CreateBundleProductEntityTestVariation7" summary="Check bundle dynamic product with tier price"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="product/data/url_key" xsi:type="string">bundle-product-%isolation%</data> <data name="product/data/name" xsi:type="string">BundleProduct %isolation%</data> <data name="product/data/sku_type" xsi:type="string">Yes</data> @@ -187,6 +191,7 @@ <constraint name="Magento\Bundle\Test\Constraint\AssertTierPriceOnBundleProductPage" /> </variation> <variation name="CreateBundleProductEntityTestVariation8"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="description" xsi:type="string">Create dynamic bundle with special price</data> <data name="product/data/url_key" xsi:type="string">bundle-product-%isolation%</data> <data name="product/data/name" xsi:type="string">Bundle Dynamic %isolation%</data> @@ -236,6 +241,7 @@ <constraint name="Magento\Bundle\Test\Constraint\AssertBundlePriceType" /> </variation> <variation name="CreateBundleProductEntityTestVariation11"> + <data name="issue" xsi:type="string">MAGETWO-52788: Dynamic Rows: support status being changed</data> <data name="description" xsi:type="string">Create fixed product with checkout first option</data> <data name="product/data/url_key" xsi:type="string">bundle-product-%isolation%</data> <data name="product/data/name" xsi:type="string">Bundle Fixed %isolation%</data> @@ -334,6 +340,7 @@ <constraint name="Magento\Bundle\Test\Constraint\AssertBundleProductPage" /> </variation> <variation name="CreateBundleProductEntityTestVariation17" summary="Create fixed bundle product with tier price and custom options with fixed and percent price"> + <data name="tag" xsi:type="string">stable:no</data> <data name="product/data/url_key" xsi:type="string">bundle-product-%isolation%</data> <data name="product/data/name" xsi:type="string">Bundle Fixed %isolation%</data> <data name="product/data/sku_type" xsi:type="string">No</data> @@ -359,6 +366,7 @@ <constraint name="Magento\Bundle\Test\Constraint\AssertBundleProductInCart" /> </variation> <variation name="CreateBundleProductEntityTestVariation18" summary="Create dynamic bundle product with tier price for sub-item"> + <data name="tag" xsi:type="string">stable:no</data> <data name="product/data/url_key" xsi:type="string">bundle-product-%isolation%</data> <data name="product/data/name" xsi:type="string">BundleProduct %isolation%</data> <data name="product/data/sku_type" xsi:type="string">Yes</data> @@ -394,6 +402,7 @@ <constraint name="Magento\Catalog\Test\Constraint\AssertProductOutOfStock" /> </variation> <variation name="CreateBundleProductEntityTestVariation21" summary="Create default fixed bundle with custom Website"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="product/data/url_key" xsi:type="string">bundle-product-%isolation%</data> <data name="product/data/name" xsi:type="string">Bundle Fixed %isolation%</data> <data name="product/data/sku_type" xsi:type="string">No</data> diff --git a/dev/tests/functional/tests/app/Magento/Bundle/Test/TestCase/UpdateBundleProductEntityTest.php b/dev/tests/functional/tests/app/Magento/Bundle/Test/TestCase/UpdateBundleProductEntityTest.php index bf17d216bcf9b479e6279f449e782bc94438600e..8326b1ba4d9ae9b0589b1d55bd973f9db6efe970 100644 --- a/dev/tests/functional/tests/app/Magento/Bundle/Test/TestCase/UpdateBundleProductEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Bundle/Test/TestCase/UpdateBundleProductEntityTest.php @@ -73,6 +73,7 @@ class UpdateBundleProductEntityTest extends Injectable */ public function test(BundleProduct $product, BundleProduct $originalProduct) { + $this->markTestIncomplete('MAGETWO-56584: [FT] Custom options are not created for product in test'); // Preconditions $originalProduct->persist(); $originalCategory = $originalProduct->hasData('category_ids') diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/Section/BlockGallery.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/Section/BlockGallery.php new file mode 100644 index 0000000000000000000000000000000000000000..bc0d0b87f24bba19d2e249fa37be7e59e16cca92 --- /dev/null +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/Section/BlockGallery.php @@ -0,0 +1,49 @@ +<?php +/** + * Copyright © 2016 Magento. All rights reserved. + * See COPYING.txt for license details. + */ + +namespace Magento\Catalog\Test\Block\Adminhtml\Product\Edit\Section; + +use Magento\Mtf\Client\Element\SimpleElement; +use Magento\Mtf\Client\Locator; +use Magento\Ui\Test\Block\Adminhtml\Section; + +/** + * Class for product gallery block. + */ +class BlockGallery extends Section +{ + /** + * Selector for image loader container. + * + * @var string + */ + private $imageLoader = '.image.image-placeholder .file-row'; + + /** + * Selector for image upload input. + * + * @var string + */ + private $imageUploadInput = '[name="image"]'; + + /** + * Upload product images. + * + * @param array $data + * @param SimpleElement|null $element + * @return $this + * @SuppressWarnings(PHPMD.UnusedFormalParameter) + */ + public function setFieldsData(array $data, SimpleElement $element = null) + { + foreach ($data['image']['value'] as $imageData) { + $uploadElement = $element->find($this->imageUploadInput, Locator::SELECTOR_CSS, 'upload'); + $uploadElement->setValue($imageData['file']); + $this->waitForElementNotVisible($this->imageLoader); + } + return $this; + } +} diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/ProductForm.xml b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/ProductForm.xml index 407b5c9cb20a3b2097ea87e9d1f5a8240e5566b2..3b66164ebe658097e05fdba2e8b53c6cb3d643d2 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/ProductForm.xml +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/ProductForm.xml @@ -143,7 +143,7 @@ </fields> </attributes> <gallery> - <class>\Magento\Ui\Test\Block\Adminhtml\Section</class> + <class>\Magento\Catalog\Test\Block\Adminhtml\Product\Edit\Section\BlockGallery</class> <selector>[data-index='block_gallery']</selector> <strategy>css selector</strategy> </gallery> diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertCanSaveProduct.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertCanSaveProduct.php new file mode 100644 index 0000000000000000000000000000000000000000..04e1c034b3db77a49a583ee819f9b8d97cb440ba --- /dev/null +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertCanSaveProduct.php @@ -0,0 +1,46 @@ +<?php +/** + * Copyright © 2016 Magento. All rights reserved. + * See COPYING.txt for license details. + */ + +namespace Magento\Catalog\Test\Constraint; + +/** + * Assert that can save already exist product. + */ +class AssertCanSaveProduct extends \Magento\Mtf\Constraint\AbstractConstraint +{ + /** + * Assert that can save already existing product. + * + * @param \Magento\Mtf\Fixture\FixtureInterface $product + * @param \Magento\Catalog\Test\Page\Adminhtml\CatalogProductEdit $catalogProductEdit + * @param \Magento\Catalog\Test\Page\Adminhtml\CatalogProductIndex $catalogProductIndex + * @return void + */ + public function processAssert( + \Magento\Mtf\Fixture\FixtureInterface $product, + \Magento\Catalog\Test\Page\Adminhtml\CatalogProductEdit $catalogProductEdit, + \Magento\Catalog\Test\Page\Adminhtml\CatalogProductIndex $catalogProductIndex + ) { + $filter = ['sku' => $product->getSku()]; + $catalogProductIndex->open()->getProductGrid()->searchAndOpen($filter); + $catalogProductEdit->getFormPageActions()->save(); + + \PHPUnit_Framework_Assert::assertNotEmpty( + $catalogProductEdit->getMessagesBlock()->getSuccessMessage(), + 'Can\'t save existing product.' + ); + } + + /** + * Returns a string representation of the object. + * + * @return string + */ + public function toString() + { + return 'Product was saved without errors.'; + } +} diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductHasImageInGrid.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductHasImageInGrid.php new file mode 100644 index 0000000000000000000000000000000000000000..fed3b36c08d661bbc0297b6f87d08aa692d3c04e --- /dev/null +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductHasImageInGrid.php @@ -0,0 +1,45 @@ +<?php +/** + * Copyright © 2016 Magento. All rights reserved. + * See COPYING.txt for license details. + */ + +namespace Magento\Catalog\Test\Constraint; + +use Magento\Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Constraint\AbstractConstraint; +use Magento\Catalog\Test\Page\Adminhtml\CatalogProductIndex; + +class AssertProductHasImageInGrid extends AbstractConstraint +{ + /** + * Assert that product image is present in grid. + * + * @param CatalogProductIndex $productGrid + * @param InjectableFixture $product + * @return void + */ + public function processAssert( + CatalogProductIndex $productGrid, + InjectableFixture $product + ) { + $filter = ['sku' => $product->getSku()]; + $productGrid->open(); + $productGrid->getProductGrid()->search($filter); + $src = $productGrid->getProductGrid()->getBaseImageSource(); + \PHPUnit_Framework_Assert::assertTrue( + strpos($src, '/placeholder/') === false, + 'Product image is not present in product grid when it should be' + ); + } + + /** + * Returns a string representation of the object. + * + * @return string + */ + public function toString() + { + return 'Product image is displayed in product grid.'; + } +} diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogProductSimple.xml b/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogProductSimple.xml index b4514208a509358a6828a7b77d33ca0c2678072a..e8ceb1d0889247805746a401f6c60bb5a0556010 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogProductSimple.xml +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogProductSimple.xml @@ -36,8 +36,8 @@ <field name="gallery" is_required="0" /> <field name="gift_message_available" is_required="0" /> <field name="has_options" is_required="0" /> - <field name="image" is_required="0" /> - <field name="image_label" is_required="0" /> + <field name="image" is_required="0" group="gallery" source="Magento\Catalog\Test\Fixture\Product\Image" /> + <field name="image_label" group="gallery" is_required="0" /> <field name="manufacturer" is_required="0" /> <field name="media_gallery" is_required="0" /> <field name="meta_description" is_required="0" group="search-engine-optimization" /> diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/Product/Image.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/Product/Image.php new file mode 100644 index 0000000000000000000000000000000000000000..ad72a6db4f4cef615f4abb7edddc497886a73981 --- /dev/null +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/Product/Image.php @@ -0,0 +1,60 @@ +<?php +/** + * Copyright © 2016 Magento. All rights reserved. + * See COPYING.txt for license details. + */ + +namespace Magento\Catalog\Test\Fixture\Product; + +use Magento\Mtf\Fixture\DataSource; +use Magento\Mtf\Fixture\FixtureFactory; + +/** + * Image entity data source. + */ +class Image extends DataSource +{ + /** + * Fixture Factory instance. + * + * @var FixtureFactory + */ + private $fixtureFactory; + + /** + * Fixture data. + * + * @var array + */ + private $fixtureData; + + /** + * @param FixtureFactory $fixtureFactory + * @param array $params + * @param array $data + */ + public function __construct(FixtureFactory $fixtureFactory, array $params, $data = []) + { + $this->fixtureFactory = $fixtureFactory; + $this->params = $params; + $this->fixtureData = $data; + } + + /** + * {@inheritdoc} + * @throws \Exception + */ + public function getData($key = null) + { + foreach ($this->fixtureData as &$imageData) { + if (isset($imageData['file']) && file_exists(MTF_TESTS_PATH . $imageData['file'])) { + $imageData['file'] = MTF_TESTS_PATH . $imageData['file']; + } else { + throw new \Exception("Image '{$imageData['file']}'' not found on the server."); + } + } + $this->data = $this->fixtureData; + + return parent::getData($key); + } +} diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Category/CreateCategoryEntityTest.xml b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Category/CreateCategoryEntityTest.xml index 22cdab45ac875c6a6987892898e3c8dda3382944..fa81264dd2d4b061ef769f882408b104ba92793f 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Category/CreateCategoryEntityTest.xml +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Category/CreateCategoryEntityTest.xml @@ -16,6 +16,7 @@ <constraint name="Magento\Catalog\Test\Constraint\AssertCategoryForm" /> </variation> <variation name="CreateCategoryEntityTestVariation2_RootCategory_AllFields"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="description" xsi:type="string">Create root category with all fields</data> <data name="addCategory" xsi:type="string">addRootCategory</data> <data name="category/data/is_active" xsi:type="string">Yes</data> @@ -56,6 +57,7 @@ <constraint name="Magento\Catalog\Test\Constraint\AssertCategoryPage" /> </variation> <variation name="CreateCategoryEntityTestVariation4_Subcategory_AllFields"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="description" xsi:type="string">Create not anchor subcategory specifying all fields</data> <data name="addCategory" xsi:type="string">addSubcategory</data> <data name="category/data/parent_id/dataset" xsi:type="string">default_category</data> @@ -90,6 +92,7 @@ <constraint name="Magento\Catalog\Test\Constraint\AssertCategoryForAssignedProducts" /> </variation> <variation name="CreateCategoryEntityTestVariation5_Anchor_MostOfFields"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="description" xsi:type="string">Create anchor subcategory with all fields</data> <data name="addCategory" xsi:type="string">addSubcategory</data> <data name="category/data/parent_id/dataset" xsi:type="string">default_category</data> @@ -150,7 +153,7 @@ <constraint name="Magento\Catalog\Test\Constraint\AssertCategoryForAssignedProducts" /> </variation> <variation name="CreateCategoryEntityTestVariation9_ThreeNesting"> - <data name="tag" xsi:type="string">test_type:extended_acceptance_test</data> + <data name="tag" xsi:type="string">test_type:extended_acceptance_test, to_maintain:yes</data> <data name="description" xsi:type="string">Create category with three nesting</data> <data name="addCategory" xsi:type="string">addSubcategory</data> <data name="category/data/parent_id/dataset" xsi:type="string">two_nested_categories</data> diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/NavigateMenuTest.xml b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/NavigateMenuTest.xml index 2c8528595f44b99bc70133cdc473841a0cbb0e22..1b61b92beef1310aa78e49acf49d2501410961b3 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/NavigateMenuTest.xml +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/NavigateMenuTest.xml @@ -14,7 +14,7 @@ </variation> <variation name="NavigateMenuTest10"> <data name="menuItem" xsi:type="string">Products > Categories</data> - <data name="pageTitle" xsi:type="string">Default Category</data> + <data name="pageTitle" xsi:type="string">Default Category (ID: 2)</data> <constraint name="Magento\Backend\Test\Constraint\AssertBackendPageIsAvailable"/> </variation> <variation name="NavigateMenuTest11"> diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/AddCompareProductsTest.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/AddCompareProductsTest.php index 131163311bcd2af4d34031883d103b3c2341cdb8..eddb620feabb3a7b211d0a8d63e4b2bd6a9ec79d 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/AddCompareProductsTest.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/AddCompareProductsTest.php @@ -29,6 +29,7 @@ class AddCompareProductsTest extends AbstractCompareProductsTest { /* tags */ const MVP = 'yes'; + const TO_MAINTAIN = 'yes'; /* end tags */ /** diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/AddCompareProductsTest.xml b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/AddCompareProductsTest.xml index 64d2a1de8a28454df0498d0b8fed68f5064d38ba..c29c99193b75dc99ab725996b617ef1ff794353c 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/AddCompareProductsTest.xml +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/AddCompareProductsTest.xml @@ -10,6 +10,7 @@ <variation name="AddCompareProductsTestVariation1"> <data name="products" xsi:type="string">catalogProductSimple::simple_for_composite_products</data> <data name="isCustomerLoggedIn" xsi:type="string">No</data> + <data name="tag" xsi:type="string">to_maintain:yes</data> <constraint name="Magento\Catalog\Test\Constraint\AssertProductCompareItemsLink" /> <constraint name="Magento\Catalog\Test\Constraint\AssertProductComparePage" /> <constraint name="Magento\Catalog\Test\Constraint\AssertProductCompareBlockOnCmsPage" /> diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/ClearAllCompareProductsTest.xml b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/ClearAllCompareProductsTest.xml index 16ebdf323e5920fb90074845b53ab61b8b91c68a..19fc527e71ab7672a96a6b0226e43ede2d356b25 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/ClearAllCompareProductsTest.xml +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/ClearAllCompareProductsTest.xml @@ -8,6 +8,7 @@ <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../../vendor/magento/mtf/etc/variations.xsd"> <testCase name="Magento\Catalog\Test\TestCase\Product\ClearAllCompareProductsTest" summary="Clear All Compare Products" ticketId="MAGETWO-25961"> <variation name="ClearAllCompareProductsTestVariation1"> + <data name="tag" xsi:type="string">stable:no</data> <data name="config/dataset" xsi:type="string">compare_products</data> <data name="products" xsi:type="string">catalogProductSimple::simple_for_composite_products,catalogProductVirtual::default,downloadableProduct::default,groupedProduct::grouped_product_with_price,configurableProduct::default,bundleProduct::bundle_dynamic_product,bundleProduct::bundle_fixed_product</data> <constraint name="Magento\Catalog\Test\Constraint\AssertProductCompareSuccessRemoveAllProductsMessage" /> diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/CreateSimpleProductEntityTest.xml b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/CreateSimpleProductEntityTest.xml index 9e410c525deef720573e7c93e0de4d463b9b2ac7..9f4a5e4bb71fea9293612125157757f7e3d965da 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/CreateSimpleProductEntityTest.xml +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/CreateSimpleProductEntityTest.xml @@ -137,6 +137,7 @@ <data name="product/data/checkout_data/dataset" xsi:type="string">simple_drop_down_with_one_option_percent_price</data> <data name="product/data/price/dataset" xsi:type="string">MAGETWO-23030</data> <data name="product/data/tier_price/dataset" xsi:type="string">MAGETWO-23002</data> + <data name="tag" xsi:type="string">to_maintain:yes</data> <constraint name="Magento\Catalog\Test\Constraint\AssertProductSaveMessage" /> <constraint name="Magento\Catalog\Test\Constraint\AssertProductInGrid" /> <constraint name="Magento\Catalog\Test\Constraint\AssertProductInCategory" /> @@ -157,6 +158,7 @@ <data name="product/data/checkout_data/dataset" xsi:type="string">simple_drop_down_with_one_option_fixed_price</data> <data name="product/data/price/dataset" xsi:type="string">MAGETWO-23029</data> <data name="product/data/tier_price/dataset" xsi:type="string">MAGETWO-23002</data> + <data name="tag" xsi:type="string">to_maintain:yes</data> <constraint name="Magento\Catalog\Test\Constraint\AssertProductSaveMessage" /> <constraint name="Magento\Catalog\Test\Constraint\AssertProductInGrid" /> <constraint name="Magento\Catalog\Test\Constraint\AssertProductInCategory" /> @@ -238,6 +240,7 @@ <constraint name="Magento\Catalog\Test\Constraint\AssertProductPage" /> </variation> <variation name="CreateSimpleProductEntityTestVariation14"> + <data name="tag" xsi:type="string">stable:no</data> <data name="description" xsi:type="string">Create simple product and check visibility in category</data> <data name="product/data/url_key" xsi:type="string">simple-product-%isolation%</data> <data name="product/data/name" xsi:type="string">Simple Product %isolation%</data> @@ -255,6 +258,7 @@ <constraint name="Magento\Catalog\Test\Constraint\AssertProductPage" /> </variation> <variation name="CreateSimpleProductEntityTestVariation15"> + <data name="tag" xsi:type="string">stable:no</data> <data name="description" xsi:type="string">Create product with tax class and group price</data> <data name="product/data/url_key" xsi:type="string">simple-product-%isolation%</data> <data name="product/data/name" xsi:type="string">Simple Product %isolation%</data> @@ -303,6 +307,7 @@ <data name="product/data/weight" xsi:type="string">66</data> <data name="product/data/quantity_and_stock_status/qty" xsi:type="string">143</data> <data name="product/data/tier_price/dataset" xsi:type="string">default</data> + <data name="tag" xsi:type="string">to_maintain:yes</data> <constraint name="Magento\Catalog\Test\Constraint\AssertProductSaveMessage" /> <constraint name="Magento\Catalog\Test\Constraint\AssertProductInGrid" /> <constraint name="Magento\Catalog\Test\Constraint\AssertProductForm" /> @@ -324,6 +329,7 @@ <data name="product/data/custom_options/dataset" xsi:type="string">options_suite</data> <data name="product/data/checkout_data/dataset" xsi:type="string">simple_options_suite</data> <data name="product/data/custom_options/import_products" xsi:type="string">catalogProductSimple::with_two_custom_option,catalogProductSimple::with_all_custom_option</data> + <data name="issue" xsi:type="string">MAGETWO-58181: All kind of Custom Options have dynamic view on Bamboo</data> <constraint name="Magento\Catalog\Test\Constraint\AssertProductSaveMessage" /> <constraint name="Magento\Catalog\Test\Constraint\AssertProductInGrid" /> <constraint name="Magento\Catalog\Test\Constraint\AssertProductForm" /> @@ -333,6 +339,7 @@ <constraint name="Magento\Catalog\Test\Constraint\AssertProductCustomOptionsOnProductPage" /> </variation> <variation name="CreateSimpleProductEntityTestVariation19" summary="Create product with cross-sell products" ticketId="MAGETWO-29081"> + <data name="tag" xsi:type="string">stable:no</data> <data name="product/data/url_key" xsi:type="string">simple-product-%isolation%</data> <data name="product/data/name" xsi:type="string">Simple Product %isolation%</data> <data name="product/data/sku" xsi:type="string">simple_sku_%isolation%</data> @@ -349,6 +356,7 @@ <constraint name="Magento\Catalog\Test\Constraint\AssertProductCrossSells" /> </variation> <variation name="CreateSimpleProductEntityTestVariation20" summary="Create product with up-sell products" ticketId="MAGETWO-29105"> + <data name="tag" xsi:type="string">stable:no</data> <data name="product/data/url_key" xsi:type="string">simple-product-%isolation%</data> <data name="product/data/name" xsi:type="string">Simple Product %isolation%</data> <data name="product/data/sku" xsi:type="string">simple_sku_%isolation%</data> @@ -401,6 +409,7 @@ <data name="product/data/sku" xsi:type="string">simple%isolation%</data> <data name="product/data/price/value" xsi:type="string">10</data> <data name="product/data/quantity_and_stock_status/qty" xsi:type="string">345</data> + <data name="tag" xsi:type="string">to_maintain:yes</data> <constraint name="Magento\Catalog\Test\Constraint\AssertProductSaveMessage" /> <constraint name="Magento\Catalog\Test\Constraint\AssertProductInCategory" /> <constraint name="Magento\Catalog\Test\Constraint\AssertProductPage" /> @@ -500,5 +509,19 @@ <constraint name="Magento\Catalog\Test\Constraint\AssertProductPage" /> <constraint name="Magento\Catalog\Test\Constraint\AssertProductInCart" /> </variation> + <variation name="CreateSimpleProductEntityWithImageTestVariation1" summary="Create product with image and try to save it again"> + <data name="product/data/image/0/file" xsi:type="string">Magento/Catalog/Test/_files/test1.png</data> + <data name="product/data/image/1/file" xsi:type="string">Magento/Catalog/Test/_files/test2.png</data> + <data name="product/data/url_key" xsi:type="string">simple-product-%isolation%</data> + <data name="product/data/name" xsi:type="string">Simple Product %isolation%</data> + <data name="product/data/sku" xsi:type="string">simple_sku_%isolation%</data> + <data name="product/data/price/value" xsi:type="string">10</data> + <data name="product/data/weight" xsi:type="string">50</data> + <data name="tag" xsi:type="string">severity:S1</data> + <data name="product/data/quantity_and_stock_status/qty" xsi:type="string">100</data> + <constraint name="Magento\Catalog\Test\Constraint\AssertProductSaveMessage" /> + <constraint name="Magento\Catalog\Test\Constraint\AssertProductHasImageInGrid" /> + <constraint name="Magento\Catalog\Test\Constraint\AssertCanSaveProduct" /> + </variation> </testCase> </config> diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/CreateVirtualProductEntityTest.xml b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/CreateVirtualProductEntityTest.xml index bf158ce4d66b772daaa03f7795cf74d1826bbe59..ed124d152d29b280e2131d1a077a0ed41f5f79af 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/CreateVirtualProductEntityTest.xml +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/CreateVirtualProductEntityTest.xml @@ -8,6 +8,7 @@ <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../../vendor/magento/mtf/etc/variations.xsd"> <testCase name="Magento\Catalog\Test\TestCase\Product\CreateVirtualProductEntityTest" summary="Create Virtual Product" ticketId="MAGETWO-23417"> <variation name="CreateVirtualProductEntityTestVariation1"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="description" xsi:type="string">Create product with required fields</data> <data name="product/data/url_key" xsi:type="string">virtual-product-%isolation%</data> <data name="product/data/name" xsi:type="string">VirtualProduct %isolation%</data> @@ -17,7 +18,7 @@ <constraint name="Magento\Catalog\Test\Constraint\AssertProductInGrid" /> </variation> <variation name="CreateVirtualProductEntityTestVariation2" summary="Create product with tier price"> - <data name="tag" xsi:type="string">test_type:extended_acceptance_test</data> + <data name="tag" xsi:type="string">test_type:extended_acceptance_test, to_maintain:yes</data> <data name="product/data/url_key" xsi:type="string">virtual-product-%isolation%</data> <data name="product/data/name" xsi:type="string">VirtualProduct %isolation%</data> <data name="product/data/sku" xsi:type="string">virtual_sku_%isolation%</data> @@ -65,12 +66,14 @@ <data name="product/data/quantity_and_stock_status/is_in_stock" xsi:type="string">In Stock</data> <data name="product/data/visibility" xsi:type="string">Catalog, Search</data> <data name="customer/dataset" xsi:type="string">default</data> + <data name="tag" xsi:type="string">to_maintain:yes</data> <constraint name="Magento\Catalog\Test\Constraint\AssertProductSaveMessage" /> <constraint name="Magento\Catalog\Test\Constraint\AssertProductForm" /> <constraint name="Magento\Catalog\Test\Constraint\AssertProductVisibleInCategory" /> <constraint name="Magento\Catalog\Test\Constraint\AssertProductTierPriceOnProductPageWithCustomer" /> </variation> <variation name="CreateVirtualProductEntityTestVariation5"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="description" xsi:type="string">Create product with custom options suite and import options</data> <data name="product/data/url_key" xsi:type="string">virtual-product-%isolation%</data> <data name="product/data/name" xsi:type="string">VirtualProduct %isolation%</data> @@ -110,6 +113,7 @@ <data name="product/data/quantity_and_stock_status/qty" xsi:type="string">999</data> <data name="product/data/tier_price/dataset" xsi:type="string">default</data> <data name="product/data/quantity_and_stock_status/is_in_stock" xsi:type="string">Out of Stock</data> + <data name="tag" xsi:type="string">to_maintain:yes</data> <constraint name="Magento\Catalog\Test\Constraint\AssertProductSaveMessage" /> <constraint name="Magento\Catalog\Test\Constraint\AssertProductPage" /> <constraint name="Magento\Catalog\Test\Constraint\AssertProductTierPriceOnProductPage" /> diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/DeleteCompareProductsTest.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/DeleteCompareProductsTest.php index 7026b757bb7de03a00f18b525076a057749d2383..81cf672344d612224ff6cab99fec93bfa97b8253 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/DeleteCompareProductsTest.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/DeleteCompareProductsTest.php @@ -28,6 +28,7 @@ class DeleteCompareProductsTest extends AbstractCompareProductsTest { /* tags */ const MVP = 'yes'; + const STABLE = 'no'; /* end tags */ /** diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/DeleteCompareProductsTest.xml b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/DeleteCompareProductsTest.xml index 883e7cdf6032c5813759db3d613378c34f04c277..9d983f52c08b6bde5c9edc5e59f30899e8da5f21 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/DeleteCompareProductsTest.xml +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/DeleteCompareProductsTest.xml @@ -8,6 +8,7 @@ <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../../vendor/magento/mtf/etc/variations.xsd"> <testCase name="Magento\Catalog\Test\TestCase\Product\DeleteCompareProductsTest" summary="Delete Compare Products" ticketId="MAGETWO-26161"> <variation name="DeleteCompareProductsTestVariation1_NotLoggedIn"> + <data name="tag" xsi:type="string">stable:no</data> <data name="products" xsi:type="string">catalogProductSimple::simple_for_composite_products,catalogProductVirtual::default,downloadableProduct::default,groupedProduct::grouped_product_with_price,configurableProduct::default,bundleProduct::bundle_dynamic_product,bundleProduct::bundle_fixed_product</data> <data name="removeProductIndex" xsi:type="string">1</data> <data name="isCustomerLoggedIn" xsi:type="string">No</data> @@ -15,6 +16,7 @@ <constraint name="Magento\Catalog\Test\Constraint\AssertProductIsNotVisibleInComparePage" /> </variation> <variation name="DeleteCompareProductsTestVariation2_LoggedIn"> + <data name="tag" xsi:type="string">stable:no</data> <data name="products" xsi:type="string">catalogProductSimple::simple_for_composite_products,catalogProductVirtual::default,downloadableProduct::default,groupedProduct::grouped_product_with_price,configurableProduct::default,bundleProduct::bundle_dynamic_product,bundleProduct::bundle_fixed_product</data> <data name="removeProductIndex" xsi:type="string">6</data> <data name="isCustomerLoggedIn" xsi:type="string">Yes</data> diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/DeleteProductEntityTest.xml b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/DeleteProductEntityTest.xml index 3bef2716d35728fff7c3a2cd730688862acae1e4..32d534941e2b91ad5ba1a96d9ba6b0e47d523e70 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/DeleteProductEntityTest.xml +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/DeleteProductEntityTest.xml @@ -10,6 +10,7 @@ <variation name="DeleteProductEntityTestVariation1"> <data name="products" xsi:type="string">catalogProductSimple::default</data> <data name="isRequired" xsi:type="string">Yes</data> + <data name="tag" xsi:type="string">to_maintain:yes</data> <constraint name="Magento\Catalog\Test\Constraint\AssertProductSuccessDeleteMessage" /> <constraint name="Magento\Catalog\Test\Constraint\AssertProductNotInGrid" /> <constraint name="Magento\Catalog\Test\Constraint\AssertProductIsNotDisplayingOnFrontend" /> diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/DuplicateProductEntityTest.xml b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/DuplicateProductEntityTest.xml index 5b81bebbc6d04e9551fa6399c308a365895b9bd7..0dad886f05ed55c7b951e32dfec8a74b433d6067 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/DuplicateProductEntityTest.xml +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/DuplicateProductEntityTest.xml @@ -8,6 +8,7 @@ <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../../vendor/magento/mtf/etc/variations.xsd"> <testCase name="Magento\Catalog\Test\TestCase\Product\DuplicateProductEntityTest" summary="Duplicate Product" ticketId="MAGETWO-23294"> <variation name="DuplicateProductEntityTestVariation1"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="productType" xsi:type="string">catalogProductSimple::default</data> <constraint name="Magento\Catalog\Test\Constraint\AssertProductSaveMessage" /> <constraint name="Magento\Catalog\Test\Constraint\AssertProductDuplicateMessage" /> diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/ProductTypeSwitchingOnCreationTest.xml b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/ProductTypeSwitchingOnCreationTest.xml index 6cb89d424fee3a0e3ddc084dc304e3fe2f25751c..4ab490478958a81f7312dd1d7a9fc6fb9835a05a 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/ProductTypeSwitchingOnCreationTest.xml +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/ProductTypeSwitchingOnCreationTest.xml @@ -8,6 +8,7 @@ <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../../vendor/magento/mtf/etc/variations.xsd"> <testCase name="Magento\Catalog\Test\TestCase\Product\ProductTypeSwitchingOnCreationTest" summary="Product Type Switching on Creation" ticketId="MAGETWO-29398"> <variation name="ProductTypeSwitchingOnCreationTestVariation1"> + <data name="tag" xsi:type="string">stable:no</data> <data name="createProduct" xsi:type="string">simple</data> <data name="product" xsi:type="string">configurableProduct::default</data> <constraint name="Magento\Catalog\Test\Constraint\AssertProductSaveMessage" /> @@ -44,6 +45,7 @@ <constraint name="Magento\Catalog\Test\Constraint\AssertProductInGrid" /> </variation> <variation name="ProductTypeSwitchingOnCreationTestVariation6"> + <data name="tag" xsi:type="string">stable:no</data> <data name="createProduct" xsi:type="string">virtual</data> <data name="product" xsi:type="string">configurableProduct::not_virtual_for_type_switching</data> <constraint name="Magento\Catalog\Test\Constraint\AssertProductSaveMessage" /> @@ -56,6 +58,7 @@ <constraint name="Magento\ConfigurableProduct\Test\Constraint\AssertChildProductIsNotDisplayedSeparately" /> </variation> <variation name="ProductTypeSwitchingOnCreationTestVariation7"> + <data name="tag" xsi:type="string">stable:no</data> <data name="createProduct" xsi:type="string">virtual</data> <data name="product" xsi:type="string">downloadableProduct::default</data> <constraint name="Magento\Catalog\Test\Constraint\AssertProductSaveMessage" /> @@ -73,6 +76,7 @@ <variation name="ProductTypeSwitchingOnCreationTestVariation9"> <data name="createProduct" xsi:type="string">downloadable</data> <data name="product" xsi:type="string">configurableProduct::not_virtual_for_type_switching</data> + <data name="tag" xsi:type="string">to_maintain:yes</data> <constraint name="Magento\Catalog\Test\Constraint\AssertProductSaveMessage" /> <constraint name="Magento\Catalog\Test\Constraint\AssertProductInGrid" /> <constraint name="Magento\ConfigurableProduct\Test\Constraint\AssertChildProductsInGrid" /> diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/ProductTypeSwitchingOnUpdateTest.xml b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/ProductTypeSwitchingOnUpdateTest.xml index a2580cee9b91a342c30d21fb4356c682e68a8383..874cac5d4bc5828769a88badc87a41643799d4fc 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/ProductTypeSwitchingOnUpdateTest.xml +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/ProductTypeSwitchingOnUpdateTest.xml @@ -11,6 +11,7 @@ <data name="productOrigin" xsi:type="string">catalogProductSimple::default</data> <data name="product" xsi:type="string">configurableProduct::default</data> <data name="actionName" xsi:type="string">-</data> + <data name="tag" xsi:type="string">to_maintain:yes</data> <constraint name="Magento\Catalog\Test\Constraint\AssertProductSaveMessage" /> <constraint name="Magento\Catalog\Test\Constraint\AssertProductInGrid" /> <constraint name="Magento\ConfigurableProduct\Test\Constraint\AssertChildProductsInGrid" /> @@ -20,6 +21,7 @@ <constraint name="Magento\ConfigurableProduct\Test\Constraint\AssertChildProductIsNotDisplayedSeparately" /> </variation> <variation name="ProductTypeSwitchingOnUpdateTestVariation2"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="productOrigin" xsi:type="string">catalogProductSimple::default</data> <data name="product" xsi:type="string">catalogProductVirtual::default</data> <data name="actionName" xsi:type="string">-</data> @@ -27,6 +29,7 @@ <constraint name="Magento\Catalog\Test\Constraint\AssertProductInGrid" /> </variation> <variation name="ProductTypeSwitchingOnUpdateTestVariation3"> + <data name="tag" xsi:type="string">stable:no</data> <data name="productOrigin" xsi:type="string">configurableProduct::default</data> <data name="product" xsi:type="string">catalogProductSimple::product_without_category</data> <data name="actionName" xsi:type="string">deleteVariations</data> @@ -37,10 +40,12 @@ <data name="productOrigin" xsi:type="string">configurableProduct::default</data> <data name="product" xsi:type="string">catalogProductVirtual::required_fields</data> <data name="actionName" xsi:type="string">deleteVariations</data> + <data name="tag" xsi:type="string">to_maintain:yes</data> <constraint name="Magento\Catalog\Test\Constraint\AssertProductSaveMessage" /> <constraint name="Magento\Catalog\Test\Constraint\AssertProductInGrid" /> </variation> <variation name="ProductTypeSwitchingOnUpdateTestVariation5"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="productOrigin" xsi:type="string">catalogProductVirtual::default</data> <data name="product" xsi:type="string">catalogProductSimple::default</data> <data name="actionName" xsi:type="string">-</data> @@ -51,6 +56,7 @@ <data name="productOrigin" xsi:type="string">catalogProductVirtual::default</data> <data name="product" xsi:type="string">configurableProduct::not_virtual_for_type_switching</data> <data name="actionName" xsi:type="string">-</data> + <data name="tag" xsi:type="string">to_maintain:yes</data> <constraint name="Magento\Catalog\Test\Constraint\AssertProductSaveMessage" /> <constraint name="Magento\Catalog\Test\Constraint\AssertProductInGrid" /> <constraint name="Magento\ConfigurableProduct\Test\Constraint\AssertChildProductsInGrid" /> @@ -63,6 +69,7 @@ <data name="productOrigin" xsi:type="string">catalogProductVirtual::default</data> <data name="product" xsi:type="string">downloadableProduct::default</data> <data name="actionName" xsi:type="string">-</data> + <data name="tag" xsi:type="string">to_maintain:yes</data> <constraint name="Magento\Catalog\Test\Constraint\AssertProductSaveMessage" /> <constraint name="Magento\Catalog\Test\Constraint\AssertProductInGrid" /> <constraint name="Magento\Downloadable\Test\Constraint\AssertDownloadableProductForm" /> @@ -74,6 +81,7 @@ <data name="productOrigin" xsi:type="string">downloadableProduct::default</data> <data name="product" xsi:type="string">catalogProductSimple::default</data> <data name="actionName" xsi:type="string">-</data> + <data name="tag" xsi:type="string">to_maintain:yes</data> <constraint name="Magento\Catalog\Test\Constraint\AssertProductSaveMessage" /> <constraint name="Magento\Catalog\Test\Constraint\AssertProductInGrid" /> </variation> @@ -81,6 +89,7 @@ <data name="productOrigin" xsi:type="string">downloadableProduct::default</data> <data name="product" xsi:type="string">configurableProduct::not_virtual_for_type_switching</data> <data name="actionName" xsi:type="string">-</data> + <data name="tag" xsi:type="string">to_maintain:yes</data> <constraint name="Magento\Catalog\Test\Constraint\AssertProductSaveMessage" /> <constraint name="Magento\Catalog\Test\Constraint\AssertProductInGrid" /> <constraint name="Magento\ConfigurableProduct\Test\Constraint\AssertChildProductsInGrid" /> @@ -90,6 +99,7 @@ <constraint name="Magento\ConfigurableProduct\Test\Constraint\AssertChildProductIsNotDisplayedSeparately" /> </variation> <variation name="ProductTypeSwitchingOnUpdateTestVariation10"> + <data name="tag" xsi:type="string">stable:no</data> <data name="productOrigin" xsi:type="string">downloadableProduct::default</data> <data name="product" xsi:type="string">catalogProductVirtual::default</data> <data name="actionName" xsi:type="string">clearDownloadableData</data> @@ -100,6 +110,7 @@ <data name="productOrigin" xsi:type="string">catalogProductSimple::default</data> <data name="product" xsi:type="string">downloadableProduct::default</data> <data name="actionName" xsi:type="string">-</data> + <data name="tag" xsi:type="string">to_maintain:yes</data> <constraint name="Magento\Catalog\Test\Constraint\AssertProductSaveMessage" /> <constraint name="Magento\Catalog\Test\Constraint\AssertProductInGrid" /> <constraint name="Magento\Downloadable\Test\Constraint\AssertDownloadableProductForm" /> diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/UpdateSimpleProductEntityTest.xml b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/UpdateSimpleProductEntityTest.xml index 0395f9f5ed8cf83c0aa570252cc5ed7df32da3c8..31aaad654f92a914c14276ab770fa7fe9790f5de 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/UpdateSimpleProductEntityTest.xml +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/UpdateSimpleProductEntityTest.xml @@ -8,6 +8,7 @@ <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../../vendor/magento/mtf/etc/variations.xsd"> <testCase name="Magento\Catalog\Test\TestCase\Product\UpdateSimpleProductEntityTest" summary="Update Simple Product" ticketId="MAGETWO-23544"> <variation name="UpdateSimpleProductEntityTestVariation1"> + <data name="tag" xsi:type="string">stable:no</data> <data name="description" xsi:type="string">Update visibility to Catalog, Search</data> <data name="initialProduct/dataset" xsi:type="string">product_with_category</data> <data name="product/data/name" xsi:type="string">Test simple product %isolation%</data> @@ -24,6 +25,7 @@ <constraint name="Magento\Catalog\Test\Constraint\AssertProductPage" /> </variation> <variation name="UpdateSimpleProductEntityTestVariation2"> + <data name="tag" xsi:type="string">stable:no</data> <data name="description" xsi:type="string">Update visibility to Not Visible Individually</data> <data name="initialProduct/dataset" xsi:type="string">product_with_category</data> <data name="product/data/name" xsi:type="string">Test simple product %isolation%</data> @@ -47,6 +49,7 @@ <data name="product/data/url_key" xsi:type="string">test-simple-product-%isolation%</data> <data name="product/data/weight" xsi:type="string">25.0000</data> <data name="product/data/visibility" xsi:type="string">Catalog</data> + <data name="tag" xsi:type="string">to_maintain:yes</data> <constraint name="Magento\Catalog\Test\Constraint\AssertProductSaveMessage" /> <constraint name="Magento\Catalog\Test\Constraint\AssertProductInStock" /> <constraint name="Magento\Catalog\Test\Constraint\AssertProductForm" /> @@ -64,6 +67,7 @@ <data name="product/data/url_key" xsi:type="string">test-simple-product-%isolation%</data> <data name="product/data/weight" xsi:type="string">89.0000</data> <data name="product/data/visibility" xsi:type="string">Search</data> + <data name="tag" xsi:type="string">to_maintain:yes</data> <constraint name="Magento\Catalog\Test\Constraint\AssertProductSaveMessage" /> <constraint name="Magento\Catalog\Test\Constraint\AssertProductInStock" /> <constraint name="Magento\Catalog\Test\Constraint\AssertProductForm" /> @@ -81,6 +85,7 @@ <data name="product/data/quantity_and_stock_status/is_in_stock" xsi:type="string">Out of Stock</data> <data name="product/data/url_key" xsi:type="string">test-simple-product-%isolation%</data> <data name="product/data/weight" xsi:type="string">125.0000</data> + <data name="tag" xsi:type="string">to_maintain:yes</data> <constraint name="Magento\Catalog\Test\Constraint\AssertProductSaveMessage" /> <constraint name="Magento\Catalog\Test\Constraint\AssertProductForm" /> <constraint name="Magento\Catalog\Test\Constraint\AssertProductOutOfStock" /> @@ -89,6 +94,7 @@ <constraint name="Magento\Catalog\Test\Constraint\AssertProductSearchableBySku" /> </variation> <variation name="UpdateSimpleProductEntityTestVariation6"> + <data name="tag" xsi:type="string">stable:no</data> <data name="description" xsi:type="string">Update product status to offline</data> <data name="initialProduct/dataset" xsi:type="string">product_with_category</data> <data name="product/data/name" xsi:type="string">Test simple product %isolation%</data> @@ -112,6 +118,7 @@ <data name="product/data/quantity_and_stock_status/qty" xsi:type="string">87</data> <data name="product/data/url_key" xsi:type="string">test-simple-product-%isolation%</data> <data name="product/data/weight" xsi:type="string">333.0000</data> + <data name="tag" xsi:type="string">to_maintain:yes</data> <constraint name="Magento\Catalog\Test\Constraint\AssertProductSaveMessage" /> <constraint name="Magento\Catalog\Test\Constraint\AssertProductForm" /> <constraint name="Magento\UrlRewrite\Test\Constraint\AssertUrlRewriteUpdatedProductInGrid" /> @@ -124,6 +131,7 @@ <data name="product/data/sku" xsi:type="string">test_simple_product_%isolation%</data> <data name="product/data/price/value" xsi:type="string">133.00</data> <data name="product/data/url_key" xsi:type="string">test-simple-product-%isolation%</data> + <data name="tag" xsi:type="string">to_maintain:yes</data> <constraint name="Magento\Catalog\Test\Constraint\AssertProductSaveMessage" /> <constraint name="Magento\Catalog\Test\Constraint\AssertProductPage" /> </variation> @@ -142,10 +150,12 @@ <data name="product/data/sku" xsi:type="string">sku_simple_product_%isolation%</data> <data name="product/data/price/value" xsi:type="string">1.99</data> <data name="product/data/attribute_set_id/dataset" xsi:type="string">default</data> + <data name="tag" xsi:type="string">to_maintain:yes</data> <constraint name="Magento\Catalog\Test\Constraint\AssertProductInGrid" /> <constraint name="Magento\Catalog\Test\Constraint\AssertProductInCategory" /> </variation> <variation name="EditSimpleProductTestVariation11" summary="Update simple product with custom option"> + <data name="tag" xsi:type="string">stable:no</data> <data name="initialProduct/dataset" xsi:type="string">product_with_category</data> <data name="product/data/name" xsi:type="string">Test simple product %isolation%</data> <data name="product/data/sku" xsi:type="string">test_simple_product_%isolation%</data> diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/UpdateVirtualProductEntityTest.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/UpdateVirtualProductEntityTest.php index ddd788d7ee1c91dde5164b06ea2d908056031c25..2a18f9e37f953b91e06332ffc1e4090c1a4acd73 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/UpdateVirtualProductEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/UpdateVirtualProductEntityTest.php @@ -37,6 +37,7 @@ class UpdateVirtualProductEntityTest extends Injectable { /* tags */ const MVP = 'no'; + const TO_MAINTAIN = 'yes'; /* end tags */ /** diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/ProductAttribute/CreateAttributeSetEntityTest.xml b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/ProductAttribute/CreateAttributeSetEntityTest.xml index 3bc4b3c780d627c6ec6e049574381f1ff726867c..a263a70e8bfc007cbcc0a224e8bc1255e86dfe2a 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/ProductAttribute/CreateAttributeSetEntityTest.xml +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/ProductAttribute/CreateAttributeSetEntityTest.xml @@ -8,6 +8,7 @@ <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../../vendor/magento/mtf/etc/variations.xsd"> <testCase name="Magento\Catalog\Test\TestCase\ProductAttribute\CreateAttributeSetEntityTest" summary="Create Attribute Set (Attribute Set)" ticketId="MAGETWO-25104"> <variation name="CreateAttributeSetEntityTestVariation1"> + <data name="tag" xsi:type="string">stable:no</data> <data name="attributeSet/data/attribute_set_name" xsi:type="string">AttributeSet%isolation%</data> <data name="attributeSet/data/skeleton_set/dataset" xsi:type="string">default</data> <constraint name="Magento\Catalog\Test\Constraint\AssertAttributeSetSuccessSaveMessage" /> diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/ProductAttribute/CreateProductAttributeEntityTest.xml b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/ProductAttribute/CreateProductAttributeEntityTest.xml index 2a94a12c0dbdf0d37082a16c19cff02c152ed7f3..543bece9331f4d0968e38b7d8f887f563b9b8ec3 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/ProductAttribute/CreateProductAttributeEntityTest.xml +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/ProductAttribute/CreateProductAttributeEntityTest.xml @@ -8,6 +8,7 @@ <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../../vendor/magento/mtf/etc/variations.xsd"> <testCase name="Magento\Catalog\Test\TestCase\ProductAttribute\CreateProductAttributeEntityTest" summary="Create Product Attribute" ticketId="MAGETWO-24767"> <variation name="CreateProductAttributeEntityTestVariation1"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="attributeSet/dataset" xsi:type="string">custom_attribute_set</data> <data name="productAttribute/data/frontend_label" xsi:type="string">Text_Field_Admin_%isolation%</data> <data name="productAttribute/data/frontend_input" xsi:type="string">Text Field</data> @@ -19,6 +20,7 @@ <constraint name="Magento\Catalog\Test\Constraint\AssertAddedProductAttributeOnProductForm" /> </variation> <variation name="CreateProductAttributeEntityTestVariation2"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="attributeSet/dataset" xsi:type="string">custom_attribute_set</data> <data name="productAttribute/data/frontend_label" xsi:type="string">Text_Field_Admin_%isolation%</data> <data name="productAttribute/data/frontend_input" xsi:type="string">Text Area</data> @@ -57,6 +59,7 @@ <data name="productAttribute/data/used_in_product_listing" xsi:type="string">Yes</data> <data name="productAttribute/data/is_used_for_promo_rules" xsi:type="string">Yes</data> <data name="productAttribute/data/used_for_sort_by" xsi:type="string">Yes</data> + <data name="tag" xsi:type="string">to_maintain:yes</data> <constraint name="Magento\Catalog\Test\Constraint\AssertProductAttributeInGrid" /> <constraint name="Magento\Catalog\Test\Constraint\AssertAttributeForm" /> <constraint name="Magento\CatalogSearch\Test\Constraint\AssertAdvancedSearchProductByAttribute" /> @@ -65,6 +68,7 @@ <constraint name="Magento\CatalogRule\Test\Constraint\AssertProductAttributeIsUsedPromoRules" /> </variation> <variation name="CreateProductAttributeEntityTestVariation4"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="attributeSet/dataset" xsi:type="string">custom_attribute_set</data> <data name="productAttribute/data/frontend_label" xsi:type="string">Yes/No_Admin_%isolation%</data> <data name="productAttribute/data/frontend_input" xsi:type="string">Yes/No</data> @@ -97,6 +101,7 @@ <data name="productAttribute/data/is_html_allowed_on_front" xsi:type="string">Yes</data> <data name="productAttribute/data/is_visible_on_front" xsi:type="string">Yes</data> <data name="productAttribute/data/used_in_product_listing" xsi:type="string">Yes</data> + <data name="tag" xsi:type="string">to_maintain:yes</data> <constraint name="Magento\Catalog\Test\Constraint\AssertProductAttributeInGrid" /> <constraint name="Magento\Catalog\Test\Constraint\AssertAttributeForm" /> <constraint name="Magento\Catalog\Test\Constraint\AssertAddedProductAttributeOnProductForm" /> @@ -110,7 +115,7 @@ <constraint name="Magento\Catalog\Test\Constraint\AssertAttributeOptionsOnProductForm" /> </variation> <variation name="CreateProductAttributeEntityTestVariation6"> - <data name="tag" xsi:type="string">test_type:extended_acceptance_test</data> + <data name="tag" xsi:type="string">test_type:extended_acceptance_test, to_maintain:yes</data> <data name="attributeSet/dataset" xsi:type="string">custom_attribute_set</data> <data name="productAttribute/data/frontend_label" xsi:type="string">Dropdown_Admin_%isolation%</data> <data name="productAttribute/data/frontend_input" xsi:type="string">Dropdown</data> @@ -148,6 +153,7 @@ <constraint name="Magento\Catalog\Test\Constraint\AssertAttributeOptionsOnProductForm" /> </variation> <variation name="CreateProductAttributeEntityTestVariation7"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="attributeSet/dataset" xsi:type="string">custom_attribute_set</data> <data name="productAttribute/data/frontend_label" xsi:type="string">Price_Admin_%isolation%</data> <data name="productAttribute/data/frontend_input" xsi:type="string">Price</data> @@ -169,6 +175,7 @@ <constraint name="Magento\Catalog\Test\Constraint\AssertProductAttributeIsFilterableInSearch" /> </variation> <variation name="CreateProductAttributeEntityTestVariation8"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="attributeSet/dataset" xsi:type="string">custom_attribute_set</data> <data name="productAttribute/data/frontend_label" xsi:type="string">Fixed_Product_Tax_Admin_%isolation%</data> <data name="productAttribute/data/frontend_input" xsi:type="string">Fixed Product Tax</data> @@ -185,6 +192,7 @@ <constraint name="Magento\Catalog\Test\Constraint\AssertAddedProductAttributeOnProductForm" /> </variation> <variation name="CreateProductAttributeEntityTestVariation9"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="attributeSet/dataset" xsi:type="string">custom_attribute_set</data> <data name="productAttribute/data/frontend_label" xsi:type="string">Text_Field_Admin_%isolation%</data> <data name="productAttribute/data/frontend_input" xsi:type="string">Text Field</data> diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/ProductAttribute/DeleteAttributeSetTest.xml b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/ProductAttribute/DeleteAttributeSetTest.xml index 3f547daa68eb58cfc8480f76ede8c1be5ea31ace..83b5be744f0251374798b2a151c9c1dabf737b53 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/ProductAttribute/DeleteAttributeSetTest.xml +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/ProductAttribute/DeleteAttributeSetTest.xml @@ -8,6 +8,7 @@ <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../../vendor/magento/mtf/etc/variations.xsd"> <testCase name="Magento\Catalog\Test\TestCase\ProductAttribute\DeleteAttributeSetTest" summary="Delete Attribute Set (Attribute Set)" ticketId="MAGETWO-25473"> <variation name="DeleteAttributeSetTestVariation1"> + <data name="tag" xsi:type="string">stable:no</data> <data name="attributeSet/dataset" xsi:type="string">custom_attribute_set</data> <data name="attributeSet/data/assigned_attributes/dataset" xsi:type="string">default</data> <data name="product/dataset" xsi:type="string">default</data> diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/ProductAttribute/DeleteProductAttributeEntityTest.xml b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/ProductAttribute/DeleteProductAttributeEntityTest.xml index a11e2679b27e0860ba298008eaa48b9f2812fe01..83d819b7db1c4d6e0fc09d6209b0255c18f8f6c0 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/ProductAttribute/DeleteProductAttributeEntityTest.xml +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/ProductAttribute/DeleteProductAttributeEntityTest.xml @@ -15,6 +15,7 @@ <constraint name="Magento\ImportExport\Test\Constraint\AssertProductAttributeAbsenceForExport" /> </variation> <variation name="DeleteProductAttributeEntityTestVariation2"> + <data name="tag" xsi:type="string">stable:no</data> <data name="attribute/dataset" xsi:type="string">attribute_type_dropdown</data> <constraint name="Magento\Catalog\Test\Constraint\AssertProductAttributeSuccessDeleteMessage" /> <constraint name="Magento\Catalog\Test\Constraint\AssertProductAttributeAbsenceInGrid" /> diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/ProductAttribute/UpdateAttributeSetTest.xml b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/ProductAttribute/UpdateAttributeSetTest.xml index a7b233a7aae4b9d97f83638c80572d7f8888a9f1..ff80366fea097217450ad1d95eb4d0b5f4191944 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/ProductAttribute/UpdateAttributeSetTest.xml +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/ProductAttribute/UpdateAttributeSetTest.xml @@ -8,6 +8,7 @@ <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../../vendor/magento/mtf/etc/variations.xsd"> <testCase name="Magento\Catalog\Test\TestCase\ProductAttribute\UpdateAttributeSetTest" summary="Update Attribute Set" ticketId="MAGETWO-26251"> <variation name="UpdateAttributeSetTestVariation1"> + <data name="tag" xsi:type="string">stable:no</data> <data name="attributeSet/data/attribute_set_name" xsi:type="string">AttributeSetEdit1%isolation%</data> <data name="attributeSet/data/group" xsi:type="string">Custom-group%isolation%</data> <data name="attributeSetOriginal/dataset" xsi:type="string">custom_attribute_set</data> diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/ProductAttribute/UpdateProductAttributeEntityTest.xml b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/ProductAttribute/UpdateProductAttributeEntityTest.xml index b7e27854a82441e35328c31d0c81f2088cf50408..7077b8e852b5e06f7fa240be8a8e106f36686068 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/ProductAttribute/UpdateProductAttributeEntityTest.xml +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/ProductAttribute/UpdateProductAttributeEntityTest.xml @@ -8,6 +8,7 @@ <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../../vendor/magento/mtf/etc/variations.xsd"> <testCase name="Magento\Catalog\Test\TestCase\ProductAttribute\UpdateProductAttributeEntityTest" summary="Update Product Attribute" ticketId="MAGETWO-23459"> <variation name="UpdateProductAttributeEntityTestVariation1"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="attributeSet/dataset" xsi:type="string">custom_attribute_set</data> <data name="productAttributeOriginal/dataset" xsi:type="string">attribute_type_text_field</data> <data name="attribute/data/frontend_label" xsi:type="string">Text_Field_%isolation%</data> @@ -28,6 +29,7 @@ <constraint name="Magento\Catalog\Test\Constraint\AssertAddedProductAttributeOnProductForm" /> </variation> <variation name="UpdateProductAttributeEntityTestVariation2"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="attributeSet/dataset" xsi:type="string">custom_attribute_set</data> <data name="productAttributeOriginal/dataset" xsi:type="string">attribute_type_dropdown</data> <data name="attribute/data/frontend_label" xsi:type="string">Dropdown_%isolation%</data> @@ -60,6 +62,7 @@ <data name="cacheTags" xsi:type="array"> <item name="0" xsi:type="string">FPC</item> </data> + <data name="tag" xsi:type="string">to_maintain:yes</data> <constraint name="Magento\PageCache\Test\Constraint\AssertCacheIsRefreshableAndInvalidated" /> <constraint name="Magento\CatalogSearch\Test\Constraint\AssertAdvancedSearchProductByAttribute" /> </variation> diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/_files/test1.png b/dev/tests/functional/tests/app/Magento/Catalog/Test/_files/test1.png new file mode 100644 index 0000000000000000000000000000000000000000..3077df38da2ffab3378a630914803dfad59e7961 Binary files /dev/null and b/dev/tests/functional/tests/app/Magento/Catalog/Test/_files/test1.png differ diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/_files/test2.png b/dev/tests/functional/tests/app/Magento/Catalog/Test/_files/test2.png new file mode 100644 index 0000000000000000000000000000000000000000..3d219e6ee734b983a39e041a2386117a10d762be Binary files /dev/null and b/dev/tests/functional/tests/app/Magento/Catalog/Test/_files/test2.png differ diff --git a/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/TestCase/SuggestSearchingResultEntityTest.xml b/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/TestCase/SuggestSearchingResultEntityTest.xml index 9359b0c402b953ba1b8fcd2343b5ca84af3a764f..3a2f2f8aa7816a53d674c6c665b058afb1a4b720 100644 --- a/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/TestCase/SuggestSearchingResultEntityTest.xml +++ b/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/TestCase/SuggestSearchingResultEntityTest.xml @@ -8,11 +8,13 @@ <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/etc/variations.xsd"> <testCase name="Magento\CatalogSearch\Test\TestCase\SuggestSearchingResultEntityTest" summary="Suggest Searching Results" ticketId="MAGETWO-24671"> <variation name="SuggestSearchingResultEntityTestVariation1"> + <data name="tag" xsi:type="string">stable:no</data> <data name="catalogSearch/data/query_text/value" xsi:type="string">catalogProductSimple::name</data> <data name="catalogSearch/data/num_results" xsi:type="string">-</data> <constraint name="Magento\CatalogSearch\Test\Constraint\AssertSuggestSearchingResult" /> </variation> <variation name="SuggestSearchingResultEntityTestVariation2"> + <data name="tag" xsi:type="string">stable:no</data> <data name="catalogSearch/data/query_text/value" xsi:type="string">catalogProductSimple::sku</data> <data name="catalogSearch/data/num_results" xsi:type="string">1</data> <constraint name="Magento\CatalogSearch\Test\Constraint\AssertSuggestSearchingResult" /> diff --git a/dev/tests/functional/tests/app/Magento/Checkout/Test/TestCase/AddProductsToShoppingCartEntityTest.xml b/dev/tests/functional/tests/app/Magento/Checkout/Test/TestCase/AddProductsToShoppingCartEntityTest.xml index 30688723ae8edb8c83b761e89f2805f5dcdcd588..9a539d856e7082ae5131e903d7d86eec5f37d6c5 100644 --- a/dev/tests/functional/tests/app/Magento/Checkout/Test/TestCase/AddProductsToShoppingCartEntityTest.xml +++ b/dev/tests/functional/tests/app/Magento/Checkout/Test/TestCase/AddProductsToShoppingCartEntityTest.xml @@ -8,6 +8,7 @@ <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/etc/variations.xsd"> <testCase name="Magento\Checkout\Test\TestCase\AddProductsToShoppingCartEntityTest" summary="Add Products to Shopping Cart" ticketId="MAGETWO-25382"> <variation name="AddProductsToShoppingCartEntityTestVariation1"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="productsData/0" xsi:type="string">bundleProduct::bundle_dynamic_product</data> <data name="cart/data/grand_total" xsi:type="string">210</data> <data name="cart/data/subtotal" xsi:type="string">200</data> @@ -20,6 +21,7 @@ <constraint name="Magento\Checkout\Test\Constraint\AssertSubtotalInMiniShoppingCart" /> </variation> <variation name="AddProductsToShoppingCartEntityTestVariation2"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="productsData/0" xsi:type="string">bundleProduct::bundle_fixed_product</data> <data name="cart/data/grand_total" xsi:type="string">761</data> <data name="cart/data/subtotal" xsi:type="string">756</data> @@ -32,6 +34,7 @@ <constraint name="Magento\Checkout\Test\Constraint\AssertSubtotalInMiniShoppingCart" /> </variation> <variation name="AddProductsToShoppingCartEntityTestVariation3"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="productsData/0" xsi:type="string">catalogProductSimple::with_two_custom_option</data> <data name="cart/data/grand_total" xsi:type="string">345</data> <data name="cart/data/subtotal" xsi:type="string">340</data> @@ -44,6 +47,7 @@ <constraint name="Magento\Checkout\Test\Constraint\AssertSubtotalInMiniShoppingCart" /> </variation> <variation name="AddProductsToShoppingCartEntityTestVariation4"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="productsData/0" xsi:type="string">catalogProductVirtual::product_50_dollar</data> <data name="cart/data/grand_total" xsi:type="string">50</data> <data name="cart/data/subtotal" xsi:type="string">50</data> @@ -56,6 +60,7 @@ <constraint name="Magento\Checkout\Test\Constraint\AssertSubtotalInMiniShoppingCart" /> </variation> <variation name="AddProductsToShoppingCartEntityTestVariation5"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="productsData/0" xsi:type="string">configurableProduct::default</data> <data name="cart/data/grand_total" xsi:type="string">135</data> <data name="cart/data/subtotal" xsi:type="string">120</data> @@ -80,6 +85,7 @@ <constraint name="Magento\Checkout\Test\Constraint\AssertSubtotalInMiniShoppingCart" /> </variation> <variation name="AddProductsToShoppingCartEntityTestVariation7"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="productsData/0" xsi:type="string">groupedProduct::three_simple_products</data> <data name="cart/data/grand_total" xsi:type="string">1950</data> <data name="cart/data/subtotal" xsi:type="string">1920</data> @@ -92,6 +98,7 @@ <constraint name="Magento\Checkout\Test\Constraint\AssertSubtotalInMiniShoppingCart" /> </variation> <variation name="AddProductsToShoppingCartEntityTestVariation8"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="productsData/0" xsi:type="string">catalogProductSimple::with_two_custom_option</data> <data name="productsData/1" xsi:type="string">catalogProductVirtual::product_50_dollar</data> <data name="productsData/2" xsi:type="string">downloadableProduct::with_two_separately_links</data> diff --git a/dev/tests/functional/tests/app/Magento/Checkout/Test/TestCase/DeleteProductsFromShoppingCartTest.xml b/dev/tests/functional/tests/app/Magento/Checkout/Test/TestCase/DeleteProductsFromShoppingCartTest.xml index 2f2177c6cc7efcdf9c7e1df8f71b8b4ca7752188..033ea76a2a5ff17c5233d7f1b543f6b72f013c61 100644 --- a/dev/tests/functional/tests/app/Magento/Checkout/Test/TestCase/DeleteProductsFromShoppingCartTest.xml +++ b/dev/tests/functional/tests/app/Magento/Checkout/Test/TestCase/DeleteProductsFromShoppingCartTest.xml @@ -16,6 +16,7 @@ <constraint name="Magento\Checkout\Test\Constraint\AssertCartIsEmpty" /> </variation> <variation name="DeleteProductsFromShoppingCartTestVariation3"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="productsData/0" xsi:type="string">catalogProductSimple::with_two_custom_option</data> <constraint name="Magento\Checkout\Test\Constraint\AssertCartIsEmpty" /> </variation> @@ -36,6 +37,7 @@ <constraint name="Magento\Checkout\Test\Constraint\AssertCartIsEmpty" /> </variation> <variation name="DeleteProductsFromShoppingCartTestVariation8"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="productsData/0" xsi:type="string">catalogProductSimple::with_two_custom_option</data> <data name="productsData/1" xsi:type="string">catalogProductVirtual::product_50_dollar</data> <data name="productsData/2" xsi:type="string">downloadableProduct::with_two_separately_links</data> diff --git a/dev/tests/functional/tests/app/Magento/Checkout/Test/TestCase/OnePageCheckoutTest.xml b/dev/tests/functional/tests/app/Magento/Checkout/Test/TestCase/OnePageCheckoutTest.xml index 6a1f225bc9429e47b68ffb85bd06fc0443ebdbf9..797255d4e374acf001132647eee1121168ec0b50 100644 --- a/dev/tests/functional/tests/app/Magento/Checkout/Test/TestCase/OnePageCheckoutTest.xml +++ b/dev/tests/functional/tests/app/Magento/Checkout/Test/TestCase/OnePageCheckoutTest.xml @@ -27,6 +27,7 @@ <constraint name="Magento\Sales\Test\Constraint\AssertOrderGrandTotal" /> </variation> <variation name="OnePageCheckoutTestVariation2" summary="US customer during checkout using coupon for all customer groups"> + <data name="tag" xsi:type="string">stable:no</data> <data name="products/0" xsi:type="string">catalogProductSimple::default</data> <data name="salesRule" xsi:type="string">active_sales_rule_for_all_groups</data> <data name="customer/dataset" xsi:type="string">default</data> @@ -48,6 +49,7 @@ <constraint name="Magento\Sales\Test\Constraint\AssertOrderGrandTotal" /> </variation> <variation name="OnePageCheckoutTestVariation3" summary="Checkout as UK guest with simple product" ticketId="MAGETWO-42603"> + <data name="tag" xsi:type="string">stable:no</data> <data name="products/0" xsi:type="string">catalogProductSimple::default</data> <data name="customer/dataset" xsi:type="string">default</data> <data name="checkoutMethod" xsi:type="string">guest</data> @@ -167,6 +169,7 @@ <constraint name="Magento\Sales\Test\Constraint\AssertOrderGrandTotal" /> </variation> <variation name="OnePageCheckoutTestVariation9" summary="One Page Checkout Products with Tier Prices"> + <data name="tag" xsi:type="string">stable:no</data> <data name="products/0" xsi:type="string">catalogProductSimple::simple_with_tier_price_and_order_qty_3</data> <data name="customer/dataset" xsi:type="string">default</data> <data name="checkoutMethod" xsi:type="string">guest</data> @@ -183,6 +186,7 @@ <constraint name="Magento\Sales\Test\Constraint\AssertOrderGrandTotal" /> </variation> <variation name="OnePageCheckoutTestVariation10" summary="One Page Checkout with all product types"> + <data name="tag" xsi:type="string">stable:no</data> <data name="products/0" xsi:type="string">catalogProductVirtual::default</data> <data name="products/1" xsi:type="string">downloadableProduct::with_two_separately_links</data> <data name="products/2" xsi:type="string">configurableProduct::with_one_option</data> diff --git a/dev/tests/functional/tests/app/Magento/Checkout/Test/TestCase/UpdateProductFromMiniShoppingCartEntityTest.xml b/dev/tests/functional/tests/app/Magento/Checkout/Test/TestCase/UpdateProductFromMiniShoppingCartEntityTest.xml index 1c60b0f156bae087433d03ac12e84c733bb9258f..5f9b069ab85ca92d37ac8773ac3d1694e5d6ee81 100644 --- a/dev/tests/functional/tests/app/Magento/Checkout/Test/TestCase/UpdateProductFromMiniShoppingCartEntityTest.xml +++ b/dev/tests/functional/tests/app/Magento/Checkout/Test/TestCase/UpdateProductFromMiniShoppingCartEntityTest.xml @@ -8,14 +8,14 @@ <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/etc/variations.xsd"> <testCase name="Magento\Checkout\Test\TestCase\UpdateProductFromMiniShoppingCartEntityTest" summary="Update Product from Mini Shopping Cart" ticketId="MAGETWO-29812"> <variation name="UpdateProductFromMiniShoppingCartEntityTestVariation1" summary="Update Simple"> - <data name="tag" xsi:type="string">test_type:extended_acceptance_test</data> + <data name="tag" xsi:type="string">test_type:extended_acceptance_test, to_maintain:yes</data> <data name="originalProduct/0" xsi:type="string">catalogProductSimple::with_two_custom_option</data> <data name="checkoutData/dataset" xsi:type="string">simple_update_mini_shopping_cart</data> <constraint name="Magento\Checkout\Test\Constraint\AssertProductDataInMiniShoppingCart" /> <constraint name="Magento\Checkout\Test\Constraint\AssertProductQtyInShoppingCart" /> </variation> <variation name="UpdateProductFromMiniShoppingCartEntityTestVariation2" summary="Update Configurable and verify previous product was updated to new one in shopping cart and mini shopping cart"> - <data name="tag" xsi:type="string">test_type:extended_acceptance_test</data> + <data name="tag" xsi:type="string">test_type:extended_acceptance_test, to_maintain:yes</data> <data name="originalProduct/0" xsi:type="string">configurableProduct::default</data> <data name="checkoutData/dataset" xsi:type="string">configurable_update_mini_shopping_cart</data> <constraint name="Magento\Checkout\Test\Constraint\AssertCartItemsOptions" /> @@ -24,7 +24,7 @@ <constraint name="Magento\Checkout\Test\Constraint\AssertProductOptionsAbsentInShoppingCart" /> </variation> <variation name="UpdateProductFromMiniShoppingCartEntityTestVariation3" summary="Update Bundle and verify previous product was updated to new one in shopping cart and mini shopping cart"> - <data name="tag" xsi:type="string">test_type:extended_acceptance_test</data> + <data name="tag" xsi:type="string">test_type:extended_acceptance_test, to_maintain:yes</data> <data name="originalProduct/0" xsi:type="string">bundleProduct::bundle_fixed_product</data> <data name="checkoutData/dataset" xsi:type="string">bundle_update_mini_shopping_cart</data> <constraint name="Magento\Checkout\Test\Constraint\AssertCartItemsOptions" /> @@ -33,7 +33,7 @@ <constraint name="Magento\Checkout\Test\Constraint\AssertProductOptionsAbsentInShoppingCart" /> </variation> <variation name="UpdateProductFromMiniShoppingCartEntityTestVariation4" summary="Update Downloadable and check previous link was updated to new one in shopping cart and mini shopping cart"> - <data name="tag" xsi:type="string">test_type:extended_acceptance_test</data> + <data name="tag" xsi:type="string">test_type:extended_acceptance_test, to_maintain:yes</data> <data name="originalProduct/0" xsi:type="string">downloadableProduct::with_two_separately_links</data> <data name="checkoutData/dataset" xsi:type="string">downloadable_update_mini_shopping_cart</data> <constraint name="Magento\Checkout\Test\Constraint\AssertCartItemsOptions" /> @@ -42,7 +42,7 @@ <constraint name="Magento\Checkout\Test\Constraint\AssertProductOptionsAbsentInShoppingCart" /> </variation> <variation name="UpdateProductFromMiniShoppingCartEntityTestVariation5" summary="Update Virtual product in mini shopping cart"> - <data name="tag" xsi:type="string">test_type:extended_acceptance_test</data> + <data name="tag" xsi:type="string">test_type:extended_acceptance_test, to_maintain:yes</data> <data name="originalProduct/0" xsi:type="string">catalogProductVirtual::default</data> <data name="checkoutData/dataset" xsi:type="string">virtual_update_mini_shopping_cart</data> <constraint name="Magento\Checkout\Test\Constraint\AssertProductDataInMiniShoppingCart" /> diff --git a/dev/tests/functional/tests/app/Magento/Checkout/Test/TestCase/UpdateShoppingCartTest.php b/dev/tests/functional/tests/app/Magento/Checkout/Test/TestCase/UpdateShoppingCartTest.php index 809688cd8286a0afdc68ef3d236a6b1673b1c66b..3dba57e26e003726e856577f5e4b48a427428a24 100644 --- a/dev/tests/functional/tests/app/Magento/Checkout/Test/TestCase/UpdateShoppingCartTest.php +++ b/dev/tests/functional/tests/app/Magento/Checkout/Test/TestCase/UpdateShoppingCartTest.php @@ -33,6 +33,7 @@ class UpdateShoppingCartTest extends Injectable { /* tags */ const MVP = 'yes'; + const STABLE = 'no'; /* end tags */ /** diff --git a/dev/tests/functional/tests/app/Magento/Cms/Test/TestCase/DeleteCmsBlockEntityTest.xml b/dev/tests/functional/tests/app/Magento/Cms/Test/TestCase/DeleteCmsBlockEntityTest.xml index fc043effe5a77682ef1a30307350ad72aab8401b..34c70c9e2a33bea3418e394a241a1d87d48ee27a 100644 --- a/dev/tests/functional/tests/app/Magento/Cms/Test/TestCase/DeleteCmsBlockEntityTest.xml +++ b/dev/tests/functional/tests/app/Magento/Cms/Test/TestCase/DeleteCmsBlockEntityTest.xml @@ -8,7 +8,7 @@ <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/etc/variations.xsd"> <testCase name="Magento\Cms\Test\TestCase\DeleteCmsBlockEntityTest" summary="Delete CMS Block" ticketId="MAGETWO-25698"> <variation name="DeleteCmsBlockEntityTestVariation1"> - <data name="tag" xsi:type="string">severity:S1</data> + <data name="tag" xsi:type="string">severity:S1, stable:no</data> <constraint name="Magento\Cms\Test\Constraint\AssertCmsBlockDeleteMessage" /> <constraint name="Magento\Cms\Test\Constraint\AssertCmsBlockNotInGrid" /> <constraint name="Magento\Cms\Test\Constraint\AssertCmsBlockNotOnCategoryPage" /> diff --git a/dev/tests/functional/tests/app/Magento/Cms/Test/TestCase/DeleteCmsPageEntityTest.xml b/dev/tests/functional/tests/app/Magento/Cms/Test/TestCase/DeleteCmsPageEntityTest.xml index 2a85425890e8e455a4ba6e32960f6d329bfcdf5b..745d60dad9f8ac8c67d891e84e33e502db1b6659 100644 --- a/dev/tests/functional/tests/app/Magento/Cms/Test/TestCase/DeleteCmsPageEntityTest.xml +++ b/dev/tests/functional/tests/app/Magento/Cms/Test/TestCase/DeleteCmsPageEntityTest.xml @@ -8,7 +8,7 @@ <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/etc/variations.xsd"> <testCase name="Magento\Cms\Test\TestCase\DeleteCmsPageEntityTest" summary="Delete CMS Page" ticketId="MAGETWO-23291"> <variation name="DeleteCmsPageEntityTestVariation1"> - <data name="tag" xsi:type="string">severity:S1</data> + <data name="tag" xsi:type="string">severity:S1, stable:no</data> <data name="cmsPage/dataset" xsi:type="string">default</data> <constraint name="Magento\Cms\Test\Constraint\AssertCmsPageDeleteMessage" /> <constraint name="Magento\Cms\Test\Constraint\AssertCmsPageNotInGrid" /> diff --git a/dev/tests/functional/tests/app/Magento/Cms/Test/TestCase/GridFullTextSearchTest.xml b/dev/tests/functional/tests/app/Magento/Cms/Test/TestCase/GridFullTextSearchTest.xml index 893cfc2f0dacc75f92b31b3a14fcc54a41aaf6b5..fc279aad59d3d7e21590be2c256f83831e7295cf 100644 --- a/dev/tests/functional/tests/app/Magento/Cms/Test/TestCase/GridFullTextSearchTest.xml +++ b/dev/tests/functional/tests/app/Magento/Cms/Test/TestCase/GridFullTextSearchTest.xml @@ -8,7 +8,7 @@ <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/etc/variations.xsd"> <testCase name="Magento\Ui\Test\TestCase\GridFullTextSearchTest" summary="Grid UI Component Full Text Search" ticketId="MAGETWO-41023"> <variation name="CmsPageGridFullTextSearch"> - <data name="tag" xsi:type="string">severity:S2</data> + <data name="tag" xsi:type="string">severity:S2, stable:no</data> <data name="description" xsi:type="string">Verify cms page grid full text search</data> <data name="itemsCount" xsi:type="string">2</data> <data name="fixtureName" xsi:type="string">cmsPage</data> diff --git a/dev/tests/functional/tests/app/Magento/Cms/Test/TestCase/GridSortingTest.xml b/dev/tests/functional/tests/app/Magento/Cms/Test/TestCase/GridSortingTest.xml index d6467a53e15659a1e5859002c04be6ad3e91b3e3..1be7e61f6bd0ea27a99733a63828f438ab481215 100644 --- a/dev/tests/functional/tests/app/Magento/Cms/Test/TestCase/GridSortingTest.xml +++ b/dev/tests/functional/tests/app/Magento/Cms/Test/TestCase/GridSortingTest.xml @@ -8,7 +8,7 @@ <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/etc/variations.xsd"> <testCase name="Magento\Ui\Test\TestCase\GridSortingTest" summary="Grid UI Component Sorting" ticketId="MAGETWO-41328"> <variation name="CmsPagesGridSorting"> - <data name="tag" xsi:type="string">severity:S2</data> + <data name="tag" xsi:type="string">severity:S2, stable:no</data> <data name="description" xsi:type="string">Verify cms page grid sorting</data> <data name="columnsForSorting" xsi:type="array"> <item name="id" xsi:type="string">ID</item> @@ -19,7 +19,7 @@ <constraint name="Magento\Ui\Test\Constraint\AssertGridSorting"/> </variation> <variation name="CmsBlocksGridSorting"> - <data name="tag" xsi:type="string">severity:S2</data> + <data name="tag" xsi:type="string">severity:S2, stable:no</data> <data name="description" xsi:type="string">Verify cms blocks grid sorting</data> <data name="steps" xsi:type="array"> <item name="0" xsi:type="string">-</item> diff --git a/dev/tests/functional/tests/app/Magento/Cms/Test/TestCase/UpdateCmsPageEntityTest.xml b/dev/tests/functional/tests/app/Magento/Cms/Test/TestCase/UpdateCmsPageEntityTest.xml index 75f8cf63f645e333e001ba26ef940f62ae95581c..93d38321ab7db4c2fa8fcda830022a8c52970e14 100644 --- a/dev/tests/functional/tests/app/Magento/Cms/Test/TestCase/UpdateCmsPageEntityTest.xml +++ b/dev/tests/functional/tests/app/Magento/Cms/Test/TestCase/UpdateCmsPageEntityTest.xml @@ -8,7 +8,7 @@ <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/etc/variations.xsd"> <testCase name="Magento\Cms\Test\TestCase\UpdateCmsPageEntityTest" summary="Update Cms Page" ticketId="MAGETWO-25186"> <variation name="UpdateCmsPageEntityTestVariation1"> - <data name="tag" xsi:type="string">severity:S3</data> + <data name="tag" xsi:type="string">severity:S3, to_maintain:yes</data> <data name="cms/data/title" xsi:type="string">CmsPageEdited%isolation%</data> <data name="cms/data/is_active" xsi:type="string">No</data> <data name="cms/data/content/content" xsi:type="string">cms_page_text_content_after_edit</data> @@ -16,7 +16,7 @@ <constraint name="Magento\Cms\Test\Constraint\AssertCmsPageDisabledOnFrontend" /> </variation> <variation name="UpdateCmsPageEntityTestVariation2"> - <data name="tag" xsi:type="string">severity:S1</data> + <data name="tag" xsi:type="string">severity:S1, to_maintain:yes</data> <data name="cms/data/title" xsi:type="string">CmsPageEdited%isolation%</data> <data name="cms/data/identifier" xsi:type="string">cms_page_url_edited_%isolation%</data> <data name="cms/data/content_heading" xsi:type="string">Content Heading TextEdited</data> diff --git a/dev/tests/functional/tests/app/Magento/Config/Test/TestCase/VerifyAdminAccountSharingEntityTest.php b/dev/tests/functional/tests/app/Magento/Config/Test/TestCase/VerifyAdminAccountSharingEntityTest.php index 30928810490d770c5ea8309748b07aeabf45314a..5df648a565dc7040c24e43d8b35bad5859a3b200 100644 --- a/dev/tests/functional/tests/app/Magento/Config/Test/TestCase/VerifyAdminAccountSharingEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Config/Test/TestCase/VerifyAdminAccountSharingEntityTest.php @@ -23,13 +23,14 @@ class VerifyAdminAccountSharingEntityTest extends Injectable /* tags */ const MVP = 'yes'; const DOMAIN = 'PS'; + const TO_MAINTAIN = 'yes'; const TEST_TYPE = 'extended_acceptance_test'; /* end tags */ /** * Admin account settings page. * - * @var adminAccountSharing + * @var AdminAccountSharing */ private $adminAccountSharing; diff --git a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/TestCase/CreateConfigurableProductEntityTest.xml b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/TestCase/CreateConfigurableProductEntityTest.xml index 187283da4602fd56c6fb6f2441d11dc5c1ad05bd..14ff24f18908da187a0631662cf74bfdaad5db6f 100644 --- a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/TestCase/CreateConfigurableProductEntityTest.xml +++ b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/TestCase/CreateConfigurableProductEntityTest.xml @@ -8,6 +8,7 @@ <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/etc/variations.xsd"> <testCase name="Magento\ConfigurableProduct\Test\TestCase\CreateConfigurableProductEntityTest" summary="Create Configurable Product" ticketId="MAGETWO-26041"> <variation name="CreateConfigurableProductEntityTestVariation1" summary="Create product with category and two new options"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="product/data/url_key" xsi:type="string">configurable-product-%isolation%</data> <data name="product/data/configurable_attributes_data/dataset" xsi:type="string">two_new_options</data> <data name="product/data/checkout_data/dataset" xsi:type="string">configurable_two_options</data> @@ -32,6 +33,7 @@ <constraint name="Magento\ConfigurableProduct\Test\Constraint\AssertChildProductIsNotDisplayedSeparately"/> </variation> <variation name="CreateConfigurableProductEntityTestVariation2" summary="Create product with two options"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="product/data/url_key" xsi:type="string">configurable-product-%isolation%</data> <data name="product/data/configurable_attributes_data/dataset" xsi:type="string">two_options</data> <data name="product/data/checkout_data/dataset" xsi:type="string">configurable_two_options</data> @@ -53,6 +55,7 @@ <constraint name="Magento\ConfigurableProduct\Test\Constraint\AssertConfigurableProductInCart" /> </variation> <variation name="CreateConfigurableProductEntityTestVariation3" summary="Create product with special price"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="product/data/url_key" xsi:type="string">configurable-product-%isolation%</data> <data name="product/data/configurable_attributes_data/dataset" xsi:type="string">two_options_with_assigned_product_special_price</data> <data name="product/data/checkout_data/dataset" xsi:type="string">configurable_two_new_options_with_special_price</data> @@ -75,6 +78,7 @@ <constraint name="Magento\Catalog\Test\Constraint\AssertProductSpecialPriceOnProductPage" /> </variation> <variation name="CreateConfigurableProductEntityTestVariation4" summary="Create product with assigned products to options"> + <data name="tag" xsi:type="string">stable:no</data> <data name="product/data/url_key" xsi:type="string">configurable-product-%isolation%</data> <data name="product/data/configurable_attributes_data/dataset" xsi:type="string">two_options_with_assigned_product</data> <data name="product/data/checkout_data/dataset" xsi:type="string">configurable_two_options_with_assigned_product</data> @@ -95,6 +99,7 @@ <constraint name="Magento\ConfigurableProduct\Test\Constraint\AssertConfigurableProductInCart" /> </variation> <variation name="CreateConfigurableProductEntityTestVariation5" summary="Create Configurable Product and Assign it to Category" ticketId="MAGETWO-12620"> + <data name="tag" xsi:type="string">stable:no</data> <data name="product/data/url_key" xsi:type="string">configurable-product-%isolation%</data> <data name="product/data/configurable_attributes_data/dataset" xsi:type="string">two_options_with_fixed_price</data> <data name="product/data/name" xsi:type="string">Configurable Product %isolation%</data> @@ -143,6 +148,7 @@ <constraint name="Magento\Catalog\Test\Constraint\AssertProductAutoincrementedSkuNoticeMessage" /> </variation> <variation name="CreateConfigurableProductEntityTestVariation9" summary="Create configurable product and assign it to custom website"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="product/data/url_key" xsi:type="string">configurable-product-%isolation%</data> <data name="product/data/configurable_attributes_data/dataset" xsi:type="string">two_options_with_assigned_product_special_price</data> <data name="product/data/checkout_data/dataset" xsi:type="string">configurable_two_new_options_with_special_price</data> diff --git a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/TestCase/DuplicateProductEntityTest.xml b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/TestCase/DuplicateProductEntityTest.xml index 62279a9fa579c99b8fce18ca6c39279834ce22c6..b069371fe5bec2aa39ea7c5ce6c7a3e6eb1d8977 100644 --- a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/TestCase/DuplicateProductEntityTest.xml +++ b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/TestCase/DuplicateProductEntityTest.xml @@ -8,6 +8,7 @@ <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/etc/variations.xsd"> <testCase name="Magento\Catalog\Test\TestCase\Product\DuplicateProductEntityTest"> <variation name="DuplicateProductEntityTestVariation2" firstConstraint="Magento\Catalog\Test\Constraint\AssertProductSaveMessage" method="test"> + <data name="tag" xsi:type="string">stable:no</data> <data name="productType" xsi:type="string">configurableProduct::default</data> <constraint name="Magento\Catalog\Test\Constraint\AssertProductSaveMessage" next="Magento\Catalog\Test\Constraint\AssertProductDuplicateMessage" /> <constraint name="Magento\Catalog\Test\Constraint\AssertProductDuplicateMessage" next="Magento\ConfigurableProduct\Test\Constraint\AssertConfigurableProductDuplicateForm" /> diff --git a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/TestCase/MassProductUpdateTest.xml b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/TestCase/MassProductUpdateTest.xml index 3d58645d618ffe4f34beb84cd3a1d58212649148..d1066de26d66c608bc96198585bb8a92112b3fbf 100644 --- a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/TestCase/MassProductUpdateTest.xml +++ b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/TestCase/MassProductUpdateTest.xml @@ -8,6 +8,7 @@ <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/etc/variations.xsd"> <testCase name="Magento\Catalog\Test\TestCase\Product\MassProductUpdateTest" summary="Edit Products Using Mass Actions" ticketId="MAGETWO-21128"> <variation name="MassProductUpdateTestVariation2" summary="Update stock data for simple and configurable"> + <data name="tag" xsi:type="string">stable:no</data> <data name="configData" xsi:type="string">product_flat</data> <data name="initialProducts/1" xsi:type="string">configurableProduct::out_of_stock</data> <data name="initialProducts/0" xsi:type="string">catalogProductSimple::out_of_stock</data> diff --git a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/TestCase/UpdateConfigurableProductEntityTest.php b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/TestCase/UpdateConfigurableProductEntityTest.php index 7ff2be303d677a944e5c2391a509882ecb7d3e96..d3ab2ffa6b026e0ec0fe8d0d93655a49193e6127 100644 --- a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/TestCase/UpdateConfigurableProductEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/TestCase/UpdateConfigurableProductEntityTest.php @@ -32,6 +32,7 @@ class UpdateConfigurableProductEntityTest extends Scenario { /* tags */ const MVP = 'yes'; + const TO_MAINTAIN = 'yes'; /* end tags */ /** diff --git a/dev/tests/functional/tests/app/Magento/CurrencySymbol/Test/TestCase/AbstractCurrencySymbolEntityTest.php b/dev/tests/functional/tests/app/Magento/CurrencySymbol/Test/TestCase/AbstractCurrencySymbolEntityTest.php index 4919d364dc6fa07592556bc66674588ec84589c0..ac6b26e85fbeb23e9a04c8a8b709e57da3b696ee 100644 --- a/dev/tests/functional/tests/app/Magento/CurrencySymbol/Test/TestCase/AbstractCurrencySymbolEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/CurrencySymbol/Test/TestCase/AbstractCurrencySymbolEntityTest.php @@ -97,7 +97,7 @@ abstract class AbstractCurrencySymbolEntityTest extends Injectable $this->currencyIndex->getCurrencyRateForm()->clickImportButton(); $this->currencyIndex->getCurrencyRateForm()->fillCurrencyUSDUAHRate(); if ($this->currencyIndex->getMessagesBlock()->isVisibleMessage('warning')) { - throw new \Exception($this->currencyIndex->getMessagesBlock()->getWarningMessages()); + throw new \Exception($this->currencyIndex->getMessagesBlock()->getWarningMessage()); } $this->currencyIndex->getFormPageActions()->save(); } diff --git a/dev/tests/functional/tests/app/Magento/CurrencySymbol/Test/TestCase/EditCurrencySymbolEntityTest.php b/dev/tests/functional/tests/app/Magento/CurrencySymbol/Test/TestCase/EditCurrencySymbolEntityTest.php index 14a9d6f283b278228f178f4f3a14ffbe7786aceb..302f23104d959119f125fb6ab3b82b78078efa3d 100644 --- a/dev/tests/functional/tests/app/Magento/CurrencySymbol/Test/TestCase/EditCurrencySymbolEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/CurrencySymbol/Test/TestCase/EditCurrencySymbolEntityTest.php @@ -27,6 +27,7 @@ class EditCurrencySymbolEntityTest extends AbstractCurrencySymbolEntityTest { /* tags */ const MVP = 'no'; + const TO_MAINTAIN = 'yes'; /* end tags */ /** diff --git a/dev/tests/functional/tests/app/Magento/CurrencySymbol/Test/TestCase/ResetCurrencySymbolEntityTest.php b/dev/tests/functional/tests/app/Magento/CurrencySymbol/Test/TestCase/ResetCurrencySymbolEntityTest.php index 8740b0000ff58324787941a92213528b6c24d11d..e49f25bc4fa181ffce4e442e1dbda485b8c5a76b 100644 --- a/dev/tests/functional/tests/app/Magento/CurrencySymbol/Test/TestCase/ResetCurrencySymbolEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/CurrencySymbol/Test/TestCase/ResetCurrencySymbolEntityTest.php @@ -28,6 +28,7 @@ class ResetCurrencySymbolEntityTest extends AbstractCurrencySymbolEntityTest { /* tags */ const MVP = 'no'; + const TO_MAINTAIN = 'yes'; /* end tags */ /** diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Repository/Address.xml b/dev/tests/functional/tests/app/Magento/Customer/Test/Repository/Address.xml index 9802ef998048a8f9cfb8914b7288c4f119a667d1..70191dc828af7aecada34068c5d0e93cce4736ee 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Repository/Address.xml +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Repository/Address.xml @@ -61,8 +61,8 @@ <field name="postcode" xsi:type="string">90230</field> <field name="country_id" xsi:type="string">United States</field> <field name="telephone" xsi:type="string">555-55-555-55</field> - <field name="default_billing" xsi:type="string">Yes</field> - <field name="default_shipping" xsi:type="string">No</field> + <field name="default_billing" xsi:type="string">No</field> + <field name="default_shipping" xsi:type="string">Yes</field> </dataset> <dataset name="US_address_1"> diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/CreateCustomerBackendEntityTest.xml b/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/CreateCustomerBackendEntityTest.xml index 14e3a9642d1a5d649536d0b84070c8ae3e9210a6..766cf96b3d6447029384715ea57e06bf21dda1e8 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/CreateCustomerBackendEntityTest.xml +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/CreateCustomerBackendEntityTest.xml @@ -19,6 +19,7 @@ <constraint name="Magento\Customer\Test\Constraint\AssertCustomerForm" /> </variation> <variation name="CreateCustomerBackendEntityTestVariation2" summary="Customer with prefix"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="customerAction" xsi:type="string">save</data> <data name="customer/data/group_id/dataset" xsi:type="string">Wholesale</data> <data name="customer/data/prefix" xsi:type="string">M</data> @@ -92,6 +93,7 @@ <constraint name="Magento\Customer\Test\Constraint\AssertCustomerBackendFormTitle" /> </variation> <variation name="CreateCustomerBackendEntityTestVariation7" summary="Create customer with custom customer group"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="customerAction" xsi:type="string">saveAndContinue</data> <data name="customer/data/website_id" xsi:type="string">Main Website</data> <data name="customer/data/group_id/dataset" xsi:type="string">customer_group_retail_customer</data> @@ -131,6 +133,7 @@ <constraint name="Magento\Customer\Test\Constraint\AssertCustomerBackendRequiredFields" /> </variation> <variation name="CreateCustomerBackendEntityTestVariation10" summary="Create customer with 2 websites and with different allowed countries."> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="customerAction" xsi:type="string">save</data> <data name="customer/data/website_id" xsi:type="string">Main Website</data> <data name="customer/data/group_id/dataset" xsi:type="string">General</data> diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/CreateCustomerGroupEntityTest.php b/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/CreateCustomerGroupEntityTest.php index 64051195daa32a808536adb8afaa6a5100c51ce6..c354e733a6913263d3b2ea1cb72d63bb7434c9a2 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/CreateCustomerGroupEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/CreateCustomerGroupEntityTest.php @@ -29,6 +29,7 @@ class CreateCustomerGroupEntityTest extends Injectable { /* tags */ const MVP = 'yes'; + const STABLE = 'no'; /* end tags */ /** diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/DeleteCustomerAddressTest.php b/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/DeleteCustomerAddressTest.php index 61771665c059ed1783c3e3820a8005601d91e631..1f00df69dfb578e552429ccdeb43a02254951d95 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/DeleteCustomerAddressTest.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/DeleteCustomerAddressTest.php @@ -30,6 +30,7 @@ class DeleteCustomerAddressTest extends Injectable { /* tags */ const MVP = 'yes'; + const STABLE = 'no'; /* end tags */ /** diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/GridSortingTest.xml b/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/GridSortingTest.xml index 18791441b1d20754360d80d7757bffe922d6c40e..b967fbd184526fd1d71fcf2055799842d0d018f1 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/GridSortingTest.xml +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/GridSortingTest.xml @@ -8,6 +8,7 @@ <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/etc/variations.xsd"> <testCase name="Magento\Ui\Test\TestCase\GridSortingTest" summary="Grid UI Component Sorting" ticketId="MAGETWO-41328"> <variation name="CustomerGridSorting"> + <data name="tag" xsi:type="string">stable:no</data> <data name="description" xsi:type="string">Verify customer page grid sorting</data> <data name="columnsForSorting" xsi:type="array"> <item name="id" xsi:type="string">ID</item> diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/MassAssignCustomerGroupTest.xml b/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/MassAssignCustomerGroupTest.xml index e86104e992deebf2b925e8a67b3346be7a6e2907..af57affcd7f07bf42182f444b16fc85ffe274ade 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/MassAssignCustomerGroupTest.xml +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/MassAssignCustomerGroupTest.xml @@ -8,7 +8,7 @@ <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/etc/variations.xsd"> <testCase name="Magento\Customer\Test\TestCase\MassAssignCustomerGroupTest" summary="Mass Assign Customer's Group to Customers" ticketId="MAGETWO-27892"> <variation name="MassAssignCustomerGroupTestVariation1"> - <data name="tag" xsi:type="string">test_type:extended_acceptance_test</data> + <data name="tag" xsi:type="string">test_type:extended_acceptance_test, to_maintain:yes</data> <data name="customerGroup/dataset" xsi:type="string">default</data> <constraint name="Magento\Customer\Test\Constraint\AssertMassActionSuccessUpdateMessage" /> <constraint name="Magento\Customer\Test\Constraint\AssertCustomerGroupInGrid" /> diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/MassDeleteCustomerBackendEntityTest.xml b/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/MassDeleteCustomerBackendEntityTest.xml index 2985252d82ffae55c5a932927623ecf7cf470aa3..cdbfd91ddbd49dddc040569252bb1a988c262a5c 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/MassDeleteCustomerBackendEntityTest.xml +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/MassDeleteCustomerBackendEntityTest.xml @@ -8,6 +8,7 @@ <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/etc/variations.xsd"> <testCase name="Magento\Customer\Test\TestCase\MassDeleteCustomerBackendEntityTest" summary="Customer Mass Delete" ticketId="MAGETWO-26848"> <variation name="MassDeleteCustomerBackendEntityTestVariation1"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="customer/dataset" xsi:type="string">default</data> <data name="customersQty" xsi:type="string">3</data> <data name="customersQtyToDelete" xsi:type="string">2</data> diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/RegisterCustomerFrontendEntityTest.xml b/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/RegisterCustomerFrontendEntityTest.xml index 31a947ad1ab02771464cdf9f8cd93f01f2451718..96e78f58d78c8402a133184b633614e4e4fd20c7 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/RegisterCustomerFrontendEntityTest.xml +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/RegisterCustomerFrontendEntityTest.xml @@ -8,6 +8,7 @@ <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/etc/variations.xsd"> <testCase name="Magento\Customer\Test\TestCase\RegisterCustomerFrontendEntityTest" summary="Register New Customer" ticketId="MAGETWO-23546"> <variation name="RegisterCustomerFrontendEntityTestVariation1" summary="Register new customer"> + <data name="tag" xsi:type="string">stable:no</data> <data name="customer/data/firstname" xsi:type="string">john</data> <data name="customer/data/lastname" xsi:type="string">doe</data> <data name="customer/data/email" xsi:type="string">johndoe%isolation%@example.com</data> diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/UpdateCustomerBackendEntityTest.xml b/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/UpdateCustomerBackendEntityTest.xml index c2132672d900a65fe81b3f011266d036cd390e91..7855fb0f17dd2d709a383722475ec1e95fbfa737 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/UpdateCustomerBackendEntityTest.xml +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/UpdateCustomerBackendEntityTest.xml @@ -8,6 +8,7 @@ <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/etc/variations.xsd"> <testCase name="Magento\Customer\Test\TestCase\UpdateCustomerBackendEntityTest" summary="Update Backend Customer" ticketId="MAGETWO-23881"> <variation name="UpdateCustomerBackendEntityTestVariation1"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="initialCustomer/dataset" xsi:type="string">default</data> <data name="customer/data/group_id/dataset" xsi:type="string">Wholesale</data> <data name="customer/data/prefix" xsi:type="string">%isolation%Prefix_</data> @@ -44,6 +45,7 @@ <constraint name="Magento\Customer\Test\Constraint\AssertCustomerInGrid" /> </variation> <variation name="UpdateCustomerBackendEntityTestVariation3" summary="Address with alphanumeric zip"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="initialCustomer/dataset" xsi:type="string">default</data> <data name="customer/data/group_id/dataset" xsi:type="string">Retailer</data> <data name="customer/data/prefix" xsi:type="string">%isolation%Prefix_</data> diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/UpdateCustomerGroupEntityTest.php b/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/UpdateCustomerGroupEntityTest.php index 7fda95c0be7d2e48e58cb2a01317704cc54a0b57..bd21e9aca690525910b5500e69e6b5913449d2e5 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/UpdateCustomerGroupEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/UpdateCustomerGroupEntityTest.php @@ -32,6 +32,7 @@ class UpdateCustomerGroupEntityTest extends Injectable { /* tags */ const MVP = 'yes'; + const TO_MAINTAIN = 'yes'; /* end tags */ /** diff --git a/dev/tests/functional/tests/app/Magento/Downloadable/Test/TestCase/CreateDownloadableProductEntityTest.xml b/dev/tests/functional/tests/app/Magento/Downloadable/Test/TestCase/CreateDownloadableProductEntityTest.xml index e2f49d40cac7395734acc42783f5fce6b0c74083..9d12218ccf0dddf72b15a21db85e6c211848f0b8 100644 --- a/dev/tests/functional/tests/app/Magento/Downloadable/Test/TestCase/CreateDownloadableProductEntityTest.xml +++ b/dev/tests/functional/tests/app/Magento/Downloadable/Test/TestCase/CreateDownloadableProductEntityTest.xml @@ -24,6 +24,7 @@ <constraint name="Magento\Catalog\Test\Constraint\AssertProductInCart" /> </variation> <variation name="CreateDownloadableProductEntityTestVariation2"> + <data name="tag" xsi:type="string">stable:no</data> <data name="description" xsi:type="string">Create product with default set links</data> <data name="product/data/name" xsi:type="string">DownloadableProduct_%isolation%</data> <data name="product/data/sku" xsi:type="string">DownloadableProduct_%isolation%</data> @@ -53,6 +54,7 @@ <data name="product/data/downloadable_sample/dataset" xsi:type="string">with_two_samples</data> <data name="product/data/downloadable_links/dataset" xsi:type="string">with_two_separately_links</data> <data name="product/data/url_key" xsi:type="string">downloadableproduct-%isolation%</data> + <data name="tag" xsi:type="string">to_maintain:yes</data> <constraint name="Magento\Catalog\Test\Constraint\AssertProductSaveMessage" /> <constraint name="Magento\Catalog\Test\Constraint\AssertProductInGrid" /> <constraint name="Magento\Downloadable\Test\Constraint\AssertDownloadableProductForm" /> @@ -91,6 +93,7 @@ <data name="product/data/downloadable_links/dataset" xsi:type="string">with_three_links</data> <data name="product/data/custom_options/dataset" xsi:type="string">two_options</data> <data name="product/data/url_key" xsi:type="string">downloadableproduct-%isolation%</data> + <data name="tag" xsi:type="string">to_maintain:yes</data> <constraint name="Magento\Catalog\Test\Constraint\AssertProductSaveMessage" /> <constraint name="Magento\Catalog\Test\Constraint\AssertProductCustomOptionsOnProductPage" /> <constraint name="Magento\Catalog\Test\Constraint\AssertProductInGrid" /> @@ -118,6 +121,7 @@ <constraint name="Magento\Downloadable\Test\Constraint\AssertDownloadableProductForm" /> </variation> <variation name="CreateDownloadableProductEntityTestVariation7"> + <data name="tag" xsi:type="string">stable:no</data> <data name="description" xsi:type="string">Create product with manage stock</data> <data name="product/data/name" xsi:type="string">DownloadableProduct_%isolation%</data> <data name="product/data/sku" xsi:type="string">DownloadableProduct_%isolation%</data> @@ -135,6 +139,7 @@ <constraint name="Magento\Catalog\Test\Constraint\AssertProductOutOfStock" /> </variation> <variation name="CreateDownloadableProductEntityTestVariation8"> + <data name="tag" xsi:type="string">stable:no</data> <data name="description" xsi:type="string">Create product without tax class id</data> <data name="product/data/name" xsi:type="string">DownloadableProduct_%isolation%</data> <data name="product/data/sku" xsi:type="string">DownloadableProduct_%isolation%</data> @@ -166,6 +171,7 @@ <data name="product/data/custom_options/dataset" xsi:type="string">default</data> <data name="product/data/custom_options/import_products" xsi:type="string">catalogProductSimple::with_two_custom_option,catalogProductSimple::with_all_custom_option</data> <data name="product/data/url_key" xsi:type="string">downloadableproduct-%isolation%</data> + <data name="tag" xsi:type="string">to_maintain:yes</data> <constraint name="Magento\Catalog\Test\Constraint\AssertProductSaveMessage" /> <constraint name="Magento\Catalog\Test\Constraint\AssertProductInGrid" /> <constraint name="Magento\Downloadable\Test\Constraint\AssertDownloadableProductForm" /> @@ -189,6 +195,7 @@ <data name="product/data/downloadable_links/dataset" xsi:type="string">with_three_links</data> <data name="product/data/custom_options/dataset" xsi:type="string">default</data> <data name="product/data/url_key" xsi:type="string">downloadableproduct-%isolation%</data> + <data name="tag" xsi:type="string">to_maintain:yes</data> <constraint name="Magento\Catalog\Test\Constraint\AssertProductSaveMessage" /> <constraint name="Magento\Catalog\Test\Constraint\AssertProductPage" /> <constraint name="Magento\Catalog\Test\Constraint\AssertProductInGrid" /> @@ -210,6 +217,7 @@ <data name="product/data/downloadable_links/dataset" xsi:type="string">with_three_links</data> <data name="product/data/custom_options/dataset" xsi:type="string">default</data> <data name="product/data/url_key" xsi:type="string">downloadableproduct-%isolation%</data> + <data name="tag" xsi:type="string">to_maintain:yes</data> <constraint name="Magento\Catalog\Test\Constraint\AssertProductSaveMessage" /> <constraint name="Magento\Catalog\Test\Constraint\AssertProductInGrid" /> <constraint name="Magento\Downloadable\Test\Constraint\AssertDownloadableProductForm" /> @@ -278,6 +286,7 @@ <data name="product/data/downloadable_links/dataset" xsi:type="string">with_two_separately_links</data> <data name="product/data/tier_price/dataset" xsi:type="string">default</data> <data name="product/data/url_key" xsi:type="string">downloadableproduct-%isolation%</data> + <data name="tag" xsi:type="string">to_maintain:yes</data> <constraint name="Magento\Catalog\Test\Constraint\AssertProductSaveMessage" /> <constraint name="Magento\Catalog\Test\Constraint\AssertProductInGrid" /> <constraint name="Magento\Downloadable\Test\Constraint\AssertDownloadableProductForm" /> @@ -285,6 +294,7 @@ <constraint name="Magento\Catalog\Test\Constraint\AssertProductTierPriceOnProductPage" /> </variation> <variation name="CreateDownloadableProductEntityTestVariation16" summary="Create downloadable product and assign it to custom website"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="product/data/name" xsi:type="string">DownloadableProduct_%isolation%</data> <data name="product/data/sku" xsi:type="string">DownloadableProduct_%isolation%</data> <data name="product/data/price/value" xsi:type="string">350</data> diff --git a/dev/tests/functional/tests/app/Magento/Downloadable/Test/TestCase/DuplicateProductEntityTest.xml b/dev/tests/functional/tests/app/Magento/Downloadable/Test/TestCase/DuplicateProductEntityTest.xml index be38a73902cd71a2a893b0f2aaf94ac70ebb4273..8e844fa90ddf94a48ed09bc1b7ed9285b51ef555 100644 --- a/dev/tests/functional/tests/app/Magento/Downloadable/Test/TestCase/DuplicateProductEntityTest.xml +++ b/dev/tests/functional/tests/app/Magento/Downloadable/Test/TestCase/DuplicateProductEntityTest.xml @@ -9,6 +9,7 @@ <testCase name="Magento\Catalog\Test\TestCase\Product\DuplicateProductEntityTest"> <variation name="DuplicateProductEntityTestVariation3" firstConstraint="Magento\Catalog\Test\Constraint\AssertProductSaveMessage" method="test"> <data name="productType" xsi:type="string">downloadableProduct::default</data> + <data name="tag" xsi:type="string">to_maintain:yes</data> <constraint name="Magento\Catalog\Test\Constraint\AssertProductSaveMessage" next="Magento\Catalog\Test\Constraint\AssertProductDuplicateMessage" /> <constraint name="Magento\Catalog\Test\Constraint\AssertProductDuplicateMessage" next="Magento\Downloadable\Test\Constraint\AssertDownloadableDuplicateForm" /> <constraint name="Magento\Downloadable\Test\Constraint\AssertDownloadableDuplicateForm" next="Magento\Catalog\Test\Constraint\AssertProductDuplicatedInGrid" /> diff --git a/dev/tests/functional/tests/app/Magento/Downloadable/Test/TestCase/TaxCalculationTest.xml b/dev/tests/functional/tests/app/Magento/Downloadable/Test/TestCase/TaxCalculationTest.xml index 87a124814fc222b7ae21df4b47b6b75284fdcdf0..e2afcbeb7cce01be9b5200b8a06c1af4392490f4 100644 --- a/dev/tests/functional/tests/app/Magento/Downloadable/Test/TestCase/TaxCalculationTest.xml +++ b/dev/tests/functional/tests/app/Magento/Downloadable/Test/TestCase/TaxCalculationTest.xml @@ -8,6 +8,7 @@ <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/etc/variations.xsd"> <testCase name="Magento\Tax\Test\TestCase\TaxCalculationTest"> <variation name="DownloadableTaxCalculationTestVariation1" summary="Downloadable product with sales rule, customer tax equals store tax and catalog price excluding tax" ticketId="MAGETWO-32076"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="configData" xsi:type="string">total_cat_excl_ship_incl_after_disc_on_incl, display_excluding_including_tax</data> <data name="product" xsi:type="string">downloadableProduct::with_two_separately_links_special_price_and_category</data> <data name="salesRule" xsi:type="string">active_sales_rule_for_all_groups_no_coupon</data> @@ -34,6 +35,7 @@ <constraint name="Magento\Tax\Test\Constraint\AssertOrderTaxOnBackendExcludingIncludingTax" /> </variation> <variation name="DownloadableTaxCalculationTestVariation2" summary="Downloadable product with catalog rule, customer tax greater than store tax and catalog price excluding tax" ticketId="MAGETWO-32076"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="configData" xsi:type="string">total_cat_excl_ship_incl_after_disc_on_incl, display_including_tax</data> <data name="product" xsi:type="string">downloadableProduct::with_two_separately_links_special_price_and_category</data> <data name="catalogRule" xsi:type="string">catalog_price_rule_all_groups</data> @@ -53,6 +55,7 @@ <constraint name="Magento\Tax\Test\Constraint\AssertOrderTaxOnBackendIncludingTax" /> </variation> <variation name="DownloadableTaxCalculationTestVariation4" summary="Downloadable product with catalog rule, customer tax greater than store tax and catalog price including tax" ticketId="MAGETWO-32076"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="configData" xsi:type="string">total_cat_incl_ship_excl_before_disc_on_excl, display_excluding_including_tax</data> <data name="product" xsi:type="string">downloadableProduct::with_two_separately_links_custom_options_and_category</data> <data name="catalogRule" xsi:type="string">catalog_price_rule_all_groups</data> @@ -77,6 +80,7 @@ <constraint name="Magento\Tax\Test\Constraint\AssertOrderTaxOnBackendExcludingIncludingTax" /> </variation> <variation name="DownloadableTaxCalculationTestVariation6" summary="Downloadable product with catalog rule, customer tax equals store tax and catalog price including tax" ticketId="MAGETWO-32076"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="configData" xsi:type="string">total_cat_incl_ship_excl_before_disc_on_excl</data> <data name="product" xsi:type="string">downloadableProduct::with_two_separately_links_custom_options_and_category</data> <data name="catalogRule" xsi:type="string">catalog_price_rule_all_groups</data> diff --git a/dev/tests/functional/tests/app/Magento/Downloadable/Test/TestCase/UpdateDownloadableProductEntityTest.php b/dev/tests/functional/tests/app/Magento/Downloadable/Test/TestCase/UpdateDownloadableProductEntityTest.php index 276cc08e8efb74f05c70868cdf67a77f452bb44a..91281de3cdbdaf1308d0aca1473aaf7aab808688 100644 --- a/dev/tests/functional/tests/app/Magento/Downloadable/Test/TestCase/UpdateDownloadableProductEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Downloadable/Test/TestCase/UpdateDownloadableProductEntityTest.php @@ -37,6 +37,7 @@ class UpdateDownloadableProductEntityTest extends Injectable { /* tags */ const MVP = 'yes'; + const TO_MAINTAIN = 'yes'; /* end tags */ /** diff --git a/dev/tests/functional/tests/app/Magento/Email/Test/TestCase/CreateEmailTemplateEntityTest.php b/dev/tests/functional/tests/app/Magento/Email/Test/TestCase/CreateEmailTemplateEntityTest.php index dc86b6479757e00564877fa3f52c7e5c6c3ef4f5..69bae8412db119983edf5f99e73da7399af5f9a7 100644 --- a/dev/tests/functional/tests/app/Magento/Email/Test/TestCase/CreateEmailTemplateEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Email/Test/TestCase/CreateEmailTemplateEntityTest.php @@ -30,6 +30,7 @@ class CreateEmailTemplateEntityTest extends Injectable /* tags */ const MVP = 'yes'; const DOMAIN = 'PS'; + const TO_MAINTAIN = 'yes'; const TEST_TYPE = 'extended_acceptance_test'; /* end tags */ diff --git a/dev/tests/functional/tests/app/Magento/GiftMessage/Test/TestCase/CheckoutWithGiftMessagesTest.xml b/dev/tests/functional/tests/app/Magento/GiftMessage/Test/TestCase/CheckoutWithGiftMessagesTest.xml index 3913817d8f3205105356b39d39e48bc212e6ca66..6226713f316c5f0a90f06291a3a8160a65ac912f 100644 --- a/dev/tests/functional/tests/app/Magento/GiftMessage/Test/TestCase/CheckoutWithGiftMessagesTest.xml +++ b/dev/tests/functional/tests/app/Magento/GiftMessage/Test/TestCase/CheckoutWithGiftMessagesTest.xml @@ -27,6 +27,7 @@ <constraint name="Magento\GiftMessage\Test\Constraint\AssertGiftMessageInFrontendOrder" /> </variation> <variation name="CheckoutWithGiftMessagesTestVariation2"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="products/0" xsi:type="string">catalogProductSimple::default</data> <data name="products/1" xsi:type="string">catalogProductVirtual::default</data> <data name="customer/dataset" xsi:type="string">default</data> diff --git a/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/TestCase/CreateGroupedProductEntityTest.xml b/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/TestCase/CreateGroupedProductEntityTest.xml index 47592328f39c10d7a257b014de640e82f969c639..a8a2aebbf2f259875cf55fecd3ac5d59f7b2b52c 100644 --- a/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/TestCase/CreateGroupedProductEntityTest.xml +++ b/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/TestCase/CreateGroupedProductEntityTest.xml @@ -57,6 +57,7 @@ <constraint name="Magento\Catalog\Test\Constraint\AssertProductOutOfStock" /> </variation> <variation name="CreateGroupedProductEntityTestVariation5" summary="Create with no required products"> + <data name="tag" xsi:type="string">stable:no</data> <data name="product/data/url_key" xsi:type="string">test-grouped-product-%isolation%</data> <data name="product/data/name" xsi:type="string">GroupedProduct %isolation%</data> <data name="product/data/sku" xsi:type="string">GroupedProduct_sku%isolation%</data> @@ -109,6 +110,7 @@ <constraint name="Magento\Catalog\Test\Constraint\AssertProductPage" /> </variation> <variation name="CreateGroupedProductEntityTestVariation10" summary="Create Grouped Product and Assign it on Custom Website"> + <data name="tag" xsi:type="string">stable:no</data> <data name="product/data/url_key" xsi:type="string">test-grouped-product-%isolation%</data> <data name="product/data/name" xsi:type="string">GroupedProduct %isolation%</data> <data name="product/data/sku" xsi:type="string">GroupedProduct_sku%isolation%</data> diff --git a/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/TestCase/DeleteProductFromMiniShoppingCartTest.xml b/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/TestCase/DeleteProductFromMiniShoppingCartTest.xml index 91c26ddb6acbc1adf214828b7cbde9b041b81eb0..92a842ee5a71e4ea2bc8a2eeba6fd3bdc6bbbeb8 100644 --- a/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/TestCase/DeleteProductFromMiniShoppingCartTest.xml +++ b/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/TestCase/DeleteProductFromMiniShoppingCartTest.xml @@ -8,6 +8,7 @@ <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/etc/variations.xsd"> <testCase name="Magento\Checkout\Test\TestCase\DeleteProductFromMiniShoppingCartTest" summary="Delete Grouped Product from Mini Shopping Cart" ticketId="MAGETWO-29104"> <variation name="DeleteGroupedProductFromMiniShoppingCartTestVariation"> + <data name="tag" xsi:type="string">stable:no</data> <data name="products/0" xsi:type="string">groupedProduct::default</data> <data name="deletedProductIndex" xsi:type="string">0</data> <constraint name="Magento\Checkout\Test\Constraint\AssertCartIsEmpty" /> diff --git a/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/TestCase/UpdateGroupedProductEntityTest.xml b/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/TestCase/UpdateGroupedProductEntityTest.xml index d2ae0836e5e7654ddc37288c582ebe9dece27e65..11f854749d3fdcde8d149fcc6e1519e359dee3d1 100644 --- a/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/TestCase/UpdateGroupedProductEntityTest.xml +++ b/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/TestCase/UpdateGroupedProductEntityTest.xml @@ -8,6 +8,7 @@ <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/etc/variations.xsd"> <testCase name="Magento\GroupedProduct\Test\TestCase\UpdateGroupedProductEntityTest" summary="Update Grouped Product" ticketId="MAGETWO-26462"> <variation name="UpdateGroupedProductEntityTestVariation1"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="originalProduct/dataset" xsi:type="string">grouped_product_out_of_stock</data> <data name="product/data/name" xsi:type="string">GroupedProduct_edited %isolation%</data> <data name="product/data/sku" xsi:type="string">GroupedProduct_sku_edited %isolation%</data> @@ -21,6 +22,7 @@ <constraint name="Magento\Catalog\Test\Constraint\AssertProductPage" /> </variation> <variation name="UpdateGroupedProductEntityTestVariation2"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="originalProduct/dataset" xsi:type="string">default</data> <data name="product/data/name" xsi:type="string">GroupedProduct_edited %isolation%</data> <data name="product/data/sku" xsi:type="string">GroupedProduct_sku_edited %isolation%</data> @@ -31,6 +33,7 @@ <constraint name="Magento\GroupedProduct\Test\Constraint\AssertGroupedProductForm" /> </variation> <variation name="UpdateGroupedProductEntityTestVariation3"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="originalProduct/dataset" xsi:type="string">default</data> <data name="product/data/name" xsi:type="string">GroupedProduct_edited %isolation%</data> <data name="product/data/sku" xsi:type="string">GroupedProduct_sku_edited %isolation%</data> @@ -42,6 +45,7 @@ <constraint name="Magento\GroupedProduct\Test\Constraint\AssertGroupedProductForm" /> </variation> <variation name="UpdateGroupedProductEntityTestVariation4"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="originalProduct/dataset" xsi:type="string">default</data> <data name="product/data/name" xsi:type="string">GroupedProduct_edited %isolation%</data> <data name="product/data/sku" xsi:type="string">GroupedProduct_sku_edited %isolation%</data> @@ -52,6 +56,7 @@ <constraint name="Magento\GroupedProduct\Test\Constraint\AssertSpecialPriceOnGroupedProductPage" /> </variation> <variation name="UpdateGroupedProductEntityTestVariation5"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="originalProduct/dataset" xsi:type="string">default</data> <data name="product/data/name" xsi:type="string">GroupedProduct_edited %isolation%</data> <data name="product/data/sku" xsi:type="string">GroupedProduct_sku_edited %isolation%</data> diff --git a/dev/tests/functional/tests/app/Magento/Integration/Test/TestCase/UpdateIntegrationEntityTest.xml b/dev/tests/functional/tests/app/Magento/Integration/Test/TestCase/UpdateIntegrationEntityTest.xml index e09d2a23559b97a904e59899177177ae38f9b93f..5965aa7ce3c581264c73106afd52197be71af583 100644 --- a/dev/tests/functional/tests/app/Magento/Integration/Test/TestCase/UpdateIntegrationEntityTest.xml +++ b/dev/tests/functional/tests/app/Magento/Integration/Test/TestCase/UpdateIntegrationEntityTest.xml @@ -20,6 +20,7 @@ <constraint name="Magento\Integration\Test\Constraint\AssertIntegrationInGrid" /> </variation> <variation name="UpdateIntegrationEntityTestVariation2"> + <data name="tag" xsi:type="string">stable:no</data> <data name="integration/data/name" xsi:type="string">Integration_%isolation%</data> <data name="integration/data/email" xsi:type="string">-</data> <data name="integration/data/endpoint" xsi:type="string">-</data> diff --git a/dev/tests/functional/tests/app/Magento/Newsletter/Test/TestCase/ActionNewsletterTemplateEntityTest.php b/dev/tests/functional/tests/app/Magento/Newsletter/Test/TestCase/ActionNewsletterTemplateEntityTest.php index a79ea3995eeff08464befe26a71e61171af3bc2e..0203cf89fe7d2d5b4745a65625df5cb14602be8d 100644 --- a/dev/tests/functional/tests/app/Magento/Newsletter/Test/TestCase/ActionNewsletterTemplateEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Newsletter/Test/TestCase/ActionNewsletterTemplateEntityTest.php @@ -31,6 +31,7 @@ class ActionNewsletterTemplateEntityTest extends Injectable { /* tags */ const MVP = 'yes'; + const STABLE = 'no'; /* end tags */ /** diff --git a/dev/tests/functional/tests/app/Magento/Newsletter/Test/TestCase/PreviewNewsletterTemplateEntityTest.xml b/dev/tests/functional/tests/app/Magento/Newsletter/Test/TestCase/PreviewNewsletterTemplateEntityTest.xml index 13b499fca5e3c40754fd78f54b158361514bbb8a..206e2d01468e7e03300fd328e798bd6b70069b73 100644 --- a/dev/tests/functional/tests/app/Magento/Newsletter/Test/TestCase/PreviewNewsletterTemplateEntityTest.xml +++ b/dev/tests/functional/tests/app/Magento/Newsletter/Test/TestCase/PreviewNewsletterTemplateEntityTest.xml @@ -8,6 +8,7 @@ <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/etc/variations.xsd"> <testCase name="Magento\Newsletter\Test\TestCase\PreviewNewsletterTemplateEntityTest" summary="Newsletter Template Preview" ticketId="MAGETWO-51979"> <variation name="PreviewNewsletterTemplateEntityTestVariation1"> + <data name="tag" xsi:type="string">stable:no</data> <data name="newsletter/dataset" xsi:type="string">default</data> <constraint name="Magento\Newsletter\Test\Constraint\AssertNewsletterPreview" /> </variation> diff --git a/dev/tests/functional/tests/app/Magento/ProductVideo/Test/TestCase/AddProductVideoTest.xml b/dev/tests/functional/tests/app/Magento/ProductVideo/Test/TestCase/AddProductVideoTest.xml index 9dfcc4d8bac35141a99400cb88df7e4206dfce44..0bcf0db70b2fba7a98b02e326f7d986d5f3c95f9 100644 --- a/dev/tests/functional/tests/app/Magento/ProductVideo/Test/TestCase/AddProductVideoTest.xml +++ b/dev/tests/functional/tests/app/Magento/ProductVideo/Test/TestCase/AddProductVideoTest.xml @@ -8,6 +8,7 @@ <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/etc/variations.xsd"> <testCase name="Magento\ProductVideo\Test\TestCase\AddProductVideoTest" summary="Add Video to PCF" ticketId="MAGETWO-43672"> <variation name="AddProductVideoEntityTestVariation1" summary="Add youtube video with all available fields filled in"> + <data name="tag" xsi:type="string">stable:no</data> <data name="product/dataset" xsi:type="string">product_with_video_youtube</data> <data name="configData" xsi:type="string">youtube_api_key,play_if_base</data> <constraint name="Magento\ProductVideo\Test\Constraint\AssertVideoCategoryView" /> @@ -15,6 +16,7 @@ <constraint name="Magento\Catalog\Test\Constraint\AssertProductForm" /> </variation> <variation name="AddProductVideoEntityTestVariation2" summary="Add vimeo video with all available fields filled in"> + <data name="tag" xsi:type="string">stable:no</data> <data name="product/dataset" xsi:type="string">product_with_video_vimeo</data> <data name="configData" xsi:type="string">play_if_base</data> <constraint name="Magento\ProductVideo\Test\Constraint\AssertVideoCategoryView" /> diff --git a/dev/tests/functional/tests/app/Magento/ProductVideo/Test/TestCase/DeleteProductVideoTest.xml b/dev/tests/functional/tests/app/Magento/ProductVideo/Test/TestCase/DeleteProductVideoTest.xml index 78a7fe00ab9f43227ffe4828769dd3b627e8cfce..26df238f11b286f47d4a923084cc56dd7d6985dd 100644 --- a/dev/tests/functional/tests/app/Magento/ProductVideo/Test/TestCase/DeleteProductVideoTest.xml +++ b/dev/tests/functional/tests/app/Magento/ProductVideo/Test/TestCase/DeleteProductVideoTest.xml @@ -8,6 +8,7 @@ <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/etc/variations.xsd"> <testCase name="Magento\ProductVideo\Test\TestCase\DeleteProductVideoTest" summary="Delete Video from PCF - Delete video" ticketId="MAGETWO-43660"> <variation name="DeleteVideoEntityTestVariation1" summary="Delete video youtube" ticketId="MAGETWO-43660"> + <data name="tag" xsi:type="string">stable:no</data> <data name="product/dataset" xsi:type="string">product_with_video_youtube</data> <data name="configData" xsi:type="string">youtube_api_key,play_if_base</data> <constraint name="Magento\Catalog\Test\Constraint\AssertProductNoImageInGrid" /> @@ -15,6 +16,7 @@ <constraint name="Magento\ProductVideo\Test\Constraint\AssertNoVideoProductView" /> </variation> <variation name="DeleteVideoEntityTestVariation2" summary="Delete video vimeo" ticketId="MAGETWO-43660"> + <data name="tag" xsi:type="string">stable:no</data> <data name="product/dataset" xsi:type="string">product_with_video_vimeo</data> <data name="configData" xsi:type="string">play_if_base</data> <constraint name="Magento\Catalog\Test\Constraint\AssertProductNoImageInGrid" /> diff --git a/dev/tests/functional/tests/app/Magento/ProductVideo/Test/TestCase/UpdateProductVideoTest.php b/dev/tests/functional/tests/app/Magento/ProductVideo/Test/TestCase/UpdateProductVideoTest.php index 30df076817dff80416933e9bccf11d598fb28a87..a02ba30f716ecea19e2ec06a30e0627afcd997a6 100644 --- a/dev/tests/functional/tests/app/Magento/ProductVideo/Test/TestCase/UpdateProductVideoTest.php +++ b/dev/tests/functional/tests/app/Magento/ProductVideo/Test/TestCase/UpdateProductVideoTest.php @@ -33,8 +33,9 @@ use Magento\Mtf\TestCase\Injectable; class UpdateProductVideoTest extends Injectable { /* tags */ - const TEST_TYPE = 'acceptance_test, extended_acceptance_test'; + const TEST_TYPE = 'extended_acceptance_test'; const MVP = 'yes'; + const STABLE = 'no'; /* end tags */ /** diff --git a/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/AbandonedCartsReportEntityTest.php b/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/AbandonedCartsReportEntityTest.php index 5930e63b9d3bd367a4c93fb241cc64613fa9aea6..95c9d518a391ddb679c3d5a4118ef79391d2cdca 100644 --- a/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/AbandonedCartsReportEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/AbandonedCartsReportEntityTest.php @@ -34,6 +34,7 @@ class AbandonedCartsReportEntityTest extends Injectable { /* tags */ const MVP = 'no'; + const STABLE = 'no'; /* end tags */ /** diff --git a/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/CustomersOrderCountReportEntityTest.php b/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/CustomersOrderCountReportEntityTest.php index cacb6e5a329bff99eb28fd62118f440c569ade46..7dc9b6106b7bb20d8507af83840abb030e9b24e7 100644 --- a/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/CustomersOrderCountReportEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/CustomersOrderCountReportEntityTest.php @@ -31,6 +31,7 @@ class CustomersOrderCountReportEntityTest extends Injectable { /* tags */ const MVP = 'no'; + const STABLE = 'no'; /* end tags */ /** diff --git a/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/DownloadProductsReportEntityTest.xml b/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/DownloadProductsReportEntityTest.xml index 6e37965603c787083bfa0a9b337d1b770df3bfec..3a25f81d37fb6316e27a891a573503778443d57b 100644 --- a/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/DownloadProductsReportEntityTest.xml +++ b/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/DownloadProductsReportEntityTest.xml @@ -8,16 +8,19 @@ <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/etc/variations.xsd"> <testCase name="Magento\Reports\Test\TestCase\DownloadProductsReportEntityTest" summary="Download Products Report" ticketId="MAGETWO-28823"> <variation name="DownloadProductsReportEntityTestVariation1"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="order/dataset" xsi:type="string">downloadable_product</data> <data name="downloads" xsi:type="string">1</data> <constraint name="Magento\Reports\Test\Constraint\AssertDownloadsReportResult" /> </variation> <variation name="DownloadProductsReportEntityTestVariation2"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="order/dataset" xsi:type="string">two_downloadable_product</data> <data name="downloads" xsi:type="string">2</data> <constraint name="Magento\Reports\Test\Constraint\AssertDownloadsReportResult" /> </variation> <variation name="DownloadProductsReportEntityTestVariation3"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="order/dataset" xsi:type="string">downloadable_product</data> <data name="downloads" xsi:type="string">0</data> <constraint name="Magento\Reports\Test\Constraint\AssertDownloadsReportResult" /> diff --git a/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/NewAccountsReportEntityTest.xml b/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/NewAccountsReportEntityTest.xml index c484c94a976f6340706e0b6f5ab045b16c83caf7..582d41a9d3bb2957abdb136a0032c051f3b5d949 100644 --- a/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/NewAccountsReportEntityTest.xml +++ b/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/NewAccountsReportEntityTest.xml @@ -8,6 +8,7 @@ <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/etc/variations.xsd"> <testCase name="Magento\Reports\Test\TestCase\NewAccountsReportEntityTest" summary="New Accounts Report" ticketId="MAGETWO-27742"> <variation name="NewAccountsReportEntityTestVariation1"> + <data name="tag" xsi:type="string">stable:no</data> <data name="customer/dataset" xsi:type="string">default</data> <data name="total" xsi:type="string">1</data> <data name="customersReport/report_from" xsi:type="string">m/d/Y</data> @@ -16,6 +17,7 @@ <constraint name="Magento\Reports\Test\Constraint\AssertNewAccountsReportTotalResult" /> </variation> <variation name="NewAccountsReportEntityTestVariation2"> + <data name="tag" xsi:type="string">stable:no</data> <data name="customer/dataset" xsi:type="string">default</data> <data name="total" xsi:type="string">1</data> <data name="customersReport/report_from" xsi:type="string">m/d/Y</data> @@ -24,6 +26,7 @@ <constraint name="Magento\Reports\Test\Constraint\AssertNewAccountsReportTotalResult" /> </variation> <variation name="NewAccountsReportEntityTestVariation3"> + <data name="tag" xsi:type="string">stable:no</data> <data name="customer/dataset" xsi:type="string">default</data> <data name="total" xsi:type="string">1</data> <data name="customersReport/report_from" xsi:type="string">m/d/Y</data> diff --git a/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/OrderedProductsReportEntityTest.php b/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/OrderedProductsReportEntityTest.php index 7d0d13862e7720b0b63516639d8b4968909c66cc..dc09819ab98790fd7b6b8acf6b69aad614ef7ccd 100644 --- a/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/OrderedProductsReportEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/OrderedProductsReportEntityTest.php @@ -28,6 +28,7 @@ class OrderedProductsReportEntityTest extends Injectable { /* tags */ const MVP = 'no'; + const STABLE = 'no'; /* end tags */ /** diff --git a/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/SalesCouponReportEntityTest.php b/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/SalesCouponReportEntityTest.php index 0d59b989fc25fc162e450ce719c96413229c45fe..8d686421a524bfc610ab22e16cc6780e559d32c9 100644 --- a/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/SalesCouponReportEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/SalesCouponReportEntityTest.php @@ -34,6 +34,7 @@ class SalesCouponReportEntityTest extends Injectable { /* tags */ const MVP = 'no'; + const STABLE = 'no'; /* end tags */ /** diff --git a/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/SalesInvoiceReportEntityTest.php b/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/SalesInvoiceReportEntityTest.php index 3ebfd4746a858f92381e9c58e8b20cc84356c0be..b8e5a5276d616061eb1e2e0c30fe74801fb96479 100644 --- a/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/SalesInvoiceReportEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/SalesInvoiceReportEntityTest.php @@ -37,6 +37,7 @@ class SalesInvoiceReportEntityTest extends Injectable { /* tags */ const MVP = 'no'; + const STABLE = 'no'; /* end tags */ /** diff --git a/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/SalesOrderReportEntityTest.xml b/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/SalesOrderReportEntityTest.xml index b1957b6315765538644619f27390d06ae0dd7aa0..1d8adebd6befdc04d23a4b6653eafeb3ce26d410 100644 --- a/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/SalesOrderReportEntityTest.xml +++ b/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/SalesOrderReportEntityTest.xml @@ -21,6 +21,7 @@ <constraint name="Magento\Reports\Test\Constraint\AssertSalesReportTotalResult" /> </variation> <variation name="SalesOrderReportEntityTestVariation2"> + <data name="tag" xsi:type="string">stable:no</data> <data name="order/dataset" xsi:type="string">default</data> <data name="order/data/price/dataset" xsi:type="string">full_invoice</data> <data name="salesReport/report_type" xsi:type="string">Order Created</data> @@ -34,6 +35,7 @@ <constraint name="Magento\Reports\Test\Constraint\AssertSalesReportTotalResult" /> </variation> <variation name="SalesOrderReportEntityTestVariation3"> + <data name="tag" xsi:type="string">stable:no</data> <data name="order/dataset" xsi:type="string">default</data> <data name="order/data/price/dataset" xsi:type="string">full_invoice</data> <data name="salesReport/report_type" xsi:type="string">Order Updated</data> diff --git a/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/SalesRefundsReportEntityTest.xml b/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/SalesRefundsReportEntityTest.xml index a3b971ec5a8caf5332c9be61a1397a28c4e4ead0..927e461fc2181d818ecaca45a57d9876f44f2965 100644 --- a/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/SalesRefundsReportEntityTest.xml +++ b/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/SalesRefundsReportEntityTest.xml @@ -20,6 +20,7 @@ <constraint name="Magento\Reports\Test\Constraint\AssertRefundReportIntervalResult" /> </variation> <variation name="SalesRefundsReportEntityTestVariation2"> + <data name="tag" xsi:type="string">stable:no</data> <data name="description" xsi:type="string">assert refunds month report</data> <data name="order/dataset" xsi:type="string">default</data> <data name="order/data/price/dataset" xsi:type="string">full_invoice</data> @@ -32,6 +33,7 @@ <constraint name="Magento\Reports\Test\Constraint\AssertRefundReportIntervalResult" /> </variation> <variation name="SalesRefundsReportEntityTestVariation3"> + <data name="tag" xsi:type="string">stable:no</data> <data name="description" xsi:type="string">assert refund Daily report</data> <data name="order/dataset" xsi:type="string">default</data> <data name="order/data/price/dataset" xsi:type="string">full_invoice</data> diff --git a/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/SalesTaxReportEntityTest.xml b/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/SalesTaxReportEntityTest.xml index df6eb7759fd5558110925b224de31d72090702c6..69440d5f15e3fe9508ae7d8a1efd3d31c8940417 100644 --- a/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/SalesTaxReportEntityTest.xml +++ b/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/SalesTaxReportEntityTest.xml @@ -22,6 +22,7 @@ <constraint name="Magento\Reports\Test\Constraint\AssertTaxReportNotInGrid" /> </variation> <variation name="SalesTaxReportEntityTestVariation2"> + <data name="tag" xsi:type="string">stable:no</data> <data name="orderSteps" xsi:type="string">invoice</data> <data name="taxRule/dataset" xsi:type="string">custom_rule</data> <data name="order/dataset" xsi:type="string">default</data> @@ -37,6 +38,7 @@ <constraint name="Magento\Reports\Test\Constraint\AssertTaxReportInGrid" /> </variation> <variation name="SalesTaxReportEntityTestVariation3"> + <data name="tag" xsi:type="string">stable:no</data> <data name="orderSteps" xsi:type="string">invoice,shipment</data> <data name="taxRule/dataset" xsi:type="string">custom_rule</data> <data name="order/dataset" xsi:type="string">default</data> diff --git a/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/ViewedProductsReportEntityTest.php b/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/ViewedProductsReportEntityTest.php index 905fa8fb70f0cebff985cf4a99d193359969e5e1..6c22348179897ffa0d533dba563a5fce06657632 100644 --- a/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/ViewedProductsReportEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/ViewedProductsReportEntityTest.php @@ -33,6 +33,7 @@ class ViewedProductsReportEntityTest extends Injectable { /* tags */ const MVP = 'no'; + const STABLE = 'no'; /* end tags */ /** diff --git a/dev/tests/functional/tests/app/Magento/Review/Test/TestCase/CreateProductReviewBackendEntityTest.php b/dev/tests/functional/tests/app/Magento/Review/Test/TestCase/CreateProductReviewBackendEntityTest.php index 9130c5285848e2d04f5978403c23ae0b2278ff16..251cbd75a793f8a0382180041b20529784526e57 100644 --- a/dev/tests/functional/tests/app/Magento/Review/Test/TestCase/CreateProductReviewBackendEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Review/Test/TestCase/CreateProductReviewBackendEntityTest.php @@ -34,6 +34,7 @@ class CreateProductReviewBackendEntityTest extends Injectable { /* tags */ const MVP = 'no'; + const TO_MAINTAIN = 'yes'; /* end tags */ /** diff --git a/dev/tests/functional/tests/app/Magento/Review/Test/TestCase/CreateProductReviewFrontendEntityTest.xml b/dev/tests/functional/tests/app/Magento/Review/Test/TestCase/CreateProductReviewFrontendEntityTest.xml index 786203e93f24d8e29ba779c8ed0ad3b4b66f0626..8cd4e44b7622a2de828b9f2d9a96738a41ae2911 100644 --- a/dev/tests/functional/tests/app/Magento/Review/Test/TestCase/CreateProductReviewFrontendEntityTest.xml +++ b/dev/tests/functional/tests/app/Magento/Review/Test/TestCase/CreateProductReviewFrontendEntityTest.xml @@ -8,6 +8,7 @@ <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/etc/variations.xsd"> <testCase name="Magento\Review\Test\TestCase\CreateProductReviewFrontendEntityTest" summary="Create Frontend Product Review" ticketId="MAGETWO-25519"> <variation name="CreateProductReviewFrontendEntityTestVariation1" summary="Create product review with rating"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="review/data/type" xsi:type="string">Guest</data> <data name="review/data/nickname" xsi:type="string">name_%isolation%</data> <data name="review/data/title" xsi:type="string">title_%isolation%</data> diff --git a/dev/tests/functional/tests/app/Magento/Review/Test/TestCase/ManageProductReviewFromCustomerPageTest.php b/dev/tests/functional/tests/app/Magento/Review/Test/TestCase/ManageProductReviewFromCustomerPageTest.php index fc58266356223d48457d54a14d508a01712acc4c..3f1adc16694ccee1b7ba8aec945e71d8d2b30d52 100644 --- a/dev/tests/functional/tests/app/Magento/Review/Test/TestCase/ManageProductReviewFromCustomerPageTest.php +++ b/dev/tests/functional/tests/app/Magento/Review/Test/TestCase/ManageProductReviewFromCustomerPageTest.php @@ -43,6 +43,7 @@ class ManageProductReviewFromCustomerPageTest extends Injectable { /* tags */ const MVP = 'no'; + const TO_MAINTAIN = 'yes'; /* end tags */ /** diff --git a/dev/tests/functional/tests/app/Magento/Review/Test/TestCase/UpdateProductReviewEntityOnProductPageTest.xml b/dev/tests/functional/tests/app/Magento/Review/Test/TestCase/UpdateProductReviewEntityOnProductPageTest.xml index 5d731c736fd69245c110161823374f3ca2843ccc..86dca577d0094e3d3fd20e15b1a9b22eabd75a1e 100644 --- a/dev/tests/functional/tests/app/Magento/Review/Test/TestCase/UpdateProductReviewEntityOnProductPageTest.xml +++ b/dev/tests/functional/tests/app/Magento/Review/Test/TestCase/UpdateProductReviewEntityOnProductPageTest.xml @@ -8,6 +8,7 @@ <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/etc/variations.xsd"> <testCase name="Magento\Review\Test\TestCase\UpdateProductReviewEntityOnProductPageTest" summary="Update Product Review from Product Page" ticketId="MAGETWO-27743"> <variation name="UpdateProductReviewEntityOnProductPageTestVariation1"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="rating" xsi:type="string">3</data> <data name="review/data/status_id" xsi:type="string">Approved</data> <data name="productRating/data/select_stores" xsi:type="string">Main Website/Main Website Store/Default Store View</data> diff --git a/dev/tests/functional/tests/app/Magento/Review/Test/TestCase/UpdateProductReviewEntityTest.xml b/dev/tests/functional/tests/app/Magento/Review/Test/TestCase/UpdateProductReviewEntityTest.xml index 549c3c3ddc3a8d91292e1169c8fe3084f628b2e9..71c40ca27fac05b1b1c3b4e4c6609d98e788ea0b 100644 --- a/dev/tests/functional/tests/app/Magento/Review/Test/TestCase/UpdateProductReviewEntityTest.xml +++ b/dev/tests/functional/tests/app/Magento/Review/Test/TestCase/UpdateProductReviewEntityTest.xml @@ -8,6 +8,7 @@ <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/etc/variations.xsd"> <testCase name="Magento\Review\Test\TestCase\UpdateProductReviewEntityTest" summary="Update Product Review" ticketId="MAGETWO-25604"> <variation name="UpdateProductReviewEntityTestVariation1"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="reviewInitial/dataset" xsi:type="string">review_for_simple_product_with_rating</data> <data name="review/data/nickname" xsi:type="string">name_upd_%isolation%</data> <data name="review/data/title" xsi:type="string">title_upd_%isolation%</data> diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Create.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Create.php index c25b96a624bfda79865d81f73f3208f0bc38d74a..9e0c1517d3d7eae9c8945b6c822928eaef0ac64f 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Create.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Create.php @@ -339,6 +339,7 @@ class Create extends Block $this->getTemplateBlock()->waitLoader(); $this->_rootElement->find($this->orderMethodsSelector)->click(); $this->getBillingMethodBlock()->selectPaymentMethod($paymentCode, $creditCard); + $this->_rootElement->click(); $this->getTemplateBlock()->waitLoader(); } diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Repository/OrderInjectable/Price.xml b/dev/tests/functional/tests/app/Magento/Sales/Test/Repository/OrderInjectable/Price.xml index 3e2dfdd7125074ac64fdc6c7a39cdc762348585a..3da1f91925e0a1274cbe317d36f2bc40271cbeb6 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Repository/OrderInjectable/Price.xml +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Repository/OrderInjectable/Price.xml @@ -43,5 +43,12 @@ <item name="grand_creditmemo_total" xsi:type="string">110</item> </field> </dataset> + + <dataset name="free_invoice"> + <field name="0" xsi:type="array"> + <item name="grand_order_total" xsi:type="string">0</item> + <item name="grand_invoice_total" xsi:type="string">0</item> + </field> + </dataset> </repository> </config> diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/TestCase/CancelCreatedOrderTest.xml b/dev/tests/functional/tests/app/Magento/Sales/Test/TestCase/CancelCreatedOrderTest.xml index b65b9a31f72f3d7ff7290afb4393edeaf73679bc..e839681907c6d291b0855f138fa7d52c9b1dd4fa 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/TestCase/CancelCreatedOrderTest.xml +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/TestCase/CancelCreatedOrderTest.xml @@ -8,6 +8,7 @@ <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/etc/variations.xsd"> <testCase name="Magento\Sales\Test\TestCase\CancelCreatedOrderTest" summary="Cancel Created Order for Offline Payment Methods" ticketId="MAGETWO-28191"> <variation name="CancelCreatedOrderTestVariationWithCheckMoneyOrderPaymentMethod" summary="Cancel order with check/money order payment method and check status on storefront"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="order/dataset" xsi:type="string">default</data> <data name="order/data/entity_id/products" xsi:type="string">catalogProductSimple::default,catalogProductSimple::default</data> <data name="status" xsi:type="string">Canceled</data> @@ -17,6 +18,7 @@ <constraint name="Magento\Sales\Test\Constraint\AssertOrderInOrdersGridOnFrontend" /> </variation> <variation name="CancelCreatedOrderTestVariationWithZeroSubtotalCheckout" summary="Cancel order with zero subtotal checkout payment method and check status on storefront"> + <data name="tag" xsi:type="string">stable:no</data> <data name="order/dataset" xsi:type="string">default</data> <data name="order/data/payment_auth_expiration/method" xsi:type="string">free</data> <data name="order/data/shipping_method" xsi:type="string">freeshipping_freeshipping</data> diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/TestCase/CreateInvoiceEntityTest.php b/dev/tests/functional/tests/app/Magento/Sales/Test/TestCase/CreateInvoiceEntityTest.php index f7cdaf74ab0f57e0544a392f6a936498bcb8efee..fc866fab6dc17fbf35d1176594ae2e8836ecf87e 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/TestCase/CreateInvoiceEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/TestCase/CreateInvoiceEntityTest.php @@ -31,6 +31,7 @@ class CreateInvoiceEntityTest extends Injectable { /* tags */ const MVP = 'yes'; + const STABLE = 'no'; /* end tags */ /** diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/TestCase/CreateInvoiceEntityTest.xml b/dev/tests/functional/tests/app/Magento/Sales/Test/TestCase/CreateInvoiceEntityTest.xml index 8753de91d1f4301710f15a968b7a7ea24e04d663..116d3cb5d4a5e36dcf30b04a953c0f94cdc3e7f0 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/TestCase/CreateInvoiceEntityTest.xml +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/TestCase/CreateInvoiceEntityTest.xml @@ -68,7 +68,7 @@ </variation> <variation name="CreateInvoiceEntityTestVariationWithZeroSubtotalCheckout"> <data name="order/dataset" xsi:type="string">default</data> - <data name="order/data/price/dataset" xsi:type="string">partial_invoice</data> + <data name="order/data/price/dataset" xsi:type="string">free_invoice</data> <data name="order/data/entity_id/products" xsi:type="string">catalogProductSimple::product_10_dollar</data> <data name="order/data/total_qty_ordered/0" xsi:type="string">-</data> <data name="order/data/payment_auth_expiration/method" xsi:type="string">free</data> diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/TestCase/CreateOrderBackendTest.xml b/dev/tests/functional/tests/app/Magento/Sales/Test/TestCase/CreateOrderBackendTest.xml index ad4cc670e43cdd6087ede4ffdb2ebffff5343f0a..bd592e9d71aaa1e9d74279af53c80ac3b319e376 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/TestCase/CreateOrderBackendTest.xml +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/TestCase/CreateOrderBackendTest.xml @@ -69,6 +69,7 @@ <constraint name="Magento\Sales\Test\Constraint\AssertOrderInOrdersGridOnFrontend" /> </variation> <variation name="CreateOrderBackendTestVariation4"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="description" xsi:type="string">Create order with virtual product for registered UK customer using Bank Transfer payment method</data> <data name="products/0" xsi:type="string">catalogProductVirtual::default</data> <data name="customer/dataset" xsi:type="string">default</data> diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/TestCase/GridFilteringTest.xml b/dev/tests/functional/tests/app/Magento/Sales/Test/TestCase/GridFilteringTest.xml index 4e61abb7c5d50b783f407a926d56b6e60473a5ae..b4c3a7568a2a1dd4fb62fe0d013b6425d372d27d 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/TestCase/GridFilteringTest.xml +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/TestCase/GridFilteringTest.xml @@ -8,6 +8,7 @@ <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/etc/variations.xsd"> <testCase name="Magento\Ui\Test\TestCase\GridFilteringTest" summary="Grid UI Component Filtering" ticketId="MAGETWO-41328"> <variation name="SalesOrderGridFiltering"> + <data name="tag" xsi:type="string">stable:no</data> <data name="description" xsi:type="string">Verify sales order grid filtering</data> <data name="steps" xsi:type="array"> <item name="0" xsi:type="string">-</item> diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/TestCase/GridFullTextSearchTest.xml b/dev/tests/functional/tests/app/Magento/Sales/Test/TestCase/GridFullTextSearchTest.xml index abd9432fe098e836ce34f0107f89e099620a33de..0979d0dcbff250a7f0bdb2d5151f60004f72efd0 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/TestCase/GridFullTextSearchTest.xml +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/TestCase/GridFullTextSearchTest.xml @@ -8,6 +8,7 @@ <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/etc/variations.xsd"> <testCase name="Magento\Ui\Test\TestCase\GridFullTextSearchTest" summary="Grid UI Component Full Text Search" ticketId="MAGETWO-41023"> <variation name="SalesOrderGridFullTextSearch"> + <data name="tag" xsi:type="string">stable:no</data> <data name="description" xsi:type="string">Verify sales order grid full text search</data> <data name="steps" xsi:type="array"> <item name="0" xsi:type="string">-</item> @@ -23,6 +24,7 @@ <constraint name="Magento\Ui\Test\Constraint\AssertGridFullTextSearch"/> </variation> <variation name="SalesInvoiceGridFullTextSearch"> + <data name="tag" xsi:type="string">stable:no</data> <data name="description" xsi:type="string">Verify sales invoice grid full text search</data> <data name="steps" xsi:type="array"> <item name="0" xsi:type="string">Magento\Sales\Test\TestStep\CreateInvoiceStep</item> @@ -55,6 +57,7 @@ <constraint name="Magento\Ui\Test\Constraint\AssertGridFullTextSearch"/> </variation> <variation name="SalesCreditMemoGridFullTextSearch"> + <data name="tag" xsi:type="string">stable:no</data> <data name="description" xsi:type="string">Verify sales credit memo grid full text search</data> <data name="steps" xsi:type="array"> <item name="0" xsi:type="array"> diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/TestCase/GridSortingTest.xml b/dev/tests/functional/tests/app/Magento/Sales/Test/TestCase/GridSortingTest.xml index 056fa5136d433ba1700b462ad12a1c0747b9dcc1..f82f232625841ddfdd77e66812970a4de31efea6 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/TestCase/GridSortingTest.xml +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/TestCase/GridSortingTest.xml @@ -8,6 +8,7 @@ <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/etc/variations.xsd"> <testCase name="Magento\Ui\Test\TestCase\GridSortingTest" summary="Grid UI Component Sorting" ticketId="MAGETWO-41328"> <variation name="SalesOrderGridSorting"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="description" xsi:type="string">Verify sales order grid storting</data> <data name="steps" xsi:type="array"> <item name="0" xsi:type="string">-</item> @@ -26,6 +27,7 @@ <constraint name="\Magento\Ui\Test\Constraint\AssertGridSorting"/> </variation> <variation name="SalesInvoiceGridSorting"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="description" xsi:type="string">Verify sales invoince grid storting</data> <data name="steps" xsi:type="array"> <item name="0" xsi:type="string">Magento\Sales\Test\TestStep\CreateInvoiceStep</item> @@ -43,6 +45,7 @@ <constraint name="\Magento\Ui\Test\Constraint\AssertGridSorting"/> </variation> <variation name="SalesShipmentGridSorting"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="description" xsi:type="string">Verify sales shipment grid storting</data> <data name="steps" xsi:type="array"> <item name="0" xsi:type="string">Magento\Sales\Test\TestStep\CreateShipmentStep</item> @@ -60,6 +63,7 @@ <constraint name="\Magento\Ui\Test\Constraint\AssertGridSorting"/> </variation> <variation name="SalesCreditMemoGridSorting"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="description" xsi:type="string">Verify sales credit memo grid storting</data> <data name="steps" xsi:type="array"> <item name="0" xsi:type="array"> diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/TestCase/MassOrdersUpdateTest.xml b/dev/tests/functional/tests/app/Magento/Sales/Test/TestCase/MassOrdersUpdateTest.xml index 02dbf74225ba9d69ffe88e7c933e5ac0cc82da9e..4d54654a04bbbf7f1d3ea0cc2f53199538d7910c 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/TestCase/MassOrdersUpdateTest.xml +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/TestCase/MassOrdersUpdateTest.xml @@ -8,6 +8,7 @@ <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/etc/variations.xsd"> <testCase name="Magento\Sales\Test\TestCase\MassOrdersUpdateTest" summary="Mass Update Orders" ticketId="MAGETWO-27897"> <variation name="MassOrdersUpdateTestVariation1"> + <data name="tag" xsi:type="string">stable:no</data> <data name="description" xsi:type="string">cancel orders in status Pending and Processing</data> <data name="steps" xsi:type="string">-</data> <data name="action" xsi:type="string">Cancel</data> @@ -44,6 +45,7 @@ <constraint name="Magento\Sales\Test\Constraint\AssertOrdersInOrdersGrid" /> </variation> <variation name="MassOrdersUpdateTestVariation5"> + <data name="tag" xsi:type="string">stable:no</data> <data name="description" xsi:type="string">Try to put order in status Complete on Hold</data> <data name="steps" xsi:type="string">invoice, shipment</data> <data name="action" xsi:type="string">Hold</data> diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/TestCase/MoveLastOrderedProductsOnOrderPageTest.xml b/dev/tests/functional/tests/app/Magento/Sales/Test/TestCase/MoveLastOrderedProductsOnOrderPageTest.xml index 8f6466b4edc4f538918c274564888758da706b62..5f4066c1d8027a7e95b2aeab2eb8f4a8aca12330 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/TestCase/MoveLastOrderedProductsOnOrderPageTest.xml +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/TestCase/MoveLastOrderedProductsOnOrderPageTest.xml @@ -8,11 +8,13 @@ <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/etc/variations.xsd"> <testCase name="Magento\Sales\Test\TestCase\MoveLastOrderedProductsOnOrderPageTest" summary="Add Products to Order from Last Ordered Products Section" ticketId="MAGETWO-27640"> <variation name="MoveLastOrderedProductsOnOrderPageTestVariation1"> + <data name="tag" xsi:type="string">stable:no</data> <data name="order/dataset" xsi:type="string">default</data> <data name="order/data/entity_id/products" xsi:type="string">catalogProductSimple::default</data> <constraint name="Magento\Sales\Test\Constraint\AssertProductInItemsOrderedGrid" /> </variation> <variation name="MoveLastOrderedProductsOnOrderPageTestVariation2"> + <data name="issue" xsi:type="string">MAGETWO-58762: Customer grid does not open in MoveLastOrderedProductsOnOrderPageTestVariation2 on Jenkins</data> <data name="order/dataset" xsi:type="string">default</data> <data name="order/data/entity_id/products" xsi:type="string">configurableProduct::configurable_with_qty_1</data> <constraint name="Magento\Sales\Test\Constraint\AssertProductInItemsOrderedGrid" /> diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/TestCase/MoveProductsInComparedOnOrderPageTest.xml b/dev/tests/functional/tests/app/Magento/Sales/Test/TestCase/MoveProductsInComparedOnOrderPageTest.xml index 4fbfbe531e8fee71987f1881c70a889d7c3deba8..695948b8b10c9caa421ebe674cbe9fe078ec6c04 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/TestCase/MoveProductsInComparedOnOrderPageTest.xml +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/TestCase/MoveProductsInComparedOnOrderPageTest.xml @@ -8,11 +8,13 @@ <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/etc/variations.xsd"> <testCase name="Magento\Sales\Test\TestCase\MoveProductsInComparedOnOrderPageTest" summary="Add Products to Order from Products in Comparison List Section" ticketId="MAGETWO-28050"> <variation name="MoveProductsInComparedOnOrderPageTestVariation1"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="products/0" xsi:type="string">catalogProductSimple::default</data> <data name="products/1" xsi:type="string">catalogProductSimple::default</data> <constraint name="Magento\Sales\Test\Constraint\AssertProductInItemsOrderedGrid" /> </variation> <variation name="MoveProductsInComparedOnOrderPageTestVariation2"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="products/0" xsi:type="string">configurableProduct::configurable_with_qty_1</data> <data name="products/1" xsi:type="string">configurableProduct::configurable_with_qty_1</data> <constraint name="Magento\Sales\Test\Constraint\AssertProductInItemsOrderedGrid" /> diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/TestCase/MoveRecentlyComparedProductsOnOrderPageTest.xml b/dev/tests/functional/tests/app/Magento/Sales/Test/TestCase/MoveRecentlyComparedProductsOnOrderPageTest.xml index e6f96da0367cae153191a4bf3c535bc33ed97b5a..601f550e4588bfd3c613ef8a50e8615174b298ae 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/TestCase/MoveRecentlyComparedProductsOnOrderPageTest.xml +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/TestCase/MoveRecentlyComparedProductsOnOrderPageTest.xml @@ -8,11 +8,13 @@ <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/etc/variations.xsd"> <testCase name="Magento\Sales\Test\TestCase\MoveRecentlyComparedProductsOnOrderPageTest" summary="Add Products to Order from Recently Compared Products Section" ticketId="MAGETWO-28109"> <variation name="MoveRecentlyComparedProductsOnOrderPageTestVariation1"> + <data name="tag" xsi:type="string">stable:no</data> <data name="products/0" xsi:type="string">catalogProductSimple::default</data> <data name="products/1" xsi:type="string">catalogProductSimple::default</data> <constraint name="Magento\Sales\Test\Constraint\AssertProductInItemsOrderedGrid" /> </variation> <variation name="MoveRecentlyComparedProductsOnOrderPageTestVariation2"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="products/0" xsi:type="string">configurableProduct::configurable_with_qty_1</data> <data name="products/1" xsi:type="string">configurableProduct::configurable_with_qty_1</data> <constraint name="Magento\Sales\Test\Constraint\AssertProductInItemsOrderedGrid" /> diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/TestCase/MoveRecentlyViewedProductsOnOrderPageTest.xml b/dev/tests/functional/tests/app/Magento/Sales/Test/TestCase/MoveRecentlyViewedProductsOnOrderPageTest.xml index 2e1c3eeea7b8942febf1b8f3505f6c1c9e407106..ae955b301d95687cb1aad697fb79a591c4e5c2d2 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/TestCase/MoveRecentlyViewedProductsOnOrderPageTest.xml +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/TestCase/MoveRecentlyViewedProductsOnOrderPageTest.xml @@ -8,10 +8,12 @@ <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/etc/variations.xsd"> <testCase name="Magento\Sales\Test\TestCase\MoveRecentlyViewedProductsOnOrderPageTest" summary="Add Products to Order from Recently Viewed Products Section" ticketId="MAGETWO-29723"> <variation name="MoveRecentlyViewedProductsOnOrderPageTestVariation1"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="products/0" xsi:type="string">configurableProduct::default</data> <constraint name="Magento\Sales\Test\Constraint\AssertProductInItemsOrderedGrid" /> </variation> <variation name="MoveRecentlyViewedProductsOnOrderPageTestVariation2"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="products/0" xsi:type="string">bundleProduct::bundle_fixed_product</data> <constraint name="Magento\Sales\Test\Constraint\AssertProductInItemsOrderedGrid" /> </variation> diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/TestCase/MoveShoppingCartProductsOnOrderPageTest.xml b/dev/tests/functional/tests/app/Magento/Sales/Test/TestCase/MoveShoppingCartProductsOnOrderPageTest.xml index e29a63165ad03aa8eddb4186546632e0c97c7687..53f321366de5ecc53d2d87ade453478371572274 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/TestCase/MoveShoppingCartProductsOnOrderPageTest.xml +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/TestCase/MoveShoppingCartProductsOnOrderPageTest.xml @@ -8,10 +8,12 @@ <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/etc/variations.xsd"> <testCase name="Magento\Sales\Test\TestCase\MoveShoppingCartProductsOnOrderPageTest" summary="Add Products to Order from Shopping Cart " ticketId="MAGETWO-28540"> <variation name="MoveShoppingCartProductsOnOrderPageTestVariation1"> + <data name="tag" xsi:type="string">stable:no</data> <data name="product" xsi:type="string">catalogProductSimple::default</data> <constraint name="Magento\Sales\Test\Constraint\AssertProductInItemsOrderedGrid" /> </variation> <variation name="MoveShoppingCartProductsOnOrderPageTestVariation2" firstConstraint="Magento\ConfigurableProduct\Test\Constraint\AssertConfigurableProductInItemsOrderedGrid" method="test"> + <data name="tag" xsi:type="string">stable:no</data> <data name="product" xsi:type="string">configurableProduct::configurable_with_qty_1</data> <constraint name="Magento\Sales\Test\Constraint\AssertProductInItemsOrderedGrid" /> </variation> diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/TestCase/PrintOrderFrontendGuestTest.xml b/dev/tests/functional/tests/app/Magento/Sales/Test/TestCase/PrintOrderFrontendGuestTest.xml index 4dc6ae8d2fcd1d55062da03c74b7dce41c70c08c..46349665259d03f2626dbbb2723e3a8d18e864f6 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/TestCase/PrintOrderFrontendGuestTest.xml +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/TestCase/PrintOrderFrontendGuestTest.xml @@ -8,6 +8,7 @@ <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/etc/variations.xsd"> <testCase name="Magento\Sales\Test\TestCase\PrintOrderFrontendGuestTest" summary="Print Order from Guest on Frontend" ticketId="MAGETWO-30253"> <variation name="PrintOrderFrontendGuestTestVariation1"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="customer" xsi:type="array"> <item name="dataset" xsi:type="string">johndoe_with_addresses</item> </data> diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/TestCase/ReorderOrderEntityTest.xml b/dev/tests/functional/tests/app/Magento/Sales/Test/TestCase/ReorderOrderEntityTest.xml index 7608ec4f68ca0d01fd8c7f736d0429ad45972503..8124a32c66eb1149c2c3e30fd79ee41381b0ee15 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/TestCase/ReorderOrderEntityTest.xml +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/TestCase/ReorderOrderEntityTest.xml @@ -8,6 +8,7 @@ <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/etc/variations.xsd"> <testCase name="Magento\Sales\Test\TestCase\ReorderOrderEntityTest" summary="Reorder Order from Admin for Offline Payment Methods" ticketId="MAGETWO-29007"> <variation name="ReorderOrderEntityTestVariation1"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="description" xsi:type="string">Reorder placed order (update products, billing address).</data> <data name="order/dataset" xsi:type="string">two_simple_product</data> <data name="salesRule" xsi:type="string">active_sales_rule_with_fixed_price_discount_coupon</data> diff --git a/dev/tests/functional/tests/app/Magento/SalesRule/Test/TestCase/ApplySeveralSalesRuleEntityTest.xml b/dev/tests/functional/tests/app/Magento/SalesRule/Test/TestCase/ApplySeveralSalesRuleEntityTest.xml index 4b837e442a4abc83219daf45301fe5a20570f1e0..b1893651726f8a562fe4ba3b9299c17e2ca082d3 100644 --- a/dev/tests/functional/tests/app/Magento/SalesRule/Test/TestCase/ApplySeveralSalesRuleEntityTest.xml +++ b/dev/tests/functional/tests/app/Magento/SalesRule/Test/TestCase/ApplySeveralSalesRuleEntityTest.xml @@ -8,6 +8,7 @@ <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/etc/variations.xsd"> <testCase name="Magento\SalesRule\Test\TestCase\ApplySeveralSalesRuleEntityTest" summary="Apply Several Sales Rules" ticketId="MAGETWO-45883"> <variation name="ApplySeveralSalesRuleEntityTestVariation1" summary="Rules with same priority, both are applied"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="salesRules/rule1" xsi:type="string">active_sales_rule_product_subselection</data> <data name="salesRules/rule2" xsi:type="string">active_sales_rule_product_attribute</data> <data name="cartPrice/sub_total" xsi:type="string">200.00</data> @@ -31,6 +32,7 @@ <constraint name="Magento\SalesRule\Test\Constraint\AssertCartPriceRuleConditionIsApplied" /> </variation> <variation name="ApplySeveralSalesRuleEntityTestVariation3" summary="Rules with different priority, both are applied"> + <data name="tag" xsi:type="string">stable:no</data> <data name="salesRules/rule1" xsi:type="string">active_sales_rule_product_attribute</data> <data name="salesRules/rule2" xsi:type="string">active_sales_total_items</data> <data name="cartPrice/sub_total" xsi:type="string">250.00</data> @@ -43,6 +45,7 @@ <constraint name="Magento\SalesRule\Test\Constraint\AssertCartPriceRuleConditionIsApplied" /> </variation> <variation name="ApplySeveralSalesRuleEntityTestVariation4" summary="Rules with different priority, none are applied"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="salesRules/rule1" xsi:type="string">active_sales_rule_row_total</data> <data name="salesRules/rule2" xsi:type="string">active_sales_total_items</data> <data name="productForSalesRule1/dataset" xsi:type="string">simple_for_salesrule_1</data> diff --git a/dev/tests/functional/tests/app/Magento/SalesRule/Test/TestCase/CreateSalesRuleEntityTest.xml b/dev/tests/functional/tests/app/Magento/SalesRule/Test/TestCase/CreateSalesRuleEntityTest.xml index bfa18c65bdcf8362a49c2c2f25ddb6d439c4d99d..d0ad41011004a3fef531865ca1c6265f9406684e 100644 --- a/dev/tests/functional/tests/app/Magento/SalesRule/Test/TestCase/CreateSalesRuleEntityTest.xml +++ b/dev/tests/functional/tests/app/Magento/SalesRule/Test/TestCase/CreateSalesRuleEntityTest.xml @@ -145,6 +145,7 @@ <constraint name="Magento\SalesRule\Test\Constraint\AssertCartPriceRuleConditionIsApplied" /> </variation> <variation name="CreateSalesRuleEntityTestVariation6"> + <data name="tag" xsi:type="string">stable:no</data> <data name="address/data/country_id" xsi:type="string">United States</data> <data name="address/data/region_id" xsi:type="string">California</data> <data name="address/data/postcode" xsi:type="string">95814</data> diff --git a/dev/tests/functional/tests/app/Magento/SalesRule/Test/etc/testcase.xml b/dev/tests/functional/tests/app/Magento/SalesRule/Test/etc/testcase.xml index 37f8366674e0573e6d7837a004b3d98fef1dadc0..b894aada2e2ba54ec7c0658b85492b66071dd1c1 100644 --- a/dev/tests/functional/tests/app/Magento/SalesRule/Test/etc/testcase.xml +++ b/dev/tests/functional/tests/app/Magento/SalesRule/Test/etc/testcase.xml @@ -32,8 +32,8 @@ <step name="applySalesRuleOnBackend" module="Magento_SalesRule" next="fillBillingAddress" /> </scenario> <scenario name="CreateOrderBackendTest"> - <step name="createSalesRule" module="Magento_SalesRule" next="applySalesRuleOnBackend" /> - <step name="applySalesRuleOnBackend" module="Magento_SalesRule" next="fillBillingAddress" /> + <step name="createSalesRule" module="Magento_SalesRule" prev="fillShippingAddress" next="applySalesRuleOnBackend" /> + <step name="applySalesRuleOnBackend" module="Magento_SalesRule" /> </scenario> <scenario name="CreateOrderFromCustomerPageTest"> <step name="createSalesRule" module="Magento_SalesRule" next="applySalesRuleOnBackend" /> diff --git a/dev/tests/functional/tests/app/Magento/Search/Test/TestCase/CreateSynonymGroupEntityTest.xml b/dev/tests/functional/tests/app/Magento/Search/Test/TestCase/CreateSynonymGroupEntityTest.xml index 21279437ea834b921f2a910714f25daf5735ca84..79a170819c50600ba0f2f15811a8b3cdfe94cb7a 100644 --- a/dev/tests/functional/tests/app/Magento/Search/Test/TestCase/CreateSynonymGroupEntityTest.xml +++ b/dev/tests/functional/tests/app/Magento/Search/Test/TestCase/CreateSynonymGroupEntityTest.xml @@ -25,7 +25,7 @@ </testCase> <testCase name="Magento\Search\Test\TestCase\CreateSynonymGroupEntityTest" summary="Create Synonym Group with custom Website and Store View" ticketId="MAGETWO-47681"> <variation name="CreateSynonymGroupEntityTestVariation3"> - <data name="tag" xsi:type="string">test_type:extended_acceptance_test</data> + <data name="tag" xsi:type="string">test_type:extended_acceptance_test, stable:no</data> <data name="synonymGroup/data/synonyms" xsi:type="string">synonym_%isolation%</data> <data name="synonymGroup/data/scope_id/dataset" xsi:type="string">custom_store</data> <constraint name="Magento\Search\Test\Constraint\AssertSynonymGroupSuccessSaveMessage" /> diff --git a/dev/tests/functional/tests/app/Magento/Search/Test/TestCase/UpdateSynonymGroupEntityTest.xml b/dev/tests/functional/tests/app/Magento/Search/Test/TestCase/UpdateSynonymGroupEntityTest.xml index 2e6e6cb2e4812b13e0354bf9ec9794f1c845a4db..636cf66fd2c86da20cd331b9a0b1c9b3f549f45d 100644 --- a/dev/tests/functional/tests/app/Magento/Search/Test/TestCase/UpdateSynonymGroupEntityTest.xml +++ b/dev/tests/functional/tests/app/Magento/Search/Test/TestCase/UpdateSynonymGroupEntityTest.xml @@ -8,9 +8,9 @@ <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/etc/variations.xsd"> <testCase name="Magento\Search\Test\TestCase\UpdateSynonymGroupEntityTest" summary="Update Synonym Groups" ticketId="MAGETWO-49412"> <variation name="UpdateSynonymGroupEntityTestVariation1"> + <data name="tag" xsi:type="string">test_type:extended_acceptance_test, to_maintain:yes</data> <data name="initialSynonymGroup/dataset" xsi:type="string">prepareMerge</data> <data name="description" xsi:type="string">Update Synonym Groups Successfully</data> - <data name="tag" xsi:type="string">test_type:extended_acceptance_test</data> <data name="synonymGroup/data/synonyms" xsi:type="string">new_synonym_%isolation%</data> <data name="synonymGroup/data/scope_id/dataset" xsi:type="string">all_store_views</data> <constraint name="Magento\Search\Test\Constraint\AssertSynonymGroupSuccessSaveMessage" /> diff --git a/dev/tests/functional/tests/app/Magento/Security/Test/TestCase/LockCustomerOnEditPageTest.xml b/dev/tests/functional/tests/app/Magento/Security/Test/TestCase/LockCustomerOnEditPageTest.xml index eeb0dd7ab12e9e33eec107f17d3678d4ec1827ad..1a5443ec9e61558b5b7cad2a9ada57825c451581 100644 --- a/dev/tests/functional/tests/app/Magento/Security/Test/TestCase/LockCustomerOnEditPageTest.xml +++ b/dev/tests/functional/tests/app/Magento/Security/Test/TestCase/LockCustomerOnEditPageTest.xml @@ -8,7 +8,7 @@ <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/etc/variations.xsd"> <testCase name="Magento\Security\Test\TestCase\LockCustomerOnEditPageTest" summary="Lock customer from edit page"> <variation name="LockCustomerOnEditPageTest1"> - <data name="tag" xsi:type="string">severity:S1</data> + <data name="tag" xsi:type="string">severity:S1, to_maintain:yes</data> <data name="configData" xsi:type="string">customer_max_login_failures_number</data> <data name="initialCustomer/dataset" xsi:type="string">default</data> <data name="customer/data/current_password" xsi:type="string">incorrect password</data> diff --git a/dev/tests/functional/tests/app/Magento/Security/Test/TestCase/LockCustomerOnLoginPageTest.xml b/dev/tests/functional/tests/app/Magento/Security/Test/TestCase/LockCustomerOnLoginPageTest.xml index a5376d73685bad9e54d4ff094348b7100c2a2a8d..df5c5bce59fe0400b308530085e99c541da60323 100644 --- a/dev/tests/functional/tests/app/Magento/Security/Test/TestCase/LockCustomerOnLoginPageTest.xml +++ b/dev/tests/functional/tests/app/Magento/Security/Test/TestCase/LockCustomerOnLoginPageTest.xml @@ -8,7 +8,7 @@ <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/etc/variations.xsd"> <testCase name="Magento\Security\Test\TestCase\LockCustomerOnLoginPageTest" summary="Lock customer on login page"> <variation name="LockCustomerOnLoginPageTestVariation1"> - <data name="tag" xsi:type="string">severity:S1</data> + <data name="tag" xsi:type="string">severity:S1, to_maintain:yes</data> <data name="configData" xsi:type="string">customer_max_login_failures_number</data> <data name="initialCustomer/dataset" xsi:type="string">default</data> <data name="incorrectPassword" xsi:type="string">incorrect password</data> diff --git a/dev/tests/functional/tests/app/Magento/Store/Test/TestCase/DeleteStoreEntityTest.xml b/dev/tests/functional/tests/app/Magento/Store/Test/TestCase/DeleteStoreEntityTest.xml index b888ba1f778370d11e19ded0f8c40cfd543541ea..2c3809e27f2eff076ffd538d7aebcfa4fed04e7f 100644 --- a/dev/tests/functional/tests/app/Magento/Store/Test/TestCase/DeleteStoreEntityTest.xml +++ b/dev/tests/functional/tests/app/Magento/Store/Test/TestCase/DeleteStoreEntityTest.xml @@ -17,7 +17,7 @@ <constraint name="Magento\Store\Test\Constraint\AssertStoreNotOnFrontend" /> </variation> <variation name="DeleteStoreEntityTestVariation2"> - <data name="tag" xsi:type="string">severity:S2</data> + <data name="tag" xsi:type="string">severity:S2, stable:no</data> <data name="store/dataset" xsi:type="string">custom</data> <data name="createBackup" xsi:type="string">No</data> <constraint name="Magento\Store\Test\Constraint\AssertStoreSuccessDeleteMessage" /> diff --git a/dev/tests/functional/tests/app/Magento/Store/Test/TestCase/DeleteStoreGroupEntityTest.xml b/dev/tests/functional/tests/app/Magento/Store/Test/TestCase/DeleteStoreGroupEntityTest.xml index 16c0aeb358bb0fe5e7f0e18216300161c6dfbbf1..cfda1263ac19f8355370ad5cb507b44a8aa43f29 100644 --- a/dev/tests/functional/tests/app/Magento/Store/Test/TestCase/DeleteStoreGroupEntityTest.xml +++ b/dev/tests/functional/tests/app/Magento/Store/Test/TestCase/DeleteStoreGroupEntityTest.xml @@ -8,7 +8,7 @@ <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/etc/variations.xsd"> <testCase name="Magento\Store\Test\TestCase\DeleteStoreGroupEntityTest" summary="Delete Store Group" ticketId="MAGETWO-27596"> <variation name="DeleteStoreGroupEntityTestVariation1"> - <data name="tag" xsi:type="string">severity:S3</data> + <data name="tag" xsi:type="string">severity:S3, stable:no</data> <data name="storeGroup/dataset" xsi:type="string">custom</data> <data name="createBackup" xsi:type="string">Yes</data> <constraint name="Magento\Store\Test\Constraint\AssertStoreGroupSuccessDeleteAndBackupMessages" /> @@ -16,7 +16,7 @@ <constraint name="Magento\Backup\Test\Constraint\AssertBackupInGrid" /> </variation> <variation name="DeleteStoreGroupEntityTestVariation2"> - <data name="tag" xsi:type="string">severity:S3</data> + <data name="tag" xsi:type="string">severity:S3, stable:no</data> <data name="storeGroup/dataset" xsi:type="string">custom</data> <data name="createBackup" xsi:type="string">No</data> <constraint name="Magento\Store\Test\Constraint\AssertStoreGroupSuccessDeleteMessage" /> diff --git a/dev/tests/functional/tests/app/Magento/Store/Test/TestCase/DeleteWebsiteEntityTest.php b/dev/tests/functional/tests/app/Magento/Store/Test/TestCase/DeleteWebsiteEntityTest.php index 94e14b4a42317edaa2b1f151a3858c770a74fc68..f349131fe5848a5a6b1f44c696bf96969053b19e 100644 --- a/dev/tests/functional/tests/app/Magento/Store/Test/TestCase/DeleteWebsiteEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Store/Test/TestCase/DeleteWebsiteEntityTest.php @@ -39,6 +39,7 @@ class DeleteWebsiteEntityTest extends Injectable /* tags */ const MVP = 'yes'; const SEVERITY = 'S3'; + const STABLE = 'no'; /* end tags */ /** diff --git a/dev/tests/functional/tests/app/Magento/Tax/Test/TestCase/CreateTaxRuleEntityTest.php b/dev/tests/functional/tests/app/Magento/Tax/Test/TestCase/CreateTaxRuleEntityTest.php index 9cfa401510bc17bd1e0651f7cb3a71370c46a2fe..55a6694571ac14f4bdb805f57d847db5db87fc62 100644 --- a/dev/tests/functional/tests/app/Magento/Tax/Test/TestCase/CreateTaxRuleEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Tax/Test/TestCase/CreateTaxRuleEntityTest.php @@ -28,6 +28,7 @@ class CreateTaxRuleEntityTest extends Injectable /* tags */ const MVP = 'yes'; const TEST_TYPE = 'acceptance_test, extended_acceptance_test'; + const TO_MAINTAIN = 'yes'; /* end tags */ /** diff --git a/dev/tests/functional/tests/app/Magento/Tax/Test/TestCase/CreateTaxRuleEntityTest.xml b/dev/tests/functional/tests/app/Magento/Tax/Test/TestCase/CreateTaxRuleEntityTest.xml index 5d338af60555fbb68836d8abb8a53cf9c2d7ceae..7bbf6d29e7b9fb13c7df662f885c2a089f73f843 100644 --- a/dev/tests/functional/tests/app/Magento/Tax/Test/TestCase/CreateTaxRuleEntityTest.xml +++ b/dev/tests/functional/tests/app/Magento/Tax/Test/TestCase/CreateTaxRuleEntityTest.xml @@ -19,6 +19,7 @@ <constraint name="Magento\Tax\Test\Constraint\AssertTaxRuleForm" /> </variation> <variation name="CreateTaxRuleEntityTestVariation2"> + <data name="tag" xsi:type="string">stable:no</data> <data name="taxRule/data/code" xsi:type="string">TaxIdentifier%isolation%</data> <data name="taxRule/data/tax_rate/dataset/rate_0" xsi:type="string">US-CA-Rate_1</data> <data name="taxRule/data/tax_rate/dataset/rate_1" xsi:type="string">US-NY-Rate_1</data> @@ -47,6 +48,7 @@ <constraint name="Magento\Tax\Test\Constraint\AssertTaxRuleForm" /> </variation> <variation name="CreateTaxRuleEntityTestVariation4"> + <data name="tag" xsi:type="string">stable:no</data> <data name="taxRule/data/code" xsi:type="string">TaxIdentifier%isolation%</data> <data name="taxRule/data/tax_rate/dataset/rate_0" xsi:type="string">withZipRange</data> <data name="taxRule/data/tax_rate/dataset/rate_1" xsi:type="string">US-CA-Rate_1</data> diff --git a/dev/tests/functional/tests/app/Magento/Tax/Test/TestCase/TaxCalculationTest.xml b/dev/tests/functional/tests/app/Magento/Tax/Test/TestCase/TaxCalculationTest.xml index 9414b9a0172f173d18604ed5929c5617adce4341..cda7bf0665b01b8ace1ef863d84932ab44388c47 100644 --- a/dev/tests/functional/tests/app/Magento/Tax/Test/TestCase/TaxCalculationTest.xml +++ b/dev/tests/functional/tests/app/Magento/Tax/Test/TestCase/TaxCalculationTest.xml @@ -8,6 +8,7 @@ <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/etc/variations.xsd"> <testCase name="Magento\Tax\Test\TestCase\TaxCalculationTest" summary="Apply Taxes for products" ticketId="MAGETWO-27809"> <variation name="TaxCalculationTestVariation1"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="description" xsi:type="string">Simple product tier price with sales rule, customer tax equals store tax and catalog price including tax</data> <data name="configData" xsi:type="string">shipping_tax_class_taxable_goods, row_cat_incl_ship_excl_after_disc_on_excl, display_excluding_including_tax</data> <data name="product" xsi:type="string">catalogProductSimple::simple_with_tier_price_and_category</data> @@ -37,6 +38,7 @@ <constraint name="Magento\Tax\Test\Constraint\AssertOrderTaxOnBackendExcludingIncludingTax" /> </variation> <variation name="TaxCalculationTestVariation4"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="description" xsi:type="string">Simple product special price with sales rule, customer tax less than store tax and catalog price including tax</data> <data name="configData" xsi:type="string">shipping_tax_class_taxable_goods, row_cat_incl_ship_excl_before_disc_on_incl, display_excluding_including_tax</data> <data name="product" xsi:type="string">catalogProductSimple::product_with_special_price_and_category</data> @@ -66,6 +68,7 @@ <constraint name="Magento\Tax\Test\Constraint\AssertOrderTaxOnBackendExcludingIncludingTax" /> </variation> <variation name="TaxCalculationTestVariation5"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="description" xsi:type="string">Simple product tier price with sales rule, customer tax less than store tax and catalog price including tax</data> <data name="configData" xsi:type="string">shipping_tax_class_taxable_goods, unit_cat_incl_ship_incl_before_disc_on_incl, display_excluding_including_tax</data> <data name="product" xsi:type="string">catalogProductSimple::simple_with_tier_price_and_category</data> @@ -95,6 +98,7 @@ <constraint name="Magento\Tax\Test\Constraint\AssertOrderTaxOnBackendExcludingIncludingTax" /> </variation> <variation name="TaxCalculationTestVariation6"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="description" xsi:type="string">Simple product special price with sales rule, customer tax equals store tax and catalog price excluding tax</data> <data name="configData" xsi:type="string">shipping_tax_class_taxable_goods, total_cat_excl_ship_incl_before_disc_on_incl, display_excluding_including_tax</data> <data name="product" xsi:type="string">catalogProductSimple::product_with_special_price_and_category</data> @@ -124,6 +128,7 @@ <constraint name="Magento\Tax\Test\Constraint\AssertOrderTaxOnBackendExcludingIncludingTax" /> </variation> <variation name="TaxCalculationTestVariation9"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="description" xsi:type="string">Simple product tier price with sales rule, customer tax greater than store tax and catalog price excluding tax</data> <data name="configData" xsi:type="string">shipping_tax_class_taxable_goods, total_cat_excl_ship_incl_after_disc_on_incl, display_excluding_including_tax</data> <data name="product" xsi:type="string">catalogProductSimple::simple_with_tier_price_and_category</data> @@ -153,6 +158,7 @@ <constraint name="Magento\Tax\Test\Constraint\AssertOrderTaxOnBackendExcludingIncludingTax" /> </variation> <variation name="TaxCalculationTestVariation10"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="description" xsi:type="string">Simple product special price with sales rule, customer tax greater than store tax and catalog price excluding tax</data> <data name="configData" xsi:type="string">shipping_tax_class_taxable_goods, unit_cat_excl_ship_incl_after_disc_on_excl, display_excluding_including_tax</data> <data name="product" xsi:type="string">catalogProductSimple::product_with_special_price_and_category</data> diff --git a/dev/tests/functional/tests/app/Magento/Tax/Test/TestCase/TaxWithCrossBorderTest.php b/dev/tests/functional/tests/app/Magento/Tax/Test/TestCase/TaxWithCrossBorderTest.php index 9517ee063ce67cbf33e50ed44412d8e7253526e2..09debcf5f75eb3441b6b18bcab438ecda3f757a3 100644 --- a/dev/tests/functional/tests/app/Magento/Tax/Test/TestCase/TaxWithCrossBorderTest.php +++ b/dev/tests/functional/tests/app/Magento/Tax/Test/TestCase/TaxWithCrossBorderTest.php @@ -37,6 +37,7 @@ class TaxWithCrossBorderTest extends Injectable { /* tags */ const MVP = 'yes'; + const STABLE = 'no'; /* end tags */ /** diff --git a/dev/tests/functional/tests/app/Magento/Tax/Test/TestCase/UpdateTaxRuleEntityTest.xml b/dev/tests/functional/tests/app/Magento/Tax/Test/TestCase/UpdateTaxRuleEntityTest.xml index a485579634ed95e4027f2147088257ad6b256a52..58e7b2b038cc20cfb4ab079254f18edd6413bf9f 100644 --- a/dev/tests/functional/tests/app/Magento/Tax/Test/TestCase/UpdateTaxRuleEntityTest.xml +++ b/dev/tests/functional/tests/app/Magento/Tax/Test/TestCase/UpdateTaxRuleEntityTest.xml @@ -48,6 +48,7 @@ <constraint name="Magento\Tax\Test\Constraint\AssertTaxRuleIsApplied" /> </variation> <variation name="UpdateTaxRuleEntityTestVariation4"> + <data name="tag" xsi:type="string">stable:no</data> <data name="initialTaxRule/dataset" xsi:type="string">tax_rule_with_custom_tax_classes</data> <data name="address/data/country_id" xsi:type="string">United States</data> <data name="address/data/region_id" xsi:type="string">Idaho</data> diff --git a/dev/tests/functional/tests/app/Magento/Ui/Test/Block/Adminhtml/DataGrid.php b/dev/tests/functional/tests/app/Magento/Ui/Test/Block/Adminhtml/DataGrid.php index 95240b5dba0644d7f10d80447399d516a4742ac2..c5968c8e936f8a5bead20016d9c70d699b8c1a0c 100644 --- a/dev/tests/functional/tests/app/Magento/Ui/Test/Block/Adminhtml/DataGrid.php +++ b/dev/tests/functional/tests/app/Magento/Ui/Test/Block/Adminhtml/DataGrid.php @@ -71,7 +71,7 @@ class DataGrid extends Grid * * @var string */ - protected $massActionToggleList = '//span[contains(@class, "action-menu-item") and .= "%s"]'; + protected $massActionToggleList = './/span[contains(@class, "action-menu-item") and .= "%s"]'; /** * Action button (located above the Grid). @@ -85,7 +85,7 @@ class DataGrid extends Grid * * @var string */ - protected $actionList = '//span[contains(@class, "action-menu-item") and .= "%s"]'; + protected $actionList = './/span[contains(@class, "action-menu-item") and .= "%s"]'; /** * Column header locator. @@ -104,6 +104,13 @@ class DataGrid extends Grid * @var string */ private $cellByHeader = "//td[count(//th[span[.='%s']][not(ancestor::*[@class='sticky-header'])]/preceding-sibling::th)+1]"; + + /** + * Admin data grid header selector. + * + * @var string + */ + private $gridHeader = './/div[@class="admin__data-grid-header"][(not(ancestor::*[@class="sticky-header"]) and not(contains(@style,"visibility: hidden"))) or (ancestor::*[@class="sticky-header" and not(contains(@style,"display: none"))])]'; // @codingStandardsIgnoreEnd /** @@ -322,12 +329,12 @@ class DataGrid extends Grid public function selectAction($action) { $actionType = is_array($action) ? key($action) : $action; - $this->_rootElement->find($this->actionButton)->click(); - $this->_rootElement + $this->getGridHeaderElement()->find($this->actionButton)->click(); + $this->getGridHeaderElement() ->find(sprintf($this->actionList, $actionType), Locator::SELECTOR_XPATH) ->click(); if (is_array($action)) { - $this->_rootElement + $this->getGridHeaderElement() ->find(sprintf($this->actionList, end($action)), Locator::SELECTOR_XPATH) ->click(); } @@ -463,4 +470,14 @@ class DataGrid extends Grid return $data; } + + /** + * Returns admin data grid header element. + * + * @return \Magento\Mtf\Client\ElementInterface + */ + private function getGridHeaderElement() + { + return $this->_rootElement->find($this->gridHeader, Locator::SELECTOR_XPATH); + } } diff --git a/dev/tests/functional/tests/app/Magento/Ui/Test/TestCase/GridFilteringTest.php b/dev/tests/functional/tests/app/Magento/Ui/Test/TestCase/GridFilteringTest.php index 39a80b783a0a1cf2dcb36a91e8d140bf3e236b8c..4b923dd4344a93be0e2bf3491c30eecf823f76ba 100644 --- a/dev/tests/functional/tests/app/Magento/Ui/Test/TestCase/GridFilteringTest.php +++ b/dev/tests/functional/tests/app/Magento/Ui/Test/TestCase/GridFilteringTest.php @@ -28,6 +28,7 @@ use Magento\Ui\Test\Block\Adminhtml\DataGrid; class GridFilteringTest extends Injectable { /* tags */ + const STABLE = 'no'; const MVP = 'no'; /* end tags */ diff --git a/dev/tests/functional/tests/app/Magento/Ui/Test/TestCase/GridFullTextSearchTest.php b/dev/tests/functional/tests/app/Magento/Ui/Test/TestCase/GridFullTextSearchTest.php index c0049f0cc2fb39d22758a1ce3cae3fcc22bf9552..510d2d61c0acd2100b295ee1422015b1833d9c36 100644 --- a/dev/tests/functional/tests/app/Magento/Ui/Test/TestCase/GridFullTextSearchTest.php +++ b/dev/tests/functional/tests/app/Magento/Ui/Test/TestCase/GridFullTextSearchTest.php @@ -28,6 +28,7 @@ use Magento\Ui\Test\Block\Adminhtml\DataGrid; class GridFullTextSearchTest extends Injectable { /* tags */ + const STABLE = 'no'; const MVP = 'no'; /* end tags */ diff --git a/dev/tests/functional/tests/app/Magento/User/Test/TestCase/CreateAdminUserEntityTest.php b/dev/tests/functional/tests/app/Magento/User/Test/TestCase/CreateAdminUserEntityTest.php index 2003bb4b27770239a2b9c2b8d75dc1a9a178f02b..fdf10565117764fa85727d38a4d10c44e4047261 100644 --- a/dev/tests/functional/tests/app/Magento/User/Test/TestCase/CreateAdminUserEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/User/Test/TestCase/CreateAdminUserEntityTest.php @@ -31,6 +31,7 @@ class CreateAdminUserEntityTest extends Injectable /* tags */ const MVP = 'no'; const TEST_TYPE = 'extended_acceptance_test'; + const STABLE = 'no'; /* end tags */ /** diff --git a/dev/tests/functional/tests/app/Magento/Variable/Test/TestCase/CreateCustomVariableEntityTest.xml b/dev/tests/functional/tests/app/Magento/Variable/Test/TestCase/CreateCustomVariableEntityTest.xml index 381728cb375aef1595153431fa704812689be7cd..4860c6c93696c038b9de309a9ee068e09d65b284 100644 --- a/dev/tests/functional/tests/app/Magento/Variable/Test/TestCase/CreateCustomVariableEntityTest.xml +++ b/dev/tests/functional/tests/app/Magento/Variable/Test/TestCase/CreateCustomVariableEntityTest.xml @@ -19,6 +19,7 @@ <constraint name="Magento\Variable\Test\Constraint\AssertCustomVariableInPage" /> </variation> <variation name="CreateCustomVariableEntityTestVariation2"> + <data name="tag" xsi:type="string">stable:no</data> <data name="customVariable/data/code" xsi:type="string">variableCode%isolation%</data> <data name="customVariable/data/name" xsi:type="string">variableName%isolation%</data> <data name="customVariable/data/html_value" xsi:type="string"><p>variableName%isolation%</p></data> diff --git a/dev/tests/functional/tests/app/Magento/Variable/Test/TestCase/DeleteCustomVariableEntityTest.xml b/dev/tests/functional/tests/app/Magento/Variable/Test/TestCase/DeleteCustomVariableEntityTest.xml index 7f2306c5154e78095979c1b64c7f171feacd722f..7234c455fcc223a6b373a04cd0f0672a2c40781e 100644 --- a/dev/tests/functional/tests/app/Magento/Variable/Test/TestCase/DeleteCustomVariableEntityTest.xml +++ b/dev/tests/functional/tests/app/Magento/Variable/Test/TestCase/DeleteCustomVariableEntityTest.xml @@ -8,6 +8,7 @@ <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/etc/variations.xsd"> <testCase name="Magento\Variable\Test\TestCase\DeleteCustomVariableEntityTest" summary="Delete Custom Variable" ticketId="MAGETWO-25535"> <variation name="DeleteCustomVariableEntityTestVariation1"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <constraint name="Magento\Variable\Test\Constraint\AssertCustomVariableSuccessDeleteMessage" /> <constraint name="Magento\Variable\Test\Constraint\AssertCustomVariableNotInGrid" /> <constraint name="Magento\Variable\Test\Constraint\AssertCustomVariableNotInCmsPageForm" /> diff --git a/dev/tests/functional/tests/app/Magento/Weee/Test/TestCase/CreateTaxWithFptTest.xml b/dev/tests/functional/tests/app/Magento/Weee/Test/TestCase/CreateTaxWithFptTest.xml index 060d2fbc9a7e6f51113238ebf186930d864eec4c..247b22c86a1b207e686fd584b06b297aa4fa3668 100644 --- a/dev/tests/functional/tests/app/Magento/Weee/Test/TestCase/CreateTaxWithFptTest.xml +++ b/dev/tests/functional/tests/app/Magento/Weee/Test/TestCase/CreateTaxWithFptTest.xml @@ -8,6 +8,7 @@ <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/etc/variations.xsd"> <testCase name="Magento\Weee\Test\TestCase\CreateTaxWithFptTest" summary="Apply FPT to Different Type Prices" ticketId="MAGETWO-29551"> <variation name="CreateTaxWithFptTestVariation1" firstConstraint="Magento\Weee\Test\Constraint\AssertFptApplied" method="test"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="description" xsi:type="string">Check not taxed FPT display set to Excluding, Description and Including FPT on product with custom option catalog price Excluding Tax</data> <data name="configData" xsi:type="string">shipping_tax_class_taxable_goods,tax_with_fpt_cat_excl_disc_on_excl</data> <data name="productData" xsi:type="string">with_custom_option_and_fpt</data> @@ -28,6 +29,7 @@ <constraint name="Magento\Weee\Test\Constraint\AssertFptApplied" /> </variation> <variation name="CreateTaxWithFptTestVariation2" firstConstraint="Magento\Weee\Test\Constraint\AssertFptApplied" method="test"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="description" xsi:type="string">Check not taxed FPT display set to Including FPT and Description on product with custom option catalog price Excluding Tax</data> <data name="configData" xsi:type="string">shipping_tax_class_taxable_goods,tax_with_fpt_cat_excl_disc_on_incl, display_including_tax</data> <data name="productData" xsi:type="string">with_custom_option_and_fpt</data> @@ -50,6 +52,7 @@ <constraint name="Magento\Weee\Test\Constraint\AssertFptApplied" /> </variation> <variation name="CreateTaxWithFptTestVariation3" firstConstraint="Magento\Weee\Test\Constraint\AssertFptApplied" method="test"> + <data name="tag" xsi:type="string">stable:no</data> <data name="description" xsi:type="string">Check not taxed FPT display set to Excluding, Description and Including FPT on product with special price catalog price Excluding Tax</data> <data name="configData" xsi:type="string">shipping_tax_class_taxable_goods,tax_with_fpt_cat_excl_disc_on_incl, display_including_tax</data> <data name="productData" xsi:type="string">with_special_price_and_fpt</data> @@ -72,6 +75,7 @@ <constraint name="Magento\Weee\Test\Constraint\AssertFptApplied" /> </variation> <variation name="CreateTaxWithFptTestVariation4" firstConstraint="Magento\Weee\Test\Constraint\AssertFptApplied" method="test"> + <data name="tag" xsi:type="string">stable:no</data> <data name="description" xsi:type="string">Check not taxed FPT display set to Including FPT and Description on product with special price catalog price Excluding Tax</data> <data name="configData" xsi:type="string">shipping_tax_class_taxable_goods,tax_with_fpt_cat_excl_disc_on_excl</data> <data name="productData" xsi:type="string">with_special_price_and_fpt</data> @@ -92,6 +96,7 @@ <constraint name="Magento\Weee\Test\Constraint\AssertFptApplied" /> </variation> <variation name="CreateTaxWithFptTestVariation5" firstConstraint="Magento\Weee\Test\Constraint\AssertFptApplied" method="test"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="description" xsi:type="string">Check taxed FPT display set to Excluding, Description and Including FPT on product with with custom option catalog price Excluding Tax</data> <data name="configData" xsi:type="string">shipping_tax_class_taxable_goods,tax_with_fpt_taxed_cat_excl_disc_on_excl</data> <data name="productData" xsi:type="string">with_custom_option_and_fpt</data> @@ -204,6 +209,7 @@ <constraint name="Magento\Weee\Test\Constraint\AssertFptApplied" /> </variation> <variation name="CreateTaxWithFptTestVariation11" firstConstraint="Magento\Weee\Test\Constraint\AssertFptApplied" method="test"> + <data name="issue" xsi:type="string">MAGETWO-44968: FPT Final price includes tax on custom option, when display is set to excluding tax</data> <data name="description" xsi:type="string">Check taxed FPT display set to Excluding, Description and Including FPT on product with with custom option and catalog price Including Tax</data> <data name="configData" xsi:type="string">shipping_tax_class_taxable_goods,tax_with_fpt_taxed_cat_incl_disc_on_excl</data> <data name="productData" xsi:type="string">with_custom_option_and_fpt</data> diff --git a/dev/tests/functional/tests/app/Magento/Widget/Test/TestCase/CreateWidgetEntityTest.xml b/dev/tests/functional/tests/app/Magento/Widget/Test/TestCase/CreateWidgetEntityTest.xml index f533e115253ed52100fa5c9a9d51f4aa2303ca6b..225759df91f179dbd911fca662c05476c4830a69 100644 --- a/dev/tests/functional/tests/app/Magento/Widget/Test/TestCase/CreateWidgetEntityTest.xml +++ b/dev/tests/functional/tests/app/Magento/Widget/Test/TestCase/CreateWidgetEntityTest.xml @@ -19,7 +19,7 @@ <constraint name="Magento\Widget\Test\Constraint\AssertWidgetOnFrontendInCatalog" /> </variation> <variation name="CreateWidgetEntityTestVariation2"> - <data name="tag" xsi:type="string">test_type:extended_acceptance_test, severity:S1</data> + <data name="tag" xsi:type="string">test_type:extended_acceptance_test, severity:S1, stable:no</data> <data name="widget/data/code" xsi:type="string">CMS Page Link</data> <data name="widget/data/theme_id" xsi:type="string">Magento Luma</data> <data name="widget/data/title" xsi:type="string">Title_%isolation%</data> @@ -42,7 +42,7 @@ <constraint name="Magento\Widget\Test\Constraint\AssertWidgetRecentlyViewedProducts" /> </variation> <variation name="CreateWidgetEntityTestVariation4"> - <data name="tag" xsi:type="string">severity:S1</data> + <data name="tag" xsi:type="string">severity:S1, stable:no</data> <data name="widget/data/code" xsi:type="string">Recently Compared Products</data> <data name="widget/data/theme_id" xsi:type="string">Magento Luma</data> <data name="widget/data/title" xsi:type="string">Title_%isolation%</data> @@ -53,7 +53,7 @@ <constraint name="Magento\Widget\Test\Constraint\AssertWidgetRecentlyComparedProducts" /> </variation> <variation name="CreateWidgetEntityTestVariation5"> - <data name="tag" xsi:type="string">severity:S1</data> + <data name="tag" xsi:type="string">severity:S1, stable:no</data> <data name="widget/data/code" xsi:type="string">Catalog Category Link</data> <data name="widget/data/theme_id" xsi:type="string">Magento Luma</data> <data name="widget/data/title" xsi:type="string">Title_%isolation%</data> @@ -76,6 +76,7 @@ <constraint name="Magento\Widget\Test\Constraint\AssertWidgetProductLink" /> </variation> <variation name="CreateWidgetEntityTestVariation7" summary="Assert widget with disabled block_html cache type"> + <data name="issue" xsi:type="string">MAGETWO-58146: There is no cache invalidate popup after creating widget with disabled block_html cache type</data> <data name="tag" xsi:type="string">severity:S2</data> <data name="caches/block_html" xsi:type="string">Disabled</data> <data name="widget/data/code" xsi:type="string">CMS Static Block</data> @@ -91,6 +92,7 @@ <constraint name="Magento\Widget\Test\Constraint\AssertWidgetOnFrontendInCatalog" /> </variation> <variation name="CreateWidgetEntityTestVariation8" summary="Assert widget with invalidated block_html cache type"> + <data name="issue" xsi:type="string">MAGETWO-58146: There is no cache invalidate popup after creating widget with disabled block_html cache type</data> <data name="tag" xsi:type="string">severity:S3</data> <data name="caches/block_html" xsi:type="string">Invalidated</data> <data name="widget/data/code" xsi:type="string">Catalog Category Link</data> @@ -106,7 +108,7 @@ <constraint name="Magento\Widget\Test\Constraint\AssertWidgetAbsentOnFrontendHome" /> </variation> <variation name="CreateWidgetEntityTestVariation9" summary="Create Catalog New Products List type widget"> - <data name="tag" xsi:type="string">severity:S1</data> + <data name="tag" xsi:type="string">severity:S1, stable:no</data> <data name="widget/data/code" xsi:type="string">Catalog New Products List</data> <data name="widget/data/theme_id" xsi:type="string">Magento Luma</data> <data name="widget/data/title" xsi:type="string">Title_%isolation%</data> diff --git a/dev/tests/functional/tests/app/Magento/Wishlist/Test/Block/Customer/Wishlist/Items/Product.php b/dev/tests/functional/tests/app/Magento/Wishlist/Test/Block/Customer/Wishlist/Items/Product.php index 683ff71e8ff7212e4e9604d581d04b4cf9b0f238..226faf7d9ce507dccfa830cc0f7053cf998eb53e 100644 --- a/dev/tests/functional/tests/app/Magento/Wishlist/Test/Block/Customer/Wishlist/Items/Product.php +++ b/dev/tests/functional/tests/app/Magento/Wishlist/Test/Block/Customer/Wishlist/Items/Product.php @@ -123,14 +123,12 @@ class Product extends Form $viewDetails = $this->_rootElement->find($this->viewDetails); if ($viewDetails->isVisible()) { $this->_rootElement->find($this->footer, Locator::SELECTOR_XPATH)->click(); - $viewDetails->click(); + $viewDetails->hover(); $labels = $this->_rootElement->getElements($this->optionLabel); $values = $this->_rootElement->getElements($this->optionValue); $data = []; foreach ($labels as $key => $label) { - if (!$label->isVisible()) { - $viewDetails->click(); - } + $viewDetails->hover(); $data[] = [ 'title' => $label->getText(), 'value' => str_replace('$', '', $values[$key]->getText()), diff --git a/dev/tests/functional/tests/app/Magento/Wishlist/Test/TestCase/AddProductToWishlistEntityTest.xml b/dev/tests/functional/tests/app/Magento/Wishlist/Test/TestCase/AddProductToWishlistEntityTest.xml index 550cffa488130e16f73a9d89b9bc4344a57a2291..1a50facc1d67d756ea9ccfb051db7bb0a643c23b 100644 --- a/dev/tests/functional/tests/app/Magento/Wishlist/Test/TestCase/AddProductToWishlistEntityTest.xml +++ b/dev/tests/functional/tests/app/Magento/Wishlist/Test/TestCase/AddProductToWishlistEntityTest.xml @@ -8,6 +8,7 @@ <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/etc/variations.xsd"> <testCase name="Magento\Wishlist\Test\TestCase\AddProductToWishlistEntityTest" summary="Add Product to Wishlist" ticketId="MAGETWO-29045"> <variation name="AddProductToWishlistEntityTestVariation1"> + <data name="tag" xsi:type="string">stable:no</data> <data name="product/0" xsi:type="string">catalogProductSimple::default</data> <constraint name="Magento\Wishlist\Test\Constraint\AssertAddProductToWishlistSuccessMessage" /> <constraint name="Magento\Wishlist\Test\Constraint\AssertProductIsPresentInWishlist" /> @@ -38,12 +39,14 @@ <constraint name="Magento\Wishlist\Test\Constraint\AssertProductIsPresentInCustomerBackendWishlist" /> </variation> <variation name="AddProductToWishlistEntityTestVariation6"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="product/0" xsi:type="string">bundleProduct::bundle_dynamic_product</data> <constraint name="Magento\Wishlist\Test\Constraint\AssertAddProductToWishlistSuccessMessage" /> <constraint name="Magento\Wishlist\Test\Constraint\AssertProductDetailsInWishlist" /> <constraint name="Magento\Wishlist\Test\Constraint\AssertProductIsPresentInCustomerBackendWishlist" /> </variation> <variation name="AddProductToWishlistEntityTestVariation7"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="product/0" xsi:type="string">bundleProduct::bundle_fixed_product</data> <constraint name="Magento\Wishlist\Test\Constraint\AssertAddProductToWishlistSuccessMessage" /> <constraint name="Magento\Wishlist\Test\Constraint\AssertProductDetailsInWishlist" /> diff --git a/dev/tests/functional/tests/app/Magento/Wishlist/Test/TestCase/AddProductsToCartFromCustomerWishlistOnFrontendTest.php b/dev/tests/functional/tests/app/Magento/Wishlist/Test/TestCase/AddProductsToCartFromCustomerWishlistOnFrontendTest.php index cf16a045c3487ca9c8520a03ff4b47fc83ed84dd..6fec88a05de2885c57a61383497b06c353b0823a 100644 --- a/dev/tests/functional/tests/app/Magento/Wishlist/Test/TestCase/AddProductsToCartFromCustomerWishlistOnFrontendTest.php +++ b/dev/tests/functional/tests/app/Magento/Wishlist/Test/TestCase/AddProductsToCartFromCustomerWishlistOnFrontendTest.php @@ -28,6 +28,7 @@ class AddProductsToCartFromCustomerWishlistOnFrontendTest extends AbstractWishli { /* tags */ const MVP = 'no'; + const STABLE = 'no'; /* end tags */ /** diff --git a/dev/tests/functional/tests/app/Magento/Wishlist/Test/TestCase/AddProductsToCartFromCustomerWishlistOnFrontendTest.xml b/dev/tests/functional/tests/app/Magento/Wishlist/Test/TestCase/AddProductsToCartFromCustomerWishlistOnFrontendTest.xml index 7f89b52dff6185330d0058d664fff9ea5c987d70..ab33641cd04420a2eaa7b92df44312278a0ec57e 100644 --- a/dev/tests/functional/tests/app/Magento/Wishlist/Test/TestCase/AddProductsToCartFromCustomerWishlistOnFrontendTest.xml +++ b/dev/tests/functional/tests/app/Magento/Wishlist/Test/TestCase/AddProductsToCartFromCustomerWishlistOnFrontendTest.xml @@ -8,6 +8,7 @@ <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/etc/variations.xsd"> <testCase name="Magento\Wishlist\Test\TestCase\AddProductsToCartFromCustomerWishlistOnFrontendTest" summary="Add Products from Wishlist to Cart" ticketId="MAGETWO-25268"> <variation name="AddProductsToCartFromCustomerWishlistOnFrontendTestVariation1"> + <data name="tag" xsi:type="string">stable:no</data> <data name="products/0" xsi:type="string">catalogProductSimple::product_100_dollar</data> <data name="qty" xsi:type="string">2</data> <constraint name="Magento\Checkout\Test\Constraint\AssertProductQtyInShoppingCart" /> @@ -20,6 +21,7 @@ <constraint name="Magento\Wishlist\Test\Constraint\AssertProductsIsAbsentInWishlist" /> </variation> <variation name="AddProductsToCartFromCustomerWishlistOnFrontendTestVariation3"> + <data name="tag" xsi:type="string">stable:no</data> <data name="products/0" xsi:type="string">catalogProductSimple::default</data> <data name="products/1" xsi:type="string">catalogProductVirtual::product_50_dollar</data> <data name="products/2" xsi:type="string">catalogProductSimple::default</data> @@ -41,18 +43,21 @@ <constraint name="Magento\Wishlist\Test\Constraint\AssertProductsIsAbsentInWishlist" /> </variation> <variation name="AddProductsToCartFromCustomerWishlistOnFrontendTestVariation6"> + <data name="tag" xsi:type="string">stable:no</data> <data name="products/0" xsi:type="string">configurableProduct::default</data> <data name="qty" xsi:type="string">3</data> <constraint name="Magento\Checkout\Test\Constraint\AssertProductQtyInShoppingCart" /> <constraint name="Magento\Wishlist\Test\Constraint\AssertProductsIsAbsentInWishlist" /> </variation> <variation name="AddProductsToCartFromCustomerWishlistOnFrontendTestVariation7"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="products/0" xsi:type="string">bundleProduct::bundle_dynamic_product</data> <data name="qty" xsi:type="string">2</data> <constraint name="Magento\Checkout\Test\Constraint\AssertProductQtyInShoppingCart" /> <constraint name="Magento\Wishlist\Test\Constraint\AssertProductsIsAbsentInWishlist" /> </variation> <variation name="AddProductsToCartFromCustomerWishlistOnFrontendTestVariation8"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="products/0" xsi:type="string">bundleProduct::bundle_fixed_product</data> <data name="qty" xsi:type="string">2</data> <constraint name="Magento\Checkout\Test\Constraint\AssertProductQtyInShoppingCart" /> diff --git a/dev/tests/functional/tests/app/Magento/Wishlist/Test/TestCase/ConfigureProductInCustomerWishlistOnBackendTest.xml b/dev/tests/functional/tests/app/Magento/Wishlist/Test/TestCase/ConfigureProductInCustomerWishlistOnBackendTest.xml index ea6e122badf8bdcda1d57dcd4900b13a83d73d3a..62654bff2b7a91c4831a28b8f59068dc1667de14 100644 --- a/dev/tests/functional/tests/app/Magento/Wishlist/Test/TestCase/ConfigureProductInCustomerWishlistOnBackendTest.xml +++ b/dev/tests/functional/tests/app/Magento/Wishlist/Test/TestCase/ConfigureProductInCustomerWishlistOnBackendTest.xml @@ -8,6 +8,7 @@ <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/etc/variations.xsd"> <testCase name="Magento\Wishlist\Test\TestCase\ConfigureProductInCustomerWishlistOnBackendTest" summary="Configure Products in Customer Wishlist on Backend" ticketId="MAGETWO-29257"> <variation name="ConfigureProductInCustomerWishlistOnBackendTestVariation1"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="product/0" xsi:type="string">catalogProductSimple::with_two_custom_option</data> <constraint name="Magento\Wishlist\Test\Constraint\AssertProductInCustomerWishlistOnBackendGrid" /> </variation> diff --git a/dev/tests/functional/tests/app/Magento/Wishlist/Test/TestCase/ConfigureProductInCustomerWishlistOnFrontendTest.php b/dev/tests/functional/tests/app/Magento/Wishlist/Test/TestCase/ConfigureProductInCustomerWishlistOnFrontendTest.php index 3738dd0631e82510715c1ef10f2c12dd5cc7c5d1..037de4cba7bcaa00d884e2f5d926b8bc977f7c14 100644 --- a/dev/tests/functional/tests/app/Magento/Wishlist/Test/TestCase/ConfigureProductInCustomerWishlistOnFrontendTest.php +++ b/dev/tests/functional/tests/app/Magento/Wishlist/Test/TestCase/ConfigureProductInCustomerWishlistOnFrontendTest.php @@ -29,6 +29,7 @@ class ConfigureProductInCustomerWishlistOnFrontendTest extends AbstractWishlistT { /* tags */ const MVP = 'no'; + const STABLE = 'no'; /* end tags */ /** diff --git a/dev/tests/functional/tests/app/Magento/Wishlist/Test/TestCase/ConfigureProductInCustomerWishlistOnFrontendTest.xml b/dev/tests/functional/tests/app/Magento/Wishlist/Test/TestCase/ConfigureProductInCustomerWishlistOnFrontendTest.xml index c9da4e6ea9b2e4c12b7f8643939f30d8bc97b638..8708ea3c8073f559d2d72c6fbe1129de5fac5017 100644 --- a/dev/tests/functional/tests/app/Magento/Wishlist/Test/TestCase/ConfigureProductInCustomerWishlistOnFrontendTest.xml +++ b/dev/tests/functional/tests/app/Magento/Wishlist/Test/TestCase/ConfigureProductInCustomerWishlistOnFrontendTest.xml @@ -8,26 +8,31 @@ <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/etc/variations.xsd"> <testCase name="Magento\Wishlist\Test\TestCase\ConfigureProductInCustomerWishlistOnFrontendTest" summary="Configure Products in Customer Wishlist on Frontend" ticketId="MAGETWO-29507"> <variation name="ConfigureProductInCustomerWishlistOnFrontendTestVariation1"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="product/0" xsi:type="string">catalogProductSimple::with_two_custom_option</data> <constraint name="Magento\Wishlist\Test\Constraint\AssertProductIsPresentInWishlist" /> <constraint name="Magento\Wishlist\Test\Constraint\AssertProductDetailsInWishlist" /> </variation> <variation name="ConfigureProductInCustomerWishlistOnFrontendTestVariation2"> + <data name="tag" xsi:type="string">stable:no</data> <data name="product/0" xsi:type="string">configurableProduct::default</data> <constraint name="Magento\Wishlist\Test\Constraint\AssertProductIsPresentInWishlist" /> <constraint name="Magento\Wishlist\Test\Constraint\AssertProductDetailsInWishlist" /> </variation> <variation name="ConfigureProductInCustomerWishlistOnFrontendTestVariation3"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="product/0" xsi:type="string">bundleProduct::bundle_dynamic_product</data> <constraint name="Magento\Wishlist\Test\Constraint\AssertProductIsPresentInWishlist" /> <constraint name="Magento\Wishlist\Test\Constraint\AssertProductDetailsInWishlist" /> </variation> <variation name="ConfigureProductInCustomerWishlistOnFrontendTestVariation4"> + <data name="tag" xsi:type="string">stable:no</data> <data name="product/0" xsi:type="string">downloadableProduct::with_two_separately_links</data> <constraint name="Magento\Wishlist\Test\Constraint\AssertProductIsPresentInWishlist" /> <constraint name="Magento\Wishlist\Test\Constraint\AssertProductDetailsInWishlist" /> </variation> <variation name="ConfigureProductInCustomerWishlistOnFrontendTestVariation5"> + <data name="tag" xsi:type="string">stable:no</data> <data name="product/0" xsi:type="string">groupedProduct::three_simple_products</data> <constraint name="Magento\Wishlist\Test\Constraint\AssertProductIsPresentInWishlist" /> <constraint name="Magento\Wishlist\Test\Constraint\AssertProductDetailsInWishlist" /> diff --git a/dev/tests/functional/tests/app/Magento/Wishlist/Test/TestCase/DeleteProductsFromWishlistOnFrontendTest.xml b/dev/tests/functional/tests/app/Magento/Wishlist/Test/TestCase/DeleteProductsFromWishlistOnFrontendTest.xml index 4d410c03d6fe6df49f6a306108d20bc8a9005e06..f74039110ea4476db0b3b01a17a2968179bc7529 100644 --- a/dev/tests/functional/tests/app/Magento/Wishlist/Test/TestCase/DeleteProductsFromWishlistOnFrontendTest.xml +++ b/dev/tests/functional/tests/app/Magento/Wishlist/Test/TestCase/DeleteProductsFromWishlistOnFrontendTest.xml @@ -8,6 +8,7 @@ <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/etc/variations.xsd"> <testCase name="Magento\Wishlist\Test\TestCase\DeleteProductsFromWishlistOnFrontendTest" summary="Delete Products from Wishlist" ticketId="MAGETWO-28874"> <variation name="DeleteProductsFromWishlistOnFrontendTestVariation1"> + <data name="tag" xsi:type="string">stable:no</data> <data name="products/0" xsi:type="string">catalogProductSimple::product_100_dollar</data> <data name="products/1" xsi:type="string">catalogProductVirtual::product_50_dollar</data> <data name="removedProductsIndex" xsi:type="array"> @@ -16,6 +17,7 @@ <constraint name="Magento\Wishlist\Test\Constraint\AssertProductsIsAbsentInWishlist" /> </variation> <variation name="DeleteProductsFromWishlistOnFrontendTestVariation2"> + <data name="tag" xsi:type="string">stable:no</data> <data name="products/0" xsi:type="string">catalogProductVirtual::product_50_dollar</data> <data name="removedProductsIndex" xsi:type="array"> <item name="0" xsi:type="string">1</item> @@ -23,6 +25,7 @@ <constraint name="Magento\Wishlist\Test\Constraint\AssertWishlistIsEmpty" /> </variation> <variation name="DeleteProductsFromWishlistOnFrontendTestVariation3"> + <data name="tag" xsi:type="string">stable:no</data> <data name="products/0" xsi:type="string">catalogProductSimple::default</data> <data name="products/1" xsi:type="string">catalogProductVirtual::product_50_dollar</data> <data name="products/2" xsi:type="string">catalogProductSimple::default</data> @@ -57,6 +60,7 @@ <constraint name="Magento\Wishlist\Test\Constraint\AssertWishlistIsEmpty" /> </variation> <variation name="DeleteProductsFromWishlistOnFrontendTestVariation7"> + <data name="tag" xsi:type="string">stable:no</data> <data name="products/0" xsi:type="string">downloadableProduct::with_two_separately_links</data> <data name="removedProductsIndex" xsi:type="array"> <item name="0" xsi:type="string">1</item> @@ -64,6 +68,7 @@ <constraint name="Magento\Wishlist\Test\Constraint\AssertWishlistIsEmpty" /> </variation> <variation name="DeleteProductsFromWishlistOnFrontendTestVariation8"> + <data name="tag" xsi:type="string">stable:no</data> <data name="products/0" xsi:type="string">groupedProduct::three_simple_products</data> <data name="removedProductsIndex" xsi:type="array"> <item name="0" xsi:type="string">1</item> diff --git a/dev/tests/functional/tests/app/Magento/Wishlist/Test/TestCase/MoveProductFromShoppingCartToWishlistTest.xml b/dev/tests/functional/tests/app/Magento/Wishlist/Test/TestCase/MoveProductFromShoppingCartToWishlistTest.xml index 3706c8f8b3085bbafc35d4974cbdefb8daacddf9..999591d3344f939db0865c53ce5cbd6013a5e069 100644 --- a/dev/tests/functional/tests/app/Magento/Wishlist/Test/TestCase/MoveProductFromShoppingCartToWishlistTest.xml +++ b/dev/tests/functional/tests/app/Magento/Wishlist/Test/TestCase/MoveProductFromShoppingCartToWishlistTest.xml @@ -8,6 +8,7 @@ <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/etc/variations.xsd"> <testCase name="Magento\Wishlist\Test\TestCase\MoveProductFromShoppingCartToWishlistTest" summary="Move Products from Shopping Cart to Wishlist" ticketId="MAGETWO-29545"> <variation name="MoveProductFromShoppingCartToWishlistTestVariation1"> + <data name="tag" xsi:type="string">stable:no</data> <data name="product/0" xsi:type="string">catalogProductSimple::default</data> <constraint name="Magento\Wishlist\Test\Constraint\AssertMoveProductToWishlistSuccessMessage" /> <constraint name="Magento\Wishlist\Test\Constraint\AssertProductIsPresentInWishlist" /> @@ -20,6 +21,7 @@ <constraint name="Magento\Checkout\Test\Constraint\AssertCartIsEmpty" /> </variation> <variation name="MoveProductFromShoppingCartToWishlistTestVariation3"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="product/0" xsi:type="string">downloadableProduct::with_two_separately_links</data> <constraint name="Magento\Wishlist\Test\Constraint\AssertMoveProductToWishlistSuccessMessage" /> <constraint name="Magento\Wishlist\Test\Constraint\AssertProductIsPresentInWishlist" /> @@ -35,6 +37,7 @@ <constraint name="Magento\Wishlist\Test\Constraint\AssertProductDetailsInWishlist" /> </variation> <variation name="MoveProductFromShoppingCartToWishlistTestVariation5"> + <data name="tag" xsi:type="string">stable:no</data> <data name="product/0" xsi:type="string">bundleProduct::bundle_dynamic_product</data> <constraint name="Magento\Wishlist\Test\Constraint\AssertMoveProductToWishlistSuccessMessage" /> <constraint name="Magento\Wishlist\Test\Constraint\AssertProductIsPresentInWishlist" /> @@ -42,6 +45,7 @@ <constraint name="Magento\Wishlist\Test\Constraint\AssertProductDetailsInWishlist" /> </variation> <variation name="MoveProductFromShoppingCartToWishlistTestVariation6"> + <data name="tag" xsi:type="string">stable:no</data> <data name="product/0" xsi:type="string">bundleProduct::bundle_fixed_product</data> <constraint name="Magento\Wishlist\Test\Constraint\AssertMoveProductToWishlistSuccessMessage" /> <constraint name="Magento\Wishlist\Test\Constraint\AssertProductIsPresentInWishlist" /> diff --git a/dev/tests/functional/tests/app/Magento/Wishlist/Test/TestCase/ViewProductInCustomerWishlistOnBackendTest.xml b/dev/tests/functional/tests/app/Magento/Wishlist/Test/TestCase/ViewProductInCustomerWishlistOnBackendTest.xml index 82d6bf563ae627530781c47c6ad90b5824bfcdc3..5025cb97250d780a56d956e28a5641437494a425 100644 --- a/dev/tests/functional/tests/app/Magento/Wishlist/Test/TestCase/ViewProductInCustomerWishlistOnBackendTest.xml +++ b/dev/tests/functional/tests/app/Magento/Wishlist/Test/TestCase/ViewProductInCustomerWishlistOnBackendTest.xml @@ -8,6 +8,7 @@ <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/etc/variations.xsd"> <testCase name="Magento\Wishlist\Test\TestCase\ViewProductInCustomerWishlistOnBackendTest" summary="View Product in Customer Wishlist on Backend" ticketId="MAGETWO-29616"> <variation name="ViewProductInCustomerWishlistOnBackendTestVariation1"> + <data name="tag" xsi:type="string">to_maintain:yes</data> <data name="product/0" xsi:type="string">catalogProductSimple::with_two_custom_option</data> <constraint name="Magento\Wishlist\Test\Constraint\AssertProductInCustomerWishlistOnBackendGrid" /> </variation> diff --git a/dev/tests/functional/testsuites/Magento/Mtf/TestSuite/InjectableTests/basic_green.xml b/dev/tests/functional/testsuites/Magento/Mtf/TestSuite/InjectableTests/basic_green.xml new file mode 100644 index 0000000000000000000000000000000000000000..df7b03a994df4d322b533162f04dd45c2108d650 --- /dev/null +++ b/dev/tests/functional/testsuites/Magento/Mtf/TestSuite/InjectableTests/basic_green.xml @@ -0,0 +1,29 @@ +<?xml version="1.0"?> +<!-- +/** + * Copyright © 2016 Magento. All rights reserved. + * See COPYING.txt for license details. + */ +--> +<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xsi:noNamespaceSchemaLocation="../../../../../vendor/magento/mtf/Magento/Mtf/TestRunner/etc/testRunner.xsd"> + <rule scope="testcase"> + <deny> + <tag group="stable" value="no" /> + <tag group="to_maintain" value="yes" /> + </deny> + </rule> + <rule scope="testsuite"> + <deny> + <module value="Magento_Setup" strict="1" /> + <module value="Magento_SampleData" strict="1" /> + </deny> + </rule> + <rule scope="variation"> + <deny> + <tag group="test_type" value="3rd_party_test" /> + <tag group="stable" value="no" /> + <tag group="to_maintain" value="yes" /> + </deny> + </rule> +</config> diff --git a/dev/tests/integration/testsuite/Magento/Webapi/Model/ServiceMetadataTest.php b/dev/tests/integration/testsuite/Magento/Webapi/Model/ServiceMetadataTest.php new file mode 100644 index 0000000000000000000000000000000000000000..8fac1c9b0e7031277e59c67d31c8bbff555910c0 --- /dev/null +++ b/dev/tests/integration/testsuite/Magento/Webapi/Model/ServiceMetadataTest.php @@ -0,0 +1,135 @@ +<?php +/** + * Copyright © 2016 Magento. All rights reserved. + * See COPYING.txt for license details. + */ +namespace Magento\Webapi\Model; + +use Magento\TestFramework\Helper\Bootstrap; +use Magento\Customer\Api\AccountManagementInterface; +use Magento\Framework\Exception\LocalizedException; + +class ServiceMetadataTest extends \PHPUnit_Framework_TestCase +{ + /** + * @var ServiceMetadata + */ + private $serviceMetadata; + + protected function setUp() + { + $objectManager = Bootstrap::getObjectManager(); + $this->serviceMetadata = $objectManager->create(ServiceMetadata::class); + } + + public function testGetServiceMetadata() + { + $expected = [ + 'methods' => [ + 'activate' => [ + 'method' => 'activate', + 'inputRequired' => false, + 'isSecure' => false, + 'resources' => [ + 'Magento_Customer::manage' + ], + 'documentation' => 'Activate a customer account using a key that was sent in a confirmation email.', + 'interface' => [ + 'in' => [ + 'parameters' => [ + 'email' => [ + 'type' => 'string', + 'required' => true, + 'documentation' => null + ], + 'confirmationKey' => [ + 'type' => 'string', + 'required' => true, + 'documentation' => null + ] + ] + ], + 'out' => [ + 'parameters' => [ + 'result' => [ + 'type' => 'CustomerDataCustomerInterface', + 'required' => true, + 'documentation' => '' + ] + ], + 'throws' => [ + '\\' . LocalizedException::class + ] + ] + ] + ] + ], + 'class' => AccountManagementInterface::class, + 'description' => 'Interface for managing customers accounts.', + ]; + $actual = $this->serviceMetadata->getServiceMetadata('customerAccountManagementV1'); + $this->assertEquals(array_replace_recursive($actual, $expected), $actual); + } + + public function testGetRouteMetadata() + { + $expected = [ + 'methods' => [ + 'activate' => [ + 'method' => 'activate', + 'inputRequired' => false, + 'isSecure' => false, + 'resources' => [ + 'Magento_Customer::manage' + ], + 'documentation' => 'Activate a customer account using a key that was sent in a confirmation email.', + 'interface' => [ + 'in' => [ + 'parameters' => [ + 'email' => [ + 'type' => 'string', + 'required' => true, + 'documentation' => null + ], + 'confirmationKey' => [ + 'type' => 'string', + 'required' => true, + 'documentation' => null + ] + ] + ], + 'out' => [ + 'parameters' => [ + 'result' => [ + 'type' => 'CustomerDataCustomerInterface', + 'required' => true, + 'documentation' => '' + ] + ], + 'throws' => [ + '\\' . LocalizedException::class + ] + ] + ] + ] + ], + 'class' => AccountManagementInterface::class, + 'description' => 'Interface for managing customers accounts.', + 'routes' => [ + '/V1/customers/me/activate' => [ + 'PUT' => [ + 'method' => 'activateById', + 'parameters' => [ + 'customerId' => [ + 'force' => true, + 'value' => '%customer_id%' + ] + ] + ] + ] + ] + ]; + $actual = $this->serviceMetadata->getRouteMetadata('customerAccountManagementV1'); + $this->assertEquals(array_replace_recursive($actual, $expected), $actual); + } +} diff --git a/dev/tests/integration/testsuite/Magento/Webapi/Model/Soap/ConfigTest.php b/dev/tests/integration/testsuite/Magento/Webapi/Model/Soap/ConfigTest.php new file mode 100644 index 0000000000000000000000000000000000000000..ff1634c60782aee3de08203078f9592716de7803 --- /dev/null +++ b/dev/tests/integration/testsuite/Magento/Webapi/Model/Soap/ConfigTest.php @@ -0,0 +1,115 @@ +<?php +/** + * Copyright © 2016 Magento. All rights reserved. + * See COPYING.txt for license details. + */ +namespace Magento\Webapi\Model\Soap; + +use Magento\TestFramework\Helper\Bootstrap; +use Magento\Customer\Api\AccountManagementInterface; +use Magento\Customer\Api\CustomerRepositoryInterface; +use Magento\Framework\Exception\LocalizedException; + +class ConfigTest extends \PHPUnit_Framework_TestCase +{ + /** + * @var Config + */ + private $soapConfig; + + protected function setUp() + { + $objectManager = Bootstrap::getObjectManager(); + $this->soapConfig = $objectManager->create(Config::class); + } + + public function testGetRequestedSoapServices() + { + $expected = [ + 'customerAccountManagementV1' => [ + 'methods' => [ + 'activate' => [ + 'method' => 'activate', + 'inputRequired' => false, + 'isSecure' => false, + 'resources' => [ + 'Magento_Customer::manage' + ], + 'documentation' + => 'Activate a customer account using a key that was sent in a confirmation email.', + 'interface' => [ + 'in' => [ + 'parameters' => [ + 'email' => [ + 'type' => 'string', + 'required' => true, + 'documentation' => null + ], + 'confirmationKey' => [ + 'type' => 'string', + 'required' => true, + 'documentation' => null + ] + ] + ], + 'out' => [ + 'parameters' => [ + 'result' => [ + 'type' => 'CustomerDataCustomerInterface', + 'required' => true, + 'documentation' => null + ] + ], + 'throws' => [ + '\\' . LocalizedException::class + ] + ] + ] + ] + ], + 'class' => AccountManagementInterface::class, + 'description' => 'Interface for managing customers accounts.', + ] + ]; + $actual = $this->soapConfig->getRequestedSoapServices( + [ + 'customerAccountManagementV1', + 'NonExistentService' + ] + ); + $this->assertEquals(array_replace_recursive($actual, $expected), $actual); + } + + public function testGetServiceMethodInfo() + { + $expected = [ + 'class' => CustomerRepositoryInterface::class, + 'method' => 'getById', + 'isSecure' => false, + 'resources' => [ + 'Magento_Customer::customer', + 'self' + ], + ]; + $actual = $this->soapConfig->getServiceMethodInfo( + 'customerCustomerRepositoryV1GetById', + [ + 'customerCustomerRepositoryV1', + 'NonExistentService' + ] + ); + $this->assertEquals($expected, $actual); + } + + public function testGetSoapOperation() + { + $expected = 'customerAccountManagementV1Activate'; + $actual = $this->soapConfig + ->getSoapOperation( + AccountManagementInterface::class, + 'activate', + 'V1' + ); + $this->assertEquals($expected, $actual); + } +} diff --git a/dev/tests/js/JsTestDriver/run_js_tests.php b/dev/tests/js/JsTestDriver/run_js_tests.php index e6578c52b0699ee334c2f0ce9213ec5f78373330..448fd85869cd28dea34d7a00384838674f086c5a 100644 --- a/dev/tests/js/JsTestDriver/run_js_tests.php +++ b/dev/tests/js/JsTestDriver/run_js_tests.php @@ -30,6 +30,8 @@ if (isset($config['Browser'])) { } else { if (strtoupper(substr(PHP_OS, 0, 3)) === 'WIN') { $browser = 'C:\Program Files (x86)\Mozilla Firefox\firefox.exe'; + } elseif (PHP_OS === 'Darwin') { + $browser = '/Applications/Firefox.app/Contents/MacOS/firefox'; } else { $browser = exec('which firefox'); } @@ -139,29 +141,35 @@ if (strtoupper(substr(PHP_OS, 0, 3)) === 'WIN') { kill -9 $LSOF fi - DISPLAY_NUM=99 - ps -ef | egrep "[X]vfb.*:$DISPLAY_NUM" - if [ $? -eq 0 ] ; then - pkill Xvfb + # Skip Xvfb setup for OS X since there browsers do not support headless display that way + if [ "$(uname)" != "Darwin" ]; then + DISPLAY_NUM=99 + ps -ef | egrep "[X]vfb.*:$DISPLAY_NUM" + if [ $? -eq 0 ] ; then + pkill Xvfb + fi + + XVFB=`which Xvfb` + if [ "$?" -eq 1 ]; + then + echo "Xvfb not found." + exit 1 + fi + + $XVFB :$DISPLAY_NUM -nolisten inet6 -ac & + PID_XVFB="$!" # take the process ID + export DISPLAY=:$DISPLAY_NUM # set display to use that of the Xvfb fi - - XVFB=`which Xvfb` - if [ "$?" -eq 1 ]; - then - echo "Xvfb not found." - exit 1 - fi - - $XVFB :$DISPLAY_NUM -nolisten inet6 -ac & - PID_XVFB="$!" # take the process ID - export DISPLAY=:$DISPLAY_NUM # set display to use that of the Xvfb + USER=`whoami` SUDO=`which sudo` # run the tests $SUDO -u $USER ' . $command . ' - kill -9 $PID_XVFB # shut down Xvfb (firefox will shut down cleanly by JsTestDriver) + if [ "$(uname)" != "Darwin" ]; then + kill -9 $PID_XVFB # shut down Xvfb (firefox will shut down cleanly by JsTestDriver) + fi echo "Done."'; fwrite($fh, $shellCommand . PHP_EOL); diff --git a/dev/tests/static/framework/Magento/TestFramework/CodingStandard/Tool/CopyPasteDetector.php b/dev/tests/static/framework/Magento/TestFramework/CodingStandard/Tool/CopyPasteDetector.php index b2d9c164fbd1bc57cf9f2497ff02d6fe6f6895e9..b2766ebd90d92e85072bd84c7c7939813d863bc8 100644 --- a/dev/tests/static/framework/Magento/TestFramework/CodingStandard/Tool/CopyPasteDetector.php +++ b/dev/tests/static/framework/Magento/TestFramework/CodingStandard/Tool/CopyPasteDetector.php @@ -56,8 +56,7 @@ class CopyPasteDetector implements ToolInterface, BlacklistInterface */ public function canRun() { - $vendorDir = require BP . '/app/etc/vendor_path.php'; - exec('php ' . BP . '/' . $vendorDir . '/bin/phpcpd --version', $output, $exitCode); + exec($this->getCommand() . ' --version', $output, $exitCode); return $exitCode === 0; } @@ -71,22 +70,37 @@ class CopyPasteDetector implements ToolInterface, BlacklistInterface */ public function run(array $whiteList) { - $blackListStr = ' '; + $blacklistedDirs = []; + $blacklistedFileNames = []; foreach ($this->blacklist as $file) { $file = escapeshellarg(trim($file)); if (!$file) { continue; } - $blackListStr .= '--exclude ' . $file . ' '; + $ext = pathinfo($file, PATHINFO_EXTENSION); + if ($ext != '') { + $blacklistedFileNames[] = $file; + } else { + $blacklistedDirs[] = '--exclude ' . $file . ' '; + } } - $vendorDir = require BP . '/app/etc/vendor_path.php'; - $command = 'php ' . BP . '/' . $vendorDir . '/bin/phpcpd' . ' --log-pmd ' . escapeshellarg( - $this->reportFile - ) . ' --names-exclude "*Test.php" --min-lines 13' . $blackListStr . ' ' . implode(' ', $whiteList); - + $command = $this->getCommand() . ' --log-pmd ' . escapeshellarg($this->reportFile) + . ' --names-exclude ' . join(',', $blacklistedFileNames) . ' --min-lines 13 ' . join(' ', $blacklistedDirs) + . ' ' . implode(' ', $whiteList); exec($command, $output, $exitCode); return !(bool)$exitCode; } + + /** + * Get PHPCPD command + * + * @return string + */ + private function getCommand() + { + $vendorDir = require BP . '/app/etc/vendor_path.php'; + return 'php ' . BP . '/' . $vendorDir . '/bin/phpcpd'; + } } diff --git a/dev/tests/static/testsuite/Magento/Test/Legacy/UnsecureFunctionsUsageTest.php b/dev/tests/static/testsuite/Magento/Test/Legacy/UnsecureFunctionsUsageTest.php index 6b18eb2b71478463e39e815dec078478c4034a07..e5263713d71d7af374ea1f32c2d765d3639e56ce 100644 --- a/dev/tests/static/testsuite/Magento/Test/Legacy/UnsecureFunctionsUsageTest.php +++ b/dev/tests/static/testsuite/Magento/Test/Legacy/UnsecureFunctionsUsageTest.php @@ -64,7 +64,7 @@ class UnsecureFunctionsUsageTest extends \PHPUnit_Framework_TestCase if ($regexp) { $matches = preg_grep( $regexp, - file($fileName, FILE_IGNORE_NEW_LINES | FILE_SKIP_EMPTY_LINES) + file($fileName) ); if (!empty($matches)) { foreach (array_keys($matches) as $line) { @@ -114,7 +114,8 @@ class UnsecureFunctionsUsageTest extends \PHPUnit_Framework_TestCase if (strpos($path, $directory) === 0) { if (preg_match($fileExtensions, $path)) { foreach ($blackListFiles as $blackListFile) { - if (preg_match($blackListFile, $path)) { + $blackListFile = preg_quote($blackListFile, '#'); + if (preg_match('#' . $blackListFile . '#', $path)) { return false; } } @@ -158,10 +159,6 @@ class UnsecureFunctionsUsageTest extends \PHPUnit_Framework_TestCase if (empty($functions)) { return ''; } - $regexArray = []; - foreach ($functions as $function) { - $regexArray[] = '\b' . $function . '\b\('; - } - return '/' . implode('|', $regexArray) . '/i'; + return '/(?<!function |[^\s])\b(' . join('|', $functions) . ')\s*\(/i'; } } diff --git a/dev/tests/static/testsuite/Magento/Test/Legacy/_files/security/blacklist.php b/dev/tests/static/testsuite/Magento/Test/Legacy/_files/security/blacklist.php index d120a4543b9ddced597d330ab489de15c80cdb86..42b8e68e784111b96d43049ae27dc5ebc963ad40 100644 --- a/dev/tests/static/testsuite/Magento/Test/Legacy/_files/security/blacklist.php +++ b/dev/tests/static/testsuite/Magento/Test/Legacy/_files/security/blacklist.php @@ -4,6 +4,7 @@ * See COPYING.txt for license details. */ return [ - '/Test\/Unit/', - '/lib\/internal\/Magento\/Framework\/DB\/Adapter\/Pdo\/Mysql\.php/', + 'Test/Unit', + 'lib/internal/Magento/Framework/DB/Adapter/Pdo/Mysql.php', + 'lib/internal/Magento/Framework/Serialize/Serializer/Serialize.php', ]; diff --git a/dev/tests/static/testsuite/Magento/Test/Legacy/_files/security/whitelist.txt b/dev/tests/static/testsuite/Magento/Test/Legacy/_files/security/whitelist.txt index 2567475de6a035b2a369ac342c076ce1e5cad07d..e464d9713657f6341ccbf1f6d77986ebac08d979 100644 --- a/dev/tests/static/testsuite/Magento/Test/Legacy/_files/security/whitelist.txt +++ b/dev/tests/static/testsuite/Magento/Test/Legacy/_files/security/whitelist.txt @@ -1,4 +1,5 @@ +# "Component Type" "Component Name" "Path Pattern" module * / library * / setup -pub \ No newline at end of file +pub diff --git a/dev/tests/static/testsuite/Magento/Test/Php/_files/phpcpd/blacklist/common.txt b/dev/tests/static/testsuite/Magento/Test/Php/_files/phpcpd/blacklist/common.txt index 56e0d51516c2632a28acd50ca2c3999e984720df..3afe3af79b14ff3177a0dc1c5ea9fe42e93b6331 100644 --- a/dev/tests/static/testsuite/Magento/Test/Php/_files/phpcpd/blacklist/common.txt +++ b/dev/tests/static/testsuite/Magento/Test/Php/_files/phpcpd/blacklist/common.txt @@ -196,4 +196,6 @@ Magento/Framework/Mview/Config/Data Magento/Framework/View/File/Collector/Override Magento/Framework/MessageQueue/Consumer/Config/ConsumerConfigItem Magento/Framework/MessageQueue/Publisher/Config/PublisherConfigItem -Magento/Framework/MessageQueue/Topology/Config/ExchangeConfigItem \ No newline at end of file +Magento/Framework/MessageQueue/Topology/Config/ExchangeConfigItem +IntegrationConfig.php +*Test.php diff --git a/dev/tests/static/testsuite/Magento/Test/Php/_files/whitelist/exempt_modules/ce.php b/dev/tests/static/testsuite/Magento/Test/Php/_files/whitelist/exempt_modules/ce.php index c0316a435662ec4f85a42e5f65295e1f232b5c72..8075f9bddc318a81e8640f44c7e2081cd5aff161 100644 --- a/dev/tests/static/testsuite/Magento/Test/Php/_files/whitelist/exempt_modules/ce.php +++ b/dev/tests/static/testsuite/Magento/Test/Php/_files/whitelist/exempt_modules/ce.php @@ -13,10 +13,8 @@ return [ 'Magento_CatalogInventory', 'Magento_CatalogRule', 'Magento_CatalogSearch', - 'Magento_CatalogWidget', 'Magento_Checkout', 'Magento_CheckoutAgreements', - 'Magento_Cms', 'Magento_Config', 'Magento_ConfigurableProduct', 'Magento_CurrencySymbol', @@ -47,8 +45,6 @@ return [ 'Magento_Theme', 'Magento_Translation', 'Magento_Ui', - 'Magento_UrlRewrite', 'Magento_User', 'Magento_Weee', - 'Magento_Widget', ]; diff --git a/lib/internal/Magento/Framework/ObjectManager/Config/Compiled.php b/lib/internal/Magento/Framework/ObjectManager/Config/Compiled.php index a3ed3b941844eec7497eb233d1c43e74045c45e1..779e8cf0a0e5ecf15b0fcb6da1e48b80a5bb3072 100644 --- a/lib/internal/Magento/Framework/ObjectManager/Config/Compiled.php +++ b/lib/internal/Magento/Framework/ObjectManager/Config/Compiled.php @@ -1,15 +1,15 @@ <?php /** - * * Copyright © 2016 Magento. All rights reserved. * See COPYING.txt for license details. */ namespace Magento\Framework\ObjectManager\Config; +use Magento\Framework\ObjectManager\ConfigInterface; use Magento\Framework\ObjectManager\ConfigCacheInterface; use Magento\Framework\ObjectManager\RelationsInterface; -class Compiled implements \Magento\Framework\ObjectManager\ConfigInterface +class Compiled implements ConfigInterface { /** * @var array @@ -129,9 +129,15 @@ class Compiled implements \Magento\Framework\ObjectManager\ConfigInterface */ public function extend(array $configuration) { - $this->arguments = $configuration['arguments']; - $this->virtualTypes = $configuration['instanceTypes']; - $this->preferences = $configuration['preferences']; + $this->arguments = isset($configuration['arguments']) + ? array_replace($this->arguments, $configuration['arguments']) + : $this->arguments; + $this->virtualTypes = isset($configuration['instanceTypes']) + ? array_replace($this->virtualTypes, $configuration['instanceTypes']) + : $this->virtualTypes; + $this->preferences = isset($configuration['preferences']) + ? array_replace($this->preferences, $configuration['preferences']) + : $this->preferences; } /** diff --git a/lib/internal/Magento/Framework/Serialize/README.md b/lib/internal/Magento/Framework/Serialize/README.md new file mode 100644 index 0000000000000000000000000000000000000000..5af8fb7f71b6b174855cb39d004ea29cb6d518a3 --- /dev/null +++ b/lib/internal/Magento/Framework/Serialize/README.md @@ -0,0 +1,8 @@ +# Serialize + +**Serialize** library provides interface *SerializerInterface* and multiple implementations: + + * *Json* - default implementation. Uses PHP native json_encode/json_decode functions; + * *Serialize* - less secure than *Json*, but gives higher performance on big arrays. Uses PHP native serialize/unserialize functions, does not unserialize objects on PHP 7. + +Using *Serialize* implementation directly is discouraged, always use *SerializerInterface*, using *Serialize* implementation may lead to security vulnerabilities. \ No newline at end of file diff --git a/lib/internal/Magento/Framework/Serialize/Serializer/Json.php b/lib/internal/Magento/Framework/Serialize/Serializer/Json.php new file mode 100644 index 0000000000000000000000000000000000000000..9c5e55b194165849cddaeebc9d6f772375d7a66e --- /dev/null +++ b/lib/internal/Magento/Framework/Serialize/Serializer/Json.php @@ -0,0 +1,30 @@ +<?php +/** + * Copyright © 2016 Magento. All rights reserved. + * See COPYING.txt for license details. + */ +namespace Magento\Framework\Serialize\Serializer; + +use Magento\Framework\Serialize\SerializerInterface; + +/** + * Class for serializing data to json string and unserializing json string to data + */ +class Json implements SerializerInterface +{ + /** + * {@inheritDoc} + */ + public function serialize($data) + { + return json_encode($data); + } + + /** + * {@inheritDoc} + */ + public function unserialize($string) + { + return json_decode($string, true); + } +} diff --git a/lib/internal/Magento/Framework/Serialize/Serializer/Serialize.php b/lib/internal/Magento/Framework/Serialize/Serializer/Serialize.php new file mode 100644 index 0000000000000000000000000000000000000000..3d2dc66e502ef478a868d04eac3bdc2e01bf8519 --- /dev/null +++ b/lib/internal/Magento/Framework/Serialize/Serializer/Serialize.php @@ -0,0 +1,45 @@ +<?php +/** + * Copyright © 2016 Magento. All rights reserved. + * See COPYING.txt for license details. + */ +namespace Magento\Framework\Serialize\Serializer; + +use Magento\Framework\Serialize\SerializerInterface; + +/** + * Less secure than Json implementation, but gives higher performance on big arrays. Does not unserialize objects on + * PHP 7. Using this implementation directly is discouraged as it may lead to security vulnerabilities, especially on + * older versions of PHP + */ +class Serialize implements SerializerInterface +{ + /** + * {@inheritDoc} + */ + public function serialize($data) + { + return serialize($data); + } + + /** + * {@inheritDoc} + */ + public function unserialize($string) + { + if ($this->getPhpVersion() >= 7) { + return unserialize($string, ['allowed_classes' => false]); + } + return unserialize($string); + } + + /** + * Return major PHP version + * + * @return int + */ + private function getPhpVersion() + { + return PHP_MAJOR_VERSION; + } +} diff --git a/lib/internal/Magento/Framework/Serialize/SerializerInterface.php b/lib/internal/Magento/Framework/Serialize/SerializerInterface.php new file mode 100644 index 0000000000000000000000000000000000000000..f7a15b31a826e004541434a6ec6b4b30863ba9c3 --- /dev/null +++ b/lib/internal/Magento/Framework/Serialize/SerializerInterface.php @@ -0,0 +1,28 @@ +<?php +/** + * Copyright © 2016 Magento. All rights reserved. + * See COPYING.txt for license details. + */ +namespace Magento\Framework\Serialize; + +/** + * Interface for serializing + */ +interface SerializerInterface +{ + /** + * Serialize data into string + * + * @param string|int|float|bool|array|null $data + * @return string|bool + */ + public function serialize($data); + + /** + * Unserialize the given string + * + * @param string $string + * @return string|int|float|bool|array|null + */ + public function unserialize($string); +} diff --git a/lib/internal/Magento/Framework/Serialize/Test/Unit/Serializer/JsonTest.php b/lib/internal/Magento/Framework/Serialize/Test/Unit/Serializer/JsonTest.php new file mode 100644 index 0000000000000000000000000000000000000000..88e06d89e3763d36a1301b595942a513359ce076 --- /dev/null +++ b/lib/internal/Magento/Framework/Serialize/Test/Unit/Serializer/JsonTest.php @@ -0,0 +1,78 @@ +<?php +/** + * Copyright © 2016 Magento. All rights reserved. + * See COPYING.txt for license details. + */ +namespace Magento\Framework\Serialize\Test\Unit\Serializer; + +use Magento\Framework\DataObject; +use Magento\Framework\Serialize\Serializer\Json; + +class JsonTest extends \PHPUnit_Framework_TestCase +{ + /** + * @var \Magento\Framework\Serialize\Serializer\Json + */ + private $json; + + protected function setUp() + { + $objectManager = new \Magento\Framework\TestFramework\Unit\Helper\ObjectManager($this); + $this->json = $objectManager->getObject(Json::class); + } + + /** + * @param string|int|float|bool|array|null $value + * @param string $expected + * @dataProvider serializeDataProvider + */ + public function testSerialize($value, $expected) + { + $this->assertEquals( + $expected, + $this->json->serialize($value) + ); + } + + public function serializeDataProvider() + { + $dataObject = new DataObject(['something']); + return [ + ['', '""'], + ['string', '"string"'], + [null, 'null'], + [false, 'false'], + [['a' => 'b', 'd' => 123], '{"a":"b","d":123}'], + [123, '123'], + [10.56, '10.56'], + [$dataObject, '{}'], + ]; + } + + /** + * @param string $value + * @param string|int|float|bool|array|null $expected + * @dataProvider unserializeDataProvider + */ + public function testUnserialize($value, $expected) + { + $this->assertEquals( + $expected, + $this->json->unserialize($value) + ); + } + + public function unserializeDataProvider() + { + return [ + ['""', ''], + ['"string"', 'string'], + ['null', null], + ['false', false], + ['{"a":"b","d":123}', ['a' => 'b', 'd' => 123]], + ['123', 123], + ['10.56', 10.56], + ['{}', []], + ]; + } +} diff --git a/lib/internal/Magento/Framework/Serialize/Test/Unit/Serializer/SerializeTest.php b/lib/internal/Magento/Framework/Serialize/Test/Unit/Serializer/SerializeTest.php new file mode 100644 index 0000000000000000000000000000000000000000..874647b5d705fc55e6b9328bab8450e1908a8921 --- /dev/null +++ b/lib/internal/Magento/Framework/Serialize/Test/Unit/Serializer/SerializeTest.php @@ -0,0 +1,71 @@ +<?php +/** + * Copyright © 2016 Magento. All rights reserved. + * See COPYING.txt for license details. + */ +namespace Magento\Framework\Serialize\Test\Unit\Serializer; + +use Magento\Framework\Serialize\Serializer\Serialize; +use Magento\Framework\Serialize\Signer; +use Psr\Log\LoggerInterface; +use Magento\Framework\Serialize\InvalidSignatureException; + +class SerializeTest extends \PHPUnit_Framework_TestCase +{ + /** + * @var Serialize + */ + private $serialize; + + protected function setUp() + { + $objectManager = new \Magento\Framework\TestFramework\Unit\Helper\ObjectManager($this); + $this->serialize = $objectManager->getObject(Serialize::class); + } + + /** + * @param string|int|float|bool|array|null $value + * @param string $serializedValue + * @dataProvider serializeDataProvider + */ + public function testSerialize($value, $serializedValue) + { + $this->assertEquals($serializedValue, $this->serialize->serialize($value)); + } + + public function serializeDataProvider() + { + return [ + ['string', 's:6:"string";'], + ['', 's:0:"";'], + [10, 'i:10;'], + [10.5, 'd:10.5;'], + [null, 'N;'], + [false, 'b:0;'], + [['foo' => 'bar'], 'a:1:{s:3:"foo";s:3:"bar";}'], + ]; + } + + /** + * @param string $serializedValue + * @param string|int|float|bool|array|null $value + * @dataProvider unserializeDataProvider + */ + public function testUnserialize($serializedValue, $value) + { + $this->assertEquals($value, $this->serialize->unserialize($serializedValue)); + } + + public function unserializeDataProvider() + { + return [ + ['s:6:"string";', 'string'], + ['s:0:"";', ''], + ['i:10;', 10], + ['d:10.5;', 10.5], + ['N;', null], + ['b:0;', false], + ['a:1:{s:3:"foo";s:3:"bar";}', ['foo' => 'bar']], + ]; + } +} diff --git a/lib/internal/Magento/Framework/Test/Unit/ObjectManager/Config/CompiledTest.php b/lib/internal/Magento/Framework/Test/Unit/ObjectManager/Config/CompiledTest.php new file mode 100644 index 0000000000000000000000000000000000000000..3dd9f5065a1421ec822d4a81377ea81a5c3f8f52 --- /dev/null +++ b/lib/internal/Magento/Framework/Test/Unit/ObjectManager/Config/CompiledTest.php @@ -0,0 +1,91 @@ +<?php +/** + * Copyright © 2016 Magento. All rights reserved. + * See COPYING.txt for license details. + */ +namespace Magento\Framework\Test\Unit\ObjectManager\Config; + +use Magento\Framework\ObjectManager\Config\Compiled as CompiledConfig; +use Magento\Framework\TestFramework\Unit\Helper\ObjectManager as ObjectManagerHelper; + +class CompiledTest extends \PHPUnit_Framework_TestCase +{ + /** + * @var ObjectManagerHelper + */ + private $objectManagerHelper; + + protected function setUp() + { + $this->objectManagerHelper = new ObjectManagerHelper($this); + } + + /** + * @param array $initialData + * @param array $configuration + * @param array $expectedArguments + * @param array $expectedVirtualTypes + * @param array $expectedPreferences + * + * @dataProvider extendDataProvider + */ + public function testExtend( + array $initialData, + array $configuration, + array $expectedArguments, + array $expectedVirtualTypes, + array $expectedPreferences + ) { + /** @var CompiledConfig $compiledConfig */ + $compiledConfig = $this->objectManagerHelper->getObject(CompiledConfig::class, ['data' => $initialData]); + $compiledConfig->extend($configuration); + + foreach ($expectedArguments as $type => $arguments) { + $this->assertEquals($arguments, $compiledConfig->getArguments($type)); + } + + $this->assertEquals($expectedVirtualTypes, $compiledConfig->getVirtualTypes()); + $this->assertEquals($expectedPreferences, $compiledConfig->getPreferences()); + } + + /** + * @return array + */ + public function extendDataProvider() + { + return [ + [ + 'initialData' => [ + 'arguments' => [ + 'type1' => serialize(['argument1_1' => 'argumentValue1_1', 'argument1_2' => 'argumentValue1_2']) + ], + 'instanceTypes' => [ + 'instanceType1' => 'instanceTypeValue1', 'instanceType2' => 'instanceTypeValue2' + ], + 'preferences' => ['preference1' => 'preferenceValue1', 'preference2' => 'preferenceValue2'] + ], + 'configuration' => [ + 'arguments' => [ + 'type1' => serialize(['argument1_1' => 'newArgumentValue1_1']), + 'type2' => serialize(['argument2_1' => 'newArgumentValue2_1']) + ], + 'instanceTypes' => [ + 'instanceType2' => 'newInstanceTypeValue2', 'instanceType3' => 'newInstanceTypeValue3' + ], + 'preferences' => ['preference1' => 'newPreferenceValue1'] + ], + 'expectedArguments' => [ + 'type1' => ['argument1_1' => 'newArgumentValue1_1'], + 'type2' => ['argument2_1' => 'newArgumentValue2_1'] + ], + 'expectedVirtualTypes' => [ + 'instanceType1' => 'instanceTypeValue1', 'instanceType2' => 'newInstanceTypeValue2', + 'instanceType3' => 'newInstanceTypeValue3' + ], + 'expectedPreferences' => [ + 'preference1' => 'newPreferenceValue1', 'preference2' => 'preferenceValue2' + ] + ] + ]; + } +} diff --git a/lib/web/mage/adminhtml/wysiwyg/tiny_mce/setup.js b/lib/web/mage/adminhtml/wysiwyg/tiny_mce/setup.js index 7b5100215200473f0610afaf27c922e4662cce8f..2c4ab52b896cb8fd8bf01974d7f39cfc8f11e4f4 100755 --- a/lib/web/mage/adminhtml/wysiwyg/tiny_mce/setup.js +++ b/lib/web/mage/adminhtml/wysiwyg/tiny_mce/setup.js @@ -82,6 +82,7 @@ define([ } var settings = { + entity_encoding: 'raw', mode: (mode != undefined ? mode : 'none'), elements: this.id, theme: 'advanced',