From b1131c56305b9d6810f1d12cc0ea78f69774dc46 Mon Sep 17 00:00:00 2001
From: Yaroslav Rogoza
Date: Sun, 24 Mar 2019 18:37:42 +0100
Subject: [PATCH 001/937] Convert ConfigPageVisibilityTest to MFTF
---
.../Mftf/Section/LocaleOptionsSection.xml | 3 ++
...eAndDeveloperConfigInDeveloperModeTest.xml | 33 +++++++++++++++++++
...AndDeveloperConfigInProductionModeTest.xml | 33 +++++++++++++++++++
.../GeneralConfigurationActionGroup.xml | 5 +++
.../Config/Test/Mftf/Page/AdminConfigPage.xml | 1 +
.../TestCase/ConfigPageVisibilityTest.xml | 1 +
6 files changed, 76 insertions(+)
create mode 100644 app/code/Magento/Backend/Test/Mftf/Test/AdminCheckLocaleAndDeveloperConfigInDeveloperModeTest.xml
create mode 100644 app/code/Magento/Backend/Test/Mftf/Test/AdminCheckLocaleAndDeveloperConfigInProductionModeTest.xml
diff --git a/app/code/Magento/Backend/Test/Mftf/Section/LocaleOptionsSection.xml b/app/code/Magento/Backend/Test/Mftf/Section/LocaleOptionsSection.xml
index a460aaebf1051..3ad8adf9e1b96 100644
--- a/app/code/Magento/Backend/Test/Mftf/Section/LocaleOptionsSection.xml
+++ b/app/code/Magento/Backend/Test/Mftf/Section/LocaleOptionsSection.xml
@@ -11,6 +11,9 @@
diff --git a/app/code/Magento/Backend/Test/Mftf/Test/AdminCheckLocaleAndDeveloperConfigInDeveloperModeTest.xml b/app/code/Magento/Backend/Test/Mftf/Test/AdminCheckLocaleAndDeveloperConfigInDeveloperModeTest.xml
new file mode 100644
index 0000000000000..7e471f4f855a1
--- /dev/null
+++ b/app/code/Magento/Backend/Test/Mftf/Test/AdminCheckLocaleAndDeveloperConfigInDeveloperModeTest.xml
@@ -0,0 +1,33 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/app/code/Magento/Backend/Test/Mftf/Test/AdminCheckLocaleAndDeveloperConfigInProductionModeTest.xml b/app/code/Magento/Backend/Test/Mftf/Test/AdminCheckLocaleAndDeveloperConfigInProductionModeTest.xml
new file mode 100644
index 0000000000000..85cc5dd047157
--- /dev/null
+++ b/app/code/Magento/Backend/Test/Mftf/Test/AdminCheckLocaleAndDeveloperConfigInProductionModeTest.xml
@@ -0,0 +1,33 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/app/code/Magento/Config/Test/Mftf/ActionGroup/GeneralConfigurationActionGroup.xml b/app/code/Magento/Config/Test/Mftf/ActionGroup/GeneralConfigurationActionGroup.xml
index f05cf5be3448e..ec230ff1952ce 100644
--- a/app/code/Magento/Config/Test/Mftf/ActionGroup/GeneralConfigurationActionGroup.xml
+++ b/app/code/Magento/Config/Test/Mftf/ActionGroup/GeneralConfigurationActionGroup.xml
@@ -20,6 +20,11 @@
+
+
+
+
+
diff --git a/app/code/Magento/Config/Test/Mftf/Page/AdminConfigPage.xml b/app/code/Magento/Config/Test/Mftf/Page/AdminConfigPage.xml
index 7a62dfff8323b..507ae0594e1cd 100644
--- a/app/code/Magento/Config/Test/Mftf/Page/AdminConfigPage.xml
+++ b/app/code/Magento/Config/Test/Mftf/Page/AdminConfigPage.xml
@@ -21,4 +21,5 @@
+
diff --git a/dev/tests/functional/tests/app/Magento/Backend/Test/TestCase/ConfigPageVisibilityTest.xml b/dev/tests/functional/tests/app/Magento/Backend/Test/TestCase/ConfigPageVisibilityTest.xml
index 2d7e609c1c389..0694966c7eaa5 100644
--- a/dev/tests/functional/tests/app/Magento/Backend/Test/TestCase/ConfigPageVisibilityTest.xml
+++ b/dev/tests/functional/tests/app/Magento/Backend/Test/TestCase/ConfigPageVisibilityTest.xml
@@ -9,6 +9,7 @@
severity:S1
+ mftf_migrated:yes
From 8d1ccc8c764db7bc966fa0a3c2f5b082b616a4ea Mon Sep 17 00:00:00 2001
From: Yaroslav Rogoza
Date: Mon, 25 Mar 2019 11:17:52 +0100
Subject: [PATCH 002/937] Refactoring
---
.../AdminCheckLocaleAndDeveloperConfigInDeveloperModeTest.xml | 2 +-
.../AdminCheckLocaleAndDeveloperConfigInProductionModeTest.xml | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/app/code/Magento/Backend/Test/Mftf/Test/AdminCheckLocaleAndDeveloperConfigInDeveloperModeTest.xml b/app/code/Magento/Backend/Test/Mftf/Test/AdminCheckLocaleAndDeveloperConfigInDeveloperModeTest.xml
index 7e471f4f855a1..90fd6e451781b 100644
--- a/app/code/Magento/Backend/Test/Mftf/Test/AdminCheckLocaleAndDeveloperConfigInDeveloperModeTest.xml
+++ b/app/code/Magento/Backend/Test/Mftf/Test/AdminCheckLocaleAndDeveloperConfigInDeveloperModeTest.xml
@@ -17,7 +17,7 @@
-
+
diff --git a/app/code/Magento/Backend/Test/Mftf/Test/AdminCheckLocaleAndDeveloperConfigInProductionModeTest.xml b/app/code/Magento/Backend/Test/Mftf/Test/AdminCheckLocaleAndDeveloperConfigInProductionModeTest.xml
index 85cc5dd047157..9c1dbe750f013 100644
--- a/app/code/Magento/Backend/Test/Mftf/Test/AdminCheckLocaleAndDeveloperConfigInProductionModeTest.xml
+++ b/app/code/Magento/Backend/Test/Mftf/Test/AdminCheckLocaleAndDeveloperConfigInProductionModeTest.xml
@@ -17,7 +17,7 @@
-
+
From d82ba2eb04a9eaa12a19dee75c8456f702515d82 Mon Sep 17 00:00:00 2001
From: Anahit Martirosyan
Date: Fri, 29 Mar 2019 10:32:46 +0400
Subject: [PATCH 003/937] MAGETWO-51891: Category with invalid data loses new
products assignment after validation
- Add automated test script
---
.../ActionGroup/AdminCategoryActionGroup.xml | 13 ++++
...ssignmentToCategoryWithInvalidDataTest.xml | 62 +++++++++++++++++++
2 files changed, 75 insertions(+)
create mode 100644 app/code/Magento/Catalog/Test/Mftf/Test/NewProductsAssignmentToCategoryWithInvalidDataTest.xml
diff --git a/app/code/Magento/Catalog/Test/Mftf/ActionGroup/AdminCategoryActionGroup.xml b/app/code/Magento/Catalog/Test/Mftf/ActionGroup/AdminCategoryActionGroup.xml
index 90d732c9654e1..80e71ef89da90 100644
--- a/app/code/Magento/Catalog/Test/Mftf/ActionGroup/AdminCategoryActionGroup.xml
+++ b/app/code/Magento/Catalog/Test/Mftf/ActionGroup/AdminCategoryActionGroup.xml
@@ -316,4 +316,17 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/app/code/Magento/Catalog/Test/Mftf/Test/NewProductsAssignmentToCategoryWithInvalidDataTest.xml b/app/code/Magento/Catalog/Test/Mftf/Test/NewProductsAssignmentToCategoryWithInvalidDataTest.xml
new file mode 100644
index 0000000000000..3ef8ecfeff304
--- /dev/null
+++ b/app/code/Magento/Catalog/Test/Mftf/Test/NewProductsAssignmentToCategoryWithInvalidDataTest.xml
@@ -0,0 +1,62 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
From 924b6b44f59087ff67be32f22a2c41468234488f Mon Sep 17 00:00:00 2001
From: Lusine Papyan
Date: Tue, 9 Apr 2019 15:44:58 +0400
Subject: [PATCH 004/937] MAGETWO-51891: Category with invalid data loses new
products assignment after validation
- Update automated test script
---
.../NewProductsAssignmentToCategoryWithInvalidDataTest.xml | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/app/code/Magento/Catalog/Test/Mftf/Test/NewProductsAssignmentToCategoryWithInvalidDataTest.xml b/app/code/Magento/Catalog/Test/Mftf/Test/NewProductsAssignmentToCategoryWithInvalidDataTest.xml
index 3ef8ecfeff304..eb02db8553f6f 100644
--- a/app/code/Magento/Catalog/Test/Mftf/Test/NewProductsAssignmentToCategoryWithInvalidDataTest.xml
+++ b/app/code/Magento/Catalog/Test/Mftf/Test/NewProductsAssignmentToCategoryWithInvalidDataTest.xml
@@ -40,7 +40,7 @@
-
+
@@ -56,7 +56,7 @@
-
-
+
+
From 7c86433a2202eb1002dd29f423962ee5e6b95b94 Mon Sep 17 00:00:00 2001
From: Vital_Pantsialeyeu
Date: Tue, 30 Apr 2019 00:27:17 +0300
Subject: [PATCH 005/937] MAGETWO-69825: [GITHUB #9891] Subcategory
"liquid-hand-soap" is not opened in category "soap"
- Implemented validation URL key during category creation
---
.../CategoryUrlPathAutogeneratorObserver.php | 24 +++++++++++++++++--
1 file changed, 22 insertions(+), 2 deletions(-)
diff --git a/app/code/Magento/CatalogUrlRewrite/Observer/CategoryUrlPathAutogeneratorObserver.php b/app/code/Magento/CatalogUrlRewrite/Observer/CategoryUrlPathAutogeneratorObserver.php
index 713dd6ac0c736..95ddceed6ec8f 100644
--- a/app/code/Magento/CatalogUrlRewrite/Observer/CategoryUrlPathAutogeneratorObserver.php
+++ b/app/code/Magento/CatalogUrlRewrite/Observer/CategoryUrlPathAutogeneratorObserver.php
@@ -3,13 +3,14 @@
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
+declare(strict_types=1);
+
namespace Magento\CatalogUrlRewrite\Observer;
use Magento\Catalog\Model\Category;
use Magento\CatalogUrlRewrite\Model\CategoryUrlPathGenerator;
use Magento\CatalogUrlRewrite\Service\V1\StoreViewService;
use Magento\Catalog\Api\CategoryRepositoryInterface;
-use Magento\Framework\Event\Observer;
use Magento\CatalogUrlRewrite\Model\Category\ChildrenCategoriesProvider;
use Magento\Framework\Event\ObserverInterface;
use Magento\Store\Model\Store;
@@ -19,6 +20,14 @@
*/
class CategoryUrlPathAutogeneratorObserver implements ObserverInterface
{
+
+ /**
+ * Reserved endpoint names.
+ *
+ * @var array
+ */
+ private $invalidValues = ['admin', 'soap', 'rest', 'graphql'];
+
/**
* @var \Magento\CatalogUrlRewrite\Model\CategoryUrlPathGenerator
*/
@@ -72,7 +81,7 @@ public function execute(\Magento\Framework\Event\Observer $observer)
if ($category->getUrlKey() !== false && !$useDefaultAttribute) {
$resultUrlKey = $this->categoryUrlPathGenerator->getUrlKey($category);
$this->updateUrlKey($category, $resultUrlKey);
- } else if ($useDefaultAttribute) {
+ } elseif ($useDefaultAttribute) {
$resultUrlKey = $category->formatUrlKey($category->getOrigData('name'));
$this->updateUrlKey($category, $resultUrlKey);
$category->setUrlKey(null)->setUrlPath(null);
@@ -92,6 +101,17 @@ private function updateUrlKey($category, $urlKey)
if (empty($urlKey)) {
throw new \Magento\Framework\Exception\LocalizedException(__('Invalid URL key'));
}
+
+ if (in_array($urlKey, $this->invalidValues)) {
+ throw new \Magento\Framework\Exception\LocalizedException(
+ __(
+ 'URL key "%1" conflicts with reserved endpoint names: %2. Try another url key.',
+ $urlKey,
+ implode(', ', $this->invalidValues)
+ )
+ );
+ }
+
$category->setUrlKey($urlKey)
->setUrlPath($this->categoryUrlPathGenerator->getUrlPath($category));
if (!$category->isObjectNew()) {
From 6e1dc006c6cee0bbb692a2d077414c0ffdab7d48 Mon Sep 17 00:00:00 2001
From: Anahit Martirosyan
Date: Tue, 30 Apr 2019 15:51:27 +0400
Subject: [PATCH 006/937] MAGETWO-51891: Category with invalid data loses new
products assignment after validation
- Add updated test script
---
.../Catalog/Test/Mftf/ActionGroup/AdminCategoryActionGroup.xml | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/app/code/Magento/Catalog/Test/Mftf/ActionGroup/AdminCategoryActionGroup.xml b/app/code/Magento/Catalog/Test/Mftf/ActionGroup/AdminCategoryActionGroup.xml
index 80e71ef89da90..57dff7fb2ae90 100644
--- a/app/code/Magento/Catalog/Test/Mftf/ActionGroup/AdminCategoryActionGroup.xml
+++ b/app/code/Magento/Catalog/Test/Mftf/ActionGroup/AdminCategoryActionGroup.xml
@@ -320,7 +320,7 @@
-
+
From 6dfc8184af647e0f515a94e09ebee2f3b2cbf537 Mon Sep 17 00:00:00 2001
From: Evgeny Petrov
Date: Sat, 4 May 2019 15:22:27 +0300
Subject: [PATCH 007/937] MAGETWO-51891: Category with invalid data loses new
products assignment after validation
- Add updated test script
---
...ssignmentToCategoryWithInvalidDataTest.xml | 62 -------------------
1 file changed, 62 deletions(-)
delete mode 100644 app/code/Magento/Catalog/Test/Mftf/Test/NewProductsAssignmentToCategoryWithInvalidDataTest.xml
diff --git a/app/code/Magento/Catalog/Test/Mftf/Test/NewProductsAssignmentToCategoryWithInvalidDataTest.xml b/app/code/Magento/Catalog/Test/Mftf/Test/NewProductsAssignmentToCategoryWithInvalidDataTest.xml
deleted file mode 100644
index eb02db8553f6f..0000000000000
--- a/app/code/Magento/Catalog/Test/Mftf/Test/NewProductsAssignmentToCategoryWithInvalidDataTest.xml
+++ /dev/null
@@ -1,62 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
From 930ba4028399b15b1a46119d0d53e20157aafd36 Mon Sep 17 00:00:00 2001
From: Evgeny Petrov
Date: Sat, 11 May 2019 16:12:28 +0300
Subject: [PATCH 008/937] MAGETWO-51891: Category with invalid data loses new
products assignment after validation
---
.../Mftf/ActionGroup/AdminCategoryActionGroup.xml | 13 -------------
1 file changed, 13 deletions(-)
diff --git a/app/code/Magento/Catalog/Test/Mftf/ActionGroup/AdminCategoryActionGroup.xml b/app/code/Magento/Catalog/Test/Mftf/ActionGroup/AdminCategoryActionGroup.xml
index 57dff7fb2ae90..90d732c9654e1 100644
--- a/app/code/Magento/Catalog/Test/Mftf/ActionGroup/AdminCategoryActionGroup.xml
+++ b/app/code/Magento/Catalog/Test/Mftf/ActionGroup/AdminCategoryActionGroup.xml
@@ -316,17 +316,4 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
From 24889de9b1cf149b64fa0bd29d0ae64946e9cefd Mon Sep 17 00:00:00 2001
From: Lusine Papyan
Date: Wed, 15 May 2019 17:58:43 +0400
Subject: [PATCH 009/937] MAGETWO-69825: [GITHUB #9891] Subcategory
"liquid-hand-soap" is not opened in category "soap"
- Added automated test script
---
.../ActionGroup/AdminCategoryActionGroup.xml | 12 ++
.../AdminCategorySidebarTreeSection.xml | 1 +
...goryWithRestrictedUrlKeyNotCreatedTest.xml | 125 ++++++++++++++++++
3 files changed, 138 insertions(+)
create mode 100644 app/code/Magento/CatalogUrlRewrite/Test/Mftf/Test/AdminCategoryWithRestrictedUrlKeyNotCreatedTest.xml
diff --git a/app/code/Magento/Catalog/Test/Mftf/ActionGroup/AdminCategoryActionGroup.xml b/app/code/Magento/Catalog/Test/Mftf/ActionGroup/AdminCategoryActionGroup.xml
index 90d732c9654e1..a944aa72e5ccd 100644
--- a/app/code/Magento/Catalog/Test/Mftf/ActionGroup/AdminCategoryActionGroup.xml
+++ b/app/code/Magento/Catalog/Test/Mftf/ActionGroup/AdminCategoryActionGroup.xml
@@ -139,6 +139,18 @@
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/app/code/Magento/Catalog/Test/Mftf/Section/AdminCategorySidebarTreeSection.xml b/app/code/Magento/Catalog/Test/Mftf/Section/AdminCategorySidebarTreeSection.xml
index fba28b3feaff1..c6f669ce5c13f 100644
--- a/app/code/Magento/Catalog/Test/Mftf/Section/AdminCategorySidebarTreeSection.xml
+++ b/app/code/Magento/Catalog/Test/Mftf/Section/AdminCategorySidebarTreeSection.xml
@@ -17,5 +17,6 @@
+
diff --git a/app/code/Magento/CatalogUrlRewrite/Test/Mftf/Test/AdminCategoryWithRestrictedUrlKeyNotCreatedTest.xml b/app/code/Magento/CatalogUrlRewrite/Test/Mftf/Test/AdminCategoryWithRestrictedUrlKeyNotCreatedTest.xml
new file mode 100644
index 0000000000000..58997aa7a5182
--- /dev/null
+++ b/app/code/Magento/CatalogUrlRewrite/Test/Mftf/Test/AdminCategoryWithRestrictedUrlKeyNotCreatedTest.xml
@@ -0,0 +1,125 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
From 4a620bd1e6b9c21978c2c3e70d4d5338a71f676e Mon Sep 17 00:00:00 2001
From: Krissy Hiserote
Date: Fri, 24 May 2019 09:33:03 -0500
Subject: [PATCH 010/937] MC-16650: Product Attribute Type Price Not Displaying
---
.../Model/Layer/Filter/Decimal.php | 8 +++--
.../Model/Search/RequestGenerator/Decimal.php | 33 ++++++++++++++++++-
.../Search/RequestGenerator/DecimalTest.php | 22 +++++++++++--
3 files changed, 57 insertions(+), 6 deletions(-)
diff --git a/app/code/Magento/CatalogSearch/Model/Layer/Filter/Decimal.php b/app/code/Magento/CatalogSearch/Model/Layer/Filter/Decimal.php
index e9fb1070fedd5..ea5492212c1f1 100644
--- a/app/code/Magento/CatalogSearch/Model/Layer/Filter/Decimal.php
+++ b/app/code/Magento/CatalogSearch/Model/Layer/Filter/Decimal.php
@@ -3,6 +3,8 @@
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
+declare(strict_types=1);
+
namespace Magento\CatalogSearch\Model\Layer\Filter;
use Magento\Catalog\Model\Layer\Filter\AbstractFilter;
@@ -74,7 +76,7 @@ public function apply(\Magento\Framework\App\RequestInterface $request)
->getProductCollection()
->addFieldToFilter(
$this->getAttributeModel()->getAttributeCode(),
- ['from' => $from, 'to' => $to]
+ ['from' => $from, 'to' => empty($to) || $from === $to ? $to : $to - 0.001]
);
$this->getLayer()->getState()->addFilter(
@@ -111,7 +113,7 @@ protected function _getItemsData()
$from = '';
}
if ($to == '*') {
- $to = null;
+ $to = '';
}
$label = $this->renderRangeLabel(empty($from) ? 0 : $from, $to);
$value = $from . '-' . $to;
@@ -138,7 +140,7 @@ protected function _getItemsData()
protected function renderRangeLabel($fromPrice, $toPrice)
{
$formattedFromPrice = $this->priceCurrency->format($fromPrice);
- if ($toPrice === null) {
+ if ($toPrice === '') {
return __('%1 and above', $formattedFromPrice);
} else {
if ($fromPrice != $toPrice) {
diff --git a/app/code/Magento/CatalogSearch/Model/Search/RequestGenerator/Decimal.php b/app/code/Magento/CatalogSearch/Model/Search/RequestGenerator/Decimal.php
index b3d39a48fe9fc..c9f738b07c175 100644
--- a/app/code/Magento/CatalogSearch/Model/Search/RequestGenerator/Decimal.php
+++ b/app/code/Magento/CatalogSearch/Model/Search/RequestGenerator/Decimal.php
@@ -3,18 +3,36 @@
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
+declare(strict_types=1);
namespace Magento\CatalogSearch\Model\Search\RequestGenerator;
use Magento\Catalog\Model\ResourceModel\Eav\Attribute;
use Magento\Framework\Search\Request\BucketInterface;
use Magento\Framework\Search\Request\FilterInterface;
+use Magento\Framework\App\Config\ScopeConfigInterface;
+use Magento\Framework\App\ObjectManager;
+use Magento\Catalog\Model\Layer\Filter\Dynamic\AlgorithmFactory;
+use Magento\Store\Model\ScopeInterface;
/**
* Catalog search range request generator.
*/
class Decimal implements GeneratorInterface
{
+ /**
+ * @var \Magento\Store\Model\ScopeInterface
+ */
+ private $scopeConfig;
+
+ /**
+ * @param \Magento\Store\Model\ScopeInterface|null $scopeConfig
+ */
+ public function __construct(ScopeConfigInterface $scopeConfig = null)
+ {
+ $this->scopeConfig = $scopeConfig ?: ObjectManager::getInstance()->get(ScopeConfigInterface::class);
+ }
+
/**
* @inheritdoc
*/
@@ -38,8 +56,21 @@ public function getAggregationData(Attribute $attribute, $bucketName)
'type' => BucketInterface::TYPE_DYNAMIC,
'name' => $bucketName,
'field' => $attribute->getAttributeCode(),
- 'method' => 'manual',
+ 'method' => $this->getRangeCalculation(),
'metric' => [['type' => 'count']],
];
}
+
+ /**
+ * Get range calculation by what was set in the configuration
+ *
+ * @return string
+ */
+ private function getRangeCalculation(): string
+ {
+ return $this->scopeConfig->getValue(
+ AlgorithmFactory::XML_PATH_RANGE_CALCULATION,
+ ScopeInterface::SCOPE_STORE
+ );
+ }
}
diff --git a/app/code/Magento/CatalogSearch/Test/Unit/Model/Search/RequestGenerator/DecimalTest.php b/app/code/Magento/CatalogSearch/Test/Unit/Model/Search/RequestGenerator/DecimalTest.php
index 8157c1fa8fa82..f04188fbf7bdd 100644
--- a/app/code/Magento/CatalogSearch/Test/Unit/Model/Search/RequestGenerator/DecimalTest.php
+++ b/app/code/Magento/CatalogSearch/Test/Unit/Model/Search/RequestGenerator/DecimalTest.php
@@ -3,6 +3,7 @@
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
+declare(strict_types=1);
namespace Magento\CatalogSearch\Test\Unit\Model\Search\RequestGenerator;
@@ -10,7 +11,11 @@
use Magento\CatalogSearch\Model\Search\RequestGenerator\Decimal;
use Magento\Framework\Search\Request\BucketInterface;
use Magento\Framework\Search\Request\FilterInterface;
+use Magento\Framework\App\Config\ScopeConfigInterface;
+/**
+ * Test catalog search range request generator.
+ */
class DecimalTest extends \PHPUnit\Framework\TestCase
{
/** @var Decimal */
@@ -19,14 +24,23 @@ class DecimalTest extends \PHPUnit\Framework\TestCase
/** @var Attribute|\PHPUnit_Framework_MockObject_MockObject */
private $attribute;
+ /** @var \Magento\Framework\App\Config\ScopeConfigInterface|\PHPUnit_Framework_MockObject_MockObject */
+ private $scopeConfigMock;
+
protected function setUp()
{
$this->attribute = $this->getMockBuilder(Attribute::class)
->disableOriginalConstructor()
->setMethods(['getAttributeCode'])
->getMockForAbstractClass();
+ $this->scopeConfigMock = $this->getMockBuilder(ScopeConfigInterface::class)
+ ->setMethods(['getValue'])
+ ->getMockForAbstractClass();
$objectManager = new \Magento\Framework\TestFramework\Unit\Helper\ObjectManager($this);
- $this->decimal = $objectManager->getObject(Decimal::class);
+ $this->decimal = $objectManager->getObject(
+ Decimal::class,
+ ['scopeConfig' => $this->scopeConfigMock]
+ );
}
public function testGetFilterData()
@@ -51,16 +65,20 @@ public function testGetAggregationData()
{
$bucketName = 'test_bucket_name';
$attributeCode = 'test_attribute_code';
+ $method = 'manual';
$expected = [
'type' => BucketInterface::TYPE_DYNAMIC,
'name' => $bucketName,
'field' => $attributeCode,
- 'method' => 'manual',
+ 'method' => $method,
'metric' => [['type' => 'count']],
];
$this->attribute->expects($this->atLeastOnce())
->method('getAttributeCode')
->willReturn($attributeCode);
+ $this->scopeConfigMock->expects($this->once())
+ ->method('getValue')
+ ->willReturn($method);
$actual = $this->decimal->getAggregationData($this->attribute, $bucketName);
$this->assertEquals($expected, $actual);
}
From e036a53959192bfeea21a8df7cc7b07891c71138 Mon Sep 17 00:00:00 2001
From: Kieu Phan
Date: Fri, 24 May 2019 14:33:27 -0500
Subject: [PATCH 011/937] MC-16650: Product Attribute Type Price Not Displaying
Added MFTF tests
---
.../Test/Mftf/Data/ProductAttributeData.xml | 22 +++++
.../Mftf/Section/AdminProductFormSection.xml | 1 +
.../StorefrontCategoryFilterSection.xml | 1 +
.../LayerNavigationOfCatalogSearchTest.xml | 85 +++++++++++++++++++
4 files changed, 109 insertions(+)
create mode 100644 app/code/Magento/CatalogSearch/Test/Mftf/Test/LayerNavigationOfCatalogSearchTest.xml
diff --git a/app/code/Magento/Catalog/Test/Mftf/Data/ProductAttributeData.xml b/app/code/Magento/Catalog/Test/Mftf/Data/ProductAttributeData.xml
index 817dd637f81dd..31a3745ca4417 100644
--- a/app/code/Magento/Catalog/Test/Mftf/Data/ProductAttributeData.xml
+++ b/app/code/Magento/Catalog/Test/Mftf/Data/ProductAttributeData.xml
@@ -278,6 +278,28 @@
false
ProductAttributeFrontendLabel
+
+ attribute
+ price
+ global
+ false
+ false
+ false
+ true
+ false
+ false
+ true
+ true
+ false
+ false
+ false
+ true
+ false
+ false
+ false
+ false
+ ProductAttributeFrontendLabel
+
text
defaultValue
diff --git a/app/code/Magento/Catalog/Test/Mftf/Section/AdminProductFormSection.xml b/app/code/Magento/Catalog/Test/Mftf/Section/AdminProductFormSection.xml
index f515171e835db..9ef3de033f808 100644
--- a/app/code/Magento/Catalog/Test/Mftf/Section/AdminProductFormSection.xml
+++ b/app/code/Magento/Catalog/Test/Mftf/Section/AdminProductFormSection.xml
@@ -207,5 +207,6 @@
+
\ No newline at end of file
diff --git a/app/code/Magento/Catalog/Test/Mftf/Section/StorefrontCategoryFilterSection.xml b/app/code/Magento/Catalog/Test/Mftf/Section/StorefrontCategoryFilterSection.xml
index ddec4428f90e2..21a0d72dc991c 100644
--- a/app/code/Magento/Catalog/Test/Mftf/Section/StorefrontCategoryFilterSection.xml
+++ b/app/code/Magento/Catalog/Test/Mftf/Section/StorefrontCategoryFilterSection.xml
@@ -11,5 +11,6 @@
diff --git a/app/code/Magento/CatalogSearch/Test/Mftf/Test/LayerNavigationOfCatalogSearchTest.xml b/app/code/Magento/CatalogSearch/Test/Mftf/Test/LayerNavigationOfCatalogSearchTest.xml
new file mode 100644
index 0000000000000..3bc086c62bb3b
--- /dev/null
+++ b/app/code/Magento/CatalogSearch/Test/Mftf/Test/LayerNavigationOfCatalogSearchTest.xml
@@ -0,0 +1,85 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
From cdc1c77a11aa1ce77cb930267e141f96e8552e4a Mon Sep 17 00:00:00 2001
From: Kieu Phan
Date: Fri, 24 May 2019 17:48:46 -0500
Subject: [PATCH 012/937] MC-16650: Product Attribute Type Price Not Displaying
Added assertion for attribute lable and set the default configuration in
Admin
---
.../Test/Mftf/Section/AdminProductFormSection.xml | 1 +
.../Mftf/Section/StorefrontCategoryFilterSection.xml | 3 ++-
.../Mftf/Test/LayerNavigationOfCatalogSearchTest.xml | 12 ++++++++----
3 files changed, 11 insertions(+), 5 deletions(-)
diff --git a/app/code/Magento/Catalog/Test/Mftf/Section/AdminProductFormSection.xml b/app/code/Magento/Catalog/Test/Mftf/Section/AdminProductFormSection.xml
index 9ef3de033f808..76659dfa1c896 100644
--- a/app/code/Magento/Catalog/Test/Mftf/Section/AdminProductFormSection.xml
+++ b/app/code/Magento/Catalog/Test/Mftf/Section/AdminProductFormSection.xml
@@ -208,5 +208,6 @@
+
\ No newline at end of file
diff --git a/app/code/Magento/Catalog/Test/Mftf/Section/StorefrontCategoryFilterSection.xml b/app/code/Magento/Catalog/Test/Mftf/Section/StorefrontCategoryFilterSection.xml
index 21a0d72dc991c..31667c9b89935 100644
--- a/app/code/Magento/Catalog/Test/Mftf/Section/StorefrontCategoryFilterSection.xml
+++ b/app/code/Magento/Catalog/Test/Mftf/Section/StorefrontCategoryFilterSection.xml
@@ -11,6 +11,7 @@
diff --git a/app/code/Magento/CatalogSearch/Test/Mftf/Test/LayerNavigationOfCatalogSearchTest.xml b/app/code/Magento/CatalogSearch/Test/Mftf/Test/LayerNavigationOfCatalogSearchTest.xml
index 3bc086c62bb3b..32d7ebcb1d7c5 100644
--- a/app/code/Magento/CatalogSearch/Test/Mftf/Test/LayerNavigationOfCatalogSearchTest.xml
+++ b/app/code/Magento/CatalogSearch/Test/Mftf/Test/LayerNavigationOfCatalogSearchTest.xml
@@ -11,13 +11,14 @@
-
-
-
+
+
+
+
@@ -43,6 +44,7 @@
+
@@ -58,7 +60,9 @@
-
+
+
+
From 06926c83b5b99c115409cec4b9c19b3909c6ba4d Mon Sep 17 00:00:00 2001
From: Yuliya Labudova
Date: Wed, 29 May 2019 11:52:34 +0300
Subject: [PATCH 013/937] MAGETWO-44170: Not pass function test
\Magento\Catalog\Test\TestCase\Product\ProductTypeSwitchingOnUpdateTest
- Unskip tests.
---
.../TestCase/Product/ProductTypeSwitchingOnUpdateTest.php | 1 +
.../TestCase/Product/ProductTypeSwitchingOnUpdateTest.xml | 7 +++++++
2 files changed, 8 insertions(+)
diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/ProductTypeSwitchingOnUpdateTest.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/ProductTypeSwitchingOnUpdateTest.php
index 90cd6bdb76328..2abd17fce5b45 100644
--- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/ProductTypeSwitchingOnUpdateTest.php
+++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/ProductTypeSwitchingOnUpdateTest.php
@@ -36,6 +36,7 @@
class ProductTypeSwitchingOnUpdateTest extends Injectable
{
/* tags */
+ const TEST_TYPE = 'acceptance_test';
const MVP = 'yes';
/* end tags */
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 5fa1cfe5e5911..3d3e36754e92c 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 @@
catalogProductSimple::default
configurableProduct::default
-
+ test_type:acceptance_test
@@ -34,6 +35,7 @@
+ test_type:acceptance_test
configurableProduct::default
catalogProductVirtual::required_fields
deleteVariations
@@ -48,6 +50,7 @@
+ test_type:acceptance_test
catalogProductVirtual::default
configurableProduct::not_virtual_for_type_switching
-
@@ -60,6 +63,7 @@
+ test_type:acceptance_test
catalogProductVirtual::default
downloadableProduct::default
-
@@ -71,6 +75,7 @@
+ test_type:acceptance_test
downloadableProduct::default
catalogProductSimple::default
-
@@ -78,6 +83,7 @@
+ test_type:acceptance_test
downloadableProduct::default
configurableProduct::not_virtual_for_type_switching
clearDownloadableData
@@ -97,6 +103,7 @@
+ test_type:acceptance_test
catalogProductSimple::default
downloadableProduct::default
-
From ea64edf1b2c274b407312adc8ce8ea3e343d0b91 Mon Sep 17 00:00:00 2001
From: Yuliya Labudova
Date: Wed, 29 May 2019 14:51:39 +0300
Subject: [PATCH 014/937] MAGETWO-94565: Catalog product collection filters
produce errors and cause inconsistent behaviour
- Fix visibility and category filters;
- Add integration tests.
---
.../ResourceModel/Product/Collection.php | 48 ++++++++++-
.../ResourceModel/Product/CollectionTest.php | 82 +++++++++++++++++--
2 files changed, 119 insertions(+), 11 deletions(-)
diff --git a/app/code/Magento/Catalog/Model/ResourceModel/Product/Collection.php b/app/code/Magento/Catalog/Model/ResourceModel/Product/Collection.php
index 384b6ddcefc31..cabbcb67fb5a7 100644
--- a/app/code/Magento/Catalog/Model/ResourceModel/Product/Collection.php
+++ b/app/code/Magento/Catalog/Model/ResourceModel/Product/Collection.php
@@ -3,6 +3,7 @@
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
+declare(strict_types=1);
namespace Magento\Catalog\Model\ResourceModel\Product;
@@ -22,6 +23,7 @@
use Magento\Framework\Indexer\DimensionFactory;
use Magento\Store\Model\Indexer\WebsiteDimensionProvider;
use Magento\Store\Model\Store;
+use Magento\Catalog\Api\CategoryRepositoryInterface;
/**
* Product collection
@@ -302,6 +304,11 @@ class Collection extends \Magento\Catalog\Model\ResourceModel\Collection\Abstrac
*/
private $urlFinder;
+ /**
+ * @var CategoryRepositoryInterface
+ */
+ private $categoryRepository;
+
/**
* Collection constructor
*
@@ -330,6 +337,7 @@ class Collection extends \Magento\Catalog\Model\ResourceModel\Collection\Abstrac
* @param TableMaintainer|null $tableMaintainer
* @param PriceTableResolver|null $priceTableResolver
* @param DimensionFactory|null $dimensionFactory
+ * @param CategoryRepositoryInterface|null $categoryRepository
*
* @SuppressWarnings(PHPMD.ExcessiveParameterList)
*/
@@ -358,7 +366,8 @@ public function __construct(
MetadataPool $metadataPool = null,
TableMaintainer $tableMaintainer = null,
PriceTableResolver $priceTableResolver = null,
- DimensionFactory $dimensionFactory = null
+ DimensionFactory $dimensionFactory = null,
+ CategoryRepositoryInterface $categoryRepository = null
) {
$this->moduleManager = $moduleManager;
$this->_catalogProductFlatState = $catalogProductFlatState;
@@ -392,6 +401,8 @@ public function __construct(
$this->priceTableResolver = $priceTableResolver ?: ObjectManager::getInstance()->get(PriceTableResolver::class);
$this->dimensionFactory = $dimensionFactory
?: ObjectManager::getInstance()->get(DimensionFactory::class);
+ $this->categoryRepository = $categoryRepository ?: ObjectManager::getInstance()
+ ->get(CategoryRepositoryInterface::class);
}
/**
@@ -1673,7 +1684,11 @@ public function addFilterByRequiredOptions()
public function setVisibility($visibility)
{
$this->_productLimitationFilters['visibility'] = $visibility;
- $this->_applyProductLimitations();
+ if ($this->getStoreId() == Store::DEFAULT_STORE_ID) {
+ $this->addAttributeToFilter('visibility', $visibility);
+ } else {
+ $this->_applyProductLimitations();
+ }
return $this;
}
@@ -2053,12 +2068,14 @@ protected function _applyProductLimitations()
protected function _applyZeroStoreProductLimitations()
{
$filters = $this->_productLimitationFilters;
+ $categories = [];
+ $categories = $this->getChildrenCategories((int)$filters['category_id'], $categories);
$conditions = [
'cat_pro.product_id=e.entity_id',
$this->getConnection()->quoteInto(
- 'cat_pro.category_id=?',
- $filters['category_id']
+ 'cat_pro.category_id IN (?)',
+ $categories
),
];
$joinCond = join(' AND ', $conditions);
@@ -2079,6 +2096,29 @@ protected function _applyZeroStoreProductLimitations()
return $this;
}
+ /**
+ * Get children categories.
+ *
+ * @param int $categoryId
+ * @param array $categories
+ * @return array
+ */
+ private function getChildrenCategories(int $categoryId, array $categories): array
+ {
+ $category = $this->categoryRepository->get($categoryId);
+ $categories[] = $category->getId();
+ if ($category->getIsAnchor()) {
+ $categoryChildren = $category->getChildren();
+ $categoryChildrenIds = explode(',', $categoryChildren);
+ foreach ($categoryChildrenIds as $categoryChildrenId) {
+ if ($categoryChildrenId) {
+ $categories = $this->getChildrenCategories((int)$categoryChildrenId, $categories);
+ }
+ }
+ }
+ return $categories;
+ }
+
/**
* Add category ids to loaded items
*
diff --git a/dev/tests/integration/testsuite/Magento/Catalog/Model/ResourceModel/Product/CollectionTest.php b/dev/tests/integration/testsuite/Magento/Catalog/Model/ResourceModel/Product/CollectionTest.php
index 4cc6265a992fa..80d700c7e54ff 100644
--- a/dev/tests/integration/testsuite/Magento/Catalog/Model/ResourceModel/Product/CollectionTest.php
+++ b/dev/tests/integration/testsuite/Magento/Catalog/Model/ResourceModel/Product/CollectionTest.php
@@ -3,8 +3,16 @@
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
+declare(strict_types=1);
+
namespace Magento\Catalog\Model\ResourceModel\Product;
+use Magento\Catalog\Model\Product\Visibility;
+use Magento\Framework\App\Area;
+use Magento\Framework\App\State;
+use Magento\Store\Model\Store;
+use Magento\TestFramework\Helper\Bootstrap;
+
/**
* Collection test
*/
@@ -31,15 +39,15 @@ class CollectionTest extends \PHPUnit\Framework\TestCase
*/
protected function setUp()
{
- $this->collection = \Magento\TestFramework\Helper\Bootstrap::getObjectManager()->create(
+ $this->collection = Bootstrap::getObjectManager()->create(
\Magento\Catalog\Model\ResourceModel\Product\Collection::class
);
- $this->processor = \Magento\TestFramework\Helper\Bootstrap::getObjectManager()->create(
+ $this->processor = Bootstrap::getObjectManager()->create(
\Magento\Catalog\Model\Indexer\Product\Price\Processor::class
);
- $this->productRepository = \Magento\TestFramework\Helper\Bootstrap::getObjectManager()->create(
+ $this->productRepository = Bootstrap::getObjectManager()->create(
\Magento\Catalog\Api\ProductRepositoryInterface::class
);
}
@@ -54,7 +62,7 @@ public function testAddPriceDataOnSchedule()
$this->processor->getIndexer()->setScheduled(true);
$this->assertTrue($this->processor->getIndexer()->isScheduled());
- $productRepository = \Magento\TestFramework\Helper\Bootstrap::getObjectManager()
+ $productRepository = Bootstrap::getObjectManager()
->create(\Magento\Catalog\Api\ProductRepositoryInterface::class);
/** @var \Magento\Catalog\Api\Data\ProductInterface $product */
$product = $productRepository->get('simple');
@@ -73,7 +81,7 @@ public function testAddPriceDataOnSchedule()
//reindexing
$this->processor->getIndexer()->reindexList([1]);
- $this->collection = \Magento\TestFramework\Helper\Bootstrap::getObjectManager()->create(
+ $this->collection = Bootstrap::getObjectManager()->create(
\Magento\Catalog\Model\ResourceModel\Product\Collection::class
);
$this->collection->addPriceData(0, 1);
@@ -89,6 +97,66 @@ public function testAddPriceDataOnSchedule()
$this->processor->getIndexer()->setScheduled(false);
}
+ /**
+ * @magentoDataFixture Magento/Catalog/_files/products.php
+ * @magentoDbIsolation disabled
+ */
+ public function testSetVisibility()
+ {
+ $appState = Bootstrap::getObjectManager()
+ ->create(State::class);
+ $appState->setAreaCode(Area::AREA_CRONTAB);
+ $this->collection->setStoreId(Store::DEFAULT_STORE_ID);
+ $this->collection->setVisibility([Visibility::VISIBILITY_BOTH]);
+ $this->collection->load();
+ /** @var \Magento\Catalog\Api\Data\ProductInterface[] $product */
+ $items = $this->collection->getItems();
+ $this->assertCount(2, $items);
+ }
+
+ /**
+ * @magentoDataFixture Magento/Catalog/_files/category_product.php
+ * @magentoDbIsolation disabled
+ */
+ public function testSetCategoryWithStoreFilter()
+ {
+ $appState = Bootstrap::getObjectManager()
+ ->create(State::class);
+ $appState->setAreaCode(Area::AREA_CRONTAB);
+
+ $category = \Magento\Framework\App\ObjectManager::getInstance()->get(
+ \Magento\Catalog\Model\Category::class
+ )->load(333);
+ $this->collection->addCategoryFilter($category)->addStoreFilter(1);
+ $this->collection->load();
+
+ $collectionStoreFilterAfter = Bootstrap::getObjectManager()->create(
+ \Magento\Catalog\Model\ResourceModel\Product\Collection::class
+ );
+ $collectionStoreFilterAfter->addStoreFilter(1)->addCategoryFilter($category);
+ $collectionStoreFilterAfter->load();
+ $this->assertEquals($this->collection->getItems(), $collectionStoreFilterAfter->getItems());
+ $this->assertCount(1, $collectionStoreFilterAfter->getItems());
+ }
+
+ /**
+ * @magentoDataFixture Magento/Catalog/_files/categories.php
+ * @magentoDbIsolation disabled
+ */
+ public function testSetCategoryFilter()
+ {
+ $appState = Bootstrap::getObjectManager()
+ ->create(State::class);
+ $appState->setAreaCode(Area::AREA_CRONTAB);
+
+ $category = \Magento\Framework\App\ObjectManager::getInstance()->get(
+ \Magento\Catalog\Model\Category::class
+ )->load(3);
+ $this->collection->addCategoryFilter($category);
+ $this->collection->load();
+ $this->assertEquals($this->collection->getSize(), 3);
+ }
+
/**
* @magentoDataFixture Magento/Catalog/_files/products.php
* @magentoAppIsolation enabled
@@ -98,7 +166,7 @@ public function testAddPriceDataOnSave()
{
$this->processor->getIndexer()->setScheduled(false);
$this->assertFalse($this->processor->getIndexer()->isScheduled());
- $productRepository = \Magento\TestFramework\Helper\Bootstrap::getObjectManager()
+ $productRepository = Bootstrap::getObjectManager()
->create(\Magento\Catalog\Api\ProductRepositoryInterface::class);
/** @var \Magento\Catalog\Api\Data\ProductInterface $product */
$product = $productRepository->get('simple');
@@ -184,7 +252,7 @@ public function testJoinTable()
$productTable = $this->collection->getTable('catalog_product_entity');
$urlRewriteTable = $this->collection->getTable('url_rewrite');
- // phpcs:ignore
+ // phpcs:ignore Magento2.SQL.RawQuery
$expected = 'SELECT `e`.*, `alias`.`request_path` FROM `' . $productTable . '` AS `e`'
. ' LEFT JOIN `' . $urlRewriteTable . '` AS `alias` ON (alias.entity_id =e.entity_id)'
. ' AND (alias.entity_type = \'product\')';
From 2358d1c605472e862ae05a539dd9a220f9503567 Mon Sep 17 00:00:00 2001
From: Kieu Phan
Date: Fri, 31 May 2019 15:00:47 -0500
Subject: [PATCH 015/937] MC-16650: Product Attribute Type Price Not Displaying
Changes entity name for MFTF test code
---
.../Magento/Catalog/Test/Mftf/Data/ProductAttributeData.xml | 2 +-
.../Test/Mftf/Test/LayerNavigationOfCatalogSearchTest.xml | 4 ++--
2 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/app/code/Magento/Catalog/Test/Mftf/Data/ProductAttributeData.xml b/app/code/Magento/Catalog/Test/Mftf/Data/ProductAttributeData.xml
index 31a3745ca4417..ca2637e9314c7 100644
--- a/app/code/Magento/Catalog/Test/Mftf/Data/ProductAttributeData.xml
+++ b/app/code/Magento/Catalog/Test/Mftf/Data/ProductAttributeData.xml
@@ -278,7 +278,7 @@
false
ProductAttributeFrontendLabel
-
+
attribute
price
global
diff --git a/app/code/Magento/CatalogSearch/Test/Mftf/Test/LayerNavigationOfCatalogSearchTest.xml b/app/code/Magento/CatalogSearch/Test/Mftf/Test/LayerNavigationOfCatalogSearchTest.xml
index 32d7ebcb1d7c5..cc414a1088ecb 100644
--- a/app/code/Magento/CatalogSearch/Test/Mftf/Test/LayerNavigationOfCatalogSearchTest.xml
+++ b/app/code/Magento/CatalogSearch/Test/Mftf/Test/LayerNavigationOfCatalogSearchTest.xml
@@ -19,8 +19,7 @@
-
-
+
@@ -31,6 +30,7 @@
+
From 15d33b8b1c9633d0a96c244c20f10abcf50823c4 Mon Sep 17 00:00:00 2001
From: Kieu Phan
Date: Mon, 3 Jun 2019 16:44:46 -0500
Subject: [PATCH 016/937] MC-16650: Product Attribute Type Price Not Displaying
Changed selector of grabTextFrom created attribute and removed the last
assertion which is not scope of this test
---
.../Test/Mftf/Section/StorefrontCategoryFilterSection.xml | 3 +--
.../Test/Mftf/Test/LayerNavigationOfCatalogSearchTest.xml | 6 +++---
2 files changed, 4 insertions(+), 5 deletions(-)
diff --git a/app/code/Magento/Catalog/Test/Mftf/Section/StorefrontCategoryFilterSection.xml b/app/code/Magento/Catalog/Test/Mftf/Section/StorefrontCategoryFilterSection.xml
index 31667c9b89935..fe3d3e298cbc9 100644
--- a/app/code/Magento/Catalog/Test/Mftf/Section/StorefrontCategoryFilterSection.xml
+++ b/app/code/Magento/Catalog/Test/Mftf/Section/StorefrontCategoryFilterSection.xml
@@ -11,7 +11,6 @@
diff --git a/app/code/Magento/CatalogSearch/Test/Mftf/Test/LayerNavigationOfCatalogSearchTest.xml b/app/code/Magento/CatalogSearch/Test/Mftf/Test/LayerNavigationOfCatalogSearchTest.xml
index cc414a1088ecb..f1c655f4b5ab1 100644
--- a/app/code/Magento/CatalogSearch/Test/Mftf/Test/LayerNavigationOfCatalogSearchTest.xml
+++ b/app/code/Magento/CatalogSearch/Test/Mftf/Test/LayerNavigationOfCatalogSearchTest.xml
@@ -14,6 +14,7 @@
+
@@ -44,7 +45,7 @@
-
+
@@ -61,8 +62,7 @@
-
-
+
From 14e6b3fc9c95023c00c670ae349de31e5a589994 Mon Sep 17 00:00:00 2001
From: Kieu Phan
Date: Mon, 3 Jun 2019 16:50:21 -0500
Subject: [PATCH 017/937] MC-16650: Product Attribute Type Price Not Displaying
Removed unnecessary selector after changing assertion in test
---
.../Catalog/Test/Mftf/Section/AdminProductFormSection.xml | 1 -
1 file changed, 1 deletion(-)
diff --git a/app/code/Magento/Catalog/Test/Mftf/Section/AdminProductFormSection.xml b/app/code/Magento/Catalog/Test/Mftf/Section/AdminProductFormSection.xml
index 76659dfa1c896..9ef3de033f808 100644
--- a/app/code/Magento/Catalog/Test/Mftf/Section/AdminProductFormSection.xml
+++ b/app/code/Magento/Catalog/Test/Mftf/Section/AdminProductFormSection.xml
@@ -208,6 +208,5 @@
-
\ No newline at end of file
From a4f2c53f19359fd4b942e3609bfc314c07404780 Mon Sep 17 00:00:00 2001
From: Kieu Phan
Date: Mon, 3 Jun 2019 17:01:12 -0500
Subject: [PATCH 018/937] MC-16650: Product Attribute Type Price Not Displaying
---
.../Test/Mftf/Test/LayerNavigationOfCatalogSearchTest.xml | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/app/code/Magento/CatalogSearch/Test/Mftf/Test/LayerNavigationOfCatalogSearchTest.xml b/app/code/Magento/CatalogSearch/Test/Mftf/Test/LayerNavigationOfCatalogSearchTest.xml
index f1c655f4b5ab1..e91fb9b7a55cc 100644
--- a/app/code/Magento/CatalogSearch/Test/Mftf/Test/LayerNavigationOfCatalogSearchTest.xml
+++ b/app/code/Magento/CatalogSearch/Test/Mftf/Test/LayerNavigationOfCatalogSearchTest.xml
@@ -61,8 +61,7 @@
-
-
+
From 8f9f248cd73446c47515ad738022f08b977ad2ff Mon Sep 17 00:00:00 2001
From: Krissy Hiserote
Date: Tue, 4 Jun 2019 11:35:21 -0500
Subject: [PATCH 019/937] MC-16650: Product Attribute Type Price Not Displaying
- extract hard to read logic and add integration tests
---
.../Model/Layer/Filter/Decimal.php | 21 ++++-
.../attribute_special_price_filterable.php | 12 +++
.../_files/multiple_visible_products.php | 76 +++++++++++++++++++
.../multiple_visible_products_rollback.php | 28 +++++++
.../Model/Layer/Filter/DecimalTest.php | 74 ++++++++++++++++++
5 files changed, 210 insertions(+), 1 deletion(-)
create mode 100644 dev/tests/integration/testsuite/Magento/Catalog/Model/Layer/Filter/_files/attribute_special_price_filterable.php
create mode 100644 dev/tests/integration/testsuite/Magento/Catalog/_files/multiple_visible_products.php
create mode 100644 dev/tests/integration/testsuite/Magento/Catalog/_files/multiple_visible_products_rollback.php
diff --git a/app/code/Magento/CatalogSearch/Model/Layer/Filter/Decimal.php b/app/code/Magento/CatalogSearch/Model/Layer/Filter/Decimal.php
index ea5492212c1f1..4c83c3f7184f1 100644
--- a/app/code/Magento/CatalogSearch/Model/Layer/Filter/Decimal.php
+++ b/app/code/Magento/CatalogSearch/Model/Layer/Filter/Decimal.php
@@ -76,7 +76,7 @@ public function apply(\Magento\Framework\App\RequestInterface $request)
->getProductCollection()
->addFieldToFilter(
$this->getAttributeModel()->getAttributeCode(),
- ['from' => $from, 'to' => empty($to) || $from === $to ? $to : $to - 0.001]
+ ['from' => $from, 'to' => $this->getToRangeValue($from, $to)]
);
$this->getLayer()->getState()->addFilter(
@@ -149,4 +149,23 @@ protected function renderRangeLabel($fromPrice, $toPrice)
return __('%1 - %2', $formattedFromPrice, $this->priceCurrency->format($toPrice));
}
}
+
+ /**
+ * Get the to range value
+ *
+ * When the range is 10-20 we only need to get products that are in the 10-19.99 range.
+ * 20 should be in the next range group.
+ *
+ * @param float|string $from
+ * @param float|string $to
+ * @return float|string
+ */
+ private function getToRangeValue($from, $to)
+ {
+ if (!empty($to) && $from !== $to) {
+ $to -= 0.001;
+ }
+
+ return $to;
+ }
}
diff --git a/dev/tests/integration/testsuite/Magento/Catalog/Model/Layer/Filter/_files/attribute_special_price_filterable.php b/dev/tests/integration/testsuite/Magento/Catalog/Model/Layer/Filter/_files/attribute_special_price_filterable.php
new file mode 100644
index 0000000000000..3c92db99cd4f1
--- /dev/null
+++ b/dev/tests/integration/testsuite/Magento/Catalog/Model/Layer/Filter/_files/attribute_special_price_filterable.php
@@ -0,0 +1,12 @@
+create(
+ \Magento\Catalog\Setup\CategorySetup::class
+);
+
+$installer->updateAttribute('catalog_product', 'special_price', 'is_filterable', 1);
\ No newline at end of file
diff --git a/dev/tests/integration/testsuite/Magento/Catalog/_files/multiple_visible_products.php b/dev/tests/integration/testsuite/Magento/Catalog/_files/multiple_visible_products.php
new file mode 100644
index 0000000000000..4ace41d23c872
--- /dev/null
+++ b/dev/tests/integration/testsuite/Magento/Catalog/_files/multiple_visible_products.php
@@ -0,0 +1,76 @@
+create(\Magento\Catalog\Model\Product::class);
+$product->isObjectNew(true);
+$product->setTypeId(\Magento\Catalog\Model\Product\Type::TYPE_SIMPLE)
+ ->setId(10)
+ ->setAttributeSetId(4)
+ ->setName('Simple Product1')
+ ->setSku('simple1')
+ ->setTaxClassId('none')
+ ->setDescription('description')
+ ->setShortDescription('short description')
+ ->setOptionsContainer('container1')
+ ->setMsrpDisplayActualPriceType(\Magento\Msrp\Model\Product\Attribute\Source\Type::TYPE_IN_CART)
+ ->setPrice(15)
+ ->setWeight(10)
+ ->setMetaTitle('meta title')
+ ->setMetaKeyword('meta keyword')
+ ->setMetaDescription('meta description')
+ ->setVisibility(\Magento\Catalog\Model\Product\Visibility::VISIBILITY_BOTH)
+ ->setStatus(\Magento\Catalog\Model\Product\Attribute\Source\Status::STATUS_ENABLED)
+ ->setWebsiteIds([1])
+ ->setCategoryIds([2])
+ ->setStockData(['use_config_manage_stock' => 1, 'qty' => 100, 'is_qty_decimal' => 0, 'is_in_stock' => 1])
+ ->setSpecialPrice('10')
+ ->save();
+
+$product = \Magento\TestFramework\Helper\Bootstrap::getObjectManager()->create(\Magento\Catalog\Model\Product::class);
+$product->isObjectNew(true);
+$product->setTypeId(\Magento\Catalog\Model\Product\Type::TYPE_SIMPLE)
+ ->setId(11)
+ ->setAttributeSetId(4)
+ ->setName('Simple Product2')
+ ->setSku('simple2')
+ ->setTaxClassId('none')
+ ->setDescription('description')
+ ->setShortDescription('short description')
+ ->setOptionsContainer('container1')
+ ->setMsrpDisplayActualPriceType(\Magento\Msrp\Model\Product\Attribute\Source\Type::TYPE_ON_GESTURE)
+ ->setPrice(25)
+ ->setWeight(20)
+ ->setMetaTitle('meta title')
+ ->setMetaKeyword('meta keyword')
+ ->setMetaDescription('meta description')
+ ->setVisibility(\Magento\Catalog\Model\Product\Visibility::VISIBILITY_BOTH)
+ ->setStatus(\Magento\Catalog\Model\Product\Attribute\Source\Status::STATUS_ENABLED)
+ ->setWebsiteIds([1])
+ ->setCategoryIds([2])
+ ->setStockData(['use_config_manage_stock' => 1, 'qty' => 50, 'is_qty_decimal' => 0, 'is_in_stock' => 1])
+ ->setSpecialPrice('20')
+ ->save();
+
+$product = \Magento\TestFramework\Helper\Bootstrap::getObjectManager()->create(\Magento\Catalog\Model\Product::class);
+$product->isObjectNew(true);
+$product->setTypeId(\Magento\Catalog\Model\Product\Type::TYPE_SIMPLE)
+ ->setId(12)
+ ->setAttributeSetId(4)
+ ->setName('Simple Product3')
+ ->setSku('simple3')
+ ->setTaxClassId('none')
+ ->setDescription('description')
+ ->setShortDescription('short description')
+ ->setPrice(35)
+ ->setWeight(30)
+ ->setVisibility(\Magento\Catalog\Model\Product\Visibility::VISIBILITY_BOTH)
+ ->setStatus(\Magento\Catalog\Model\Product\Attribute\Source\Status::STATUS_ENABLED)
+ ->setWebsiteIds([1])
+ ->setCategoryIds([2])
+ ->setStockData(['use_config_manage_stock' => 1, 'qty' => 140, 'is_qty_decimal' => 0, 'is_in_stock' => 1])
+ ->setSpecialPrice('30')
+ ->save();
diff --git a/dev/tests/integration/testsuite/Magento/Catalog/_files/multiple_visible_products_rollback.php b/dev/tests/integration/testsuite/Magento/Catalog/_files/multiple_visible_products_rollback.php
new file mode 100644
index 0000000000000..a9155d3fadf0b
--- /dev/null
+++ b/dev/tests/integration/testsuite/Magento/Catalog/_files/multiple_visible_products_rollback.php
@@ -0,0 +1,28 @@
+get(\Magento\Framework\Registry::class);
+
+$registry->unregister('isSecureArea');
+$registry->register('isSecureArea', true);
+
+/** @var \Magento\Catalog\Api\ProductRepositoryInterface $productRepository */
+$productRepository = $objectManager->create(\Magento\Catalog\Api\ProductRepositoryInterface::class);
+
+foreach (['simple1', 'simple2', 'simple3'] as $sku) {
+ try {
+ $product = $productRepository->get($sku, false, null, true);
+ $productRepository->delete($product);
+ } catch (\Magento\Framework\Exception\NoSuchEntityException $exception) {
+ //Product already removed
+ }
+}
+
+$registry->unregister('isSecureArea');
+$registry->register('isSecureArea', false);
diff --git a/dev/tests/integration/testsuite/Magento/CatalogSearch/Model/Layer/Filter/DecimalTest.php b/dev/tests/integration/testsuite/Magento/CatalogSearch/Model/Layer/Filter/DecimalTest.php
index f0c8402c51879..33dea3ea37179 100644
--- a/dev/tests/integration/testsuite/Magento/CatalogSearch/Model/Layer/Filter/DecimalTest.php
+++ b/dev/tests/integration/testsuite/Magento/CatalogSearch/Model/Layer/Filter/DecimalTest.php
@@ -49,6 +49,80 @@ protected function setUp()
$this->_model->setAttributeModel($attribute);
}
+ /**
+ * Test the product collection returns the correct number of items after the filter is applied.
+ *
+ * @magentoDataFixture Magento/Catalog/Model/Layer/Filter/_files/attribute_special_price_filterable.php
+ * @magentoDataFixture Magento/Catalog/_files/multiple_visible_products.php
+ * @magentoDbIsolation disabled
+ */
+ public function testApplyProductCollection()
+ {
+ /** @var $objectManager \Magento\TestFramework\ObjectManager */
+ $objectManager = \Magento\TestFramework\Helper\Bootstrap::getObjectManager();
+ $category = $objectManager->create(\Magento\Catalog\Model\Category::class);
+ $category->load(2);
+ $this->_model->getLayer()->setCurrentCategory($category);
+
+ /** @var $attribute \Magento\Catalog\Model\Entity\Attribute */
+ $attribute = $objectManager->create(\Magento\Catalog\Model\Entity\Attribute::class);
+ $attribute->loadByCode('catalog_product', 'special_price');
+ $this->_model->setAttributeModel($attribute);
+
+ /** @var $objectManager \Magento\TestFramework\ObjectManager */
+ $objectManager = \Magento\TestFramework\Helper\Bootstrap::getObjectManager();
+ /** @var $request \Magento\TestFramework\Request */
+ $request = $objectManager->get(\Magento\TestFramework\Request::class);
+ $request->setParam('special_price', '10-20');
+ $result = $this->_model->apply($request);
+ $collection = $this->_model->getLayer()->getProductCollection();
+ $size = $collection->getSize();
+ $this->assertEquals(
+ 1,
+ $size
+ );
+ }
+
+ /**
+ * Test the filter label is correct
+ */
+ public function testApplyFilterLabel()
+ {
+ /** @var $objectManager \Magento\TestFramework\ObjectManager */
+ $objectManager = \Magento\TestFramework\Helper\Bootstrap::getObjectManager();
+ /** @var $request \Magento\TestFramework\Request */
+ $request = $objectManager->get(\Magento\TestFramework\Request::class);
+ $request->setParam('weight', '10-20');
+ $this->_model->apply($request);
+
+ $filters = $this->_model->getLayer()->getState()->getFilters();
+ $this->assertArrayHasKey(0, $filters);
+ $this->assertEquals(
+ '$10.00 - $19.99 ',
+ (string)$filters[0]->getLabel()
+ );
+ }
+
+ /**
+ * Test the filter label is correct when there is empty To value
+ */
+ public function testApplyFilterLabelWithEmptyToValue()
+ {
+ /** @var $objectManager \Magento\TestFramework\ObjectManager */
+ $objectManager = \Magento\TestFramework\Helper\Bootstrap::getObjectManager();
+ /** @var $request \Magento\TestFramework\Request */
+ $request = $objectManager->get(\Magento\TestFramework\Request::class);
+ $request->setParam('weight', '10-');
+ $this->_model->apply($request);
+
+ $filters = $this->_model->getLayer()->getState()->getFilters();
+ $this->assertArrayHasKey(0, $filters);
+ $this->assertEquals(
+ '$10.00 and above',
+ (string)$filters[0]->getLabel()
+ );
+ }
+
public function testApplyNothing()
{
$this->assertEmpty($this->_model->getData('range'));
From 353f99504423191e1b09b6b1a4355949e60fe56b Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=C5=81ukasz=20Bajsarowicz?=
Date: Tue, 11 Jun 2019 01:58:56 +0200
Subject: [PATCH 020/937] Refactor: Instead of using hardcoded `amOnPage` - use
LogoutActionGroup instead
---
.../Catalog/Test/Mftf/Test/AdminCreateCategoryTest.xml | 2 +-
.../Mftf/Test/AdminCreateProductDuplicateUrlkeyTest.xml | 2 +-
.../Test/Mftf/Test/AdminCreateSimpleProductTest.xml | 1 -
.../Mftf/Test/AdminCreateSimpleProductWithUnicodeTest.xml | 2 +-
.../Test/AdminMultipleWebsitesUseDefaultValuesTest.xml | 2 +-
.../AdminRequiredFieldsHaveRequiredFieldIndicatorTest.xml | 2 +-
.../Test/Mftf/Test/AdminSimpleProductImagesTest.xml | 4 ++--
.../Test/Mftf/Test/AdminUpdateCategoryStoreUrlKeyTest.xml | 2 +-
.../Catalog/Test/Mftf/Test/DeleteCategoriesTest.xml | 2 +-
.../SaveProductWithCustomOptionsSecondWebsiteTest.xml | 2 +-
.../Test/Mftf/Test/CheckCheckoutSuccessPageTest.xml | 4 ++--
.../Test/Mftf/Test/StorefrontCustomerCheckoutTest.xml | 2 +-
.../Test/Mftf/Test/StorefrontGuestCheckoutTest.xml | 4 ++--
.../Magento/Cms/Test/Mftf/Test/AdminCreateCmsPageTest.xml | 2 +-
.../Test/Mftf/Test/AdminConfigurableProductCreateTest.xml | 2 +-
.../Test/Mftf/Test/AdminConfigurableProductDeleteTest.xml | 4 ++--
.../Mftf/Test/AdminConfigurableProductLongSkuTest.xml | 2 +-
.../Mftf/Test/AdminConfigurableProductOutOfStockTest.xml | 6 +++---
.../Test/Mftf/Test/AdminConfigurableProductSearchTest.xml | 4 ++--
.../Test/AdminConfigurableProductUpdateAttributeTest.xml | 4 ++--
.../Test/Mftf/Test/AdminConfigurableProductUpdateTest.xml | 6 +++---
.../ConfigurableProductPriceAdditionalStoreViewTest.xml | 2 +-
...efrontConfigurableProductCategoryViewChildOnlyTest.xml | 2 +-
.../Test/StorefrontConfigurableProductChildSearchTest.xml | 2 +-
.../Test/StorefrontConfigurableProductDetailsTest.xml | 8 ++++----
.../Mftf/Test/StorefrontConfigurableProductViewTest.xml | 6 +++---
...refrontConfigurableProductWithFileCustomOptionTest.xml | 2 +-
.../Customer/Test/Mftf/Test/AdminCreateCustomerTest.xml | 2 +-
.../Test/Mftf/Test/EndToEndB2CLoggedInUserTest.xml | 2 +-
.../Test/Mftf/Test/StorefrontAddCustomerAddressTest.xml | 4 ++--
.../Test/Mftf/Test/StorefrontCreateCustomerTest.xml | 2 +-
.../Mftf/Test/VerifySubscribedNewsletterDisplayedTest.xml | 2 +-
.../Sales/Test/Mftf/Test/AdminCreateInvoiceTest.xml | 2 +-
.../Test/AdminSubmitsOrderPaymentMethodValidationTest.xml | 2 +-
.../Test/AdminSubmitsOrderWithAndWithoutEmailTest.xml | 2 +-
...dminSubmitsOrderWithAndWithoutFieldsValidationTest.xml | 2 +-
.../Test/CreditMemoTotalAfterShippingDiscountTest.xml | 4 ++--
.../Test/Mftf/Test/AdminCreateBuyXGetYFreeTest.xml | 2 +-
.../AdminCreateCartPriceRuleForGeneratedCouponTest.xml | 2 +-
.../Test/Mftf/Test/AdminCreateFixedAmountDiscountTest.xml | 2 +-
.../Test/AdminCreateFixedAmountWholeCartDiscountTest.xml | 2 +-
.../Mftf/Test/AdminCreatePercentOfProductPriceTest.xml | 2 +-
.../Store/Test/Mftf/Test/AdminCreateStoreGroupTest.xml | 2 +-
.../Swatches/Test/Mftf/Test/AdminCreateTextSwatchTest.xml | 2 +-
.../Test/Mftf/Test/AdminCreateVisualSwatchTest.xml | 2 +-
.../Test/Mftf/Test/StorefrontFilterByImageSwatchTest.xml | 2 +-
.../Test/Mftf/Test/StorefrontFilterByTextSwatchTest.xml | 2 +-
.../Test/Mftf/Test/StorefrontFilterByVisualSwatchTest.xml | 2 +-
.../StorefrontSwatchProductWithFileCustomOptionTest.xml | 2 +-
.../Widget/Test/Mftf/Test/NewProductsListWidgetTest.xml | 2 +-
...urableProductChildImageShouldBeShownOnWishListTest.xml | 2 +-
.../StorefrontAddMultipleStoreProductsToWishlistTest.xml | 2 +-
.../Mftf/Test/StorefrontDeletePersistedWishlistTest.xml | 2 +-
53 files changed, 69 insertions(+), 70 deletions(-)
diff --git a/app/code/Magento/Catalog/Test/Mftf/Test/AdminCreateCategoryTest.xml b/app/code/Magento/Catalog/Test/Mftf/Test/AdminCreateCategoryTest.xml
index 15171fe3713c3..784b5d3fd1827 100644
--- a/app/code/Magento/Catalog/Test/Mftf/Test/AdminCreateCategoryTest.xml
+++ b/app/code/Magento/Catalog/Test/Mftf/Test/AdminCreateCategoryTest.xml
@@ -19,7 +19,7 @@
-
+
diff --git a/app/code/Magento/Catalog/Test/Mftf/Test/AdminCreateProductDuplicateUrlkeyTest.xml b/app/code/Magento/Catalog/Test/Mftf/Test/AdminCreateProductDuplicateUrlkeyTest.xml
index 6658ad36d7150..291b6985bd3e5 100644
--- a/app/code/Magento/Catalog/Test/Mftf/Test/AdminCreateProductDuplicateUrlkeyTest.xml
+++ b/app/code/Magento/Catalog/Test/Mftf/Test/AdminCreateProductDuplicateUrlkeyTest.xml
@@ -23,7 +23,7 @@
-
+
diff --git a/app/code/Magento/Catalog/Test/Mftf/Test/AdminCreateSimpleProductTest.xml b/app/code/Magento/Catalog/Test/Mftf/Test/AdminCreateSimpleProductTest.xml
index 6096ee1fa3996..a7587a5ed31fe 100644
--- a/app/code/Magento/Catalog/Test/Mftf/Test/AdminCreateSimpleProductTest.xml
+++ b/app/code/Magento/Catalog/Test/Mftf/Test/AdminCreateSimpleProductTest.xml
@@ -22,7 +22,6 @@
-
diff --git a/app/code/Magento/Catalog/Test/Mftf/Test/AdminCreateSimpleProductWithUnicodeTest.xml b/app/code/Magento/Catalog/Test/Mftf/Test/AdminCreateSimpleProductWithUnicodeTest.xml
index 896a28d0298e6..94d488f216b49 100644
--- a/app/code/Magento/Catalog/Test/Mftf/Test/AdminCreateSimpleProductWithUnicodeTest.xml
+++ b/app/code/Magento/Catalog/Test/Mftf/Test/AdminCreateSimpleProductWithUnicodeTest.xml
@@ -22,7 +22,7 @@
-
+
diff --git a/app/code/Magento/Catalog/Test/Mftf/Test/AdminMultipleWebsitesUseDefaultValuesTest.xml b/app/code/Magento/Catalog/Test/Mftf/Test/AdminMultipleWebsitesUseDefaultValuesTest.xml
index 264615ff6736f..f7fd81f28199f 100644
--- a/app/code/Magento/Catalog/Test/Mftf/Test/AdminMultipleWebsitesUseDefaultValuesTest.xml
+++ b/app/code/Magento/Catalog/Test/Mftf/Test/AdminMultipleWebsitesUseDefaultValuesTest.xml
@@ -22,7 +22,7 @@
-
+
diff --git a/app/code/Magento/Catalog/Test/Mftf/Test/AdminRequiredFieldsHaveRequiredFieldIndicatorTest.xml b/app/code/Magento/Catalog/Test/Mftf/Test/AdminRequiredFieldsHaveRequiredFieldIndicatorTest.xml
index 240a5492355cf..ebae27a1f7182 100644
--- a/app/code/Magento/Catalog/Test/Mftf/Test/AdminRequiredFieldsHaveRequiredFieldIndicatorTest.xml
+++ b/app/code/Magento/Catalog/Test/Mftf/Test/AdminRequiredFieldsHaveRequiredFieldIndicatorTest.xml
@@ -18,7 +18,7 @@
-
+
diff --git a/app/code/Magento/Catalog/Test/Mftf/Test/AdminSimpleProductImagesTest.xml b/app/code/Magento/Catalog/Test/Mftf/Test/AdminSimpleProductImagesTest.xml
index 1cd0e15780c11..41f27497a50eb 100644
--- a/app/code/Magento/Catalog/Test/Mftf/Test/AdminSimpleProductImagesTest.xml
+++ b/app/code/Magento/Catalog/Test/Mftf/Test/AdminSimpleProductImagesTest.xml
@@ -34,7 +34,7 @@
-
+
@@ -186,7 +186,7 @@
-
+
diff --git a/app/code/Magento/Catalog/Test/Mftf/Test/AdminUpdateCategoryStoreUrlKeyTest.xml b/app/code/Magento/Catalog/Test/Mftf/Test/AdminUpdateCategoryStoreUrlKeyTest.xml
index 2ff83afa15e5e..0f63a72844452 100644
--- a/app/code/Magento/Catalog/Test/Mftf/Test/AdminUpdateCategoryStoreUrlKeyTest.xml
+++ b/app/code/Magento/Catalog/Test/Mftf/Test/AdminUpdateCategoryStoreUrlKeyTest.xml
@@ -22,7 +22,7 @@
-
+
diff --git a/app/code/Magento/Catalog/Test/Mftf/Test/DeleteCategoriesTest.xml b/app/code/Magento/Catalog/Test/Mftf/Test/DeleteCategoriesTest.xml
index 5cae81b36a323..674d46b9c18b1 100644
--- a/app/code/Magento/Catalog/Test/Mftf/Test/DeleteCategoriesTest.xml
+++ b/app/code/Magento/Catalog/Test/Mftf/Test/DeleteCategoriesTest.xml
@@ -36,7 +36,7 @@
-
+
diff --git a/app/code/Magento/Catalog/Test/Mftf/Test/SaveProductWithCustomOptionsSecondWebsiteTest.xml b/app/code/Magento/Catalog/Test/Mftf/Test/SaveProductWithCustomOptionsSecondWebsiteTest.xml
index e9e9eb0158789..8092b03c53cba 100644
--- a/app/code/Magento/Catalog/Test/Mftf/Test/SaveProductWithCustomOptionsSecondWebsiteTest.xml
+++ b/app/code/Magento/Catalog/Test/Mftf/Test/SaveProductWithCustomOptionsSecondWebsiteTest.xml
@@ -53,7 +53,7 @@
-
+
diff --git a/app/code/Magento/Checkout/Test/Mftf/Test/CheckCheckoutSuccessPageTest.xml b/app/code/Magento/Checkout/Test/Mftf/Test/CheckCheckoutSuccessPageTest.xml
index 9714b76a05613..163e71c50053f 100644
--- a/app/code/Magento/Checkout/Test/Mftf/Test/CheckCheckoutSuccessPageTest.xml
+++ b/app/code/Magento/Checkout/Test/Mftf/Test/CheckCheckoutSuccessPageTest.xml
@@ -30,7 +30,7 @@
-
+
@@ -147,7 +147,7 @@
-
+
diff --git a/app/code/Magento/Checkout/Test/Mftf/Test/StorefrontCustomerCheckoutTest.xml b/app/code/Magento/Checkout/Test/Mftf/Test/StorefrontCustomerCheckoutTest.xml
index f77e3df11713d..84e1017bf9cf0 100644
--- a/app/code/Magento/Checkout/Test/Mftf/Test/StorefrontCustomerCheckoutTest.xml
+++ b/app/code/Magento/Checkout/Test/Mftf/Test/StorefrontCustomerCheckoutTest.xml
@@ -147,7 +147,7 @@
-
+
diff --git a/app/code/Magento/Checkout/Test/Mftf/Test/StorefrontGuestCheckoutTest.xml b/app/code/Magento/Checkout/Test/Mftf/Test/StorefrontGuestCheckoutTest.xml
index 15410921f1bb1..6ff561564d9c2 100644
--- a/app/code/Magento/Checkout/Test/Mftf/Test/StorefrontGuestCheckoutTest.xml
+++ b/app/code/Magento/Checkout/Test/Mftf/Test/StorefrontGuestCheckoutTest.xml
@@ -25,7 +25,7 @@
-
+
@@ -111,7 +111,7 @@
-
+
diff --git a/app/code/Magento/Cms/Test/Mftf/Test/AdminCreateCmsPageTest.xml b/app/code/Magento/Cms/Test/Mftf/Test/AdminCreateCmsPageTest.xml
index fccc5b5980f2b..b7c7e4a4212fe 100644
--- a/app/code/Magento/Cms/Test/Mftf/Test/AdminCreateCmsPageTest.xml
+++ b/app/code/Magento/Cms/Test/Mftf/Test/AdminCreateCmsPageTest.xml
@@ -23,7 +23,7 @@
-
+
diff --git a/app/code/Magento/ConfigurableProduct/Test/Mftf/Test/AdminConfigurableProductCreateTest.xml b/app/code/Magento/ConfigurableProduct/Test/Mftf/Test/AdminConfigurableProductCreateTest.xml
index 2af85e1bac048..9a648329dc04d 100644
--- a/app/code/Magento/ConfigurableProduct/Test/Mftf/Test/AdminConfigurableProductCreateTest.xml
+++ b/app/code/Magento/ConfigurableProduct/Test/Mftf/Test/AdminConfigurableProductCreateTest.xml
@@ -26,7 +26,7 @@
-
+
diff --git a/app/code/Magento/ConfigurableProduct/Test/Mftf/Test/AdminConfigurableProductDeleteTest.xml b/app/code/Magento/ConfigurableProduct/Test/Mftf/Test/AdminConfigurableProductDeleteTest.xml
index 1a694b8adf17e..33a6da9dabf34 100644
--- a/app/code/Magento/ConfigurableProduct/Test/Mftf/Test/AdminConfigurableProductDeleteTest.xml
+++ b/app/code/Magento/ConfigurableProduct/Test/Mftf/Test/AdminConfigurableProductDeleteTest.xml
@@ -66,7 +66,7 @@
-
+
@@ -216,7 +216,7 @@
-
+
diff --git a/app/code/Magento/ConfigurableProduct/Test/Mftf/Test/AdminConfigurableProductLongSkuTest.xml b/app/code/Magento/ConfigurableProduct/Test/Mftf/Test/AdminConfigurableProductLongSkuTest.xml
index c599a6a23f190..c47e320b3a170 100644
--- a/app/code/Magento/ConfigurableProduct/Test/Mftf/Test/AdminConfigurableProductLongSkuTest.xml
+++ b/app/code/Magento/ConfigurableProduct/Test/Mftf/Test/AdminConfigurableProductLongSkuTest.xml
@@ -52,7 +52,7 @@
-
+
diff --git a/app/code/Magento/ConfigurableProduct/Test/Mftf/Test/AdminConfigurableProductOutOfStockTest.xml b/app/code/Magento/ConfigurableProduct/Test/Mftf/Test/AdminConfigurableProductOutOfStockTest.xml
index 5633c3675ca85..a7581cc694b13 100644
--- a/app/code/Magento/ConfigurableProduct/Test/Mftf/Test/AdminConfigurableProductOutOfStockTest.xml
+++ b/app/code/Magento/ConfigurableProduct/Test/Mftf/Test/AdminConfigurableProductOutOfStockTest.xml
@@ -77,7 +77,7 @@
-
+
@@ -200,7 +200,7 @@
-
+
@@ -301,7 +301,7 @@
-
+
diff --git a/app/code/Magento/ConfigurableProduct/Test/Mftf/Test/AdminConfigurableProductSearchTest.xml b/app/code/Magento/ConfigurableProduct/Test/Mftf/Test/AdminConfigurableProductSearchTest.xml
index 059a18200e90c..410c85d314904 100644
--- a/app/code/Magento/ConfigurableProduct/Test/Mftf/Test/AdminConfigurableProductSearchTest.xml
+++ b/app/code/Magento/ConfigurableProduct/Test/Mftf/Test/AdminConfigurableProductSearchTest.xml
@@ -68,7 +68,7 @@
-
+
@@ -147,7 +147,7 @@
-
+
diff --git a/app/code/Magento/ConfigurableProduct/Test/Mftf/Test/AdminConfigurableProductUpdateAttributeTest.xml b/app/code/Magento/ConfigurableProduct/Test/Mftf/Test/AdminConfigurableProductUpdateAttributeTest.xml
index 001d4d17ec213..736276933a3af 100644
--- a/app/code/Magento/ConfigurableProduct/Test/Mftf/Test/AdminConfigurableProductUpdateAttributeTest.xml
+++ b/app/code/Magento/ConfigurableProduct/Test/Mftf/Test/AdminConfigurableProductUpdateAttributeTest.xml
@@ -96,7 +96,7 @@
-
+
@@ -213,7 +213,7 @@
-
+
diff --git a/app/code/Magento/ConfigurableProduct/Test/Mftf/Test/AdminConfigurableProductUpdateTest.xml b/app/code/Magento/ConfigurableProduct/Test/Mftf/Test/AdminConfigurableProductUpdateTest.xml
index 1791fc002ab95..18053da86fe16 100644
--- a/app/code/Magento/ConfigurableProduct/Test/Mftf/Test/AdminConfigurableProductUpdateTest.xml
+++ b/app/code/Magento/ConfigurableProduct/Test/Mftf/Test/AdminConfigurableProductUpdateTest.xml
@@ -37,7 +37,7 @@
-
+
@@ -277,7 +277,7 @@
-
+
@@ -326,7 +326,7 @@
-
+
diff --git a/app/code/Magento/ConfigurableProduct/Test/Mftf/Test/ConfigurableProductPriceAdditionalStoreViewTest.xml b/app/code/Magento/ConfigurableProduct/Test/Mftf/Test/ConfigurableProductPriceAdditionalStoreViewTest.xml
index a71f51526c8ab..83d9bbe8c270a 100644
--- a/app/code/Magento/ConfigurableProduct/Test/Mftf/Test/ConfigurableProductPriceAdditionalStoreViewTest.xml
+++ b/app/code/Magento/ConfigurableProduct/Test/Mftf/Test/ConfigurableProductPriceAdditionalStoreViewTest.xml
@@ -77,7 +77,7 @@
-
+
diff --git a/app/code/Magento/ConfigurableProduct/Test/Mftf/Test/StorefrontConfigurableProductCategoryViewChildOnlyTest.xml b/app/code/Magento/ConfigurableProduct/Test/Mftf/Test/StorefrontConfigurableProductCategoryViewChildOnlyTest.xml
index ac468fc92e4db..805727e29a17a 100644
--- a/app/code/Magento/ConfigurableProduct/Test/Mftf/Test/StorefrontConfigurableProductCategoryViewChildOnlyTest.xml
+++ b/app/code/Magento/ConfigurableProduct/Test/Mftf/Test/StorefrontConfigurableProductCategoryViewChildOnlyTest.xml
@@ -88,7 +88,7 @@
-
+
diff --git a/app/code/Magento/ConfigurableProduct/Test/Mftf/Test/StorefrontConfigurableProductChildSearchTest.xml b/app/code/Magento/ConfigurableProduct/Test/Mftf/Test/StorefrontConfigurableProductChildSearchTest.xml
index 1075f79aef187..c60b4d46f7fec 100644
--- a/app/code/Magento/ConfigurableProduct/Test/Mftf/Test/StorefrontConfigurableProductChildSearchTest.xml
+++ b/app/code/Magento/ConfigurableProduct/Test/Mftf/Test/StorefrontConfigurableProductChildSearchTest.xml
@@ -131,7 +131,7 @@
-
+
diff --git a/app/code/Magento/ConfigurableProduct/Test/Mftf/Test/StorefrontConfigurableProductDetailsTest.xml b/app/code/Magento/ConfigurableProduct/Test/Mftf/Test/StorefrontConfigurableProductDetailsTest.xml
index 836bc2cdca970..f75e30907a1f4 100644
--- a/app/code/Magento/ConfigurableProduct/Test/Mftf/Test/StorefrontConfigurableProductDetailsTest.xml
+++ b/app/code/Magento/ConfigurableProduct/Test/Mftf/Test/StorefrontConfigurableProductDetailsTest.xml
@@ -31,7 +31,7 @@
-
+
@@ -72,7 +72,7 @@
-
+
@@ -113,7 +113,7 @@
-
+
@@ -151,7 +151,7 @@
-
+
diff --git a/app/code/Magento/ConfigurableProduct/Test/Mftf/Test/StorefrontConfigurableProductViewTest.xml b/app/code/Magento/ConfigurableProduct/Test/Mftf/Test/StorefrontConfigurableProductViewTest.xml
index cc8291a83eb40..0ade410714a25 100644
--- a/app/code/Magento/ConfigurableProduct/Test/Mftf/Test/StorefrontConfigurableProductViewTest.xml
+++ b/app/code/Magento/ConfigurableProduct/Test/Mftf/Test/StorefrontConfigurableProductViewTest.xml
@@ -32,7 +32,7 @@
-
+
@@ -68,7 +68,7 @@
-
+
@@ -106,7 +106,7 @@
-
+
diff --git a/app/code/Magento/ConfigurableProduct/Test/Mftf/Test/StorefrontConfigurableProductWithFileCustomOptionTest.xml b/app/code/Magento/ConfigurableProduct/Test/Mftf/Test/StorefrontConfigurableProductWithFileCustomOptionTest.xml
index d890d59858116..4c955f3385643 100644
--- a/app/code/Magento/ConfigurableProduct/Test/Mftf/Test/StorefrontConfigurableProductWithFileCustomOptionTest.xml
+++ b/app/code/Magento/ConfigurableProduct/Test/Mftf/Test/StorefrontConfigurableProductWithFileCustomOptionTest.xml
@@ -25,7 +25,7 @@
-
+
diff --git a/app/code/Magento/Customer/Test/Mftf/Test/AdminCreateCustomerTest.xml b/app/code/Magento/Customer/Test/Mftf/Test/AdminCreateCustomerTest.xml
index 78bae7ad60dd8..a11fb9d0eaa8f 100644
--- a/app/code/Magento/Customer/Test/Mftf/Test/AdminCreateCustomerTest.xml
+++ b/app/code/Magento/Customer/Test/Mftf/Test/AdminCreateCustomerTest.xml
@@ -23,7 +23,7 @@
-
+
diff --git a/app/code/Magento/Customer/Test/Mftf/Test/EndToEndB2CLoggedInUserTest.xml b/app/code/Magento/Customer/Test/Mftf/Test/EndToEndB2CLoggedInUserTest.xml
index 2b24233e8b072..bf8844b2cc7ab 100644
--- a/app/code/Magento/Customer/Test/Mftf/Test/EndToEndB2CLoggedInUserTest.xml
+++ b/app/code/Magento/Customer/Test/Mftf/Test/EndToEndB2CLoggedInUserTest.xml
@@ -25,7 +25,7 @@
-
+
diff --git a/app/code/Magento/Customer/Test/Mftf/Test/StorefrontAddCustomerAddressTest.xml b/app/code/Magento/Customer/Test/Mftf/Test/StorefrontAddCustomerAddressTest.xml
index 413bbfd06a539..e2c55eb3962f2 100644
--- a/app/code/Magento/Customer/Test/Mftf/Test/StorefrontAddCustomerAddressTest.xml
+++ b/app/code/Magento/Customer/Test/Mftf/Test/StorefrontAddCustomerAddressTest.xml
@@ -24,7 +24,7 @@
-
+
@@ -101,7 +101,7 @@
-
+
diff --git a/app/code/Magento/Customer/Test/Mftf/Test/StorefrontCreateCustomerTest.xml b/app/code/Magento/Customer/Test/Mftf/Test/StorefrontCreateCustomerTest.xml
index 97c932f0cb28a..7d51f97f2463a 100644
--- a/app/code/Magento/Customer/Test/Mftf/Test/StorefrontCreateCustomerTest.xml
+++ b/app/code/Magento/Customer/Test/Mftf/Test/StorefrontCreateCustomerTest.xml
@@ -20,7 +20,7 @@
-
+
diff --git a/app/code/Magento/Newsletter/Test/Mftf/Test/VerifySubscribedNewsletterDisplayedTest.xml b/app/code/Magento/Newsletter/Test/Mftf/Test/VerifySubscribedNewsletterDisplayedTest.xml
index 22ca214c94aec..4d60b7676605e 100644
--- a/app/code/Magento/Newsletter/Test/Mftf/Test/VerifySubscribedNewsletterDisplayedTest.xml
+++ b/app/code/Magento/Newsletter/Test/Mftf/Test/VerifySubscribedNewsletterDisplayedTest.xml
@@ -49,7 +49,7 @@
-
+
diff --git a/app/code/Magento/Sales/Test/Mftf/Test/AdminCreateInvoiceTest.xml b/app/code/Magento/Sales/Test/Mftf/Test/AdminCreateInvoiceTest.xml
index ce66409ed9b3c..3785651a34324 100644
--- a/app/code/Magento/Sales/Test/Mftf/Test/AdminCreateInvoiceTest.xml
+++ b/app/code/Magento/Sales/Test/Mftf/Test/AdminCreateInvoiceTest.xml
@@ -25,7 +25,7 @@
-
+
diff --git a/app/code/Magento/Sales/Test/Mftf/Test/AdminSubmitsOrderPaymentMethodValidationTest.xml b/app/code/Magento/Sales/Test/Mftf/Test/AdminSubmitsOrderPaymentMethodValidationTest.xml
index e487c62b96727..255a7a91f9b10 100644
--- a/app/code/Magento/Sales/Test/Mftf/Test/AdminSubmitsOrderPaymentMethodValidationTest.xml
+++ b/app/code/Magento/Sales/Test/Mftf/Test/AdminSubmitsOrderPaymentMethodValidationTest.xml
@@ -29,7 +29,7 @@
-
+
diff --git a/app/code/Magento/Sales/Test/Mftf/Test/AdminSubmitsOrderWithAndWithoutEmailTest.xml b/app/code/Magento/Sales/Test/Mftf/Test/AdminSubmitsOrderWithAndWithoutEmailTest.xml
index ed536bd3351f9..01021ad745f70 100644
--- a/app/code/Magento/Sales/Test/Mftf/Test/AdminSubmitsOrderWithAndWithoutEmailTest.xml
+++ b/app/code/Magento/Sales/Test/Mftf/Test/AdminSubmitsOrderWithAndWithoutEmailTest.xml
@@ -26,7 +26,7 @@
-
+
diff --git a/app/code/Magento/Sales/Test/Mftf/Test/AdminSubmitsOrderWithAndWithoutFieldsValidationTest.xml b/app/code/Magento/Sales/Test/Mftf/Test/AdminSubmitsOrderWithAndWithoutFieldsValidationTest.xml
index 1490fc1a1a388..9268e9e728658 100644
--- a/app/code/Magento/Sales/Test/Mftf/Test/AdminSubmitsOrderWithAndWithoutFieldsValidationTest.xml
+++ b/app/code/Magento/Sales/Test/Mftf/Test/AdminSubmitsOrderWithAndWithoutFieldsValidationTest.xml
@@ -25,7 +25,7 @@
-
+
diff --git a/app/code/Magento/Sales/Test/Mftf/Test/CreditMemoTotalAfterShippingDiscountTest.xml b/app/code/Magento/Sales/Test/Mftf/Test/CreditMemoTotalAfterShippingDiscountTest.xml
index dfbdc53677993..2a5123d579653 100644
--- a/app/code/Magento/Sales/Test/Mftf/Test/CreditMemoTotalAfterShippingDiscountTest.xml
+++ b/app/code/Magento/Sales/Test/Mftf/Test/CreditMemoTotalAfterShippingDiscountTest.xml
@@ -33,7 +33,7 @@
-
+
@@ -58,7 +58,7 @@
-
+
diff --git a/app/code/Magento/SalesRule/Test/Mftf/Test/AdminCreateBuyXGetYFreeTest.xml b/app/code/Magento/SalesRule/Test/Mftf/Test/AdminCreateBuyXGetYFreeTest.xml
index 92d221de9e157..02078ff15ecc2 100644
--- a/app/code/Magento/SalesRule/Test/Mftf/Test/AdminCreateBuyXGetYFreeTest.xml
+++ b/app/code/Magento/SalesRule/Test/Mftf/Test/AdminCreateBuyXGetYFreeTest.xml
@@ -30,7 +30,7 @@
-
+
diff --git a/app/code/Magento/SalesRule/Test/Mftf/Test/AdminCreateCartPriceRuleForGeneratedCouponTest.xml b/app/code/Magento/SalesRule/Test/Mftf/Test/AdminCreateCartPriceRuleForGeneratedCouponTest.xml
index 03dffe9f448ea..9d807de409a0c 100644
--- a/app/code/Magento/SalesRule/Test/Mftf/Test/AdminCreateCartPriceRuleForGeneratedCouponTest.xml
+++ b/app/code/Magento/SalesRule/Test/Mftf/Test/AdminCreateCartPriceRuleForGeneratedCouponTest.xml
@@ -30,7 +30,7 @@
-
+
diff --git a/app/code/Magento/SalesRule/Test/Mftf/Test/AdminCreateFixedAmountDiscountTest.xml b/app/code/Magento/SalesRule/Test/Mftf/Test/AdminCreateFixedAmountDiscountTest.xml
index 08a08275ee07a..1681d910ccdb0 100644
--- a/app/code/Magento/SalesRule/Test/Mftf/Test/AdminCreateFixedAmountDiscountTest.xml
+++ b/app/code/Magento/SalesRule/Test/Mftf/Test/AdminCreateFixedAmountDiscountTest.xml
@@ -30,7 +30,7 @@
-
+
diff --git a/app/code/Magento/SalesRule/Test/Mftf/Test/AdminCreateFixedAmountWholeCartDiscountTest.xml b/app/code/Magento/SalesRule/Test/Mftf/Test/AdminCreateFixedAmountWholeCartDiscountTest.xml
index a39530f7607e4..69918bda8c426 100644
--- a/app/code/Magento/SalesRule/Test/Mftf/Test/AdminCreateFixedAmountWholeCartDiscountTest.xml
+++ b/app/code/Magento/SalesRule/Test/Mftf/Test/AdminCreateFixedAmountWholeCartDiscountTest.xml
@@ -30,7 +30,7 @@
-
+
diff --git a/app/code/Magento/SalesRule/Test/Mftf/Test/AdminCreatePercentOfProductPriceTest.xml b/app/code/Magento/SalesRule/Test/Mftf/Test/AdminCreatePercentOfProductPriceTest.xml
index 1f7d849ac02b0..898e5a07304b6 100644
--- a/app/code/Magento/SalesRule/Test/Mftf/Test/AdminCreatePercentOfProductPriceTest.xml
+++ b/app/code/Magento/SalesRule/Test/Mftf/Test/AdminCreatePercentOfProductPriceTest.xml
@@ -30,7 +30,7 @@
-
+
diff --git a/app/code/Magento/Store/Test/Mftf/Test/AdminCreateStoreGroupTest.xml b/app/code/Magento/Store/Test/Mftf/Test/AdminCreateStoreGroupTest.xml
index 25e93f8f6ff4c..e93fd62a74999 100644
--- a/app/code/Magento/Store/Test/Mftf/Test/AdminCreateStoreGroupTest.xml
+++ b/app/code/Magento/Store/Test/Mftf/Test/AdminCreateStoreGroupTest.xml
@@ -21,7 +21,7 @@
-
+
diff --git a/app/code/Magento/Swatches/Test/Mftf/Test/AdminCreateTextSwatchTest.xml b/app/code/Magento/Swatches/Test/Mftf/Test/AdminCreateTextSwatchTest.xml
index 3ef347b7aca12..87d3f0bb5bcb9 100644
--- a/app/code/Magento/Swatches/Test/Mftf/Test/AdminCreateTextSwatchTest.xml
+++ b/app/code/Magento/Swatches/Test/Mftf/Test/AdminCreateTextSwatchTest.xml
@@ -22,7 +22,7 @@
-
+
diff --git a/app/code/Magento/Swatches/Test/Mftf/Test/AdminCreateVisualSwatchTest.xml b/app/code/Magento/Swatches/Test/Mftf/Test/AdminCreateVisualSwatchTest.xml
index 90e94466351b6..65f0e2b09b82a 100644
--- a/app/code/Magento/Swatches/Test/Mftf/Test/AdminCreateVisualSwatchTest.xml
+++ b/app/code/Magento/Swatches/Test/Mftf/Test/AdminCreateVisualSwatchTest.xml
@@ -35,7 +35,7 @@
-
+
diff --git a/app/code/Magento/Swatches/Test/Mftf/Test/StorefrontFilterByImageSwatchTest.xml b/app/code/Magento/Swatches/Test/Mftf/Test/StorefrontFilterByImageSwatchTest.xml
index b1ae06428c0ab..824817a322137 100644
--- a/app/code/Magento/Swatches/Test/Mftf/Test/StorefrontFilterByImageSwatchTest.xml
+++ b/app/code/Magento/Swatches/Test/Mftf/Test/StorefrontFilterByImageSwatchTest.xml
@@ -30,7 +30,7 @@
-
+
diff --git a/app/code/Magento/Swatches/Test/Mftf/Test/StorefrontFilterByTextSwatchTest.xml b/app/code/Magento/Swatches/Test/Mftf/Test/StorefrontFilterByTextSwatchTest.xml
index 28df5ffd53436..f150c6697bb96 100644
--- a/app/code/Magento/Swatches/Test/Mftf/Test/StorefrontFilterByTextSwatchTest.xml
+++ b/app/code/Magento/Swatches/Test/Mftf/Test/StorefrontFilterByTextSwatchTest.xml
@@ -28,7 +28,7 @@
-
+
diff --git a/app/code/Magento/Swatches/Test/Mftf/Test/StorefrontFilterByVisualSwatchTest.xml b/app/code/Magento/Swatches/Test/Mftf/Test/StorefrontFilterByVisualSwatchTest.xml
index d12cb0433fed1..623fd7456830c 100644
--- a/app/code/Magento/Swatches/Test/Mftf/Test/StorefrontFilterByVisualSwatchTest.xml
+++ b/app/code/Magento/Swatches/Test/Mftf/Test/StorefrontFilterByVisualSwatchTest.xml
@@ -30,7 +30,7 @@
-
+
diff --git a/app/code/Magento/Swatches/Test/Mftf/Test/StorefrontSwatchProductWithFileCustomOptionTest.xml b/app/code/Magento/Swatches/Test/Mftf/Test/StorefrontSwatchProductWithFileCustomOptionTest.xml
index 7ef030ef8dfa8..5e712ebc38292 100644
--- a/app/code/Magento/Swatches/Test/Mftf/Test/StorefrontSwatchProductWithFileCustomOptionTest.xml
+++ b/app/code/Magento/Swatches/Test/Mftf/Test/StorefrontSwatchProductWithFileCustomOptionTest.xml
@@ -26,7 +26,7 @@
-
+
diff --git a/app/code/Magento/Widget/Test/Mftf/Test/NewProductsListWidgetTest.xml b/app/code/Magento/Widget/Test/Mftf/Test/NewProductsListWidgetTest.xml
index 2c4e2e70fec71..9ed4e2ced99f7 100644
--- a/app/code/Magento/Widget/Test/Mftf/Test/NewProductsListWidgetTest.xml
+++ b/app/code/Magento/Widget/Test/Mftf/Test/NewProductsListWidgetTest.xml
@@ -27,7 +27,7 @@
-
+
diff --git a/app/code/Magento/Wishlist/Test/Mftf/Test/ConfigurableProductChildImageShouldBeShownOnWishListTest.xml b/app/code/Magento/Wishlist/Test/Mftf/Test/ConfigurableProductChildImageShouldBeShownOnWishListTest.xml
index 6b951c89208c2..0489ec750b7e0 100644
--- a/app/code/Magento/Wishlist/Test/Mftf/Test/ConfigurableProductChildImageShouldBeShownOnWishListTest.xml
+++ b/app/code/Magento/Wishlist/Test/Mftf/Test/ConfigurableProductChildImageShouldBeShownOnWishListTest.xml
@@ -32,7 +32,7 @@
-
+
diff --git a/app/code/Magento/Wishlist/Test/Mftf/Test/StorefrontAddMultipleStoreProductsToWishlistTest.xml b/app/code/Magento/Wishlist/Test/Mftf/Test/StorefrontAddMultipleStoreProductsToWishlistTest.xml
index ede63322235f2..2d2248705d804 100644
--- a/app/code/Magento/Wishlist/Test/Mftf/Test/StorefrontAddMultipleStoreProductsToWishlistTest.xml
+++ b/app/code/Magento/Wishlist/Test/Mftf/Test/StorefrontAddMultipleStoreProductsToWishlistTest.xml
@@ -43,7 +43,7 @@
-
+
diff --git a/app/code/Magento/Wishlist/Test/Mftf/Test/StorefrontDeletePersistedWishlistTest.xml b/app/code/Magento/Wishlist/Test/Mftf/Test/StorefrontDeletePersistedWishlistTest.xml
index 0001bd9d6db75..1c6d66a8fc48a 100644
--- a/app/code/Magento/Wishlist/Test/Mftf/Test/StorefrontDeletePersistedWishlistTest.xml
+++ b/app/code/Magento/Wishlist/Test/Mftf/Test/StorefrontDeletePersistedWishlistTest.xml
@@ -35,7 +35,7 @@
-
+
From c240fda0d5e7dd2f6ed6ef2f8ca8bce27319c87a Mon Sep 17 00:00:00 2001
From: Aliaksei Yakimovich2
Date: Thu, 13 Jun 2019 14:41:53 +0300
Subject: [PATCH 021/937] MAGETWO-70803: [GITHUB] Inconsistent CSV file Import
error: #7495
- Fixed an issue with dublicated file validation;
---
app/code/Magento/CatalogImportExport/Model/Import/Product.php | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/app/code/Magento/CatalogImportExport/Model/Import/Product.php b/app/code/Magento/CatalogImportExport/Model/Import/Product.php
index 0b7fbaf86826b..a8395aac0f4eb 100644
--- a/app/code/Magento/CatalogImportExport/Model/Import/Product.php
+++ b/app/code/Magento/CatalogImportExport/Model/Import/Product.php
@@ -1508,6 +1508,7 @@ public function getImagesFromRow(array $rowData)
* @SuppressWarnings(PHPMD.ExcessiveMethodLength)
* @SuppressWarnings(PHPMD.UnusedLocalVariable)
* @throws LocalizedException
+ * phpcs:disable Generic.Metrics.NestingLevel
*/
protected function _saveProducts()
{
@@ -1882,6 +1883,7 @@ protected function _saveProducts()
return $this;
}
+ //phpcs:enable Generic.Metrics.NestingLevel
/**
* Prepare array with image states (visible or hidden from product page)
@@ -2726,8 +2728,6 @@ protected function _saveValidatedBunches()
try {
$rowData = $source->current();
} catch (\InvalidArgumentException $e) {
- $this->addRowError($e->getMessage(), $this->_processedRowsCount);
- $this->_processedRowsCount++;
$source->next();
continue;
}
From 1ed2728a4566dc6cda4ab7d3e99e7eeda34844df Mon Sep 17 00:00:00 2001
From: Yuliya Labudova
Date: Thu, 13 Jun 2019 18:50:33 +0300
Subject: [PATCH 022/937] MAGETWO-94565: Catalog product collection filters
produce errors and cause inconsistent behaviour
- Fix CR comment
---
.../ResourceModel/Product/Collection.php | 20 +++++++++++--------
1 file changed, 12 insertions(+), 8 deletions(-)
diff --git a/app/code/Magento/Catalog/Model/ResourceModel/Product/Collection.php b/app/code/Magento/Catalog/Model/ResourceModel/Product/Collection.php
index 6e790abd5372a..76152250c41df 100644
--- a/app/code/Magento/Catalog/Model/ResourceModel/Product/Collection.php
+++ b/app/code/Magento/Catalog/Model/ResourceModel/Product/Collection.php
@@ -23,7 +23,7 @@
use Magento\Framework\Indexer\DimensionFactory;
use Magento\Store\Model\Indexer\WebsiteDimensionProvider;
use Magento\Store\Model\Store;
-use Magento\Catalog\Api\CategoryRepositoryInterface;
+use Magento\Catalog\Model\ResourceModel\Category\CollectionFactory;
/**
* Product collection
@@ -305,9 +305,9 @@ class Collection extends \Magento\Catalog\Model\ResourceModel\Collection\Abstrac
private $urlFinder;
/**
- * @var CategoryRepositoryInterface
+ * @var CollectionFactory
*/
- private $categoryRepository;
+ private $categoryCollectionFactory;
/**
* Collection constructor
@@ -337,7 +337,7 @@ class Collection extends \Magento\Catalog\Model\ResourceModel\Collection\Abstrac
* @param TableMaintainer|null $tableMaintainer
* @param PriceTableResolver|null $priceTableResolver
* @param DimensionFactory|null $dimensionFactory
- * @param CategoryRepositoryInterface|null $categoryRepository
+ * @param CollectionFactory|null $categoryCollectionFactory
*
* @SuppressWarnings(PHPMD.ExcessiveParameterList)
*/
@@ -367,7 +367,7 @@ public function __construct(
TableMaintainer $tableMaintainer = null,
PriceTableResolver $priceTableResolver = null,
DimensionFactory $dimensionFactory = null,
- CategoryRepositoryInterface $categoryRepository = null
+ CollectionFactory $categoryCollectionFactory = null
) {
$this->moduleManager = $moduleManager;
$this->_catalogProductFlatState = $catalogProductFlatState;
@@ -401,8 +401,8 @@ public function __construct(
$this->priceTableResolver = $priceTableResolver ?: ObjectManager::getInstance()->get(PriceTableResolver::class);
$this->dimensionFactory = $dimensionFactory
?: ObjectManager::getInstance()->get(DimensionFactory::class);
- $this->categoryRepository = $categoryRepository ?: ObjectManager::getInstance()
- ->get(CategoryRepositoryInterface::class);
+ $this->categoryCollectionFactory = $categoryCollectionFactory ?: ObjectManager::getInstance()
+ ->get(CollectionFactory::class);
}
/**
@@ -2105,7 +2105,11 @@ protected function _applyZeroStoreProductLimitations()
*/
private function getChildrenCategories(int $categoryId, array $categories): array
{
- $category = $this->categoryRepository->get($categoryId);
+ /** @var \Magento\Catalog\Model\ResourceModel\Category\Collection $categoryCollection */
+ $categoryCollection = $this->categoryCollectionFactory->create();
+ $category = $categoryCollection
+ ->addAttributeToSelect('is_anchor')->addIdFilter([$categoryId])
+ ->load()->getFirstItem();
$categories[] = $category->getId();
if ($category->getIsAnchor()) {
$categoryChildren = $category->getChildren();
From 102cc0fa543b0fcba9faa1fc4c610bd28ad53775 Mon Sep 17 00:00:00 2001
From: Vital_Pantsialeyeu
Date: Thu, 13 Jun 2019 14:47:01 +0300
Subject: [PATCH 023/937] MAGETWO-69825: [GITHUB #9891] Subcategory
"liquid-hand-soap" is not opened in category "soap"
- Implemented validation URL key during category creation
---
.../CategoryUrlPathAutogeneratorObserver.php | 25 ++++++++++++++++---
1 file changed, 22 insertions(+), 3 deletions(-)
diff --git a/app/code/Magento/CatalogUrlRewrite/Observer/CategoryUrlPathAutogeneratorObserver.php b/app/code/Magento/CatalogUrlRewrite/Observer/CategoryUrlPathAutogeneratorObserver.php
index 95ddceed6ec8f..346804db8a18b 100644
--- a/app/code/Magento/CatalogUrlRewrite/Observer/CategoryUrlPathAutogeneratorObserver.php
+++ b/app/code/Magento/CatalogUrlRewrite/Observer/CategoryUrlPathAutogeneratorObserver.php
@@ -48,22 +48,31 @@ class CategoryUrlPathAutogeneratorObserver implements ObserverInterface
*/
private $categoryRepository;
+ /**
+ * @var \Magento\Backend\App\Area\FrontNameResolver
+ */
+ private $frontNameResolver;
+
/**
* @param CategoryUrlPathGenerator $categoryUrlPathGenerator
* @param ChildrenCategoriesProvider $childrenCategoriesProvider
* @param \Magento\CatalogUrlRewrite\Service\V1\StoreViewService $storeViewService
* @param CategoryRepositoryInterface $categoryRepository
+ * @param \Magento\Backend\App\Area\FrontNameResolver $frontNameResolver
*/
public function __construct(
CategoryUrlPathGenerator $categoryUrlPathGenerator,
ChildrenCategoriesProvider $childrenCategoriesProvider,
StoreViewService $storeViewService,
- CategoryRepositoryInterface $categoryRepository
+ CategoryRepositoryInterface $categoryRepository,
+ \Magento\Backend\App\Area\FrontNameResolver $frontNameResolver = null
) {
$this->categoryUrlPathGenerator = $categoryUrlPathGenerator;
$this->childrenCategoriesProvider = $childrenCategoriesProvider;
$this->storeViewService = $storeViewService;
$this->categoryRepository = $categoryRepository;
+ $this->frontNameResolver = $frontNameResolver ?: \Magento\Framework\App\ObjectManager::getInstance()
+ ->get(\Magento\Backend\App\Area\FrontNameResolver::class);
}
/**
@@ -102,12 +111,12 @@ private function updateUrlKey($category, $urlKey)
throw new \Magento\Framework\Exception\LocalizedException(__('Invalid URL key'));
}
- if (in_array($urlKey, $this->invalidValues)) {
+ if (in_array($urlKey, $this->getInvalidValues())) {
throw new \Magento\Framework\Exception\LocalizedException(
__(
'URL key "%1" conflicts with reserved endpoint names: %2. Try another url key.',
$urlKey,
- implode(', ', $this->invalidValues)
+ implode(', ', $this->getInvalidValues())
)
);
}
@@ -122,6 +131,16 @@ private function updateUrlKey($category, $urlKey)
}
}
+ /**
+ * Get reserved endpoint names.
+ *
+ * @return array
+ */
+ private function getInvalidValues()
+ {
+ return array_unique(array_merge($this->invalidValues, [$this->frontNameResolver->getFrontName()]));
+ }
+
/**
* Update url path for children category.
*
From 3d556b2d38522d8f71aca0bba82333a9d2d179eb Mon Sep 17 00:00:00 2001
From: Lusine Papyan
Date: Wed, 19 Jun 2019 10:05:42 +0400
Subject: [PATCH 024/937] MAGETWO-44170: Not pass function test
\Magento\Catalog\Test\TestCase\Product\ProductTypeSwitchingOnUpdateTest
- Added automated test script.
---
...AdminProductTypeSwitchingOnEditingTest.xml | 423 ++++++++++++++++++
1 file changed, 423 insertions(+)
create mode 100644 app/code/Magento/Catalog/Test/Mftf/Test/AdminProductTypeSwitchingOnEditingTest.xml
diff --git a/app/code/Magento/Catalog/Test/Mftf/Test/AdminProductTypeSwitchingOnEditingTest.xml b/app/code/Magento/Catalog/Test/Mftf/Test/AdminProductTypeSwitchingOnEditingTest.xml
new file mode 100644
index 0000000000000..116fbc1b6b455
--- /dev/null
+++ b/app/code/Magento/Catalog/Test/Mftf/Test/AdminProductTypeSwitchingOnEditingTest.xml
@@ -0,0 +1,423 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
From fd3a8ae0e7fb437277e6e0f8fbec088582a49c2d Mon Sep 17 00:00:00 2001
From: Nikita Chubukov
Date: Thu, 20 Jun 2019 16:29:25 +0300
Subject: [PATCH 025/937] MC-15256: Exported customer without modification can
not be imported
- Changed import validation logic for attributes with empty select value
---
.../Model/Import/Customer.php | 15 ++++++++++++---
1 file changed, 12 insertions(+), 3 deletions(-)
diff --git a/app/code/Magento/CustomerImportExport/Model/Import/Customer.php b/app/code/Magento/CustomerImportExport/Model/Import/Customer.php
index ab940c9e84533..f181119f1acf5 100644
--- a/app/code/Magento/CustomerImportExport/Model/Import/Customer.php
+++ b/app/code/Magento/CustomerImportExport/Model/Import/Customer.php
@@ -3,6 +3,8 @@
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
+declare(strict_types=1);
+
namespace Magento\CustomerImportExport\Model\Import;
use Magento\Customer\Api\Data\CustomerInterface;
@@ -288,9 +290,12 @@ private function getCustomerEntityFieldsToUpdate(array $entitiesToUpdate): array
{
$firstCustomer = reset($entitiesToUpdate);
$columnsToUpdate = array_keys($firstCustomer);
- $customerFieldsToUpdate = array_filter($this->customerFields, function ($field) use ($columnsToUpdate) {
- return in_array($field, $columnsToUpdate);
- });
+ $customerFieldsToUpdate = array_filter(
+ $this->customerFields,
+ function ($field) use ($columnsToUpdate) {
+ return in_array($field, $columnsToUpdate);
+ }
+ );
return $customerFieldsToUpdate;
}
@@ -606,6 +611,10 @@ protected function _validateRowForUpdate(array $rowData, $rowNumber)
}
if (isset($rowData[$attributeCode]) && strlen($rowData[$attributeCode])) {
+ if ($attributeParams['type'] == 'select' && empty($rowData[$attributeCode])) {
+ continue;
+ }
+
$this->isAttributeValid(
$attributeCode,
$attributeParams,
From 62bfe249b9dd0b1b6e2517152364a94b422470fc Mon Sep 17 00:00:00 2001
From: Yuliya Labudova
Date: Fri, 21 Jun 2019 14:08:24 +0300
Subject: [PATCH 026/937] MAGETWO-94565: Catalog product collection filters
produce errors and cause inconsistent behaviour
- Fix CR comments.
---
.../Model/ResourceModel/Product/Collection.php | 14 ++++++++------
1 file changed, 8 insertions(+), 6 deletions(-)
diff --git a/app/code/Magento/Catalog/Model/ResourceModel/Product/Collection.php b/app/code/Magento/Catalog/Model/ResourceModel/Product/Collection.php
index 76152250c41df..7127aa2cb3e77 100644
--- a/app/code/Magento/Catalog/Model/ResourceModel/Product/Collection.php
+++ b/app/code/Magento/Catalog/Model/ResourceModel/Product/Collection.php
@@ -2068,8 +2068,7 @@ protected function _applyProductLimitations()
protected function _applyZeroStoreProductLimitations()
{
$filters = $this->_productLimitationFilters;
- $categories = [];
- $categories = $this->getChildrenCategories((int)$filters['category_id'], $categories);
+ $categories = $this->getChildrenCategories((int)$filters['category_id'], []);
$conditions = [
'cat_pro.product_id=e.entity_id',
@@ -2105,13 +2104,16 @@ protected function _applyZeroStoreProductLimitations()
*/
private function getChildrenCategories(int $categoryId, array $categories): array
{
+ $categories[] = $categoryId;
+
/** @var \Magento\Catalog\Model\ResourceModel\Category\Collection $categoryCollection */
$categoryCollection = $this->categoryCollectionFactory->create();
$category = $categoryCollection
- ->addAttributeToSelect('is_anchor')->addIdFilter([$categoryId])
- ->load()->getFirstItem();
- $categories[] = $category->getId();
- if ($category->getIsAnchor()) {
+ ->addAttributeToSelect('is_anchor')
+ ->addAttributeToFilter('is_anchor', 1)
+ ->addIdFilter([$categoryId])
+ ->getFirstItem();
+ if ($category) {
$categoryChildren = $category->getChildren();
$categoryChildrenIds = explode(',', $categoryChildren);
foreach ($categoryChildrenIds as $categoryChildrenId) {
From d9c3e7bb31800f11b93410b347f0452fceea9c40 Mon Sep 17 00:00:00 2001
From: Krissy Hiserote
Date: Mon, 24 Jun 2019 10:09:07 -0500
Subject: [PATCH 027/937] MC-16650: Product Attribute Type Price Not Displaying
- use price filter for all attributes with catalog input type = 'price'
---
.../Catalog/Model/Layer/FilterList.php | 10 ++++--
.../Test/Unit/Model/Layer/FilterListTest.php | 8 +++--
.../Model/Layer/Filter/Price.php | 5 ++-
.../Model/Search/RequestGenerator/Decimal.php | 32 +------------------
.../Unit/Model/Layer/Filter/PriceTest.php | 7 ++++
.../Model/Layer/Filter/PriceTest.php | 8 +++++
6 files changed, 33 insertions(+), 37 deletions(-)
diff --git a/app/code/Magento/Catalog/Model/Layer/FilterList.php b/app/code/Magento/Catalog/Model/Layer/FilterList.php
index 9d7b71c981c6b..7f06c97d3e8d9 100644
--- a/app/code/Magento/Catalog/Model/Layer/FilterList.php
+++ b/app/code/Magento/Catalog/Model/Layer/FilterList.php
@@ -3,9 +3,15 @@
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
+declare(strict_types=1);
namespace Magento\Catalog\Model\Layer;
+use Magento\Catalog\Model\Product\Attribute\Backend\Price;
+
+/**
+ * Layer navigation filters
+ */
class FilterList
{
const CATEGORY_FILTER = 'category';
@@ -106,9 +112,9 @@ protected function getAttributeFilterClass(\Magento\Catalog\Model\ResourceModel\
{
$filterClassName = $this->filterTypes[self::ATTRIBUTE_FILTER];
- if ($attribute->getAttributeCode() == 'price') {
+ if ($attribute->getBackendModel() === Price::class) {
$filterClassName = $this->filterTypes[self::PRICE_FILTER];
- } elseif ($attribute->getBackendType() == 'decimal') {
+ } elseif ($attribute->getBackendType() === 'decimal') {
$filterClassName = $this->filterTypes[self::DECIMAL_FILTER];
}
diff --git a/app/code/Magento/Catalog/Test/Unit/Model/Layer/FilterListTest.php b/app/code/Magento/Catalog/Test/Unit/Model/Layer/FilterListTest.php
index 8733f305ce091..2d3c764cb6907 100644
--- a/app/code/Magento/Catalog/Test/Unit/Model/Layer/FilterListTest.php
+++ b/app/code/Magento/Catalog/Test/Unit/Model/Layer/FilterListTest.php
@@ -3,10 +3,12 @@
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
+declare(strict_types=1);
namespace Magento\Catalog\Test\Unit\Model\Layer;
use \Magento\Catalog\Model\Layer\FilterList;
+use Magento\Catalog\Model\Product\Attribute\Backend\Price;
class FilterListTest extends \PHPUnit\Framework\TestCase
{
@@ -95,8 +97,8 @@ public function getFiltersDataProvider()
{
return [
[
- 'method' => 'getAttributeCode',
- 'value' => FilterList::PRICE_FILTER,
+ 'method' => 'getBackendModel',
+ 'value' => Price::class,
'expectedClass' => 'PriceFilterClass',
],
[
@@ -105,7 +107,7 @@ public function getFiltersDataProvider()
'expectedClass' => 'DecimalFilterClass',
],
[
- 'method' => 'getAttributeCode',
+ 'method' => 'getBackendModel',
'value' => null,
'expectedClass' => 'AttributeFilterClass',
]
diff --git a/app/code/Magento/CatalogSearch/Model/Layer/Filter/Price.php b/app/code/Magento/CatalogSearch/Model/Layer/Filter/Price.php
index a19f53469ae01..66d9281ed38e2 100644
--- a/app/code/Magento/CatalogSearch/Model/Layer/Filter/Price.php
+++ b/app/code/Magento/CatalogSearch/Model/Layer/Filter/Price.php
@@ -3,6 +3,8 @@
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
+declare(strict_types=1);
+
namespace Magento\CatalogSearch\Model\Layer\Filter;
use Magento\Catalog\Model\Layer\Filter\AbstractFilter;
@@ -11,6 +13,7 @@
* Layer price filter based on Search API
*
* @SuppressWarnings(PHPMD.CouplingBetweenObjects)
+ * @SuppressWarnings(PHPMD.CookieAndSessionMisuse)
*/
class Price extends AbstractFilter
{
@@ -138,7 +141,7 @@ public function apply(\Magento\Framework\App\RequestInterface $request)
list($from, $to) = $filter;
$this->getLayer()->getProductCollection()->addFieldToFilter(
- 'price',
+ $this->getAttributeModel()->getAttributeCode(),
['from' => $from, 'to' => empty($to) || $from == $to ? $to : $to - self::PRICE_DELTA]
);
diff --git a/app/code/Magento/CatalogSearch/Model/Search/RequestGenerator/Decimal.php b/app/code/Magento/CatalogSearch/Model/Search/RequestGenerator/Decimal.php
index c9f738b07c175..73d011cc532db 100644
--- a/app/code/Magento/CatalogSearch/Model/Search/RequestGenerator/Decimal.php
+++ b/app/code/Magento/CatalogSearch/Model/Search/RequestGenerator/Decimal.php
@@ -10,29 +10,12 @@
use Magento\Catalog\Model\ResourceModel\Eav\Attribute;
use Magento\Framework\Search\Request\BucketInterface;
use Magento\Framework\Search\Request\FilterInterface;
-use Magento\Framework\App\Config\ScopeConfigInterface;
-use Magento\Framework\App\ObjectManager;
-use Magento\Catalog\Model\Layer\Filter\Dynamic\AlgorithmFactory;
-use Magento\Store\Model\ScopeInterface;
/**
* Catalog search range request generator.
*/
class Decimal implements GeneratorInterface
{
- /**
- * @var \Magento\Store\Model\ScopeInterface
- */
- private $scopeConfig;
-
- /**
- * @param \Magento\Store\Model\ScopeInterface|null $scopeConfig
- */
- public function __construct(ScopeConfigInterface $scopeConfig = null)
- {
- $this->scopeConfig = $scopeConfig ?: ObjectManager::getInstance()->get(ScopeConfigInterface::class);
- }
-
/**
* @inheritdoc
*/
@@ -56,21 +39,8 @@ public function getAggregationData(Attribute $attribute, $bucketName)
'type' => BucketInterface::TYPE_DYNAMIC,
'name' => $bucketName,
'field' => $attribute->getAttributeCode(),
- 'method' => $this->getRangeCalculation(),
+ 'method' => 'manual',
'metric' => [['type' => 'count']],
];
}
-
- /**
- * Get range calculation by what was set in the configuration
- *
- * @return string
- */
- private function getRangeCalculation(): string
- {
- return $this->scopeConfig->getValue(
- AlgorithmFactory::XML_PATH_RANGE_CALCULATION,
- ScopeInterface::SCOPE_STORE
- );
- }
}
diff --git a/app/code/Magento/CatalogSearch/Test/Unit/Model/Layer/Filter/PriceTest.php b/app/code/Magento/CatalogSearch/Test/Unit/Model/Layer/Filter/PriceTest.php
index abad58a6876d3..f783f75a170e3 100644
--- a/app/code/Magento/CatalogSearch/Test/Unit/Model/Layer/Filter/PriceTest.php
+++ b/app/code/Magento/CatalogSearch/Test/Unit/Model/Layer/Filter/PriceTest.php
@@ -3,6 +3,7 @@
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
+declare(strict_types=1);
namespace Magento\CatalogSearch\Test\Unit\Model\Layer\Filter;
@@ -208,6 +209,12 @@ public function testApply()
$priceId = '15-50';
$requestVar = 'test_request_var';
+ $this->target->setAttributeModel($this->attribute);
+ $attributeCode = 'price';
+ $this->attribute->expects($this->any())
+ ->method('getAttributeCode')
+ ->will($this->returnValue($attributeCode));
+
$this->target->setRequestVar($requestVar);
$this->request->expects($this->exactly(1))
->method('getParam')
diff --git a/dev/tests/integration/testsuite/Magento/CatalogSearch/Model/Layer/Filter/PriceTest.php b/dev/tests/integration/testsuite/Magento/CatalogSearch/Model/Layer/Filter/PriceTest.php
index 451553113af2c..a7944566eb8e0 100644
--- a/dev/tests/integration/testsuite/Magento/CatalogSearch/Model/Layer/Filter/PriceTest.php
+++ b/dev/tests/integration/testsuite/Magento/CatalogSearch/Model/Layer/Filter/PriceTest.php
@@ -3,6 +3,8 @@
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
+declare(strict_types=1);
+
namespace Magento\CatalogSearch\Model\Layer\Filter;
use Magento\TestFramework\Helper\Bootstrap;
@@ -35,10 +37,16 @@ protected function setUp()
$category->load(4);
$layer = $this->objectManager->get(\Magento\Catalog\Model\Layer\Category::class);
$layer->setCurrentCategory($category);
+ /** @var $attribute \Magento\Catalog\Model\Entity\Attribute */
+ $attribute = \Magento\TestFramework\Helper\Bootstrap::getObjectManager()->create(
+ \Magento\Catalog\Model\Entity\Attribute::class
+ );
+ $attribute->loadByCode('catalog_product', 'price');
$this->_model = $this->objectManager->create(
\Magento\CatalogSearch\Model\Layer\Filter\Price::class,
['layer' => $layer]
);
+ $this->_model->setAttributeModel($attribute);
}
public function testApplyNothing()
From 9fe43844e09517ca6d4e58c786605af871463d59 Mon Sep 17 00:00:00 2001
From: Lusine Papyan
Date: Tue, 25 Jun 2019 17:33:36 +0400
Subject: [PATCH 028/937] MAGETWO-70803: [GITHUB] Inconsistent CSV file Import
error: #7495
- Added automated test script
---
.../AdminImportProductsActionGroup.xml | 7 ++
.../Mftf/Section/AdminImportMainSection.xml | 2 +
...ImportCSVFileCorrectDifferentFilesTest.xml | 47 +++++++
.../acceptance/tests/_data/BB-Products.csv | 118 ++++++++++++++++++
.../tests/_data/BB-ProductsWorking.csv | 29 +++++
5 files changed, 203 insertions(+)
create mode 100644 app/code/Magento/ImportExport/Test/Mftf/Test/AdminProductImportCSVFileCorrectDifferentFilesTest.xml
create mode 100644 dev/tests/acceptance/tests/_data/BB-Products.csv
create mode 100644 dev/tests/acceptance/tests/_data/BB-ProductsWorking.csv
diff --git a/app/code/Magento/ImportExport/Test/Mftf/ActionGroup/AdminImportProductsActionGroup.xml b/app/code/Magento/ImportExport/Test/Mftf/ActionGroup/AdminImportProductsActionGroup.xml
index a9100b4730b8c..13843dc804655 100644
--- a/app/code/Magento/ImportExport/Test/Mftf/ActionGroup/AdminImportProductsActionGroup.xml
+++ b/app/code/Magento/ImportExport/Test/Mftf/ActionGroup/AdminImportProductsActionGroup.xml
@@ -27,4 +27,11 @@
+
+
+
+
+
+
+
diff --git a/app/code/Magento/ImportExport/Test/Mftf/Section/AdminImportMainSection.xml b/app/code/Magento/ImportExport/Test/Mftf/Section/AdminImportMainSection.xml
index 2ce6b1e35777f..6f6d6e4e6b8ac 100644
--- a/app/code/Magento/ImportExport/Test/Mftf/Section/AdminImportMainSection.xml
+++ b/app/code/Magento/ImportExport/Test/Mftf/Section/AdminImportMainSection.xml
@@ -13,5 +13,7 @@
+
+
diff --git a/app/code/Magento/ImportExport/Test/Mftf/Test/AdminProductImportCSVFileCorrectDifferentFilesTest.xml b/app/code/Magento/ImportExport/Test/Mftf/Test/AdminProductImportCSVFileCorrectDifferentFilesTest.xml
new file mode 100644
index 0000000000000..349d3415af06e
--- /dev/null
+++ b/app/code/Magento/ImportExport/Test/Mftf/Test/AdminProductImportCSVFileCorrectDifferentFilesTest.xml
@@ -0,0 +1,47 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dev/tests/acceptance/tests/_data/BB-Products.csv b/dev/tests/acceptance/tests/_data/BB-Products.csv
new file mode 100644
index 0000000000000..7ab03fd5eaeda
--- /dev/null
+++ b/dev/tests/acceptance/tests/_data/BB-Products.csv
@@ -0,0 +1,118 @@
+sku,store_view_code,attribute_set_code,product_type,categories,product_websites,name,description,short_description,weight,product_online,tax_class_name,visibility,price,special_price,special_price_from_date,special_price_to_date,url_key,meta_title,meta_keywords,meta_description,base_image,base_image_label,small_image,small_image_label,thumbnail_image,thumbnail_image_label,swatch_image,swatch_image_label,created_at,updated_at,new_from_date,new_to_date,display_product_options_in,map_price,msrp_price,map_enabled,gift_message_available,custom_design,custom_design_from,custom_design_to,custom_layout_update,page_layout,product_options_container,msrp_display_actual_price_type,country_of_manufacture,additional_attributes,qty,out_of_stock_qty,use_config_min_qty,is_qty_decimal,allow_backorders,use_config_backorders,min_cart_qty,use_config_min_sale_qty,max_cart_qty,use_config_max_sale_qty,is_in_stock,notify_on_stock_below,use_config_notify_stock_qty,manage_stock,use_config_manage_stock,use_config_qty_increments,qty_increments,use_config_enable_qty_inc,enable_qty_increments,is_decimal_divided,website_id,related_skus,related_position,crosssell_skus,crosssell_position,upsell_skus,upsell_position,additional_images,additional_image_labels,hide_from_product_page,bundle_price_type,bundle_sku_type,bundle_price_view,bundle_weight_type,bundle_values,bundle_shipment_type,configurable_variations,configurable_variation_labels,associated_skus
+BB-D2010129,,Default,simple,"Default Category/Casa Giardino,Default Category/Casa Giardino/Sistemi di Climatizzazione,Default Category/Casa Giardino/Sistemi di Climatizzazione/Aria condizionata e ventilatori",base,"Ventilatore Portatile Spray FunFan Nero","Se
sei il tipo di persona che è sempre alla ricerca di prodotti innovativi per combattere il caldo estivo, non perderti il ventilatore portatile spray FunFan . Si tratta di una soluzione pratica per mantenersi al fresco in una moltitudine di situazioni, come escursioni, gite in spiaggia, mentre si fa sport, ecc. Inoltre, grazie alle sue dimensioni ridotte (dimensioni: circa 9 x 26 x 6,5 cm) e peso ridotto (circa 130 g), lo puoi portare ovunque!www.myfunfan.com Questo ventilatore portatile originale ha un pulsante per attivare le eliche in PVC malleabili e una leva che spruzza l'acqua. Cosa c'è di più, puoi aggiungere il ghiaccio per aumentare la sensazione di freddo! Include 1 cacciavite a croce per inserire le batterie. Realizzato in PVC. Funzionamento a batterie (2 x AA, non incluse).
Dimenzioni per Ventilatore Portatile Spray FunFan :
Altezza: 10 Cm Larghezza: 28 Cm Profondita': 7.5 Cm Peso: 0.185 Kg Codice Prodotto (EAN): 4899888101772
","Se sei il tipo di persona che è sempre alla ricerca di prodotti innovativi per combattere il caldo estivo, non perderti il ventilatore portatile spray FunFan. Maggiori Informazioni ",0.185,1,"Taxable Goods","Catalog, Search",19.9,,,,Ventilatore-Portatile-Spray-FunFan-Nero,"Ventilatore Portatile Spray FunFan Nero","Casa Giardino,Casa,Giardino,Sistemi di Climatizzazione,Sistemi,Climatizzazione,Aria condizionata e ventilatori,Aria,condizionata,ventilatori,Colore Nero,Nero,","Se sei il tipo di persona che è sempre alla ricerca di prodotti innovativi per combattere il caldo estivo, non perderti il ventilatore portatile spray FunFan",http://dropshipping.bigbuy.eu/imgs/D2010128_78887.jpg,,http://dropshipping.bigbuy.eu/imgs/D2010128_78887.jpg,,,,,,"2016-01-12 09:56:53",,,,,,,,,,,,,,,,,"GTIN=4899888101772",41,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/D2010128_78898.jpg,http://dropshipping.bigbuy.eu/imgs/D2010128_78890.jpg,http://dropshipping.bigbuy.eu/imgs/D2010128_78889.jpg,http://dropshipping.bigbuy.eu/imgs/D2010128_78888.jpg,http://dropshipping.bigbuy.eu/imgs/D2010128_78886.jpg","GTIN=4899888101772",,,,,,,,,,
+BB-D2010130,,Default,simple,"Default Category/Casa Giardino,Default Category/Casa Giardino/Sistemi di Climatizzazione,Default Category/Casa Giardino/Sistemi di Climatizzazione/Aria condizionata e ventilatori",base,"Ventilatore Portatile Spray FunFan Bianco","Se
sei il tipo di persona che è sempre alla ricerca di prodotti innovativi per combattere il caldo estivo, non perderti il ventilatore portatile spray FunFan . Si tratta di una soluzione pratica per mantenersi al fresco in una moltitudine di situazioni, come escursioni, gite in spiaggia, mentre si fa sport, ecc. Inoltre, grazie alle sue dimensioni ridotte (dimensioni: circa 9 x 26 x 6,5 cm) e peso ridotto (circa 130 g), lo puoi portare ovunque!www.myfunfan.com Questo ventilatore portatile originale ha un pulsante per attivare le eliche in PVC malleabili e una leva che spruzza l'acqua. Cosa c'è di più, puoi aggiungere il ghiaccio per aumentare la sensazione di freddo! Include 1 cacciavite a croce per inserire le batterie. Realizzato in PVC. Funzionamento a batterie (2 x AA, non incluse). Dimenzioni per Ventilatore Portatile Spray FunFan :
Altezza: 10 Cm Larghezza: 28 Cm Profondita': 7.5 Cm Peso: 0.185 Kg Codice Prodotto (EAN): 4899888107965
","Se sei il tipo di persona che è sempre alla ricerca di prodotti innovativi per combattere il caldo estivo, non perderti il ventilatore portatile spray FunFan. Maggiori Informazioni ",0.185,1,"Taxable Goods","Catalog, Search",19.9,,,,Ventilatore-Portatile-Spray-FunFan-Bianco,"Ventilatore Portatile Spray FunFan Bianco","Casa Giardino,Casa,Giardino,Sistemi di Climatizzazione,Sistemi,Climatizzazione,Aria condizionata e ventilatori,Aria,condizionata,ventilatori,Colore Bianco,Bianco,","Se sei il tipo di persona che è sempre alla ricerca di prodotti innovativi per combattere il caldo estivo, non perderti il ventilatore portatile spray FunFan",http://dropshipping.bigbuy.eu/imgs/D2010128_78898.jpg,,http://dropshipping.bigbuy.eu/imgs/D2010128_78898.jpg,,,,,,"2016-01-12 09:56:53",,,,,,,,,,,,,,,,,"GTIN=4899888107965",741,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/D2010128_78887.jpg,http://dropshipping.bigbuy.eu/imgs/D2010128_78890.jpg,http://dropshipping.bigbuy.eu/imgs/D2010128_78889.jpg,http://dropshipping.bigbuy.eu/imgs/D2010128_78888.jpg,http://dropshipping.bigbuy.eu/imgs/D2010128_78886.jpg","GTIN=4899888107965",,,,,,,,,,
+BB-D2010131,,Default,simple,"Default Category/Casa Giardino,Default Category/Casa Giardino/Sistemi di Climatizzazione,Default Category/Casa Giardino/Sistemi di Climatizzazione/Aria condizionata e ventilatori",base,"Ventilatore Portatile Spray FunFan Rosso","Se
sei il tipo di persona che è sempre alla ricerca di prodotti innovativi per combattere il caldo estivo, non perderti il ventilatore portatile spray FunFan . Si tratta di una soluzione pratica per mantenersi al fresco in una moltitudine di situazioni, come escursioni, gite in spiaggia, mentre si fa sport, ecc. Inoltre, grazie alle sue dimensioni ridotte (dimensioni: circa 9 x 26 x 6,5 cm) e peso ridotto (circa 130 g), lo puoi portare ovunque!www.myfunfan.com Questo ventilatore portatile originale ha un pulsante per attivare le eliche in PVC malleabili e una leva che spruzza l'acqua. Cosa c'è di più, puoi aggiungere il ghiaccio per aumentare la sensazione di freddo! Include 1 cacciavite a croce per inserire le batterie. Realizzato in PVC. Funzionamento a batterie (2 x AA, non incluse). Dimenzioni per Ventilatore Portatile Spray FunFan :
Altezza: 10 Cm Larghezza: 28 Cm Profondita': 7.5 Cm Peso: 0.185 Kg Codice Prodotto (EAN): 4899888107972
","Se sei il tipo di persona che è sempre alla ricerca di prodotti innovativi per combattere il caldo estivo, non perderti il ventilatore portatile spray FunFan. Maggiori Informazioni ",0.185,1,"Taxable Goods","Catalog, Search",19.9,,,,Ventilatore-Portatile-Spray-FunFan-Rosso,"Ventilatore Portatile Spray FunFan Rosso","Casa Giardino,Casa,Giardino,Sistemi di Climatizzazione,Sistemi,Climatizzazione,Aria condizionata e ventilatori,Aria,condizionata,ventilatori,Colore Rosso,Rosso,","Se sei il tipo di persona che è sempre alla ricerca di prodotti innovativi per combattere il caldo estivo, non perderti il ventilatore portatile spray FunFan",http://dropshipping.bigbuy.eu/imgs/D2010128_78890.jpg,,http://dropshipping.bigbuy.eu/imgs/D2010128_78890.jpg,,,,,,"2016-01-12 09:56:53",,,,,,,,,,,,,,,,,"GTIN=4899888107972",570,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/D2010128_78887.jpg,http://dropshipping.bigbuy.eu/imgs/D2010128_78898.jpg,http://dropshipping.bigbuy.eu/imgs/D2010128_78889.jpg,http://dropshipping.bigbuy.eu/imgs/D2010128_78888.jpg,http://dropshipping.bigbuy.eu/imgs/D2010128_78886.jpg","GTIN=4899888107972",,,,,,,,,,
+BB-H1000163,,Default,simple,"Default Category/Casa Giardino,Default Category/Casa Giardino/Giardino e Terrazza,Default Category/Casa Giardino/Giardino e Terrazza/Decorazione, illuminazione e mobili",base,"Sedia Pieghevole Campart Travel CH0592 Blu Marino","Se
stai cercando comfort e convenienza allo stesso tempo, probabilmente adorerai la sedia pieghevole Campart Travel ! Questa sedia da campeggio imbottita è perfetta per i luoghi di campeggio, cortili, giardini, ecc. Ideale per il riposo e il relax. Può portare fino a 120 kg. Dimensioni: 66 x 70 / 120 x 87 / 115 cm circa. Semplice da trasportare ovunque, grazie al suo design funzionale ed elegante (dimensioni quando piegato: circa 66 x 110 x 10 cm). 7 posizioni regolabili e un poggiatesta incorporato. Struttura in alluminio e stoffa imbottita in poliestere. Altezza sedia: circa 50 cm. Dimenzioni per Sedia Pieghevole Campart Travel:
Altezza: 10 Cm Larghezza: 66 Cm Profondita': 110 Cm Peso: 5.3 Kg Codice Prodotto (EAN): 8713016005922
","Se stai cercando comfort e convenienza allo stesso tempo, probabilmente adorerai la sedia pieghevole Campart Travel! Questa sedia da campeggio imbottita è perfetta per i luoghi di campeggio, cortili, giardini, ecc. Maggiori Informazioni ",5.3,1,"Taxable Goods","Catalog, Search",129,,,,Sedia-Pieghevole-Campart-Travel-CH0592 Blu Marino,"Sedia Pieghevole Campart Travel CH0592 Blu Marino","Casa Giardino,Casa,Giardino,Giardino e Terrazza,Giardino,Terrazza,Decorazione, illuminazione e mobili,Decorazione,,illuminazione,mobili,Referenza e Colore CH0592 Blu Marino,CH0592 Blu Marino,","Se stai cercando comfort e convenienza allo stesso tempo, probabilmente adorerai la sedia pieghevole Campart Travel! Questa sedia da campeggio imbottita è perfetta per i luoghi di campeggio, cortili, giardini, ecc",http://dropshipping.bigbuy.eu/imgs/silla_plegable_camping_00.jpg,,http://dropshipping.bigbuy.eu/imgs/silla_plegable_camping_00.jpg,,,,,,"2015-09-21 15:58:54",,,,,,,,,,,,,,,,,"GTIN=8713016005922",1,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/silla_plegable_camping_02.jpg,http://dropshipping.bigbuy.eu/imgs/silla_plegable_camping_04.jpg,http://dropshipping.bigbuy.eu/imgs/silla_plegable_camping_03.jpg,http://dropshipping.bigbuy.eu/imgs/silla_plegable_camping_01.jpg","GTIN=8713016005922",,,,,,,,,,
+BB-H1000162,,Default,simple,"Default Category/Casa Giardino,Default Category/Casa Giardino/Giardino e Terrazza,Default Category/Casa Giardino/Giardino e Terrazza/Decorazione, illuminazione e mobili",base,"Sedia Pieghevole Campart Travel CH0596 Grigio","Se
stai cercando comfort e convenienza allo stesso tempo, probabilmente adorerai la sedia pieghevole Campart Travel ! Questa sedia da campeggio imbottita è perfetta per i luoghi di campeggio, cortili, giardini, ecc. Ideale per il riposo e il relax. Può portare fino a 120 kg. Dimensioni: 66 x 70 / 120 x 87 / 115 cm circa. Semplice da trasportare ovunque, grazie al suo design funzionale ed elegante (dimensioni quando piegato: circa 66 x 110 x 10 cm). 7 posizioni regolabili e un poggiatesta incorporato. Struttura in alluminio e stoffa imbottita in poliestere. Altezza sedia: circa 50 cm. Dimenzioni per Sedia Pieghevole Campart Travel:
Altezza: 10 Cm Larghezza: 66 Cm Profondita': 110 Cm Peso: 5.3 Kg Codice Prodotto (EAN): 8713016005960
","Se stai cercando comfort e convenienza allo stesso tempo, probabilmente adorerai la sedia pieghevole Campart Travel! Questa sedia da campeggio imbottita è perfetta per i luoghi di campeggio, cortili, giardini, ecc. Maggiori Informazioni ",5.3,1,"Taxable Goods","Catalog, Search",129,,,,Sedia-Pieghevole-Campart-Travel-CH0596 Grigio,"Sedia Pieghevole Campart Travel CH0596 Grigio","Casa Giardino,Casa,Giardino,Giardino e Terrazza,Giardino,Terrazza,Decorazione, illuminazione e mobili,Decorazione,,illuminazione,mobili,Referenza e Colore CH0596 Grigio,CH0596 Grigio,","Se stai cercando comfort e convenienza allo stesso tempo, probabilmente adorerai la sedia pieghevole Campart Travel! Questa sedia da campeggio imbottita è perfetta per i luoghi di campeggio, cortili, giardini, ecc",http://dropshipping.bigbuy.eu/imgs/silla_plegable_camping_02.jpg,,http://dropshipping.bigbuy.eu/imgs/silla_plegable_camping_02.jpg,,,,,,"2015-09-21 15:58:54",,,,,,,,,,,,,,,,,"GTIN=8713016005960",2,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/silla_plegable_camping_00.jpg,http://dropshipping.bigbuy.eu/imgs/silla_plegable_camping_04.jpg,http://dropshipping.bigbuy.eu/imgs/silla_plegable_camping_03.jpg,http://dropshipping.bigbuy.eu/imgs/silla_plegable_camping_01.jpg","GTIN=8713016005960",,,,,,,,,,
+BB-F1520329,,Default,simple,"Default Category/Casa Giardino,Default Category/Casa Giardino/Giardino e Terrazza,Default Category/Casa Giardino/Giardino e Terrazza/Decorazione, illuminazione e mobili",base,"Poggiapiedi Pieghevole Campart Travel CH0593 Blu Marino","Approfitta
di un'esperienza rilassante con l'aiuto del poggiapiedi pieghevole Campart Travel ! Questo poggiapiedi imbottito è l'accessorio ideale per sedie da cortile, terrazzo, giardini, luoghi da campeggio, ecc. Possiede 2 ganci di circa 3 cm di diametro che possono essere facilmente attaccate alla barra inferiore delle sedie (utilizzabile solo per sedie con una barra inferiore di circa 2 cm di diametro). Struttura in alluminio. Tessuto: poliestere. Dimensioni: circa 51 x 47 x 96 cm (dimensioni quando ripiegato: circa 51 x 12 x 96 cm). Ideale per le sedie pieghevoli Campart Travel CH0592 e CH0596. Dimenzioni per Poggiapiedi Pieghevole Campart Travel:
Altezza: 13 Cm Larghezza: 53 Cm Profondita': 97 Cm Peso: 1.377 Kg Codice Prodotto (EAN): 8713016005939
","Approfitta di un'esperienza rilassante con l'aiuto del poggiapiedi pieghevole Campart Travel! Questo poggiapiedi imbottito è l'accessorio ideale per sedie da cortile, terrazzo, giardini, luoghi da campeggio, ecc. Maggiori Informazioni ",1.377,1,"Taxable Goods","Catalog, Search",46.6,,,,Poggiapiedi-Pieghevole-Campart-Travel-CH0593 Blu Marino,"Poggiapiedi Pieghevole Campart Travel CH0593 Blu Marino","Casa Giardino,Casa,Giardino,Giardino e Terrazza,Giardino,Terrazza,Decorazione, illuminazione e mobili,Decorazione,,illuminazione,mobili,Referenza e Colore CH0593 Blu Marino,CH0593 Blu Marino,","Approfitta di un'esperienza rilassante con l'aiuto del poggiapiedi pieghevole Campart Travel! Questo poggiapiedi imbottito è l'accessorio ideale per sedie da cortile, terrazzo, giardini, luoghi da campeggio, ecc",http://dropshipping.bigbuy.eu/imgs/reposapies_CH-0609_00.jpg,,http://dropshipping.bigbuy.eu/imgs/reposapies_CH-0609_00.jpg,,,,,,"2015-09-21 15:58:54",,,,,,,,,,,,,,,,,"GTIN=8713016005939",1,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/reposapies_CH-0609_01.jpg,http://dropshipping.bigbuy.eu/imgs/reposapies_CH-0609_02.jpg,http://dropshipping.bigbuy.eu/imgs/reposapies_CH-0609_08.jpg,http://dropshipping.bigbuy.eu/imgs/reposapies_CH-0609_07.jpg,http://dropshipping.bigbuy.eu/imgs/reposapies_CH-0609_06.jpg,http://dropshipping.bigbuy.eu/imgs/reposapies_CH-0609_05.jpg,http://dropshipping.bigbuy.eu/imgs/reposapies_CH-0609_04.jpg","GTIN=8713016005939",,,,,,,,,,
+BB-F1520328,,Default,simple,"Default Category/Casa Giardino,Default Category/Casa Giardino/Giardino e Terrazza,Default Category/Casa Giardino/Giardino e Terrazza/Decorazione, illuminazione e mobili",base,"Poggiapiedi Pieghevole Campart Travel CH0597 Grigio","Approfitta
di un'esperienza rilassante con l'aiuto del poggiapiedi pieghevole Campart Travel ! Questo poggiapiedi imbottito è l'accessorio ideale per sedie da cortile, terrazzo, giardini, luoghi da campeggio, ecc. Possiede 2 ganci di circa 3 cm di diametro che possono essere facilmente attaccate alla barra inferiore delle sedie (utilizzabile solo per sedie con una barra inferiore di circa 2 cm di diametro). Struttura in alluminio. Tessuto: poliestere. Dimensioni: circa 51 x 47 x 96 cm (dimensioni quando ripiegato: circa 51 x 12 x 96 cm). Ideale per le sedie pieghevoli Campart Travel CH0592 e CH0596. Dimenzioni per Poggiapiedi Pieghevole Campart Travel:
Altezza: 13 Cm Larghezza: 53 Cm Profondita': 97 Cm Peso: 1.377 Kg Codice Prodotto (EAN): 8713016005977
","Approfitta di un'esperienza rilassante con l'aiuto del poggiapiedi pieghevole Campart Travel! Questo poggiapiedi imbottito è l'accessorio ideale per sedie da cortile, terrazzo, giardini, luoghi da campeggio, ecc. Maggiori Informazioni ",1.377,1,"Taxable Goods","Catalog, Search",46.6,,,,Poggiapiedi-Pieghevole-Campart-Travel-CH0597 Grigio,"Poggiapiedi Pieghevole Campart Travel CH0597 Grigio","Casa Giardino,Casa,Giardino,Giardino e Terrazza,Giardino,Terrazza,Decorazione, illuminazione e mobili,Decorazione,,illuminazione,mobili,Referenza e Colore CH0597 Grigio,CH0597 Grigio,","Approfitta di un'esperienza rilassante con l'aiuto del poggiapiedi pieghevole Campart Travel! Questo poggiapiedi imbottito è l'accessorio ideale per sedie da cortile, terrazzo, giardini, luoghi da campeggio, ecc",http://dropshipping.bigbuy.eu/imgs/reposapies_CH-0609_01.jpg,,http://dropshipping.bigbuy.eu/imgs/reposapies_CH-0609_01.jpg,,,,,,"2015-09-21 15:58:54",,,,,,,,,,,,,,,,,"GTIN=8713016005977",7,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/reposapies_CH-0609_00.jpg,http://dropshipping.bigbuy.eu/imgs/reposapies_CH-0609_02.jpg,http://dropshipping.bigbuy.eu/imgs/reposapies_CH-0609_08.jpg,http://dropshipping.bigbuy.eu/imgs/reposapies_CH-0609_07.jpg,http://dropshipping.bigbuy.eu/imgs/reposapies_CH-0609_06.jpg,http://dropshipping.bigbuy.eu/imgs/reposapies_CH-0609_05.jpg,http://dropshipping.bigbuy.eu/imgs/reposapies_CH-0609_04.jpg","GTIN=8713016005977",,,,,,,,,,
+BB-H4502058,,Default,simple,"Default Category/Casa Giardino,Default Category/Casa Giardino/Decorazione e Illuminazione,Default Category/Casa Giardino/Decorazione e Illuminazione/Orologi da parete e da tavolo",base,"Orologio da Parete Star Wars","I
fan di Star Wars non potranno fare a meno di appendere l'orologio da parete Star Wars in casa loro! Realizzato in plastica. Funziona a batterie (1 x AA, non incluse). Diametro circa: 25,5 cm. Spessore circa: 3,5 cm. Dimenzioni per Orologio da Parete Star Wars:
Altezza: 25.5 Cm Larghezza: 26 Cm Profondita': 3.8 Cm Peso: 0.287 Kg Codice Prodotto (EAN): 6950687214204
","I fan di Star Wars non potranno fare a meno di appendere l'orologio da parete Star Wars in casa loro! Realizzato in plastica. Maggiori Informazioni ",0.287,1,"Taxable Goods","Catalog, Search",22.5,,,,Orologio-da-Parete-Star-Wars,"Orologio da Parete Star Wars","Casa Giardino,Casa,Giardino,Decorazione e Illuminazione,Decorazione,Illuminazione,Orologi da parete e da tavolo,Orologi,parete,tavolo,","I fan di Star Wars non potranno fare a meno di appendere l'orologio da parete Star Wars in casa loro! Realizzato in plastica",http://dropshipping.bigbuy.eu/imgs/H4502058_84712.jpg,,http://dropshipping.bigbuy.eu/imgs/H4502058_84712.jpg,,,,,,"2016-08-08 21:09:24",,,,,,,,,,,,,,,,,"GTIN=6950687214204",130,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/H4502058_84713.jpg,http://dropshipping.bigbuy.eu/imgs/H4502058_84711.jpg,http://dropshipping.bigbuy.eu/imgs/H4502058_84710.jpg","GTIN=6950687214204",,,,,,,,,,
+BB-G0500195,,Default,simple,"Default Category/Casa Giardino,Default Category/Casa Giardino/Decorazione e Illuminazione,Default Category/Casa Giardino/Decorazione e Illuminazione/Illuminazione LED",base,"Braccialetto Sportivo a LED MegaLed Rosso","Se
ti piace praticare la corsa, il ciclismo, o qualunque sport all'aria aperta, non può mancare tra i tuoi accessori il braccialetto per lo sport a LED MegaLed. Con questo braccialetto di sicurezza sarai visibile ai motorini e alle auto nell'oscurità, così da poter stare molto più sicuro e tranquillo. È dotato di 2 luci a LED con 2 possibili soluzioni (luce fissa ed intermittente). La lunghezza massima è di circa 55 cm e quella minima è di circa 42 cm. Molto leggero (circa 50 g). Autonomia circa: 24-40 ore. Funziona a batterie (2 x CR2023, incluse).
Dimenzioni per Braccialetto Sportivo a LED MegaLed:
Altezza: 3 Cm Larghezza: 20 Cm Profondita': 4 Cm Peso: 0.049 Kg Codice Prodotto (EAN): 8436545443507
","Se ti piace praticare la corsa, il ciclismo, o qualunque sport all'aria aperta, non può mancare tra i tuoi accessori il braccialetto per lo sport a LED MegaLed. Maggiori Informazioni ",0.049,1,"Taxable Goods","Catalog, Search",22,,,,Braccialetto-Sportivo-a-LED-MegaLed-Rosso,"Braccialetto Sportivo a LED MegaLed Rosso","Casa Giardino,Casa,Giardino,Decorazione e Illuminazione,Decorazione,Illuminazione,Illuminazione LED,Illuminazione,LED,Colore Rosso,Rosso,","Se ti piace praticare la corsa, il ciclismo, o qualunque sport all'aria aperta, non può mancare tra i tuoi accessori il braccialetto per lo sport a LED MegaLed",http://dropshipping.bigbuy.eu/imgs/G0500194_87774.jpg,,http://dropshipping.bigbuy.eu/imgs/G0500194_87774.jpg,,,,,,"2016-01-08 12:34:41",,,,,,,,,,,,,,,,,"GTIN=8436545443507",22,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/G0500194_87775.jpg,http://dropshipping.bigbuy.eu/imgs/G0500194_87773.jpg,http://dropshipping.bigbuy.eu/imgs/G0500194_87772.jpg","GTIN=8436545443507",,,,,,,,,,
+BB-G0500196,,Default,simple,"Default Category/Casa Giardino,Default Category/Casa Giardino/Decorazione e Illuminazione,Default Category/Casa Giardino/Decorazione e Illuminazione/Illuminazione LED",base,"Braccialetto Sportivo a LED MegaLed Verde","Se
ti piace praticare la corsa, il ciclismo, o qualunque sport all'aria aperta, non può mancare tra i tuoi accessori il braccialetto per lo sport a LED MegaLed. Con questo braccialetto di sicurezza sarai visibile ai motorini e alle auto nell'oscurità, così da poter stare molto più sicuro e tranquillo. È dotato di 2 luci a LED con 2 possibili soluzioni (luce fissa ed intermittente). La lunghezza massima è di circa 55 cm e quella minima è di circa 42 cm. Molto leggero (circa 50 g). Autonomia circa: 24-40 ore. Funziona a batterie (2 x CR2023, incluse).
Dimenzioni per Braccialetto Sportivo a LED MegaLed:
Altezza: 3 Cm Larghezza: 20 Cm Profondita': 4 Cm Peso: 0.049 Kg Codice Prodotto (EAN): 8436545443507
","Se ti piace praticare la corsa, il ciclismo, o qualunque sport all'aria aperta, non può mancare tra i tuoi accessori il braccialetto per lo sport a LED MegaLed. Maggiori Informazioni ",0.049,1,"Taxable Goods","Catalog, Search",22,,,,Braccialetto-Sportivo-a-LED-MegaLed-Verde,"Braccialetto Sportivo a LED MegaLed Verde","Casa Giardino,Casa,Giardino,Decorazione e Illuminazione,Decorazione,Illuminazione,Illuminazione LED,Illuminazione,LED,Colore Verde,Verde,","Se ti piace praticare la corsa, il ciclismo, o qualunque sport all'aria aperta, non può mancare tra i tuoi accessori il braccialetto per lo sport a LED MegaLed",http://dropshipping.bigbuy.eu/imgs/G0500194_87775.jpg,,http://dropshipping.bigbuy.eu/imgs/G0500194_87775.jpg,,,,,,"2016-01-08 12:34:41",,,,,,,,,,,,,,,,,"GTIN=8436545443507",37,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/G0500194_87774.jpg,http://dropshipping.bigbuy.eu/imgs/G0500194_87773.jpg,http://dropshipping.bigbuy.eu/imgs/G0500194_87772.jpg","GTIN=8436545443507",,,,,,,,,,
+BB-I2500333,,Default,simple,"Default Category/Casa Giardino,Default Category/Casa Giardino/Decorazione e Illuminazione,Default Category/Casa Giardino/Decorazione e Illuminazione/Orologi da parete e da tavolo",base,"Orologio da Parete Mom's Diner","Decora
la tua cucina con l'originale orologio da parete Mom's Diner in stile vintage! È realizzato in legno. Diametro: 58 cm circa. Spessore: 0,8 cm circa. Funziona a pile (1 x AA, non inclusa). Dimenzioni per Orologio da Parete Mom's Diner:
Altezza: 59 Cm Larghezza: 59 Cm Profondita': 6 Cm Peso: 2.1 Kg Codice Prodotto (EAN): 4029811345052
","Decora la tua cucina con l'originale orologio da parete Mom's Diner in stile vintage! È realizzato in legno. Maggiori Informazioni ",2.1,1,"Taxable Goods","Catalog, Search",42.5,,,,Orologio-da-Parete-Mom's-Diner,"Orologio da Parete Mom's Diner","Casa Giardino,Casa,Giardino,Decorazione e Illuminazione,Decorazione,Illuminazione,Orologi da parete e da tavolo,Orologi,parete,tavolo,","Decora la tua cucina con l'originale orologio da parete Mom's Diner in stile vintage! È realizzato in legno",http://dropshipping.bigbuy.eu/imgs/I2500333_88061.jpg,,http://dropshipping.bigbuy.eu/imgs/I2500333_88061.jpg,,,,,,"2016-07-21 13:05:12",,,,,,,,,,,,,,,,,"GTIN=4029811345052",2,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/I2500333_88060.jpg,http://dropshipping.bigbuy.eu/imgs/I2500333_88059.jpg,http://dropshipping.bigbuy.eu/imgs/I2500333_88058.jpg","GTIN=4029811345052",,,,,,,,,,
+BB-I2500334,,Default,simple,"Default Category/Casa Giardino,Default Category/Casa Giardino/Decorazione e Illuminazione,Default Category/Casa Giardino/Decorazione e Illuminazione/Orologi da parete e da tavolo",base,"Orologio da Parete Coffee Endless Cup","Se
sei un appassionato di caffè, non puoi rimanere senza l'orologio da parete Coffee Endless Cup ! Un orologio vintage in legno con un design in perfetto stile caffettoso! Diametro: 58 cm circa. Spessore: 0,8 cm circa. Funziona a pile (1 x AA, non inclusa). Dimenzioni per Orologio da Parete Coffee Endless Cup:
Altezza: 59 Cm Larghezza: 59 Cm Profondita': 6 Cm Peso: 2.1 Kg Codice Prodotto (EAN): 4029811345069
","Se sei un appassionato di caffè, non puoi rimanere senza l'orologio da parete Coffee Endless Cup! Un orologio vintage in legno con un design in perfetto stile caffettoso! Diametro: 58 cm circa. Maggiori Informazioni ",2.1,1,"Taxable Goods","Catalog, Search",42.5,,,,Orologio-da-Parete-Coffee-Endless-Cup,"Orologio da Parete Coffee Endless Cup","Casa Giardino,Casa,Giardino,Decorazione e Illuminazione,Decorazione,Illuminazione,Orologi da parete e da tavolo,Orologi,parete,tavolo,","Se sei un appassionato di caffè, non puoi rimanere senza l'orologio da parete Coffee Endless Cup! Un orologio vintage in legno con un design in perfetto stile caffettoso! Diametro: 58 cm circa",http://dropshipping.bigbuy.eu/imgs/I2500334_88065.jpg,,http://dropshipping.bigbuy.eu/imgs/I2500334_88065.jpg,,,,,,"2016-08-30 13:41:52",,,,,,,,,,,,,,,,,"GTIN=4029811345069",4,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/I2500334_88064.jpg,http://dropshipping.bigbuy.eu/imgs/I2500334_88063.jpg,http://dropshipping.bigbuy.eu/imgs/I2500334_88062.jpg","GTIN=4029811345069",,,,,,,,,,
+BB-V0000252,,Default,simple,"Default Category/Casa Giardino,Default Category/Casa Giardino/Decorazione e Illuminazione,Default Category/Casa Giardino/Decorazione e Illuminazione/Altri articoli decorativi",base,"Insegna Dito Vintage Look Stop!","Se
sei alla ricerca di una decorazione vintage originale e divertente per la tua casa, l'insegna dito Vintage Look ti conquisterà con il suo stile e i suoi simpatici messaggi! Realizzata in legno. Dimensioni: 69 x 17 x 1 cm circa. Dimenzioni per Insegna Dito Vintage Look:
Altezza: 17 Cm Larghezza: 69 Cm Profondita': 1 Cm Peso: 0.63 Kg Codice Prodotto (EAN): 4029811346196
","Se sei alla ricerca di una decorazione vintage originale e divertente per la tua casa, l'insegna dito Vintage Look ti conquisterà con il suo stile e i suoi simpatici messaggi! Realizzata in legno. Maggiori Informazioni ",0.63,1,"Taxable Goods","Catalog, Search",15.99,,,,Insegna-Dito-Vintage-Look-Stop!,"Insegna Dito Vintage Look Stop!","Casa Giardino,Casa,Giardino,Decorazione e Illuminazione,Decorazione,Illuminazione,Altri articoli decorativi,Altri,articoli,decorativi,Design Stop!,Stop!,","Se sei alla ricerca di una decorazione vintage originale e divertente per la tua casa, l'insegna dito Vintage Look ti conquisterà con il suo stile e i suoi simpatici messaggi! Realizzata in legno",http://dropshipping.bigbuy.eu/imgs/V0000251_89745.jpg,,http://dropshipping.bigbuy.eu/imgs/V0000251_89745.jpg,,,,,,"2016-02-29 09:49:10",,,,,,,,,,,,,,,,,"GTIN=4029811346196",21,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/V0000251_89746.jpg,http://dropshipping.bigbuy.eu/imgs/V0000251_89744.jpg,http://dropshipping.bigbuy.eu/imgs/V0000251_89743.jpg,http://dropshipping.bigbuy.eu/imgs/V0000251_89742.jpg,http://dropshipping.bigbuy.eu/imgs/V0000251_89741.jpg","GTIN=4029811346196",,,,,,,,,,
+BB-V0000253,,Default,simple,"Default Category/Casa Giardino,Default Category/Casa Giardino/Decorazione e Illuminazione,Default Category/Casa Giardino/Decorazione e Illuminazione/Altri articoli decorativi",base,"Insegna Dito Vintage Look Adults Only","Se
sei alla ricerca di una decorazione vintage originale e divertente per la tua casa, l'insegna dito Vintage Look ti conquisterà con il suo stile e i suoi simpatici messaggi! Realizzata in legno. Dimensioni: 69 x 17 x 1 cm circa. Dimenzioni per Insegna Dito Vintage Look:
Altezza: 17 Cm Larghezza: 69 Cm Profondita': 1 Cm Peso: 0.63 Kg Codice Prodotto (EAN): 4029811346202
","Se sei alla ricerca di una decorazione vintage originale e divertente per la tua casa, l'insegna dito Vintage Look ti conquisterà con il suo stile e i suoi simpatici messaggi! Realizzata in legno. Maggiori Informazioni ",0.63,1,"Taxable Goods","Catalog, Search",15.99,,,,Insegna-Dito-Vintage-Look-Adults Only,"Insegna Dito Vintage Look Adults Only","Casa Giardino,Casa,Giardino,Decorazione e Illuminazione,Decorazione,Illuminazione,Altri articoli decorativi,Altri,articoli,decorativi,Design Adults Only,Adults Only,","Se sei alla ricerca di una decorazione vintage originale e divertente per la tua casa, l'insegna dito Vintage Look ti conquisterà con il suo stile e i suoi simpatici messaggi! Realizzata in legno",http://dropshipping.bigbuy.eu/imgs/V0000251_89746.jpg,,http://dropshipping.bigbuy.eu/imgs/V0000251_89746.jpg,,,,,,"2016-02-29 09:49:10",,,,,,,,,,,,,,,,,"GTIN=4029811346202",18,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/V0000251_89745.jpg,http://dropshipping.bigbuy.eu/imgs/V0000251_89744.jpg,http://dropshipping.bigbuy.eu/imgs/V0000251_89743.jpg,http://dropshipping.bigbuy.eu/imgs/V0000251_89742.jpg,http://dropshipping.bigbuy.eu/imgs/V0000251_89741.jpg","GTIN=4029811346202",,,,,,,,,,
+BB-V0000254,,Default,simple,"Default Category/Casa Giardino,Default Category/Casa Giardino/Decorazione e Illuminazione,Default Category/Casa Giardino/Decorazione e Illuminazione/Altri articoli decorativi",base,"Insegna Dito Vintage Look Talk","Se
sei alla ricerca di una decorazione vintage originale e divertente per la tua casa, l'insegna dito Vintage Look ti conquisterà con il suo stile e i suoi simpatici messaggi! Realizzata in legno. Dimensioni: 69 x 17 x 1 cm circa. Dimenzioni per Insegna Dito Vintage Look:
Altezza: 17 Cm Larghezza: 69 Cm Profondita': 1 Cm Peso: 0.63 Kg Codice Prodotto (EAN): 4029811346318
","Se sei alla ricerca di una decorazione vintage originale e divertente per la tua casa, l'insegna dito Vintage Look ti conquisterà con il suo stile e i suoi simpatici messaggi! Realizzata in legno. Maggiori Informazioni ",0.63,1,"Taxable Goods","Catalog, Search",15.99,,,,Insegna-Dito-Vintage-Look-Talk,"Insegna Dito Vintage Look Talk","Casa Giardino,Casa,Giardino,Decorazione e Illuminazione,Decorazione,Illuminazione,Altri articoli decorativi,Altri,articoli,decorativi,Design Talk,Talk,","Se sei alla ricerca di una decorazione vintage originale e divertente per la tua casa, l'insegna dito Vintage Look ti conquisterà con il suo stile e i suoi simpatici messaggi! Realizzata in legno",http://dropshipping.bigbuy.eu/imgs/V0000251_89744.jpg,,http://dropshipping.bigbuy.eu/imgs/V0000251_89744.jpg,,,,,,"2016-02-29 09:49:10",,,,,,,,,,,,,,,,,"GTIN=4029811346318",8,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/V0000251_89745.jpg,http://dropshipping.bigbuy.eu/imgs/V0000251_89746.jpg,http://dropshipping.bigbuy.eu/imgs/V0000251_89743.jpg,http://dropshipping.bigbuy.eu/imgs/V0000251_89742.jpg,http://dropshipping.bigbuy.eu/imgs/V0000251_89741.jpg","GTIN=4029811346318",,,,,,,,,,
+BB-V0000256,,Default,simple,"Default Category/Casa Giardino,Default Category/Casa Giardino/Decorazione e Illuminazione,Default Category/Casa Giardino/Decorazione e Illuminazione/Altri articoli decorativi",base,"Freccia Decorativa Vintage Look Go Left","Stupisci
tutti con la divertente ed originale freccia decorativa Vintage Look ! Le pareti di casa tua non resteranno indifferenti a nessuno! Fabbricata in legno. Misure appross.: 25 x 40 x 1 cm. Dimenzioni per Freccia Decorativa Vintage Look:
Altezza: 25.5 Cm Larghezza: 0.8 Cm Profondita': 40 Cm Peso: 0.376 Kg Codice Prodotto (EAN): 4029811346325
","Stupisci tutti con la divertente ed originale freccia decorativa Vintage Look! Le pareti di casa tua non resteranno indifferenti a nessuno! Fabbricata in legno. Maggiori Informazioni ",0.376,1,"Taxable Goods","Catalog, Search",13.9,,,,Freccia-Decorativa-Vintage-Look-Go Left,"Freccia Decorativa Vintage Look Go Left","Casa Giardino,Casa,Giardino,Decorazione e Illuminazione,Decorazione,Illuminazione,Altri articoli decorativi,Altri,articoli,decorativi,Design Go Left,Go Left,","Stupisci tutti con la divertente ed originale freccia decorativa Vintage Look! Le pareti di casa tua non resteranno indifferenti a nessuno! Fabbricata in legno",http://dropshipping.bigbuy.eu/imgs/V0000255_89756.jpg,,http://dropshipping.bigbuy.eu/imgs/V0000255_89756.jpg,,,,,,"2016-02-29 10:39:59",,,,,,,,,,,,,,,,,"GTIN=4029811346325",4,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/V0000255_89761.jpg,http://dropshipping.bigbuy.eu/imgs/V0000255_89760.jpg,http://dropshipping.bigbuy.eu/imgs/V0000255_89759.jpg,http://dropshipping.bigbuy.eu/imgs/V0000255_89758.jpg,http://dropshipping.bigbuy.eu/imgs/V0000255_89757.jpg","GTIN=4029811346325",,,,,,,,,,
+BB-V0000257,,Default,simple,"Default Category/Casa Giardino,Default Category/Casa Giardino/Decorazione e Illuminazione,Default Category/Casa Giardino/Decorazione e Illuminazione/Altri articoli decorativi",base,"Freccia Decorativa Vintage Look Exit","Stupisci
tutti con la divertente ed originale freccia decorativa Vintage Look ! Le pareti di casa tua non resteranno indifferenti a nessuno! Fabbricata in legno. Misure appross.: 25 x 40 x 1 cm. Dimenzioni per Freccia Decorativa Vintage Look:
Altezza: 25.5 Cm Larghezza: 0.8 Cm Profondita': 40 Cm Peso: 0.376 Kg Codice Prodotto (EAN): 4029811346332
","Stupisci tutti con la divertente ed originale freccia decorativa Vintage Look! Le pareti di casa tua non resteranno indifferenti a nessuno! Fabbricata in legno. Maggiori Informazioni ",0.376,1,"Taxable Goods","Catalog, Search",13.9,,,,Freccia-Decorativa-Vintage-Look-Exit,"Freccia Decorativa Vintage Look Exit","Casa Giardino,Casa,Giardino,Decorazione e Illuminazione,Decorazione,Illuminazione,Altri articoli decorativi,Altri,articoli,decorativi,Design Exit,Exit,","Stupisci tutti con la divertente ed originale freccia decorativa Vintage Look! Le pareti di casa tua non resteranno indifferenti a nessuno! Fabbricata in legno",http://dropshipping.bigbuy.eu/imgs/V0000255_89761.jpg,,http://dropshipping.bigbuy.eu/imgs/V0000255_89761.jpg,,,,,,"2016-02-29 10:39:59",,,,,,,,,,,,,,,,,"GTIN=4029811346332",19,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/V0000255_89756.jpg,http://dropshipping.bigbuy.eu/imgs/V0000255_89760.jpg,http://dropshipping.bigbuy.eu/imgs/V0000255_89759.jpg,http://dropshipping.bigbuy.eu/imgs/V0000255_89758.jpg,http://dropshipping.bigbuy.eu/imgs/V0000255_89757.jpg","GTIN=4029811346332",,,,,,,,,,
+BB-V0000258,,Default,simple,"Default Category/Casa Giardino,Default Category/Casa Giardino/Decorazione e Illuminazione,Default Category/Casa Giardino/Decorazione e Illuminazione/Altri articoli decorativi",base,"Freccia Decorativa Vintage Look Cold beer here","Stupisci
tutti con la divertente ed originale freccia decorativa Vintage Look ! Le pareti di casa tua non resteranno indifferenti a nessuno! Fabbricata in legno. Misure appross.: 25 x 40 x 1 cm. Dimenzioni per Freccia Decorativa Vintage Look:
Altezza: 25.5 Cm Larghezza: 0.8 Cm Profondita': 40 Cm Peso: 0.376 Kg Codice Prodotto (EAN): 4029811346349
","Stupisci tutti con la divertente ed originale freccia decorativa Vintage Look! Le pareti di casa tua non resteranno indifferenti a nessuno! Fabbricata in legno. Maggiori Informazioni ",0.376,1,"Taxable Goods","Catalog, Search",13.9,,,,Freccia-Decorativa-Vintage-Look-Cold beer here,"Freccia Decorativa Vintage Look Cold beer here","Casa Giardino,Casa,Giardino,Decorazione e Illuminazione,Decorazione,Illuminazione,Altri articoli decorativi,Altri,articoli,decorativi,Design Cold beer here,Cold beer here,","Stupisci tutti con la divertente ed originale freccia decorativa Vintage Look! Le pareti di casa tua non resteranno indifferenti a nessuno! Fabbricata in legno",http://dropshipping.bigbuy.eu/imgs/V0000255_89760.jpg,,http://dropshipping.bigbuy.eu/imgs/V0000255_89760.jpg,,,,,,"2016-02-29 10:39:59",,,,,,,,,,,,,,,,,"GTIN=4029811346349",20,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/V0000255_89756.jpg,http://dropshipping.bigbuy.eu/imgs/V0000255_89761.jpg,http://dropshipping.bigbuy.eu/imgs/V0000255_89759.jpg,http://dropshipping.bigbuy.eu/imgs/V0000255_89758.jpg,http://dropshipping.bigbuy.eu/imgs/V0000255_89757.jpg","GTIN=4029811346349",,,,,,,,,,
+BB-V0200190,,Default,simple,"Default Category/Casa Giardino,Default Category/Casa Giardino/Decorazione e Illuminazione,Default Category/Casa Giardino/Decorazione e Illuminazione/Centrotavola e Vasi",base,"Ciotola in Bambù TakeTokio Bianco","Arricchisci
la selezione dei tuoi utensili da cucina con la ciotola in bambù TakeTokio , una ciotola da cucina funzionale e dal design moderno è perfetta come insalatiera , portafrutta, ecc. Realizzata in pregiato legno di bambù. Dimensioni (diametro x altezza): 25 x 15 cm circa. Diametro della base: 9 cm circa.www.taketokio.com
Dimenzioni per Ciotola in Bambù TakeTokio:
Altezza: 25 Cm Larghezza: 25 Cm Profondita': 15 Cm Peso: 0.39 Kg Codice Prodotto (EAN): 8718158904577
","Arricchisci la selezione dei tuoi utensili da cucina con la ciotola in bambù TakeTokio, una ciotola da cucina funzionale e dal design moderno è perfetta come insalatiera, portafrutta, ecc. Maggiori Informazioni ",0.39,1,"Taxable Goods","Catalog, Search",19.8,,,,Ciotola-in-Bambù-TakeTokio-Bianco,"Ciotola in Bambù TakeTokio Bianco","Casa Giardino,Casa,Giardino,Decorazione e Illuminazione,Decorazione,Illuminazione,Centrotavola e Vasi,Centrotavola,Vasi,Colore Bianco,Bianco,","Arricchisci la selezione dei tuoi utensili da cucina con la ciotola in bambù TakeTokio, una ciotola da cucina funzionale e dal design moderno è perfetta come insalatiera, portafrutta, ecc",http://dropshipping.bigbuy.eu/imgs/V0200189_90746.jpg,,http://dropshipping.bigbuy.eu/imgs/V0200189_90746.jpg,,,,,,"-0001-11-30 00:00:00",,,,,,,,,,,,,,,,,"GTIN=8718158904577",0,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/V0200189_90747.jpg,http://dropshipping.bigbuy.eu/imgs/V0200189_90745.jpg,http://dropshipping.bigbuy.eu/imgs/V0200189_90744.jpg,http://dropshipping.bigbuy.eu/imgs/V0200189_90743.jpg,http://dropshipping.bigbuy.eu/imgs/V0200189_90742.jpg","GTIN=8718158904577",,,,,,,,,,
+BB-V0200192,,Default,simple,"Default Category/Casa Giardino,Default Category/Casa Giardino/Decorazione e Illuminazione,Default Category/Casa Giardino/Decorazione e Illuminazione/Centrotavola e Vasi",base,"Ciotola in Bambù TakeTokio Grigio","Arricchisci
la selezione dei tuoi utensili da cucina con la ciotola in bambù TakeTokio , una ciotola da cucina funzionale e dal design moderno è perfetta come insalatiera , portafrutta, ecc. Realizzata in pregiato legno di bambù. Dimensioni (diametro x altezza): 25 x 15 cm circa. Diametro della base: 9 cm circa.www.taketokio.com
Dimenzioni per Ciotola in Bambù TakeTokio:
Altezza: 25 Cm Larghezza: 25 Cm Profondita': 15 Cm Peso: 0.39 Kg Codice Prodotto (EAN): 8718158904577
","Arricchisci la selezione dei tuoi utensili da cucina con la ciotola in bambù TakeTokio, una ciotola da cucina funzionale e dal design moderno è perfetta come insalatiera, portafrutta, ecc. Maggiori Informazioni ",0.39,1,"Taxable Goods","Catalog, Search",19.8,,,,Ciotola-in-Bambù-TakeTokio-Grigio,"Ciotola in Bambù TakeTokio Grigio","Casa Giardino,Casa,Giardino,Decorazione e Illuminazione,Decorazione,Illuminazione,Centrotavola e Vasi,Centrotavola,Vasi,Colore Grigio,Grigio,","Arricchisci la selezione dei tuoi utensili da cucina con la ciotola in bambù TakeTokio, una ciotola da cucina funzionale e dal design moderno è perfetta come insalatiera, portafrutta, ecc",http://dropshipping.bigbuy.eu/imgs/V0200189_90747.jpg,,http://dropshipping.bigbuy.eu/imgs/V0200189_90747.jpg,,,,,,"-0001-11-30 00:00:00",,,,,,,,,,,,,,,,,"GTIN=8718158904577",26,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/V0200189_90746.jpg,http://dropshipping.bigbuy.eu/imgs/V0200189_90745.jpg,http://dropshipping.bigbuy.eu/imgs/V0200189_90744.jpg,http://dropshipping.bigbuy.eu/imgs/V0200189_90743.jpg,http://dropshipping.bigbuy.eu/imgs/V0200189_90742.jpg","GTIN=8718158904577",,,,,,,,,,
+BB-V0200191,,Default,simple,"Default Category/Casa Giardino,Default Category/Casa Giardino/Decorazione e Illuminazione,Default Category/Casa Giardino/Decorazione e Illuminazione/Centrotavola e Vasi",base,"Ciotola in Bambù TakeTokio Nero","Arricchisci
la selezione dei tuoi utensili da cucina con la ciotola in bambù TakeTokio , una ciotola da cucina funzionale e dal design moderno è perfetta come insalatiera , portafrutta, ecc. Realizzata in pregiato legno di bambù. Dimensioni (diametro x altezza): 25 x 15 cm circa. Diametro della base: 9 cm circa.www.taketokio.com
Dimenzioni per Ciotola in Bambù TakeTokio:
Altezza: 25 Cm Larghezza: 25 Cm Profondita': 15 Cm Peso: 0.39 Kg Codice Prodotto (EAN): 8718158904577
","Arricchisci la selezione dei tuoi utensili da cucina con la ciotola in bambù TakeTokio, una ciotola da cucina funzionale e dal design moderno è perfetta come insalatiera, portafrutta, ecc. Maggiori Informazioni ",0.39,1,"Taxable Goods","Catalog, Search",19.8,,,,Ciotola-in-Bambù-TakeTokio-Nero,"Ciotola in Bambù TakeTokio Nero","Casa Giardino,Casa,Giardino,Decorazione e Illuminazione,Decorazione,Illuminazione,Centrotavola e Vasi,Centrotavola,Vasi,Colore Nero,Nero,","Arricchisci la selezione dei tuoi utensili da cucina con la ciotola in bambù TakeTokio, una ciotola da cucina funzionale e dal design moderno è perfetta come insalatiera, portafrutta, ecc",http://dropshipping.bigbuy.eu/imgs/V0200189_90745.jpg,,http://dropshipping.bigbuy.eu/imgs/V0200189_90745.jpg,,,,,,"-0001-11-30 00:00:00",,,,,,,,,,,,,,,,,"GTIN=8718158904577",22,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/V0200189_90746.jpg,http://dropshipping.bigbuy.eu/imgs/V0200189_90747.jpg,http://dropshipping.bigbuy.eu/imgs/V0200189_90744.jpg,http://dropshipping.bigbuy.eu/imgs/V0200189_90743.jpg,http://dropshipping.bigbuy.eu/imgs/V0200189_90742.jpg","GTIN=8718158904577",,,,,,,,,,
+BB-V0200360,,Default,simple,"Default Category/Casa Giardino,Default Category/Casa Giardino/Arredamento,Default Category/Casa Giardino/Arredamento/Soluzioni per Organizzare",base,"Scatola porta Tè Flower Vintage Coconut Rosa","Gli
amanti della moda vintage non potranno resistere di fronte all'adorabile scatola porta tè Flower Vintage Coconut ! Una scatola vintage in legno ottima come decorazione e utilissima per sistemare le bustine di tè o di altri infusi. Dispone di un coperchio in cristallo e vari scompartimenti. Dimensioni: circa 23 x 7 x 23 cm.www.vintagecoconut.com
Dimenzioni per Scatola porta Tè Flower Vintage Coconut:
Altezza: 23 Cm Larghezza: 7.1 Cm Profondita': 23 Cm Peso: 0.795 Kg Codice Prodotto (EAN): 8711295889547
","Gli amanti della moda vintage non potranno resistere di fronte all'adorabile scatola porta tè Flower Vintage Coconut! Una scatola vintage in legno ottima come decorazione e utilissima per sistemare le bustine di tè o di altri infusi. Maggiori Informazioni ",0.795,1,"Taxable Goods","Catalog, Search",25.9,,,,Scatola-porta-Tè-Flower-Vintage-Coconut-Rosa,"Scatola porta Tè Flower Vintage Coconut Rosa","Casa Giardino,Casa,Giardino,Arredamento,Soluzioni per Organizzare,Soluzioni,Organizzare,Colore Rosa,Rosa,","Gli amanti della moda vintage non potranno resistere di fronte all'adorabile scatola porta tè Flower Vintage Coconut! Una scatola vintage in legno ottima come decorazione e utilissima per sistemare le bustine di tè o di altri infusi",http://dropshipping.bigbuy.eu/imgs/V0200328_92649.jpg,,http://dropshipping.bigbuy.eu/imgs/V0200328_92649.jpg,,,,,,"-0001-11-30 00:00:00",,,,,,,,,,,,,,,,,"GTIN=8711295889547",13,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/V0200328_92648.jpg,http://dropshipping.bigbuy.eu/imgs/V0200328_92647.jpg","GTIN=8711295889547",,,,,,,,,,
+BB-V0200361,,Default,simple,"Default Category/Casa Giardino,Default Category/Casa Giardino/Arredamento,Default Category/Casa Giardino/Arredamento/Soluzioni per Organizzare",base,"Scatola porta Tè Flower Vintage Coconut Azzurro","Gli
amanti della moda vintage non potranno resistere di fronte all'adorabile scatola porta tè Flower Vintage Coconut ! Una scatola vintage in legno ottima come decorazione e utilissima per sistemare le bustine di tè o di altri infusi. Dispone di un coperchio in cristallo e vari scompartimenti. Dimensioni: circa 23 x 7 x 23 cm.www.vintagecoconut.com
Dimenzioni per Scatola porta Tè Flower Vintage Coconut:
Altezza: 23 Cm Larghezza: 7.1 Cm Profondita': 23 Cm Peso: 0.795 Kg Codice Prodotto (EAN): 8711295889547
","Gli amanti della moda vintage non potranno resistere di fronte all'adorabile scatola porta tè Flower Vintage Coconut! Una scatola vintage in legno ottima come decorazione e utilissima per sistemare le bustine di tè o di altri infusi. Maggiori Informazioni ",0.795,1,"Taxable Goods","Catalog, Search",25.9,,,,Scatola-porta-Tè-Flower-Vintage-Coconut-Azzurro,"Scatola porta Tè Flower Vintage Coconut Azzurro","Casa Giardino,Casa,Giardino,Arredamento,Soluzioni per Organizzare,Soluzioni,Organizzare,Colore Azzurro,Azzurro,","Gli amanti della moda vintage non potranno resistere di fronte all'adorabile scatola porta tè Flower Vintage Coconut! Una scatola vintage in legno ottima come decorazione e utilissima per sistemare le bustine di tè o di altri infusi",http://dropshipping.bigbuy.eu/imgs/V0200328_92648.jpg,,http://dropshipping.bigbuy.eu/imgs/V0200328_92648.jpg,,,,,,"-0001-11-30 00:00:00",,,,,,,,,,,,,,,,,"GTIN=8711295889547",21,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/V0200328_92649.jpg,http://dropshipping.bigbuy.eu/imgs/V0200328_92647.jpg","GTIN=8711295889547",,,,,,,,,,
+BB-V0200353,,Default,simple,"Default Category/Casa Giardino,Default Category/Casa Giardino/Giardino e Terrazza,Default Category/Casa Giardino/Giardino e Terrazza/Barbecue",base,"Ventilatore a Pistola classico per Barbecue BBQ Classics","Utilizza
i migliori barbecue alimentando il fuoco con il ventilatore a pistola classico per babecue BBQ Classics ! Basterà solo fare una leggera pressione sul pulsante per far uscire l'aria.www.bbqclassics.com
Realizzato in plastica e metallo Dimensioni: 25 x 18 x 4 cm circa Dimenzioni per Ventilatore a Pistola classico per Barbecue BBQ Classics:
Altezza: 5.5 Cm Larghezza: 11 Cm Profondita': 22 Cm Peso: 0.167 Kg Codice Prodotto (EAN): 8718158032706
","Utilizza i migliori barbecue alimentando il fuoco con il ventilatore a pistola classico per babecue BBQ Classics! Basterà solo fare una leggera pressione sul pulsante per far uscire l'aria. Maggiori Informazioni ",0.167,1,"Taxable Goods","Catalog, Search",9.3,,,,Ventilatore-a-Pistola-classico-per-Barbecue-BBQ-Classics,"Ventilatore a Pistola classico per Barbecue BBQ Classics","Casa Giardino,Casa,Giardino,Giardino e Terrazza,Giardino,Terrazza,Barbecue,","Utilizza i migliori barbecue alimentando il fuoco con il ventilatore a pistola classico per babecue BBQ Classics! Basterà solo fare una leggera pressione sul pulsante per far uscire l'aria",http://dropshipping.bigbuy.eu/imgs/V0200353_92695.jpg,,http://dropshipping.bigbuy.eu/imgs/V0200353_92695.jpg,,,,,,"2016-09-13 09:56:07",,,,,,,,,,,,,,,,,"GTIN=8718158032706",60,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/V0200353_92696.jpg,http://dropshipping.bigbuy.eu/imgs/V0200353_92694.jpg","GTIN=8718158032706",,,,,,,,,,
+BB-V1600123,,Default,simple,"Default Category/Casa Giardino,Default Category/Casa Giardino/Arredamento,Default Category/Casa Giardino/Arredamento/Soluzioni per Organizzare",base,"Contenitore Portagiochi Frozen (32 x 23 cm)","Non
c'è nulla di meglio che tenere le camere dei più piccini in ordine in modo originale e divertente. Con il contenitore portagiochi Frozen (32 x 23 cm) sarà semplicissimo!Realizzato in polipropilene Dimensioni aprossimative: 32 x 15 x 23 cm Età consigliata: +3 anni
Dimenzioni per Contenitore Portagiochi Frozen (32 x 23 cm):
Altezza: 15 Cm Larghezza: 34 Cm Profondita': 23 Cm Peso: 0.331 Kg Codice Prodotto (EAN): 8412842766006
","Non c'è nulla di meglio che tenere le camere dei più piccini in ordine in modo originale e divertente. Maggiori Informazioni ",0.331,1,"Taxable Goods","Catalog, Search",21.9,,,,Contenitore-Portagiochi-Frozen-(32-x-23-cm),"Contenitore Portagiochi Frozen (32 x 23 cm)","Casa Giardino,Casa,Giardino,Arredamento,Soluzioni per Organizzare,Soluzioni,Organizzare,","Non c'è nulla di meglio che tenere le camere dei più piccini in ordine in modo originale e divertente",http://dropshipping.bigbuy.eu/imgs/V1600123_93002.jpg,,http://dropshipping.bigbuy.eu/imgs/V1600123_93002.jpg,,,,,,"2016-08-08 21:04:27",,,,,,,,,,,,,,,,,"GTIN=8412842766006",48,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/V1600123_93005.jpg,http://dropshipping.bigbuy.eu/imgs/V1600123_93004.jpg,http://dropshipping.bigbuy.eu/imgs/V1600123_93003.jpg","GTIN=8412842766006",,,,,,,,,,
+BB-V1600124,,Default,simple,"Default Category/Casa Giardino,Default Category/Casa Giardino/Arredamento,Default Category/Casa Giardino/Arredamento/Soluzioni per Organizzare",base,"Contenitore Portagiochi Spiderman (32 x 23 cm)","Desideri
sorprendere i più piccini con un regalo molto originale? Il contenitore portagiochi Spiderman (32 x 23 cm) decorerà e metterà in ordine le loro camerette.Realizzato in polipropilene Dimensioni approssimative: 32 x 15 x 23 cm Età consigliata: +3 anni Dimenzioni per Contenitore Portagiochi Spiderman (32 x 23 cm):
Altezza: 15 Cm Larghezza: 34 Cm Profondita': 23 Cm Peso: 0.331 Kg Codice Prodotto (EAN): 8412842766037
","Desideri sorprendere i più piccini con un regalo molto originale? Il contenitore portagiochi Spiderman (32 x 23 cm) decorerà e metterà in ordine le loro camerette. Maggiori Informazioni ",0.331,1,"Taxable Goods","Catalog, Search",21.9,,,,Contenitore-Portagiochi-Spiderman--(32-x-23-cm),"Contenitore Portagiochi Spiderman (32 x 23 cm)","Casa Giardino,Casa,Giardino,Arredamento,Soluzioni per Organizzare,Soluzioni,Organizzare,","Desideri sorprendere i più piccini con un regalo molto originale? Il contenitore portagiochi Spiderman (32 x 23 cm) decorerà e metterà in ordine le loro camerette",http://dropshipping.bigbuy.eu/imgs/V1600124_93006.jpg,,http://dropshipping.bigbuy.eu/imgs/V1600124_93006.jpg,,,,,,"2016-08-08 21:09:24",,,,,,,,,,,,,,,,,"GTIN=8412842766037",52,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/V1600124_93008.jpg,http://dropshipping.bigbuy.eu/imgs/V1600124_93007.jpg","GTIN=8412842766037",,,,,,,,,,
+BB-V1600125,,Default,simple,"Default Category/Casa Giardino,Default Category/Casa Giardino/Arredamento,Default Category/Casa Giardino/Arredamento/Soluzioni per Organizzare",base,"Contenitore Portagiochi Frozen (45 x 32 cm)","Insegna
ai tuoi bambini a tenere i giocattoli conservati ben in ordine con l'aiuto del contenitore portagiochi Frozen (45 x 32 cm) . Il portagiocattoli che tutte le bambine sognano!Realizzato in polipropilene Dimensioni: circa 45 x 22 x 32 cm Età consigliata: +3 anni Dimenzioni per Contenitore Portagiochi Frozen (45 x 32 cm):
Altezza: 22 Cm Larghezza: 37 Cm Profondita': 45 Cm Peso: 0.775 Kg Codice Prodotto (EAN): 8412842766129
","Insegna ai tuoi bambini a tenere i giocattoli conservati ben in ordine con l'aiuto del contenitore portagiochi Frozen (45 x 32 cm). Maggiori Informazioni ",0.775,1,"Taxable Goods","Catalog, Search",39.6,,,,Contenitore-Portagiochi-Frozen-(45-x-32-cm),"Contenitore Portagiochi Frozen (45 x 32 cm)","Casa Giardino,Casa,Giardino,Arredamento,Soluzioni per Organizzare,Soluzioni,Organizzare,","Insegna ai tuoi bambini a tenere i giocattoli conservati ben in ordine con l'aiuto del contenitore portagiochi Frozen (45 x 32 cm)",http://dropshipping.bigbuy.eu/imgs/V1600125_93010.jpg,,http://dropshipping.bigbuy.eu/imgs/V1600125_93010.jpg,,,,,,"2016-08-08 21:04:27",,,,,,,,,,,,,,,,,"GTIN=8412842766129",17,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/V1600125_93011.jpg,http://dropshipping.bigbuy.eu/imgs/V1600125_93009.jpg","GTIN=8412842766129",,,,,,,,,,
+BB-V1600126,,Default,simple,"Default Category/Casa Giardino,Default Category/Casa Giardino/Arredamento,Default Category/Casa Giardino/Arredamento/Soluzioni per Organizzare",base,"Contenitore Portagiochi Spiderman (45 x 32 cm)","I
piccoli di casa ora possono ordinare e riporre i loro giocattoli facilmente grazie al contenitore portagiochi Spiderman (45 x 32 cm) . Il contenitore portagiochi preferito dai bambini!Fabbricato in polipropilene Dimensioni: circa 45 x 22 x 32 cm Età raccomandata: +3 anni Dimenzioni per Contenitore Portagiochi Spiderman (45 x 32 cm):
Altezza: 22 Cm Larghezza: 37 Cm Profondita': 45 Cm Peso: 0.775 Kg Codice Prodotto (EAN): 8412842766150
","I piccoli di casa ora possono ordinare e riporre i loro giocattoli facilmente grazie al contenitore portagiochi Spiderman (45 x 32 cm). Maggiori Informazioni ",0.775,1,"Taxable Goods","Catalog, Search",39.6,,,,Contenitore-Portagiochi-Spiderman-(45-x-32-cm),"Contenitore Portagiochi Spiderman (45 x 32 cm)","Casa Giardino,Casa,Giardino,Arredamento,Soluzioni per Organizzare,Soluzioni,Organizzare,","I piccoli di casa ora possono ordinare e riporre i loro giocattoli facilmente grazie al contenitore portagiochi Spiderman (45 x 32 cm)",http://dropshipping.bigbuy.eu/imgs/V1600126_93012.jpg,,http://dropshipping.bigbuy.eu/imgs/V1600126_93012.jpg,,,,,,"2016-08-08 21:09:24",,,,,,,,,,,,,,,,,"GTIN=8412842766150",18,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/V1600126_93014.jpg,http://dropshipping.bigbuy.eu/imgs/V1600126_93013.jpg","GTIN=8412842766150",,,,,,,,,,
+BB-V1300154,,Default,simple,"Default Category/Relax Tempo Libero,Default Category/Relax Tempo Libero/Mare e Piscina",base,"Zaino per Piscina Spiderman (4 pezzi)","Vorresti
sorprendere i più piccoli della casa con un regalo originale ? Se adorano il mare o la piscina, lo zaino per piscina Spiderman (4 pezzi) li farà impazzire.Dispone di una cerniera, una rete posteriore e uno scompartimento per il nome Dispone di manico regolabile 1 asciugamano 42,5 x 90,5 cm (80 % poliestere e 20 % poliammide) dall'asciugatura rapida 1 cuffia da nuoto taglia unica (85 % poliestere e 15 % elastam) 1 paio di occhialini da nuoto (norme 89/686/CEE e ISO 12312-1:2013) anti appannamento Dimensioni dello zaino: 24 x 31 x 6 cm circa Dimenzioni per Zaino per Piscina Spiderman (4 pezzi):
Altezza: 3 Cm Larghezza: 25 Cm Profondita': 30.5 Cm Peso: 0.283 Kg Codice Prodotto (EAN): 7569000752232
","Vorresti sorprendere i più piccoli della casa con un regalo originale? Se adorano il mare o la piscina, lo zaino per piscina Spiderman (4 pezzi) li farà impazzire. Maggiori Informazioni ",0.283,1,"Taxable Goods","Catalog, Search",37.9,,,,Zaino-per-Piscina-Spiderman-(4-pezzi),"Zaino per Piscina Spiderman (4 pezzi)","Relax Tempo Libero,Relax,Tempo,Libero,Mare e Piscina,Mare,Piscina,","Vorresti sorprendere i più piccoli della casa con un regalo originale? Se adorano il mare o la piscina, lo zaino per piscina Spiderman (4 pezzi) li farà impazzire",http://dropshipping.bigbuy.eu/imgs/V1300154_93570.jpg,,http://dropshipping.bigbuy.eu/imgs/V1300154_93570.jpg,,,,,,"2016-08-16 13:42:17",,,,,,,,,,,,,,,,,"GTIN=7569000752232",129,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/V1300154_93576.jpg,http://dropshipping.bigbuy.eu/imgs/V1300154_93575.jpg,http://dropshipping.bigbuy.eu/imgs/V1300154_93574.jpg,http://dropshipping.bigbuy.eu/imgs/V1300154_93573.jpg,http://dropshipping.bigbuy.eu/imgs/V1300154_93572.jpg,http://dropshipping.bigbuy.eu/imgs/V1300154_93571.jpg","GTIN=7569000752232",,,,,,,,,,
+BB-V1300156,,Default,simple,"Default Category/Relax Tempo Libero,Default Category/Relax Tempo Libero/Mare e Piscina",base,"Zaino per Piscina Frozen (4 pezzi)","Vuoi
fare un regalo originale ai piccoli di casa? Se adorano il mare o la piscina, lo zaino per piscina Frozen (4 pezzi) li farà impazzire.Presenta una cerniera, una rete posteriore e uno scompartimento per il nome Dispone di manico regolabile 1 asciugamano 42,5 x 90,5 cm (80 % poliestere e 20 % poliammide) dall'asciugatura rapida 1 cuffia da nuoto taglia unica (85 % poliestere e 15 % elastam) 1 paio di occhialini da nuoto (norme 89/686/CEE e ISO 12312-1:2013) anti appannamento Dimensioni dello zaino: circa 24 x 31 x 6 cm Dimenzioni per Zaino per Piscina Frozen (4 pezzi):
Altezza: 2 Cm Larghezza: 23 Cm Profondita': 30.5 Cm Peso: 0.277 Kg Codice Prodotto (EAN): 7569000752225
","Vuoi fare un regalo originale ai piccoli di casa? Se adorano il mare o la piscina, lo zaino per piscina Frozen (4 pezzi) li farà impazzire. Maggiori Informazioni ",0.277,1,"Taxable Goods","Catalog, Search",37.9,,,,Zaino-per-Piscina-Frozen-(4-pezzi),"Zaino per Piscina Frozen (4 pezzi)","Relax Tempo Libero,Relax,Tempo,Libero,Mare e Piscina,Mare,Piscina,","Vuoi fare un regalo originale ai piccoli di casa? Se adorano il mare o la piscina, lo zaino per piscina Frozen (4 pezzi) li farà impazzire",http://dropshipping.bigbuy.eu/imgs/V1300156_93580.jpg,,http://dropshipping.bigbuy.eu/imgs/V1300156_93580.jpg,,,,,,"2016-08-26 13:31:11",,,,,,,,,,,,,,,,,"GTIN=7569000752225",104,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/V1300156_93594.jpg,http://dropshipping.bigbuy.eu/imgs/V1300156_93585.jpg,http://dropshipping.bigbuy.eu/imgs/V1300156_93584.jpg,http://dropshipping.bigbuy.eu/imgs/V1300156_93583.jpg,http://dropshipping.bigbuy.eu/imgs/V1300156_93582.jpg,http://dropshipping.bigbuy.eu/imgs/V1300156_93581.jpg","GTIN=7569000752225",,,,,,,,,,
+BB-V1300157,,Default,simple,"Default Category/Relax Tempo Libero,Default Category/Relax Tempo Libero/Mare e Piscina",base,"Zaino per Piscina Minnie (4 pezzi)","Ti
piacerebbe sorprendere le bimbe della casa con un regalo originale ? Se adorano il mare o la piscina, lo zaino per piscina Minnie (4 pezzi) le farà impazzire.Dispone di una cerniera, una rete posteriore e uno scompartimento per il nome Dispone di manico regolabile 1 asciugamano 42,5 x 90,5 cm (80 % poliestere e 20 % poliammide) dall'asciugatura rapida 1 cuffia da nuoto taglia unica (85 % poliestere e 15 % elastam) 1 paio di occhialini da nuoto (norme 89/686/CEE e ISO 12312-1:2013) anti appannamento Dimensioni dello zaino: 24 x 31 x 6 cm circa Dimenzioni per Zaino per Piscina Minnie (4 pezzi):
Altezza: 4 Cm Larghezza: 24 Cm Profondita': 30 Cm Peso: 0.277 Kg Codice Prodotto (EAN): 8427934823796
","Ti piacerebbe sorprendere le bimbe della casa con un regalo originale? Se adorano il mare o la piscina, lo zaino per piscina Minnie (4 pezzi) le farà impazzire. Maggiori Informazioni ",0.277,1,"Taxable Goods","Catalog, Search",37.9,,,,Zaino-per-Piscina-Minnie-(4-pezzi),"Zaino per Piscina Minnie (4 pezzi)","Relax Tempo Libero,Relax,Tempo,Libero,Mare e Piscina,Mare,Piscina,","Ti piacerebbe sorprendere le bimbe della casa con un regalo originale? Se adorano il mare o la piscina, lo zaino per piscina Minnie (4 pezzi) le farà impazzire",http://dropshipping.bigbuy.eu/imgs/V1300157_93587.jpg,,http://dropshipping.bigbuy.eu/imgs/V1300157_93587.jpg,,,,,,"2016-08-26 13:30:29",,,,,,,,,,,,,,,,,"GTIN=8427934823796",137,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/V1300157_93593.jpg,http://dropshipping.bigbuy.eu/imgs/V1300157_93592.jpg,http://dropshipping.bigbuy.eu/imgs/V1300157_93591.jpg,http://dropshipping.bigbuy.eu/imgs/V1300157_93590.jpg,http://dropshipping.bigbuy.eu/imgs/V1300157_93589.jpg,http://dropshipping.bigbuy.eu/imgs/V1300157_93586.jpg","GTIN=8427934823796",,,,,,,,,,
+BB-V1300158,,Default,simple,"Default Category/Relax Tempo Libero,Default Category/Relax Tempo Libero/Mare e Piscina",base,"Zaino per Piscina Avengers (4 pezzi)","Ti
piacerebbe sorprendere i più piccoli della casa con un regalo originale ? Se adorano il mare o la piscina, lo zaino per piscina Avengers (4 pezzi) li farà impazzire.Dispone di una cerniera, una rete posteriore e uno scompartimento per il nome Dispone di manico regolabile 1 asciugamano 42,5 x 90,5 cm (80 % poliestere e 20 % poliammide) dall'asciugatura rapida 1 cuffia da nuoto taglia unica (85 % poliestere e 15 % elastam) 1 paio di occhialini da nuoto (norme 89/686/CEE e ISO 12312-1:2013) anti appannamento Dimensioni dello zaino: 24 x 31 x 6 cm circa Dimenzioni per Zaino per Piscina Avengers (4 pezzi):
Altezza: 3 Cm Larghezza: 23 Cm Profondita': 31 Cm Peso: 0.279 Kg Codice Prodotto (EAN): 7569000752249
","Ti piacerebbe sorprendere i più piccoli della casa con un regalo originale? Se adorano il mare o la piscina, lo zaino per piscina Avengers (4 pezzi) li farà impazzire. Maggiori Informazioni ",0.279,1,"Taxable Goods","Catalog, Search",37.9,,,,Zaino-per-Piscina-Avengers-(4-pezzi),"Zaino per Piscina Avengers (4 pezzi)","Relax Tempo Libero,Relax,Tempo,Libero,Mare e Piscina,Mare,Piscina,","Ti piacerebbe sorprendere i più piccoli della casa con un regalo originale? Se adorano il mare o la piscina, lo zaino per piscina Avengers (4 pezzi) li farà impazzire",http://dropshipping.bigbuy.eu/imgs/V1300158_93596.jpg,,http://dropshipping.bigbuy.eu/imgs/V1300158_93596.jpg,,,,,,"2016-08-26 11:29:45",,,,,,,,,,,,,,,,,"GTIN=7569000752249",139,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/V1300158_93601.jpg,http://dropshipping.bigbuy.eu/imgs/V1300158_93600.jpg,http://dropshipping.bigbuy.eu/imgs/V1300158_93599.jpg,http://dropshipping.bigbuy.eu/imgs/V1300158_93598.jpg,http://dropshipping.bigbuy.eu/imgs/V1300158_93597.jpg,http://dropshipping.bigbuy.eu/imgs/V1300158_93595.jpg","GTIN=7569000752249",,,,,,,,,,
+BB-V1300159,,Default,simple,"Default Category/Relax Tempo Libero,Default Category/Relax Tempo Libero/Mare e Piscina",base,"Zaino per Piscina Minions (4 pezzi)","Ti
piacerebbe sorprendere i più piccoli di casa con un regalo originale ? Se adorano il mare o la piscina, lo zaino per piscina Minions (4 pezzi) li farà impazzire.Dispone di una cerniera, una rete posteriore e uno scompartimento per il nome Dispone di manico regolabile 1 asciugamano 42,5 x 90,5 cm (80 % poliestere e 20 % poliammide) dall'asciugatura rapida 1 cuffia da nuoto taglia unica (85 % poliestere e 15 % elastam) 1 paio di occhialini da nuoto (norme 89/686/CEE e ISO 12312-1:2013) anti appannamento Dimensioni dello zaino: 24 x 31 x 6 cm circa Dimenzioni per Zaino per Piscina Minions (4 pezzi):
Altezza: 3 Cm Larghezza: 23 Cm Profondita': 31 Cm Peso: 0.279 Kg Codice Prodotto (EAN): 8427934823833
","Ti piacerebbe sorprendere i più piccoli di casa con un regalo originale? Se adorano il mare o la piscina, lo zaino per piscina Minions (4 pezzi) li farà impazzire. Maggiori Informazioni ",0.279,1,"Taxable Goods","Catalog, Search",37.9,,,,Zaino-per-Piscina-Minions-(4-pezzi),"Zaino per Piscina Minions (4 pezzi)","Relax Tempo Libero,Relax,Tempo,Libero,Mare e Piscina,Mare,Piscina,","Ti piacerebbe sorprendere i più piccoli di casa con un regalo originale? Se adorano il mare o la piscina, lo zaino per piscina Minions (4 pezzi) li farà impazzire",http://dropshipping.bigbuy.eu/imgs/V1300159_93602.jpg,,http://dropshipping.bigbuy.eu/imgs/V1300159_93602.jpg,,,,,,"2016-08-26 11:29:10",,,,,,,,,,,,,,,,,"GTIN=8427934823833",132,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/V1300159_93608.jpg,http://dropshipping.bigbuy.eu/imgs/V1300159_93607.jpg,http://dropshipping.bigbuy.eu/imgs/V1300159_93606.jpg,http://dropshipping.bigbuy.eu/imgs/V1300159_93605.jpg,http://dropshipping.bigbuy.eu/imgs/V1300159_93604.jpg,http://dropshipping.bigbuy.eu/imgs/V1300159_93603.jpg","GTIN=8427934823833",,,,,,,,,,
+BB-G0500179,,Default,simple,"Default Category/Sport Fitness,Default Category/Sport Fitness/Abbigliamento, Accessori e Dispositivi Indossabili",base,"Clip di Sicurezza a LED per Scarpe da Corsa GoFit","Ti
piace allenarti la sera all'aria aperta? Allora, non dimenticare di indossare la tua clip di sicurezza a LED per scarpe da corsa GoFit ! Grazie a questo utile accessorio da corsa , sarai visibile al buio mentre corri o ti alleni. Include 2 tipi di luce (fissa o intermittente) e può essere facilmente applicata sulla parte posteriore della scarpa o indossata intorno al polso. Possiede un bottone on/off che ti permette inoltre di cambiare il tipo di luce. Progettato in Europa con materiali di alta qualità. 1 pezzo incluso.Caratteristiche:
LED verde per alta visibilità Circa 100 ore di luce intermittente Circa 70 ore di luce fissa Adattabile a scrarpe da 6 a 8,5 cm di larghezza Funziona a batterie (2 x CR2032, incluse) Dimenzioni per Clip di Sicurezza a LED per Scarpe da Corsa GoFit :
Altezza: 18 Cm Larghezza: 9 Cm Profondita': 3.7 Cm Peso: 0.095 Kg Codice Prodotto (EAN): 8018417209116
","Ti piace allenarti la sera all'aria aperta? Allora, non dimenticare di indossare la tua clip di sicurezza a LED per scarpe da corsa GoFit! Grazie a questo utile accessorio da corsa, sarai visibile al buio mentre corri o ti alleni. Maggiori Informazioni ",0.095,1,"Taxable Goods","Catalog, Search",34.95,,,,Clip-di-Sicurezza-a-LED-per-Scarpe-da-Corsa-GoFit,"Clip di Sicurezza a LED per Scarpe da Corsa GoFit","Sport Fitness,Sport,Fitness,Abbigliamento, Accessori e Dispositivi Indossabili,Abbigliamento,,Accessori,Dispositivi,Indossabili,","Ti piace allenarti la sera all'aria aperta? Allora, non dimenticare di indossare la tua clip di sicurezza a LED per scarpe da corsa GoFit! Grazie a questo utile accessorio da corsa, sarai visibile al buio mentre corri o ti alleni",http://dropshipping.bigbuy.eu/imgs/clip_led_running_go_fit.jpg,,http://dropshipping.bigbuy.eu/imgs/clip_led_running_go_fit.jpg,,,,,,"2016-08-22 08:23:08",,,,,,,,,,,,,,,,,"GTIN=8018417209116",207,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/clip_led_running_go_fit_04.jpg,http://dropshipping.bigbuy.eu/imgs/clip_led_running_go_fit_02.jpg,http://dropshipping.bigbuy.eu/imgs/clip_led_running_go_fit_002.jpg","GTIN=8018417209116",,,,,,,,,,
+BB-G0500187,,Default,simple,"Default Category/Sport Fitness,Default Category/Sport Fitness/Abbigliamento, Accessori e Dispositivi Indossabili",base,"Sensore di Velocità Bluetooth GoFit","Se
sei un amante del ciclismo e vuoi tener traccia della velocità, ritmo e distanza mentre pedali? Allora non perdere l'occasione, acquista il sensore di velocità Bluetooth GoFit , in modo da essere in grado di monitorare tutti i suoi dati in ogni momento, grazie al suo ingegnoso dispositivo! Devi solo installare il sensore e scaricare l'apposita applicazione sul tuo telefono cellulare. Questo sensore di velocità e ritmo è stato progettato in Europa ed è costituito di materiali resistenti all'acqua, in polimeri termoplastici. Molto semplice da installare. Compatibile con iOS (7.0 e successivi) e Android (4.3 e successivi). Funziona a batterie (1 x CR2032, incluse).Include:
1 sensore di velocità e ritmo (dimensioni: circa 8,5 x 7 x 1,5 cm) 1 magnete per ritmo pedale (dimensioni: circa 1,5 x 3,5 x 2 cm) 1 magnete per ruote 1 cacciavite 2 fascette 1 banda elastica Dimenzioni per Sensore di Velocità Bluetooth GoFit:
Altezza: 20.3 Cm Larghezza: 9 Cm Profondita': 3.5 Cm Peso: 0.143 Kg Codice Prodotto (EAN): 8018417209109
","Se sei un amante del ciclismo e vuoi tener traccia della velocità, ritmo e distanza mentre pedali? Allora non perdere l'occasione, acquista il sensore di velocità Bluetooth GoFit, in modo da essere in grado di monitorare tutti i suoi dati in ogni momento, grazie al suo ingegnoso dispositivo! Devi solo installare il sensore e scaricare l'apposita applicazione sul tuo telefono cellulare. Maggiori Informazioni ",0.143,1,"Taxable Goods","Catalog, Search",179.9,,,,Sensore-di-Velocità-Bluetooth-GoFit,"Sensore di Velocità Bluetooth GoFit","Sport Fitness,Sport,Fitness,Abbigliamento, Accessori e Dispositivi Indossabili,Abbigliamento,,Accessori,Dispositivi,Indossabili,","Se sei un amante del ciclismo e vuoi tener traccia della velocità, ritmo e distanza mentre pedali? Allora non perdere l'occasione, acquista il sensore di velocità Bluetooth GoFit, in modo da essere in grado di monitorare tutti i suoi dati in ogni mo",http://dropshipping.bigbuy.eu/imgs/G0500187_81130.jpg,,http://dropshipping.bigbuy.eu/imgs/G0500187_81130.jpg,,,,,,"2016-08-08 21:04:27",,,,,,,,,,,,,,,,,"GTIN=8018417209109",17,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/G0500187_81089.jpg,http://dropshipping.bigbuy.eu/imgs/G0500187_81088.jpg,http://dropshipping.bigbuy.eu/imgs/G0500187_81087.jpg,http://dropshipping.bigbuy.eu/imgs/G0500187_81086.jpg","GTIN=8018417209109",,,,,,,,,,
+BB-G0500188,,Default,simple,"Default Category/Sport Fitness,Default Category/Sport Fitness/Abbigliamento, Accessori e Dispositivi Indossabili",base,"Luce a Led di Sicurezza per Lacci GoFit (pacco da 2)","Da
ora in poi potrai fare jogging serenamente, sapendo che puoi essere visto dai veicoli intorno a te! Basta inserire la luce a led di sicurezza GoFit (pacco da 2) dentro ogni scarpa da corsa per aumentare la tua visibilità. Le loro 2 potenti luci a LED verdi si attivano ad ogni passo che fai. È davvero semplice! Ogni luce a LED funziona a pile ( 2 x CR1220 , 6 V , incluse). Durata delle batterie: 150,000 lampeggi di luce. Queste luci a LED sono costituite di materiali di alta qualità e sono adatte all'utilizzo con i lacci con uno spessore massimo di 9 mm. Include 2 unità. Dimensioni: circa 4 x 1,5 x 0,8 cm. Dimenzioni per Luce a Led di Sicurezza per Lacci GoFit (pacco da 2):
Altezza: 9 Cm Larghezza: 3.7 Cm Profondita': 20 Cm Peso: 0.061 Kg Codice Prodotto (EAN): 8018417209482
","Da ora in poi potrai fare jogging serenamente, sapendo che puoi essere visto dai veicoli intorno a te! Basta inserire la luce a led di sicurezza GoFit (pacco da 2) dentro ogni scarpa da corsa per aumentare la tua visibilità. Maggiori Informazioni ",0.061,1,"Taxable Goods","Catalog, Search",33.95,,,,Luce-a-Led-di-Sicurezza-per-Lacci-GoFit-(pacco-da-2),"Luce a Led di Sicurezza per Lacci GoFit (pacco da 2)","Sport Fitness,Sport,Fitness,Abbigliamento, Accessori e Dispositivi Indossabili,Abbigliamento,,Accessori,Dispositivi,Indossabili,","Da ora in poi potrai fare jogging serenamente, sapendo che puoi essere visto dai veicoli intorno a te! Basta inserire la luce a led di sicurezza GoFit (pacco da 2) dentro ogni scarpa da corsa per aumentare la tua visibilità",http://dropshipping.bigbuy.eu/imgs/G0500188_81129.jpg,,http://dropshipping.bigbuy.eu/imgs/G0500188_81129.jpg,,,,,,"2016-08-08 21:04:27",,,,,,,,,,,,,,,,,"GTIN=8018417209482",238,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/G0500188_81096.jpg,http://dropshipping.bigbuy.eu/imgs/G0500188_81095.jpg","GTIN=8018417209482",,,,,,,,,,
+BB-G0500189,,Default,simple,"Default Category/Sport Fitness,Default Category/Sport Fitness/Abbigliamento, Accessori e Dispositivi Indossabili",base,"Bracciale di Sicurezza LED GoFit","Non
possiedi ancora il bracciale di sicurezza LED GoFit ? Non perdertelo e pratica i tuoi sport preferiti con questo leggero e comodo bracciale progettato in Europa. Qualunque auto o moto ti vedrà nel buio! Include 2 luci a LED e 2 modalità di illuminazione (fissa e lampeggiante) che puoi scegliere premendo il pulsante del bracciale. La cinghia di velcro lo fissa al braccio ed è flessibile e regolabile. La lunghezza massima è di circa 38,5 cm e la minima è di 31 cm. Funziona a batterie (2 x CR2023, incluse). Dimenzioni per Bracciale di Sicurezza LED GoFit:
Altezza: 9 Cm Larghezza: 4 Cm Profondita': 20 Cm Peso: 0.087 Kg Codice Prodotto (EAN): 8018417209475
","Non possiedi ancora il bracciale di sicurezza LED GoFit? Non perdertelo e pratica i tuoi sport preferiti con questo leggero e comodo bracciale progettato in Europa. Maggiori Informazioni ",0.087,1,"Taxable Goods","Catalog, Search",44.95,,,,Bracciale-di-Sicurezza-LED-GoFit,"Bracciale di Sicurezza LED GoFit","Sport Fitness,Sport,Fitness,Abbigliamento, Accessori e Dispositivi Indossabili,Abbigliamento,,Accessori,Dispositivi,Indossabili,","Non possiedi ancora il bracciale di sicurezza LED GoFit? Non perdertelo e pratica i tuoi sport preferiti con questo leggero e comodo bracciale progettato in Europa",http://dropshipping.bigbuy.eu/imgs/G0500189_81128.jpg,,http://dropshipping.bigbuy.eu/imgs/G0500189_81128.jpg,,,,,,"2016-08-08 21:04:27",,,,,,,,,,,,,,,,,"GTIN=8018417209475",93,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/G0500189_81093.jpg,http://dropshipping.bigbuy.eu/imgs/G0500189_81092.jpg,http://dropshipping.bigbuy.eu/imgs/G0500189_81091.jpg","GTIN=8018417209475",,,,,,,,,,
+BB-F1510306,,Default,simple,"Default Category/Moda Accessori,Default Category/Moda Accessori/Abbigliamento e Scarpe,Default Category/Moda Accessori/Abbigliamento e Scarpe/Pigiami e vestaglie",base,"Coperta con Maniche Snug Snug Big Tribu Leopardato","Affronta
il freddo invernale con l'originale coperta con maniche Snug Snug Big Tribu ! Un fantastico prodotto firmato Snug Snug che ti farà sentire comodo e al caldo, mentre sei sdraiato sul divano o stai facendo qualsiasi lavoro in casa, grazie alle maniche che ti permettono una totale libertà di movimenti. La coperta con maniche Big Tribu è dotata di tasca centrale per avere tutto a portata di mano, il telecomando della TV, il tuo libro preferito, ecc. Realizzata in morbido pile 100 % poliestere. Misure: 170 x 130 cm circa.www.snugsnug.com
Dimenzioni per Coperta con Maniche Snug Snug Big Tribu:
Altezza: 25 Cm Larghezza: 8.5 Cm Profondita': 26.5 Cm Peso: 0.602 Kg Codice Prodotto (EAN): 4899888103530
","Affronta il freddo invernale con l'originale coperta con maniche Snug Snug Big Tribu! Un fantastico prodotto firmato Snug Snug che ti farà sentire comodo e al caldo, mentre sei sdraiato sul divano o stai facendo qualsiasi lavoro in casa, grazie alle maniche che ti permettono una totale libertà di movimenti. Maggiori Informazioni ",0.602,1,"Taxable Goods","Catalog, Search",39.9,,,,Coperta-con-Maniche-Snug-Snug-Big-Tribu-Leopardato,"Coperta con Maniche Snug Snug Big Tribu Leopardato","Moda Accessori,Moda,Accessori,Abbigliamento e Scarpe,Abbigliamento,Scarpe,Pigiami e vestaglie,Pigiami,vestaglie,Colore Leopardato,Leopardato,","Affronta il freddo invernale con l'originale coperta con maniche Snug Snug Big Tribu! Un fantastico prodotto firmato Snug Snug che ti farà sentire comodo e al caldo, mentre sei sdraiato sul divano o stai facendo qualsiasi lavoro in casa, grazie alle",http://dropshipping.bigbuy.eu/imgs/F1510300_81361.jpg,,http://dropshipping.bigbuy.eu/imgs/F1510300_81361.jpg,,,,,,"2015-12-30 17:30:06",,,,,,,,,,,,,,,,,"GTIN=4899888103530",46,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/F1510300_81365.jpg,http://dropshipping.bigbuy.eu/imgs/F1510300_81364.jpg,http://dropshipping.bigbuy.eu/imgs/F1510300_81363.jpg,http://dropshipping.bigbuy.eu/imgs/F1510300_81362.jpg","GTIN=4899888103530",,,,,,,,,,
+BB-F1510307,,Default,simple,"Default Category/Moda Accessori,Default Category/Moda Accessori/Abbigliamento e Scarpe,Default Category/Moda Accessori/Abbigliamento e Scarpe/Pigiami e vestaglie",base,"Coperta con Maniche Snug Snug Big Tribu Zebra","Affronta
il freddo invernale con l'originale coperta con maniche Snug Snug Big Tribu ! Un fantastico prodotto firmato Snug Snug che ti farà sentire comodo e al caldo, mentre sei sdraiato sul divano o stai facendo qualsiasi lavoro in casa, grazie alle maniche che ti permettono una totale libertà di movimenti. La coperta con maniche Big Tribu è dotata di tasca centrale per avere tutto a portata di mano, il telecomando della TV, il tuo libro preferito, ecc. Realizzata in morbido pile 100 % poliestere. Misure: 170 x 130 cm circa.www.snugsnug.com
Dimenzioni per Coperta con Maniche Snug Snug Big Tribu:
Altezza: 25 Cm Larghezza: 8.5 Cm Profondita': 26.5 Cm Peso: 0.602 Kg Codice Prodotto (EAN): 4899888103530
","Affronta il freddo invernale con l'originale coperta con maniche Snug Snug Big Tribu! Un fantastico prodotto firmato Snug Snug che ti farà sentire comodo e al caldo, mentre sei sdraiato sul divano o stai facendo qualsiasi lavoro in casa, grazie alle maniche che ti permettono una totale libertà di movimenti. Maggiori Informazioni ",0.602,1,"Taxable Goods","Catalog, Search",39.9,,,,Coperta-con-Maniche-Snug-Snug-Big-Tribu-Zebra,"Coperta con Maniche Snug Snug Big Tribu Zebra","Moda Accessori,Moda,Accessori,Abbigliamento e Scarpe,Abbigliamento,Scarpe,Pigiami e vestaglie,Pigiami,vestaglie,Colore Zebra,Zebra,","Affronta il freddo invernale con l'originale coperta con maniche Snug Snug Big Tribu! Un fantastico prodotto firmato Snug Snug che ti farà sentire comodo e al caldo, mentre sei sdraiato sul divano o stai facendo qualsiasi lavoro in casa, grazie alle",http://dropshipping.bigbuy.eu/imgs/F1510300_81365.jpg,,http://dropshipping.bigbuy.eu/imgs/F1510300_81365.jpg,,,,,,"2016-01-21 08:26:10",,,,,,,,,,,,,,,,,"GTIN=4899888103530",486,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/F1510300_81361.jpg,http://dropshipping.bigbuy.eu/imgs/F1510300_81364.jpg,http://dropshipping.bigbuy.eu/imgs/F1510300_81363.jpg,http://dropshipping.bigbuy.eu/imgs/F1510300_81362.jpg","GTIN=4899888103530",,,,,,,,,,
+BB-F1510308,,Default,simple,"Default Category/Moda Accessori,Default Category/Moda Accessori/Abbigliamento e Scarpe,Default Category/Moda Accessori/Abbigliamento e Scarpe/Pigiami e vestaglie",base,"Coperta con Maniche Snug Snug Big Tribu Dalmata","Affronta
il freddo invernale con l'originale coperta con maniche Snug Snug Big Tribu ! Un fantastico prodotto firmato Snug Snug che ti farà sentire comodo e al caldo, mentre sei sdraiato sul divano o stai facendo qualsiasi lavoro in casa, grazie alle maniche che ti permettono una totale libertà di movimenti. La coperta con maniche Big Tribu è dotata di tasca centrale per avere tutto a portata di mano, il telecomando della TV, il tuo libro preferito, ecc. Realizzata in morbido pile 100 % poliestere. Misure: 170 x 130 cm circa.www.snugsnug.com
Dimenzioni per Coperta con Maniche Snug Snug Big Tribu:
Altezza: 25 Cm Larghezza: 8.5 Cm Profondita': 26.5 Cm Peso: 0.602 Kg Codice Prodotto (EAN): 4899888103530
","Affronta il freddo invernale con l'originale coperta con maniche Snug Snug Big Tribu! Un fantastico prodotto firmato Snug Snug che ti farà sentire comodo e al caldo, mentre sei sdraiato sul divano o stai facendo qualsiasi lavoro in casa, grazie alle maniche che ti permettono una totale libertà di movimenti. Maggiori Informazioni ",0.602,1,"Taxable Goods","Catalog, Search",39.9,,,,Coperta-con-Maniche-Snug-Snug-Big-Tribu-Dalmata,"Coperta con Maniche Snug Snug Big Tribu Dalmata","Moda Accessori,Moda,Accessori,Abbigliamento e Scarpe,Abbigliamento,Scarpe,Pigiami e vestaglie,Pigiami,vestaglie,Colore Dalmata,Dalmata,","Affronta il freddo invernale con l'originale coperta con maniche Snug Snug Big Tribu! Un fantastico prodotto firmato Snug Snug che ti farà sentire comodo e al caldo, mentre sei sdraiato sul divano o stai facendo qualsiasi lavoro in casa, grazie alle",http://dropshipping.bigbuy.eu/imgs/F1510300_81364.jpg,,http://dropshipping.bigbuy.eu/imgs/F1510300_81364.jpg,,,,,,"2016-02-22 08:16:26",,,,,,,,,,,,,,,,,"GTIN=4899888103530",307,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/F1510300_81361.jpg,http://dropshipping.bigbuy.eu/imgs/F1510300_81365.jpg,http://dropshipping.bigbuy.eu/imgs/F1510300_81363.jpg,http://dropshipping.bigbuy.eu/imgs/F1510300_81362.jpg","GTIN=4899888103530",,,,,,,,,,
+BB-F1510302,,Default,simple,"Default Category/Moda Accessori,Default Category/Moda Accessori/Abbigliamento e Scarpe,Default Category/Moda Accessori/Abbigliamento e Scarpe/Pigiami e vestaglie",base,"Coperta con Maniche Snug Snug One Big Azzurro","Affronta
il freddo invernale con l'originale coperta con maniche Snug Snug One Big ! Un fantastico prodotto firmato Snug Snug che ti farà sentire comodo e al caldo, mentre sei sdraiato sul divano o stai facendo qualsiasi lavoro in casa, grazie alle maniche che ti permettono una totale libertà di movimenti. La coperta con maniche One Big è dotata di tasca centrale per avere tutto a portata di mano, il telecomando della TV, il tuo libro preferito, ecc. Realizzata in morbido pile 100 % poliestere. Misure: 170 x 130 cm circa.www.snugsnug.com Dimenzioni per Coperta con Maniche Snug Snug One Big:
Altezza: 26.5 Cm Larghezza: 25 Cm Profondita': 23.7 Cm Peso: 0.538 Kg Codice Prodotto (EAN): 4899888102977
","Affronta il freddo invernale con l'originale coperta con maniche Snug Snug One Big! Un fantastico prodotto firmato Snug Snug che ti farà sentire comodo e al caldo, mentre sei sdraiato sul divano o stai facendo qualsiasi lavoro in casa, grazie alle maniche che ti permettono una totale libertà di movimenti. Maggiori Informazioni ",0.538,1,"Taxable Goods","Catalog, Search",29.9,,,,Coperta-con-Maniche-Snug-Snug-One-Big-Azzurro,"Coperta con Maniche Snug Snug One Big Azzurro","Moda Accessori,Moda,Accessori,Abbigliamento e Scarpe,Abbigliamento,Scarpe,Pigiami e vestaglie,Pigiami,vestaglie,Colore Azzurro,Azzurro,","Affronta il freddo invernale con l'originale coperta con maniche Snug Snug One Big! Un fantastico prodotto firmato Snug Snug che ti farà sentire comodo e al caldo, mentre sei sdraiato sul divano o stai facendo qualsiasi lavoro in casa, grazie alle m",http://dropshipping.bigbuy.eu/imgs/F1510301_81356.jpg,,http://dropshipping.bigbuy.eu/imgs/F1510301_81356.jpg,,,,,,"2015-12-28 17:26:13",,,,,,,,,,,,,,,,,"GTIN=4899888102977",538,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/F1510301_81360.jpg,http://dropshipping.bigbuy.eu/imgs/F1510301_81359.jpg,http://dropshipping.bigbuy.eu/imgs/F1510301_81358.jpg,http://dropshipping.bigbuy.eu/imgs/F1510301_81357.jpg","GTIN=4899888102977",,,,,,,,,,
+BB-F1510303,,Default,simple,"Default Category/Moda Accessori,Default Category/Moda Accessori/Abbigliamento e Scarpe,Default Category/Moda Accessori/Abbigliamento e Scarpe/Pigiami e vestaglie",base,"Coperta con Maniche Snug Snug One Big Rosso","Affronta
il freddo invernale con l'originale coperta con maniche Snug Snug One Big ! Un fantastico prodotto firmato Snug Snug che ti farà sentire comodo e al caldo, mentre sei sdraiato sul divano o stai facendo qualsiasi lavoro in casa, grazie alle maniche che ti permettono una totale libertà di movimenti. La coperta con maniche One Big è dotata di tasca centrale per avere tutto a portata di mano, il telecomando della TV, il tuo libro preferito, ecc. Realizzata in morbido pile 100 % poliestere. Misure: 170 x 130 cm circa.www.snugsnug.com Dimenzioni per Coperta con Maniche Snug Snug One Big:
Altezza: 26.5 Cm Larghezza: 25 Cm Profondita': 23.7 Cm Peso: 0.538 Kg Codice Prodotto (EAN): 4899888102977
","Affronta il freddo invernale con l'originale coperta con maniche Snug Snug One Big! Un fantastico prodotto firmato Snug Snug che ti farà sentire comodo e al caldo, mentre sei sdraiato sul divano o stai facendo qualsiasi lavoro in casa, grazie alle maniche che ti permettono una totale libertà di movimenti. Maggiori Informazioni ",0.538,1,"Taxable Goods","Catalog, Search",29.9,,,,Coperta-con-Maniche-Snug-Snug-One-Big-Rosso,"Coperta con Maniche Snug Snug One Big Rosso","Moda Accessori,Moda,Accessori,Abbigliamento e Scarpe,Abbigliamento,Scarpe,Pigiami e vestaglie,Pigiami,vestaglie,Colore Rosso,Rosso,","Affronta il freddo invernale con l'originale coperta con maniche Snug Snug One Big! Un fantastico prodotto firmato Snug Snug che ti farà sentire comodo e al caldo, mentre sei sdraiato sul divano o stai facendo qualsiasi lavoro in casa, grazie alle m",http://dropshipping.bigbuy.eu/imgs/F1510301_81360.jpg,,http://dropshipping.bigbuy.eu/imgs/F1510301_81360.jpg,,,,,,"2016-01-20 10:35:30",,,,,,,,,,,,,,,,,"GTIN=4899888102977",600,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/F1510301_81356.jpg,http://dropshipping.bigbuy.eu/imgs/F1510301_81359.jpg,http://dropshipping.bigbuy.eu/imgs/F1510301_81358.jpg,http://dropshipping.bigbuy.eu/imgs/F1510301_81357.jpg","GTIN=4899888102977",,,,,,,,,,
+BB-F1510304,,Default,simple,"Default Category/Moda Accessori,Default Category/Moda Accessori/Abbigliamento e Scarpe,Default Category/Moda Accessori/Abbigliamento e Scarpe/Pigiami e vestaglie",base,"Coperta con Maniche Snug Snug One Big Verde","Affronta
il freddo invernale con l'originale coperta con maniche Snug Snug One Big ! Un fantastico prodotto firmato Snug Snug che ti farà sentire comodo e al caldo, mentre sei sdraiato sul divano o stai facendo qualsiasi lavoro in casa, grazie alle maniche che ti permettono una totale libertà di movimenti. La coperta con maniche One Big è dotata di tasca centrale per avere tutto a portata di mano, il telecomando della TV, il tuo libro preferito, ecc. Realizzata in morbido pile 100 % poliestere. Misure: 170 x 130 cm circa.www.snugsnug.com Dimenzioni per Coperta con Maniche Snug Snug One Big:
Altezza: 26.5 Cm Larghezza: 25 Cm Profondita': 23.7 Cm Peso: 0.538 Kg Codice Prodotto (EAN): 4899888102977
","Affronta il freddo invernale con l'originale coperta con maniche Snug Snug One Big! Un fantastico prodotto firmato Snug Snug che ti farà sentire comodo e al caldo, mentre sei sdraiato sul divano o stai facendo qualsiasi lavoro in casa, grazie alle maniche che ti permettono una totale libertà di movimenti. Maggiori Informazioni ",0.538,1,"Taxable Goods","Catalog, Search",29.9,,,,Coperta-con-Maniche-Snug-Snug-One-Big-Verde,"Coperta con Maniche Snug Snug One Big Verde","Moda Accessori,Moda,Accessori,Abbigliamento e Scarpe,Abbigliamento,Scarpe,Pigiami e vestaglie,Pigiami,vestaglie,Colore Verde,Verde,","Affronta il freddo invernale con l'originale coperta con maniche Snug Snug One Big! Un fantastico prodotto firmato Snug Snug che ti farà sentire comodo e al caldo, mentre sei sdraiato sul divano o stai facendo qualsiasi lavoro in casa, grazie alle m",http://dropshipping.bigbuy.eu/imgs/F1510301_81359.jpg,,http://dropshipping.bigbuy.eu/imgs/F1510301_81359.jpg,,,,,,"2015-10-06 11:20:02",,,,,,,,,,,,,,,,,"GTIN=4899888102977",764,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/F1510301_81356.jpg,http://dropshipping.bigbuy.eu/imgs/F1510301_81360.jpg,http://dropshipping.bigbuy.eu/imgs/F1510301_81358.jpg,http://dropshipping.bigbuy.eu/imgs/F1510301_81357.jpg","GTIN=4899888102977",,,,,,,,,,
+BB-F1510305,,Default,simple,"Default Category/Moda Accessori,Default Category/Moda Accessori/Abbigliamento e Scarpe,Default Category/Moda Accessori/Abbigliamento e Scarpe/Pigiami e vestaglie",base,"Coperta con Maniche Snug Snug One Big Rosa","Affronta
il freddo invernale con l'originale coperta con maniche Snug Snug One Big ! Un fantastico prodotto firmato Snug Snug che ti farà sentire comodo e al caldo, mentre sei sdraiato sul divano o stai facendo qualsiasi lavoro in casa, grazie alle maniche che ti permettono una totale libertà di movimenti. La coperta con maniche One Big è dotata di tasca centrale per avere tutto a portata di mano, il telecomando della TV, il tuo libro preferito, ecc. Realizzata in morbido pile 100 % poliestere. Misure: 170 x 130 cm circa.www.snugsnug.com Dimenzioni per Coperta con Maniche Snug Snug One Big:
Altezza: 26.5 Cm Larghezza: 25 Cm Profondita': 23.7 Cm Peso: 0.538 Kg Codice Prodotto (EAN): 4899888102977
","Affronta il freddo invernale con l'originale coperta con maniche Snug Snug One Big! Un fantastico prodotto firmato Snug Snug che ti farà sentire comodo e al caldo, mentre sei sdraiato sul divano o stai facendo qualsiasi lavoro in casa, grazie alle maniche che ti permettono una totale libertà di movimenti. Maggiori Informazioni ",0.538,1,"Taxable Goods","Catalog, Search",29.9,,,,Coperta-con-Maniche-Snug-Snug-One-Big-Rosa,"Coperta con Maniche Snug Snug One Big Rosa","Moda Accessori,Moda,Accessori,Abbigliamento e Scarpe,Abbigliamento,Scarpe,Pigiami e vestaglie,Pigiami,vestaglie,Colore Rosa,Rosa,","Affronta il freddo invernale con l'originale coperta con maniche Snug Snug One Big! Un fantastico prodotto firmato Snug Snug che ti farà sentire comodo e al caldo, mentre sei sdraiato sul divano o stai facendo qualsiasi lavoro in casa, grazie alle m",http://dropshipping.bigbuy.eu/imgs/F1510301_81358.jpg,,http://dropshipping.bigbuy.eu/imgs/F1510301_81358.jpg,,,,,,"2015-12-29 06:48:13",,,,,,,,,,,,,,,,,"GTIN=4899888102977",968,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/F1510301_81356.jpg,http://dropshipping.bigbuy.eu/imgs/F1510301_81360.jpg,http://dropshipping.bigbuy.eu/imgs/F1510301_81359.jpg,http://dropshipping.bigbuy.eu/imgs/F1510301_81357.jpg","GTIN=4899888102977",,,,,,,,,,
+BB-V1300145,,Default,simple,"Default Category/Moda Accessori,Default Category/Moda Accessori/Accessori,Default Category/Relax Tempo Libero/Accessori/Ombrelli",base,"Ombrello Star Wars con LED","I
fan di Guerre Stellari impazziranno con l'ombrello Star Wars con LED !Interruttore on/off sul manico LED di vari colori sul manico centrale Funziona a batterie (3 x AA, incluse) Struttura: metallo, plastica e fibra di vetro Cupola: poliestere (pongee) Lunghezza approssimativa: 79,5 cm Diametro approssimativo: 95 cm Dimenzioni per Ombrello Star Wars con LED:
Altezza: 4 Cm Larghezza: 79.5 Cm Profondita': 5 Cm Peso: 0.458 Kg Codice Prodotto (EAN): 7569000752317
","I fan di Guerre Stellari impazziranno con l'ombrello Star Wars con LED!Interruttore on/off sul manicoLED di vari colori sul manico centraleFunziona a batterie (3 x AA, incluse)Struttura: metallo, plastica e fibra di vetroCupola: poliestere (pongee)Lunghezza approssimativa: 79,5 cmDiametro approssimativo: 95 cm. Maggiori Informazioni ",0.458,1,"Taxable Goods","Catalog, Search",53.9,,,,Ombrello-Star-Wars-con-LED,"Ombrello Star Wars con LED","Moda Accessori,Moda,Accessori,Accessori,Ombrelli,","I fan di Guerre Stellari impazziranno con l'ombrello Star Wars con LED!Interruttore on/off sul manicoLED di vari colori sul manico centraleFunziona a batterie (3 x AA, incluse)Struttura: metallo, plastica e fibra di vetroCupola: poliestere (pongee)L",http://dropshipping.bigbuy.eu/imgs/V1300145_93662.jpg,,http://dropshipping.bigbuy.eu/imgs/V1300145_93662.jpg,,,,,,"2016-09-12 07:48:53",,,,,,,,,,,,,,,,,"GTIN=7569000752317",23,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/V1300145_93665.jpg,http://dropshipping.bigbuy.eu/imgs/V1300145_93664.jpg,http://dropshipping.bigbuy.eu/imgs/V1300145_93663.jpg,http://dropshipping.bigbuy.eu/imgs/V1300145_93661.jpg","GTIN=7569000752317",,,,,,,,,,
+BB-H4530316,,Default,simple,"Default Category/Giochi Bambini,Default Category/Giochi Bambini/Giocattoli e Giochi,Default Category/Giochi Bambini/Giocattoli e Giochi/Giochi educativi",base,"Elastici per fare bracciali con Perline di Frozen","Se
cerchi un gioco che intrattenga i tuoi figli e che sia l'ideale per essere alla moda, non perdere gli elastici per fare bracciali con le perline di Frozen . Contiene 130 elastici di diversi colori, perline di differenti forme con i protagonisti di Frozen, 1 gancino metallico, una chiusura a S, perline di diversi colori, 1 strumento per tenere gli elastici. Età consigliata: +5 anni.
Dimenzioni per Elastici per fare bracciali con Perline di Frozen:
Altezza: 18 Cm Larghezza: 3.5 Cm Profondita': 15 Cm Peso: 0.102 Kg Codice Prodotto (EAN): 8714274680036
","Se cerchi un gioco che intrattenga i tuoi figli e che sia l'ideale per essere alla moda, non perdere gli elastici per fare bracciali con le perline di Frozen. Maggiori Informazioni ",0.102,1,"Taxable Goods","Catalog, Search",35,,,,Elastici-per-fare-bracciali-con-Perline-di-Frozen,"Elastici per fare bracciali con Perline di Frozen","Giochi Bambini,Giochi,Bambini,Giocattoli e Giochi,Giocattoli,Giochi,Giochi educativi,Giochi,educativi,","Se cerchi un gioco che intrattenga i tuoi figli e che sia l'ideale per essere alla moda, non perdere gli elastici per fare bracciali con le perline di Frozen",http://dropshipping.bigbuy.eu/imgs/H4530316_93063.jpg,,http://dropshipping.bigbuy.eu/imgs/H4530316_93063.jpg,,,,,,"2016-08-08 21:04:27",,,,,,,,,,,,,,,,,"GTIN=8714274680036",78,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/H4530316_93067.jpg,http://dropshipping.bigbuy.eu/imgs/H4530316_93066.jpg,http://dropshipping.bigbuy.eu/imgs/H4530316_93065.jpg,http://dropshipping.bigbuy.eu/imgs/H4530316_93064.jpg","GTIN=8714274680036",,,,,,,,,,
+BB-V1300134,,Default,simple,"Default Category/Giochi Bambini,Default Category/Giochi Bambini/Neonati e Bambini,Default Category/Giochi Bambini/Neonati e Bambini/Ombrelli e cappellini per bambini",base,"Berretto per Bambini Cars Rosso","Vuoi
sorprendere i piccoli della tua casa? Lightning McQueen proteggerà i più piccoli della casa dal sole di questa estate! Non perderti il berretto per bambini Cars . Dimensioni 54-56 cm. Misure della visiera: 14 x 6,5 cm circa. Composizione: 65% cotone e 35% poliestere Dimenzioni per Berretto per Bambini Cars:
Altezza: 10 Cm Larghezza: 17 Cm Profondita': 21 Cm Peso: 0.048 Kg Codice Prodotto (EAN): 8427934797318
","Vuoi sorprendere i piccoli della tua casa? Lightning McQueen proteggerà i più piccoli della casa dal sole di questa estate! Non perderti il berretto per bambini Cars. Maggiori Informazioni ",0.048,1,"Taxable Goods","Catalog, Search",7.9,,,,Berretto-per-Bambini-Cars-Rosso,"Berretto per Bambini Cars Rosso","Giochi Bambini,Giochi,Bambini,Neonati e Bambini,Neonati,Bambini,Ombrelli e cappellini per bambini,Ombrelli,cappellini,bambini,Colore Rosso,Rosso,","Vuoi sorprendere i piccoli della tua casa? Lightning McQueen proteggerà i più piccoli della casa dal sole di questa estate! Non perderti il berretto per bambini Cars",http://dropshipping.bigbuy.eu/imgs/V1300133_91571.jpg,,http://dropshipping.bigbuy.eu/imgs/V1300133_91571.jpg,,,,,,"-0001-11-30 00:00:00",,,,,,,,,,,,,,,,,"GTIN=8427934797318",87,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/V1300133_91229.jpg,http://dropshipping.bigbuy.eu/imgs/V1300133_91197.jpg,http://dropshipping.bigbuy.eu/imgs/V1300133_91196.jpg,http://dropshipping.bigbuy.eu/imgs/V1300133_91195.jpg,http://dropshipping.bigbuy.eu/imgs/V1300133_91194.jpg,http://dropshipping.bigbuy.eu/imgs/V1300133_91193.jpg","GTIN=8427934797318",,,,,,,,,,
+BB-V1300135,,Default,simple,"Default Category/Giochi Bambini,Default Category/Giochi Bambini/Neonati e Bambini,Default Category/Giochi Bambini/Neonati e Bambini/Ombrelli e cappellini per bambini",base,"Berretto per Bambini Cars Nero","Vuoi
sorprendere i piccoli della tua casa? Lightning McQueen proteggerà i più piccoli della casa dal sole di questa estate! Non perderti il berretto per bambini Cars . Dimensioni 54-56 cm. Misure della visiera: 14 x 6,5 cm circa. Composizione: 65% cotone e 35% poliestere Dimenzioni per Berretto per Bambini Cars:
Altezza: 10 Cm Larghezza: 17 Cm Profondita': 21 Cm Peso: 0.048 Kg Codice Prodotto (EAN): 8427934797301
","Vuoi sorprendere i piccoli della tua casa? Lightning McQueen proteggerà i più piccoli della casa dal sole di questa estate! Non perderti il berretto per bambini Cars. Maggiori Informazioni ",0.048,1,"Taxable Goods","Catalog, Search",7.9,,,,Berretto-per-Bambini-Cars-Nero,"Berretto per Bambini Cars Nero","Giochi Bambini,Giochi,Bambini,Neonati e Bambini,Neonati,Bambini,Ombrelli e cappellini per bambini,Ombrelli,cappellini,bambini,Colore Nero,Nero,","Vuoi sorprendere i piccoli della tua casa? Lightning McQueen proteggerà i più piccoli della casa dal sole di questa estate! Non perderti il berretto per bambini Cars",http://dropshipping.bigbuy.eu/imgs/V1300133_91229.jpg,,http://dropshipping.bigbuy.eu/imgs/V1300133_91229.jpg,,,,,,"-0001-11-30 00:00:00",,,,,,,,,,,,,,,,,"GTIN=8427934797301",123,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/V1300133_91571.jpg,http://dropshipping.bigbuy.eu/imgs/V1300133_91197.jpg,http://dropshipping.bigbuy.eu/imgs/V1300133_91196.jpg,http://dropshipping.bigbuy.eu/imgs/V1300133_91195.jpg,http://dropshipping.bigbuy.eu/imgs/V1300133_91194.jpg,http://dropshipping.bigbuy.eu/imgs/V1300133_91193.jpg","GTIN=8427934797301",,,,,,,,,,
+BB-V1300138,,Default,simple,"Default Category/Giochi Bambini,Default Category/Giochi Bambini/Neonati e Bambini,Default Category/Giochi Bambini/Neonati e Bambini/Ombrelli e cappellini per bambini",base,"Cappello per Bambini Batman vs Superman Blu Marino","A
quale bambino non piace vantarsi dei suoi accessori moda ? Sorprendi i più piccoli con il cappello per bambini Batman vs Superman e quest'estate fai sì che siano ben protetti dai raggi solari. Taglia 52-54 cm. Dimensioni della visiera: 15 x 6,5 cm circa. Composizione: 65 % cotone e 35 % poliestere. Dimenzioni per Cappello per Bambini Batman vs Superman:
Altezza: 10 Cm Larghezza: 19 Cm Profondita': 20 Cm Peso: 0.048 Kg Codice Prodotto (EAN): 8427934824359
","A quale bambino non piace vantarsi dei suoi accessori moda? Sorprendi i più piccoli con il cappello per bambini Batman vs Superman e quest'estate fai sì che siano ben protetti dai raggi solari. Maggiori Informazioni ",0.048,1,"Taxable Goods","Catalog, Search",12.5,,,,Cappello-per-Bambini-Batman-vs-Superman-Blu Marino,"Cappello per Bambini Batman vs Superman Blu Marino","Giochi Bambini,Giochi,Bambini,Neonati e Bambini,Neonati,Bambini,Ombrelli e cappellini per bambini,Ombrelli,cappellini,bambini,Colore Blu Marino,Blu Marino,","A quale bambino non piace vantarsi dei suoi accessori moda? Sorprendi i più piccoli con il cappello per bambini Batman vs Superman e quest'estate fai sì che siano ben protetti dai raggi solari",http://dropshipping.bigbuy.eu/imgs/V1300136_91230.jpg,,http://dropshipping.bigbuy.eu/imgs/V1300136_91230.jpg,,,,,,"-0001-11-30 00:00:00",,,,,,,,,,,,,,,,,"GTIN=8427934824359",98,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/V1300136_91231.jpg,http://dropshipping.bigbuy.eu/imgs/V1300136_91201.jpg,http://dropshipping.bigbuy.eu/imgs/V1300136_91200.jpg,http://dropshipping.bigbuy.eu/imgs/V1300136_91199.jpg","GTIN=8427934824359",,,,,,,,,,
+BB-V1300137,,Default,simple,"Default Category/Giochi Bambini,Default Category/Giochi Bambini/Neonati e Bambini,Default Category/Giochi Bambini/Neonati e Bambini/Ombrelli e cappellini per bambini",base,"Cappello per Bambini Batman vs Superman Grigio","A
quale bambino non piace vantarsi dei suoi accessori moda ? Sorprendi i più piccoli con il cappello per bambini Batman vs Superman e quest'estate fai sì che siano ben protetti dai raggi solari. Taglia 52-54 cm. Dimensioni della visiera: 15 x 6,5 cm circa. Composizione: 65 % cotone e 35 % poliestere. Dimenzioni per Cappello per Bambini Batman vs Superman:
Altezza: 10 Cm Larghezza: 19 Cm Profondita': 20 Cm Peso: 0.048 Kg Codice Prodotto (EAN): 8427934824335
","A quale bambino non piace vantarsi dei suoi accessori moda? Sorprendi i più piccoli con il cappello per bambini Batman vs Superman e quest'estate fai sì che siano ben protetti dai raggi solari. Maggiori Informazioni ",0.048,1,"Taxable Goods","Catalog, Search",12.5,,,,Cappello-per-Bambini-Batman-vs-Superman-Grigio,"Cappello per Bambini Batman vs Superman Grigio","Giochi Bambini,Giochi,Bambini,Neonati e Bambini,Neonati,Bambini,Ombrelli e cappellini per bambini,Ombrelli,cappellini,bambini,Colore Grigio,Grigio,","A quale bambino non piace vantarsi dei suoi accessori moda? Sorprendi i più piccoli con il cappello per bambini Batman vs Superman e quest'estate fai sì che siano ben protetti dai raggi solari",http://dropshipping.bigbuy.eu/imgs/V1300136_91231.jpg,,http://dropshipping.bigbuy.eu/imgs/V1300136_91231.jpg,,,,,,"-0001-11-30 00:00:00",,,,,,,,,,,,,,,,,"GTIN=8427934824335",102,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/V1300136_91230.jpg,http://dropshipping.bigbuy.eu/imgs/V1300136_91201.jpg,http://dropshipping.bigbuy.eu/imgs/V1300136_91200.jpg,http://dropshipping.bigbuy.eu/imgs/V1300136_91199.jpg","GTIN=8427934824335",,,,,,,,,,
+BB-V1300125,,Default,simple,"Default Category/Giochi Bambini,Default Category/Giochi Bambini/Neonati e Bambini,Default Category/Giochi Bambini/Neonati e Bambini/Ombrelli e cappellini per bambini",base,"Berretto per Bambini Avengers Rosso","A
quale bambino non piace mostrare gli accessori di moda ? Sorprendili con il berretto per bambini Avengers e proteggili dai raggi del sole di questa estate. Taglia 52-54 cm. Dimensioni della visiera: 15 x 6,5 cm circa. Composizione: 65% cotone e 35% poliestere. Dimenzioni per Berretto per Bambini Avengers:
Altezza: 10 Cm Larghezza: 20 Cm Profondita': 18 Cm Peso: 0.048 Kg Codice Prodotto (EAN): 8427934792252
","A quale bambino non piace mostrare gli accessori di moda? Sorprendili con il berretto per bambini Avengers e proteggili dai raggi del sole di questa estate. Maggiori Informazioni ",0.048,1,"Taxable Goods","Catalog, Search",10.9,,,,Berretto-per-Bambini-Avengers-Rosso,"Berretto per Bambini Avengers Rosso","Giochi Bambini,Giochi,Bambini,Neonati e Bambini,Neonati,Bambini,Ombrelli e cappellini per bambini,Ombrelli,cappellini,bambini,Colore Rosso,Rosso,","A quale bambino non piace mostrare gli accessori di moda? Sorprendili con il berretto per bambini Avengers e proteggili dai raggi del sole di questa estate",http://dropshipping.bigbuy.eu/imgs/V1300124_91179.jpg,,http://dropshipping.bigbuy.eu/imgs/V1300124_91179.jpg,,,,,,"-0001-11-30 00:00:00",,,,,,,,,,,,,,,,,"GTIN=8427934792252",101,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/V1300124_91180.jpg,http://dropshipping.bigbuy.eu/imgs/V1300124_91178.jpg,http://dropshipping.bigbuy.eu/imgs/V1300124_91177.jpg,http://dropshipping.bigbuy.eu/imgs/V1300124_91176.jpg,http://dropshipping.bigbuy.eu/imgs/V1300124_91175.jpg","GTIN=8427934792252",,,,,,,,,,
+BB-V1300126,,Default,simple,"Default Category/Giochi Bambini,Default Category/Giochi Bambini/Neonati e Bambini,Default Category/Giochi Bambini/Neonati e Bambini/Ombrelli e cappellini per bambini",base,"Berretto per Bambini Avengers Nero","A
quale bambino non piace mostrare gli accessori di moda ? Sorprendili con il berretto per bambini Avengers e proteggili dai raggi del sole di questa estate. Taglia 52-54 cm. Dimensioni della visiera: 15 x 6,5 cm circa. Composizione: 65% cotone e 35% poliestere. Dimenzioni per Berretto per Bambini Avengers:
Altezza: 10 Cm Larghezza: 20 Cm Profondita': 18 Cm Peso: 0.048 Kg Codice Prodotto (EAN): 8427934792269
","A quale bambino non piace mostrare gli accessori di moda? Sorprendili con il berretto per bambini Avengers e proteggili dai raggi del sole di questa estate. Maggiori Informazioni ",0.048,1,"Taxable Goods","Catalog, Search",10.9,,,,Berretto-per-Bambini-Avengers-Nero,"Berretto per Bambini Avengers Nero","Giochi Bambini,Giochi,Bambini,Neonati e Bambini,Neonati,Bambini,Ombrelli e cappellini per bambini,Ombrelli,cappellini,bambini,Colore Nero,Nero,","A quale bambino non piace mostrare gli accessori di moda? Sorprendili con il berretto per bambini Avengers e proteggili dai raggi del sole di questa estate",http://dropshipping.bigbuy.eu/imgs/V1300124_91180.jpg,,http://dropshipping.bigbuy.eu/imgs/V1300124_91180.jpg,,,,,,"-0001-11-30 00:00:00",,,,,,,,,,,,,,,,,"GTIN=8427934792269",92,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/V1300124_91179.jpg,http://dropshipping.bigbuy.eu/imgs/V1300124_91178.jpg,http://dropshipping.bigbuy.eu/imgs/V1300124_91177.jpg,http://dropshipping.bigbuy.eu/imgs/V1300124_91176.jpg,http://dropshipping.bigbuy.eu/imgs/V1300124_91175.jpg","GTIN=8427934792269",,,,,,,,,,
+BB-V0500179,,Default,simple,"Default Category/Giochi Bambini,Default Category/Giochi Bambini/Neonati e Bambini,Default Category/Giochi Bambini/Neonati e Bambini/Stoviglie per bambini",base,"Posate Bambini Disney (5 pezzi) Minnie","Quando
i piccoli di casa hanno già familiarizzato con il fatto di mangiare da soli, bisogna fare il passo successivo e comprare loro il set per mangiare da grandi, come le posate per bambini Disney (5 pezzi). Include: 1 piatto fondo, 1 piatto piano, 1 cucchiaio, 1 forchetta e 1 tazza.Età raccomandata: +12 mesi Realizzato in polipropilene (senza BPA) Adatto a lavastoviglie e microonde Dimensioni del piatto fondo (diametro x altura): 15,5 x 3 cm circa Dimensioni del piatto piano (diametro x altura): 22 x 1,5 cm circa Lunghezza del cucchiaio: 15,5 cm circa Lunghezza della forchetta: 15,5 cm circa Dimensioni della tazza: 11 x 8,5 x 8,5 cm circa Capacità della tazza: circa 250 ml Conforme alla normativa UNE-EN 14372 (requisiti di sicurezza per gli articoli di puericultura per l'alimentazione: servizio di posate e utensili) Conforme alla normativa UNE-EN 14350 (requisiti di sicurezza per gli articoli di puericultura per l'alimentazione liquida) Dimenzioni per Posate Bambini Disney (5 pezzi):
Altezza: 27.5 Cm Larghezza: 9.7 Cm Profondita': 9 Cm Peso: 0.487 Kg Codice Prodotto (EAN): 3662332013348
","Quando i piccoli di casa hanno già familiarizzato con il fatto di mangiare da soli, bisogna fare il passo successivo e comprare loro il set per mangiare da grandi, come le posate per bambini Disney (5 pezzi). Maggiori Informazioni ",0.487,1,"Taxable Goods","Catalog, Search",41.5,,,,Posate-Bambini-Disney-(5-pezzi)-Minnie,"Posate Bambini Disney (5 pezzi) Minnie","Giochi Bambini,Giochi,Bambini,Neonati e Bambini,Neonati,Bambini,Stoviglie per bambini,Stoviglie,bambini,Modello Minnie,Minnie,","Quando i piccoli di casa hanno già familiarizzato con il fatto di mangiare da soli, bisogna fare il passo successivo e comprare loro il set per mangiare da grandi, come le posate per bambini Disney (5 pezzi)",http://dropshipping.bigbuy.eu/imgs/V0500178_92050.jpg,,http://dropshipping.bigbuy.eu/imgs/V0500178_92050.jpg,,,,,,"-0001-11-30 00:00:00",,,,,,,,,,,,,,,,,"GTIN=3662332013348",34,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/V0500178_92051.jpg,http://dropshipping.bigbuy.eu/imgs/V0500178_92049.jpg","GTIN=3662332013348",,,,,,,,,,
+BB-V0500180,,Default,simple,"Default Category/Giochi Bambini,Default Category/Giochi Bambini/Neonati e Bambini,Default Category/Giochi Bambini/Neonati e Bambini/Stoviglie per bambini",base,"Posate Bambini Disney (5 pezzi) Mickey","Quando
i piccoli di casa hanno già familiarizzato con il fatto di mangiare da soli, bisogna fare il passo successivo e comprare loro il set per mangiare da grandi, come le posate per bambini Disney (5 pezzi). Include: 1 piatto fondo, 1 piatto piano, 1 cucchiaio, 1 forchetta e 1 tazza.Età raccomandata: +12 mesi Realizzato in polipropilene (senza BPA) Adatto a lavastoviglie e microonde Dimensioni del piatto fondo (diametro x altura): 15,5 x 3 cm circa Dimensioni del piatto piano (diametro x altura): 22 x 1,5 cm circa Lunghezza del cucchiaio: 15,5 cm circa Lunghezza della forchetta: 15,5 cm circa Dimensioni della tazza: 11 x 8,5 x 8,5 cm circa Capacità della tazza: circa 250 ml Conforme alla normativa UNE-EN 14372 (requisiti di sicurezza per gli articoli di puericultura per l'alimentazione: servizio di posate e utensili) Conforme alla normativa UNE-EN 14350 (requisiti di sicurezza per gli articoli di puericultura per l'alimentazione liquida) Dimenzioni per Posate Bambini Disney (5 pezzi):
Altezza: 27.5 Cm Larghezza: 9.7 Cm Profondita': 9 Cm Peso: 0.487 Kg Codice Prodotto (EAN): 3662332013355
","Quando i piccoli di casa hanno già familiarizzato con il fatto di mangiare da soli, bisogna fare il passo successivo e comprare loro il set per mangiare da grandi, come le posate per bambini Disney (5 pezzi). Maggiori Informazioni ",0.487,1,"Taxable Goods","Catalog, Search",41.5,,,,Posate-Bambini-Disney-(5-pezzi)-Mickey,"Posate Bambini Disney (5 pezzi) Mickey","Giochi Bambini,Giochi,Bambini,Neonati e Bambini,Neonati,Bambini,Stoviglie per bambini,Stoviglie,bambini,Modello Mickey,Mickey,","Quando i piccoli di casa hanno già familiarizzato con il fatto di mangiare da soli, bisogna fare il passo successivo e comprare loro il set per mangiare da grandi, come le posate per bambini Disney (5 pezzi)",http://dropshipping.bigbuy.eu/imgs/V0500178_92051.jpg,,http://dropshipping.bigbuy.eu/imgs/V0500178_92051.jpg,,,,,,"-0001-11-30 00:00:00",,,,,,,,,,,,,,,,,"GTIN=3662332013355",37,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/V0500178_92050.jpg,http://dropshipping.bigbuy.eu/imgs/V0500178_92049.jpg","GTIN=3662332013355",,,,,,,,,,
+BB-V1300179,,Default,simple,"Default Category/Giochi Bambini,Default Category/Giochi Bambini/Neonati e Bambini,Default Category/Giochi Bambini/Neonati e Bambini/Ombrelli e cappellini per bambini",base,"Ombrello per Bambini Pieghevole Star Wars","Ti
presentiamo l'ombrello più galattico del pianeta, l'ombrello per bambini pieghevole Star Wars ! Perfetto come regalo per bambini. Struttura: 75 % metallo, 25 % plastica Cupola: 100 % poliestere Lunghezza: circa 23-52 cm Diametro: circa 85 cm Custodia inclusa
Dimenzioni per Ombrello per Bambini Pieghevole Star Wars:
Altezza: 4 Cm Larghezza: 6.5 Cm Profondita': 23 Cm Peso: 0.255 Kg Codice Prodotto (EAN): 7569000732739
","Ti presentiamo l'ombrello più galattico del pianeta, l'ombrello per bambini pieghevole Star Wars! Perfetto come regalo per bambini. Maggiori Informazioni ",0.255,1,"Taxable Goods","Catalog, Search",24.5,,,,Ombrello-per-Bambini-Pieghevole-Star-Wars,"Ombrello per Bambini Pieghevole Star Wars","Giochi Bambini,Giochi,Bambini,Neonati e Bambini,Neonati,Bambini,Ombrelli e cappellini per bambini,Ombrelli,cappellini,bambini,","Ti presentiamo l'ombrello più galattico del pianeta, l'ombrello per bambini pieghevole Star Wars! Perfetto come regalo per bambini",http://dropshipping.bigbuy.eu/imgs/V1300179_101280.jpg,,http://dropshipping.bigbuy.eu/imgs/V1300179_101280.jpg,,,,,,"2016-08-29 12:58:30",,,,,,,,,,,,,,,,,"GTIN=7569000732739",0,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/V1300179_101281.jpg,http://dropshipping.bigbuy.eu/imgs/V1300179_101279.jpg,http://dropshipping.bigbuy.eu/imgs/V1300179_101278.jpg,http://dropshipping.bigbuy.eu/imgs/V1300179_101277.jpg","GTIN=7569000732739",,,,,,,,,,
+BB-V1300195,,Default,simple,"Default Category/Giochi Bambini,Default Category/Giochi Bambini/Neonati e Bambini,Default Category/Giochi Bambini/Neonati e Bambini/Passeggiate e viaggi",base,"Borsa Termica Porta Merenda Rubble (PAW Patrol)","Ti
presentiamo la borsa termica porta merende Rubble (PAW Patrol) ! Dispone di un disegno in rilievo nella parte frontale (gomma EVA), cerniera, manico e due cinte regolabili per appenderla. Ideale per portare con sé il pranzo e la merenda.Dimensioni: circa 23 x 19 x 8 cm Composizione: poliestere, schiuma di poliuretano e PEVA (polietilene di acetato di vinilo) Dimenzioni per Borsa Termica Porta Merenda Rubble (PAW Patrol):
Altezza: 4 Cm Larghezza: 22 Cm Profondita': 26 Cm Peso: 0.196 Kg Codice Prodotto (EAN): 7569000732890
","Ti presentiamo la borsa termica porta merende Rubble (PAW Patrol)! Dispone di un disegno in rilievo nella parte frontale (gomma EVA), cerniera, manico e due cinte regolabili per appenderla. Maggiori Informazioni ",0.196,1,"Taxable Goods","Catalog, Search",26.9,,,,Borsa-Termica-Porta-Merenda-Rubble-(PAW-Patrol),"Borsa Termica Porta Merenda Rubble (PAW Patrol)","Giochi Bambini,Giochi,Bambini,Neonati e Bambini,Neonati,Bambini,Passeggiate e viaggi,Passeggiate,viaggi,","Ti presentiamo la borsa termica porta merende Rubble (PAW Patrol)! Dispone di un disegno in rilievo nella parte frontale (gomma EVA), cerniera, manico e due cinte regolabili per appenderla",http://dropshipping.bigbuy.eu/imgs/V1300195_101259.jpg,,http://dropshipping.bigbuy.eu/imgs/V1300195_101259.jpg,,,,,,"2016-08-26 13:36:55",,,,,,,,,,,,,,,,,"GTIN=7569000732890",59,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/V1300195_101258.jpg,http://dropshipping.bigbuy.eu/imgs/V1300195_101257.jpg,http://dropshipping.bigbuy.eu/imgs/V1300195_101256.jpg","GTIN=7569000732890",,,,,,,,,,
+BB-V1300196,,Default,simple,"Default Category/Giochi Bambini,Default Category/Giochi Bambini/Neonati e Bambini,Default Category/Giochi Bambini/Neonati e Bambini/Passeggiate e viaggi",base,"Borsa Termica Porta Merenda Everest (PAW Patrol)","Scopri
la borsa termica porta merenda Everest (PAW Patrol) che sta facendo furore tra i bambini! Dispone di un disegno in rilievo nella parte frontale (gomma EVA), cerniera, manico e due cinte regolabili per appenderla. Perfetta per portare con sé il pranzo e la merenda.Dimensioni: circa 23 x 19 x 8 cm Composizione: poliestere, schiuma di poliuretano e PEVA (polietilene di acetato di vinilo) Dimenzioni per Borsa Termica Porta Merenda Everest (PAW Patrol):
Altezza: 4 Cm Larghezza: 22 Cm Profondita': 26 Cm Peso: 0.196 Kg Codice Prodotto (EAN): 7569000732906
","Scopri la borsa termica porta merenda Everest (PAW Patrol) che sta facendo furore tra i bambini! Dispone di un disegno in rilievo nella parte frontale (gomma EVA), cerniera, manico e due cinte regolabili per appenderla. Maggiori Informazioni ",0.196,1,"Taxable Goods","Catalog, Search",26.9,,,,Borsa-Termica-Porta-Merenda-Everest-(PAW-Patrol),"Borsa Termica Porta Merenda Everest (PAW Patrol)","Giochi Bambini,Giochi,Bambini,Neonati e Bambini,Neonati,Bambini,Passeggiate e viaggi,Passeggiate,viaggi,","Scopri la borsa termica porta merenda Everest (PAW Patrol) che sta facendo furore tra i bambini! Dispone di un disegno in rilievo nella parte frontale (gomma EVA), cerniera, manico e due cinte regolabili per appenderla",http://dropshipping.bigbuy.eu/imgs/V1300196_101260.jpg,,http://dropshipping.bigbuy.eu/imgs/V1300196_101260.jpg,,,,,,"2016-08-26 13:36:36",,,,,,,,,,,,,,,,,"GTIN=7569000732906",51,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/V1300196_101263.jpg,http://dropshipping.bigbuy.eu/imgs/V1300196_101262.jpg,http://dropshipping.bigbuy.eu/imgs/V1300196_101261.jpg","GTIN=7569000732906",,,,,,,,,,
+BB-V1300198,,Default,simple,"Default Category/Giochi Bambini,Default Category/Giochi Bambini/Neonati e Bambini,Default Category/Giochi Bambini/Neonati e Bambini/Passeggiate e viaggi",base,"Borsa Termica Porta Merenda Frozen","Tutte
le bambine vogliono subito la borsa termica porta merenda Frozen ! Dispone di un disegno in rilievo nella parte frontale (gomma EVA), cerniera, manico e due cinte regolabili per appenderla. Perfetta per portare con sé il pranzo e la merenda.Dimensioni: circa 23 x 19 x 8 cm Composizione: poliestere, schiuma di poliuretano e PEVA (polietilene di acetato di vinilo) Dimenzioni per Borsa Termica Porta Merenda Frozen:
Altezza: 4 Cm Larghezza: 22 Cm Profondita': 26 Cm Peso: 0.196 Kg Codice Prodotto (EAN): 7569000732920
","Tutte le bambine vogliono subito la borsa termica porta merenda Frozen! Dispone di un disegno in rilievo nella parte frontale (gomma EVA), cerniera, manico e due cinte regolabili per appenderla. Maggiori Informazioni ",0.196,1,"Taxable Goods","Catalog, Search",26.9,,,,Borsa-Termica-Porta-Merenda-Frozen,"Borsa Termica Porta Merenda Frozen","Giochi Bambini,Giochi,Bambini,Neonati e Bambini,Neonati,Bambini,Passeggiate e viaggi,Passeggiate,viaggi,","Tutte le bambine vogliono subito la borsa termica porta merenda Frozen! Dispone di un disegno in rilievo nella parte frontale (gomma EVA), cerniera, manico e due cinte regolabili per appenderla",http://dropshipping.bigbuy.eu/imgs/V1300198_101268.jpg,,http://dropshipping.bigbuy.eu/imgs/V1300198_101268.jpg,,,,,,"2016-08-30 07:32:17",,,,,,,,,,,,,,,,,"GTIN=7569000732920",52,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/V1300198_101271.jpg,http://dropshipping.bigbuy.eu/imgs/V1300198_101270.jpg,http://dropshipping.bigbuy.eu/imgs/V1300198_101269.jpg","GTIN=7569000732920",,,,,,,,,,
+BB-V1300204,,Default,simple,"Default Category/Giochi Bambini,Default Category/Giochi Bambini/Materiale Scolastico,Default Category/Giochi Bambini/Materiale Scolastico/Astucci e portapenne",base,"Astuccio Scuola 3D Frozen","Le
piccola fan delle principesse Anna ed Elsa non possono tornare a scuola senza l'astuccio scuola 3D Frozen !Cinque scompartimenti separati Due cerniere Dimensioni: 21,5 x 12 x 10 cm circa Composizione: poliestere Dimenzioni per Astuccio Scuola 3D Frozen:
Altezza: 2 Cm Larghezza: 24 Cm Profondita': 14 Cm Peso: 0.099 Kg Codice Prodotto (EAN): 7569000733248
","Le piccola fan delle principesse Anna ed Elsa non possono tornare a scuola senza l'astuccio scuola 3D Frozen!Cinque scompartimenti separatiDue cerniereDimensioni: 21,5 x 12 x 10 cm circaComposizione: poliestere. Maggiori Informazioni ",0.099,1,"Taxable Goods","Catalog, Search",19.9,,,,Astuccio-Scuola-3D-Frozen,"Astuccio Scuola 3D Frozen","Giochi Bambini,Giochi,Bambini,Materiale Scolastico,Materiale,Scolastico,Astucci e portapenne,Astucci,portapenne,","Le piccola fan delle principesse Anna ed Elsa non possono tornare a scuola senza l'astuccio scuola 3D Frozen!Cinque scompartimenti separatiDue cerniereDimensioni: 21,5 x 12 x 10 cm circaComposizione: poliestere",http://dropshipping.bigbuy.eu/imgs/V1300204_102661.jpg,,http://dropshipping.bigbuy.eu/imgs/V1300204_102661.jpg,,,,,,"2016-09-14 07:51:11",,,,,,,,,,,,,,,,,"GTIN=7569000733248",138,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/V1300204_102663.jpg,http://dropshipping.bigbuy.eu/imgs/V1300204_102662.jpg","GTIN=7569000733248",,,,,,,,,,
+BB-V1300208,,Default,simple,"Default Category/Giochi Bambini,Default Category/Giochi Bambini/Materiale Scolastico,Default Category/Giochi Bambini/Materiale Scolastico/Zaini scuola",base,"Zaino-Sacca Frozen","Lo
zaino-sacca Frozen è lo zaino che sta facendo furore tra le bambine!Realizzato in poliestere Manico superiore e cinghie con velcro Tasca frontale con cerniera Dimensioni: circa 33 x 44 cm
Dimenzioni per Zaino-Sacca Frozen:
Altezza: 0.5 Cm Larghezza: 37 Cm Profondita': 46 Cm Peso: 0.138 Kg Codice Prodotto (EAN): 7569000733286
","Lo zaino-sacca Frozen è lo zaino che sta facendo furore tra le bambine!Realizzato in poliestereManico superiore e cinghie con velcroTasca frontale con cernieraDimensioni: circa 33 x 44 cm . Maggiori Informazioni ",0.138,1,"Taxable Goods","Catalog, Search",24.9,,,,Zaino-Sacca-Frozen,"Zaino-Sacca Frozen","Giochi Bambini,Giochi,Bambini,Materiale Scolastico,Materiale,Scolastico,Zaini scuola,Zaini,scuola,","Lo zaino-sacca Frozen è lo zaino che sta facendo furore tra le bambine!Realizzato in poliestereManico superiore e cinghie con velcroTasca frontale con cernieraDimensioni: circa 33 x 44 cm ",http://dropshipping.bigbuy.eu/imgs/V1300208_102667.jpg,,http://dropshipping.bigbuy.eu/imgs/V1300208_102667.jpg,,,,,,"2016-09-14 07:50:58",,,,,,,,,,,,,,,,,"GTIN=7569000733286",141,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/V1300208_102669.jpg,http://dropshipping.bigbuy.eu/imgs/V1300208_102668.jpg","GTIN=7569000733286",,,,,,,,,,
+BB-I4115041,,Default,simple,"Default Category/Informatica Elettronica,Default Category/Informatica Elettronica/Telefonia e Accessori,Default Category/Informatica Elettronica/Telefonia e Accessori/Cover e custodie",base,"Custodia Impermeabile per Cellulare WpShield Azzurro","Sei
una di quelle persone che portano il loro smartphone ovunque? Se desideri che il tuo telefono venga protetto dalla sporcizia, sabbia, graffi e anche dall'acqua, non perderti la custodia impermeabile per cellulare WpShield . Con questa custodia impermeabile potrai portare il telefono ovunque ti piaccia, anche per un tuffo in piscina o sul mare.www.waterproofshield.com Questa custodia impermeabile dispone sia di un cinturino con chiusura a velcro (lunghezza massima: circa 37 cm) e un cavo con chiusura di sicurezza da indossare al collo (lunghezza massima: circa 60 cm). Composizione: PVC (Spessore: circa 3 mm). Dimensioni: circa 10,5 x 15,5 cm. Dimenzioni per Custodia Impermeabile per Cellulare WpShield :
Altezza: 20 Cm Larghezza: 11.1 Cm Profondita': 1.9 Cm Peso: 0.06 Kg Codice Prodotto (EAN): 4899888106722
","Sei una di quelle persone che portano il loro smartphone ovunque? Se desideri che il tuo telefono venga protetto dalla sporcizia, sabbia, graffi e anche dall'acqua, non perderti la custodia impermeabile per cellulare WpShield. Maggiori Informazioni ",0.06,1,"Taxable Goods","Catalog, Search",14.5,,,,Custodia-Impermeabile-per-Cellulare-WpShield-Azzurro,"Custodia Impermeabile per Cellulare WpShield Azzurro","Informatica Elettronica,Informatica,Elettronica,Telefonia e Accessori,Telefonia,Accessori,Cover e custodie,Cover,custodie,Colore Azzurro,Azzurro,","Sei una di quelle persone che portano il loro smartphone ovunque? Se desideri che il tuo telefono venga protetto dalla sporcizia, sabbia, graffi e anche dall'acqua, non perderti la custodia impermeabile per cellulare WpShield",http://dropshipping.bigbuy.eu/imgs/I4115040_78768.jpg,,http://dropshipping.bigbuy.eu/imgs/I4115040_78768.jpg,,,,,,"2015-12-21 12:09:49",,,,,,,,,,,,,,,,,"GTIN=4899888106722",4125,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/I4115040_78770.jpg,http://dropshipping.bigbuy.eu/imgs/I4115040_78769.jpg,http://dropshipping.bigbuy.eu/imgs/I4115040_78767.jpg","GTIN=4899888106722",,,,,,,,,,
+BB-I4115042,,Default,simple,"Default Category/Informatica Elettronica,Default Category/Informatica Elettronica/Telefonia e Accessori,Default Category/Informatica Elettronica/Telefonia e Accessori/Cover e custodie",base,"Custodia Impermeabile per Cellulare WpShield Bianco","Sei
una di quelle persone che portano il loro smartphone ovunque? Se desideri che il tuo telefono venga protetto dalla sporcizia, sabbia, graffi e anche dall'acqua, non perderti la custodia impermeabile per cellulare WpShield . Con questa custodia impermeabile potrai portare il telefono ovunque ti piaccia, anche per un tuffo in piscina o sul mare.www.waterproofshield.com Questa custodia impermeabile dispone sia di un cinturino con chiusura a velcro (lunghezza massima: circa 37 cm) e un cavo con chiusura di sicurezza da indossare al collo (lunghezza massima: circa 60 cm). Composizione: PVC (Spessore: circa 3 mm). Dimensioni: circa 10,5 x 15,5 cm. Dimenzioni per Custodia Impermeabile per Cellulare WpShield :
Altezza: 20 Cm Larghezza: 11.1 Cm Profondita': 1.9 Cm Peso: 0.06 Kg Codice Prodotto (EAN): 4899888106739
","Sei una di quelle persone che portano il loro smartphone ovunque? Se desideri che il tuo telefono venga protetto dalla sporcizia, sabbia, graffi e anche dall'acqua, non perderti la custodia impermeabile per cellulare WpShield. Maggiori Informazioni ",0.06,1,"Taxable Goods","Catalog, Search",14.5,,,,Custodia-Impermeabile-per-Cellulare-WpShield-Bianco,"Custodia Impermeabile per Cellulare WpShield Bianco","Informatica Elettronica,Informatica,Elettronica,Telefonia e Accessori,Telefonia,Accessori,Cover e custodie,Cover,custodie,Colore Bianco,Bianco,","Sei una di quelle persone che portano il loro smartphone ovunque? Se desideri che il tuo telefono venga protetto dalla sporcizia, sabbia, graffi e anche dall'acqua, non perderti la custodia impermeabile per cellulare WpShield",http://dropshipping.bigbuy.eu/imgs/I4115040_78770.jpg,,http://dropshipping.bigbuy.eu/imgs/I4115040_78770.jpg,,,,,,"2015-12-21 12:10:05",,,,,,,,,,,,,,,,,"GTIN=4899888106739",4321,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/I4115040_78768.jpg,http://dropshipping.bigbuy.eu/imgs/I4115040_78769.jpg,http://dropshipping.bigbuy.eu/imgs/I4115040_78767.jpg","GTIN=4899888106739",,,,,,,,,,
+BB-I4115044,,Default,simple,"Default Category/Informatica Elettronica,Default Category/Informatica Elettronica/Batterie, Caricatori, Adattatori",base,"Doppia Porta USB con Presa Elettrica e Caricabatteria da Auto Pocken Bianco","Non
uscire di casa senza la doppia porta USB con presa elettrica e caricabatteria da auto Pocken per auto! Puoi connetterla in auto o alla rete elettrica per ricaricare i dispositivi mobili, poichè include sia un adattatore per auto che una spina. Questo caricatore con doppio ingresso USB è molto pratico e semplice da usare. Dimensioni approssimative: 6 x 6 x 3,5 cm.www.pockenrg.com
Caratteristiche tecniche:
Ingresso AC: 100-240 V / 0.15 A / 50-60 Hz Ingresso DC: 12-24 V / 0.35 A Uscita DC: +5 V / 1 A Dimenzioni per Doppia Porta USB con Presa Elettrica e Caricabatteria da Auto Pocken :
Altezza: 4 Cm Larghezza: 6.5 Cm Profondita': 6.5 Cm Peso: 0.077 Kg Codice Prodotto (EAN): 4899888106944
","Non uscire di casa senza la doppia porta USB con presa elettrica e caricabatteria da auto Pocken per auto! Puoi connetterla in auto o alla rete elettrica per ricaricare i dispositivi mobili, poichè include sia un adattatore per auto che una spina. Maggiori Informazioni ",0.077,1,"Taxable Goods","Catalog, Search",29.99,,,,Doppia-Porta-USB-con-Presa-Elettrica-e-Caricabatteria-da-Auto-Pocken-Bianco,"Doppia Porta USB con Presa Elettrica e Caricabatteria da Auto Pocken Bianco","Informatica Elettronica,Informatica,Elettronica,Batterie, Caricatori, Adattatori,Batterie,,Caricatori,,Adattatori,Colore Bianco,Bianco,","Non uscire di casa senza la doppia porta USB con presa elettrica e caricabatteria da auto Pocken per auto! Puoi connetterla in auto o alla rete elettrica per ricaricare i dispositivi mobili, poichè include sia un adattatore per auto che una spina",http://dropshipping.bigbuy.eu/imgs/cargador_usb_doble_coche_0002.jpg,,http://dropshipping.bigbuy.eu/imgs/cargador_usb_doble_coche_0002.jpg,,,,,,"2015-05-14 07:58:09",,,,,,,,,,,,,,,,,"GTIN=4899888106944",161,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/cargador_usb_doble_coche_00.jpg,http://dropshipping.bigbuy.eu/imgs/cargador_usb_doble_coche_08.jpg,http://dropshipping.bigbuy.eu/imgs/cargador_usb_doble_coche_04.jpg,http://dropshipping.bigbuy.eu/imgs/cargador_usb_doble_coche_004.jpg,http://dropshipping.bigbuy.eu/imgs/cargador_usb_doble_coche_0004.jpg,http://dropshipping.bigbuy.eu/imgs/cargador_usb_doble_coche_03.jpg,http://dropshipping.bigbuy.eu/imgs/cargador_usb_doble_coche_0003.jpg","GTIN=4899888106944",,,,,,,,,,
+BB-I4115045,,Default,simple,"Default Category/Informatica Elettronica,Default Category/Informatica Elettronica/Batterie, Caricatori, Adattatori",base,"Doppia Porta USB con Presa Elettrica e Caricabatteria da Auto Pocken Nero","Non
uscire di casa senza la doppia porta USB con presa elettrica e caricabatteria da auto Pocken per auto! Puoi connetterla in auto o alla rete elettrica per ricaricare i dispositivi mobili, poichè include sia un adattatore per auto che una spina. Questo caricatore con doppio ingresso USB è molto pratico e semplice da usare. Dimensioni approssimative: 6 x 6 x 3,5 cm.www.pockenrg.com
Caratteristiche tecniche:
Ingresso AC: 100-240 V / 0.15 A / 50-60 Hz Ingresso DC: 12-24 V / 0.35 A Uscita DC: +5 V / 1 A Dimenzioni per Doppia Porta USB con Presa Elettrica e Caricabatteria da Auto Pocken :
Altezza: 4 Cm Larghezza: 6.5 Cm Profondita': 6.5 Cm Peso: 0.077 Kg Codice Prodotto (EAN): 4899888106678
","Non uscire di casa senza la doppia porta USB con presa elettrica e caricabatteria da auto Pocken per auto! Puoi connetterla in auto o alla rete elettrica per ricaricare i dispositivi mobili, poichè include sia un adattatore per auto che una spina. Maggiori Informazioni ",0.077,1,"Taxable Goods","Catalog, Search",29.99,,,,Doppia-Porta-USB-con-Presa-Elettrica-e-Caricabatteria-da-Auto-Pocken-Nero,"Doppia Porta USB con Presa Elettrica e Caricabatteria da Auto Pocken Nero","Informatica Elettronica,Informatica,Elettronica,Batterie, Caricatori, Adattatori,Batterie,,Caricatori,,Adattatori,Colore Nero,Nero,","Non uscire di casa senza la doppia porta USB con presa elettrica e caricabatteria da auto Pocken per auto! Puoi connetterla in auto o alla rete elettrica per ricaricare i dispositivi mobili, poichè include sia un adattatore per auto che una spina",http://dropshipping.bigbuy.eu/imgs/cargador_usb_doble_coche_00.jpg,,http://dropshipping.bigbuy.eu/imgs/cargador_usb_doble_coche_00.jpg,,,,,,"2015-08-18 12:37:09",,,,,,,,,,,,,,,,,"GTIN=4899888106678",265,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/cargador_usb_doble_coche_0002.jpg,http://dropshipping.bigbuy.eu/imgs/cargador_usb_doble_coche_08.jpg,http://dropshipping.bigbuy.eu/imgs/cargador_usb_doble_coche_04.jpg,http://dropshipping.bigbuy.eu/imgs/cargador_usb_doble_coche_004.jpg,http://dropshipping.bigbuy.eu/imgs/cargador_usb_doble_coche_0004.jpg,http://dropshipping.bigbuy.eu/imgs/cargador_usb_doble_coche_03.jpg,http://dropshipping.bigbuy.eu/imgs/cargador_usb_doble_coche_0003.jpg","GTIN=4899888106678",,,,,,,,,,
+BB-I3505259,,Default,simple,"Default Category/Informatica Elettronica,Default Category/Informatica Elettronica/Audio e Hi-Fi,Default Category/Informatica Elettronica/Audio e Hi-Fi/Cuffie",base,"Auricolari da Corsa GoFit Bianco","Fai
sport mentre ascolti la musica o parli al telefono indossando questi auricolari da corsa ! Questi auricolari sportivi GoFit sono molto comodi e pratici, si adattano perfettamente al tuo orecchio per una migliore aderenza. Progettate specificamente per gli altleti. Con materiali speciali e ottima qualità sonora. Caratteristiche:Suono: stereo Connessione audio: cavo con uscita 3,5 mm Microfono integrato Pulsante di risposta alla chiamata Risposta in frequenza: 20-20000 Hz Intensità del suono: 93 dB Impedenza dello speaker: 32 Ω Adatto agli iPhone, smartphone e telefoni cellulari Dimenzioni per Auricolari da Corsa GoFit:
Altezza: 20 Cm Larghezza: 9 Cm Profondita': 2.7 Cm Peso: 0.079 Kg Codice Prodotto (EAN): 8018417204005
","Fai sport mentre ascolti la musica o parli al telefono indossando questi auricolari da corsa! Questi auricolari sportivi GoFit sono molto comodi e pratici, si adattano perfettamente al tuo orecchio per una migliore aderenza. Maggiori Informazioni ",0.079,1,"Taxable Goods","Catalog, Search",38.9,,,,Auricolari-da-Corsa-GoFit-Bianco,"Auricolari da Corsa GoFit Bianco","Informatica Elettronica,Informatica,Elettronica,Audio e Hi-Fi,Audio,Hi-Fi,Cuffie,Colore Bianco,Bianco,","Fai sport mentre ascolti la musica o parli al telefono indossando questi auricolari da corsa! Questi auricolari sportivi GoFit sono molto comodi e pratici, si adattano perfettamente al tuo orecchio per una migliore aderenza",http://dropshipping.bigbuy.eu/imgs/I3505223_80641.jpg,,http://dropshipping.bigbuy.eu/imgs/I3505223_80641.jpg,,,,,,"2015-09-23 10:52:34",,,,,,,,,,,,,,,,,"GTIN=8018417204005",21,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/I3505223_80644.jpg,http://dropshipping.bigbuy.eu/imgs/I3505223_80643.jpg,http://dropshipping.bigbuy.eu/imgs/I3505223_80642.jpg,http://dropshipping.bigbuy.eu/imgs/I3505223_80640.jpg","GTIN=8018417204005",,,,,,,,,,
+BB-I3505260,,Default,simple,"Default Category/Informatica Elettronica,Default Category/Informatica Elettronica/Audio e Hi-Fi,Default Category/Informatica Elettronica/Audio e Hi-Fi/Cuffie",base,"Auricolari da Corsa GoFit Arancio","Fai
sport mentre ascolti la musica o parli al telefono indossando questi auricolari da corsa ! Questi auricolari sportivi GoFit sono molto comodi e pratici, si adattano perfettamente al tuo orecchio per una migliore aderenza. Progettate specificamente per gli altleti. Con materiali speciali e ottima qualità sonora. Caratteristiche:Suono: stereo Connessione audio: cavo con uscita 3,5 mm Microfono integrato Pulsante di risposta alla chiamata Risposta in frequenza: 20-20000 Hz Intensità del suono: 93 dB Impedenza dello speaker: 32 Ω Adatto agli iPhone, smartphone e telefoni cellulari Dimenzioni per Auricolari da Corsa GoFit:
Altezza: 20 Cm Larghezza: 9 Cm Profondita': 2.7 Cm Peso: 0.079 Kg Codice Prodotto (EAN): 8018417209512
","Fai sport mentre ascolti la musica o parli al telefono indossando questi auricolari da corsa! Questi auricolari sportivi GoFit sono molto comodi e pratici, si adattano perfettamente al tuo orecchio per una migliore aderenza. Maggiori Informazioni ",0.079,1,"Taxable Goods","Catalog, Search",38.9,,,,Auricolari-da-Corsa-GoFit-Arancio,"Auricolari da Corsa GoFit Arancio","Informatica Elettronica,Informatica,Elettronica,Audio e Hi-Fi,Audio,Hi-Fi,Cuffie,Colore Arancio,Arancio,","Fai sport mentre ascolti la musica o parli al telefono indossando questi auricolari da corsa! Questi auricolari sportivi GoFit sono molto comodi e pratici, si adattano perfettamente al tuo orecchio per una migliore aderenza",http://dropshipping.bigbuy.eu/imgs/I3505223_80644.jpg,,http://dropshipping.bigbuy.eu/imgs/I3505223_80644.jpg,,,,,,"2015-09-23 10:52:34",,,,,,,,,,,,,,,,,"GTIN=8018417209512",43,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/I3505223_80641.jpg,http://dropshipping.bigbuy.eu/imgs/I3505223_80643.jpg,http://dropshipping.bigbuy.eu/imgs/I3505223_80642.jpg,http://dropshipping.bigbuy.eu/imgs/I3505223_80640.jpg","GTIN=8018417209512",,,,,,,,,,
+BB-I3505248,,Default,simple,"Default Category/Informatica Elettronica,Default Category/Informatica Elettronica/Audio e Hi-Fi,Default Category/Informatica Elettronica/Audio e Hi-Fi/Casse",base,"Altoparlante Bluetooth Portatile AudioSonic SK1511 Azzurro","Se
adori la musica e la tecnologia, l'altoparlante Bluetooth portatile AudioSonic è l'ideale per te! Riesci ad immaginare di indossare questo altoparlante intorno al collo mentre ascolti la tua musica preferita e rispondi alle chiamate del tuo smartphone? Con questo prodotto versatile è possibile! Lunghezza della corda in silicone: circa 40 cm. Dimensioni: circa 5,5 x 7 x 1 cm. Raggio del bluetooth: circa 10 m.Caratteristiche:
Batteria ricaricabile Li-ion Vita della batteria: 4 ore Batteria 300 mAh Microfono incorporato Controllo a mani libere Pulsanti di controllo Porta micro USB porta: 5 V Porta input Aux Potenza: 3 W Include:
Cavo USB + micro USB Cavo dual jack da 3,5 mm Dimenzioni per Altoparlante Bluetooth Portatile AudioSonic:
Altezza: 13 Cm Larghezza: 8 Cm Profondita': 4.6 Cm Peso: 0.143 Kg Codice Prodotto (EAN): 8713016015112
","Se adori la musica e la tecnologia, l'altoparlante Bluetooth portatile AudioSonic è l'ideale per te! Riesci ad immaginare di indossare questo altoparlante intorno al collo mentre ascolti la tua musica preferita e rispondi alle chiamate del tuo smartphone? Con questo prodotto versatile è possibile! Lunghezza della corda in silicone: circa 40 cm. Maggiori Informazioni ",0.143,1,"Taxable Goods","Catalog, Search",33.35,,,,Altoparlante-Bluetooth-Portatile-AudioSonic-SK1511 Azzurro,"Altoparlante Bluetooth Portatile AudioSonic SK1511 Azzurro","Informatica Elettronica,Informatica,Elettronica,Audio e Hi-Fi,Audio,Hi-Fi,Casse,Referenza e Colore SK1511 Azzurro,SK1511 Azzurro,","Se adori la musica e la tecnologia, l'altoparlante Bluetooth portatile AudioSonic è l'ideale per te! Riesci ad immaginare di indossare questo altoparlante intorno al collo mentre ascolti la tua musica preferita e rispondi alle chiamate del tuo smart",http://dropshipping.bigbuy.eu/imgs/altavoz_audiosonic_SK-1539_00.jpg,,http://dropshipping.bigbuy.eu/imgs/altavoz_audiosonic_SK-1539_00.jpg,,,,,,"2015-12-21 11:15:29",,,,,,,,,,,,,,,,,"GTIN=8713016015112",8,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/altavoz_SK-1511_01.jpg,http://dropshipping.bigbuy.eu/imgs/altavoz-cordón-SK-1511.jpg,http://dropshipping.bigbuy.eu/imgs/altavoz_SK-1511_004.jpg,http://dropshipping.bigbuy.eu/imgs/altavoz_SK-1511_02.jpg,http://dropshipping.bigbuy.eu/imgs/altavoz_SK-1511_0004.jpg,http://dropshipping.bigbuy.eu/imgs/altavoz_SK-1511_00.jpg,http://dropshipping.bigbuy.eu/imgs/altavoz_SK-1511_04.jpg","GTIN=8713016015112",,,,,,,,,,
+BB-I3505249,,Default,simple,"Default Category/Informatica Elettronica,Default Category/Informatica Elettronica/Audio e Hi-Fi,Default Category/Informatica Elettronica/Audio e Hi-Fi/Casse",base,"Altoparlante Bluetooth Portatile AudioSonic SK1513 Rosa","Se
adori la musica e la tecnologia, l'altoparlante Bluetooth portatile AudioSonic è l'ideale per te! Riesci ad immaginare di indossare questo altoparlante intorno al collo mentre ascolti la tua musica preferita e rispondi alle chiamate del tuo smartphone? Con questo prodotto versatile è possibile! Lunghezza della corda in silicone: circa 40 cm. Dimensioni: circa 5,5 x 7 x 1 cm. Raggio del bluetooth: circa 10 m.Caratteristiche:
Batteria ricaricabile Li-ion Vita della batteria: 4 ore Batteria 300 mAh Microfono incorporato Controllo a mani libere Pulsanti di controllo Porta micro USB porta: 5 V Porta input Aux Potenza: 3 W Include:
Cavo USB + micro USB Cavo dual jack da 3,5 mm Dimenzioni per Altoparlante Bluetooth Portatile AudioSonic:
Altezza: 13 Cm Larghezza: 8 Cm Profondita': 4.6 Cm Peso: 0.143 Kg Codice Prodotto (EAN): 8713016000996
","Se adori la musica e la tecnologia, l'altoparlante Bluetooth portatile AudioSonic è l'ideale per te! Riesci ad immaginare di indossare questo altoparlante intorno al collo mentre ascolti la tua musica preferita e rispondi alle chiamate del tuo smartphone? Con questo prodotto versatile è possibile! Lunghezza della corda in silicone: circa 40 cm. Maggiori Informazioni ",0.143,1,"Taxable Goods","Catalog, Search",33.35,,,,Altoparlante-Bluetooth-Portatile-AudioSonic-SK1513 Rosa,"Altoparlante Bluetooth Portatile AudioSonic SK1513 Rosa","Informatica Elettronica,Informatica,Elettronica,Audio e Hi-Fi,Audio,Hi-Fi,Casse,Referenza e Colore SK1513 Rosa,SK1513 Rosa,","Se adori la musica e la tecnologia, l'altoparlante Bluetooth portatile AudioSonic è l'ideale per te! Riesci ad immaginare di indossare questo altoparlante intorno al collo mentre ascolti la tua musica preferita e rispondi alle chiamate del tuo smart",http://dropshipping.bigbuy.eu/imgs/altavoz_SK-1511_01.jpg,,http://dropshipping.bigbuy.eu/imgs/altavoz_SK-1511_01.jpg,,,,,,"2015-06-01 09:01:55",,,,,,,,,,,,,,,,,"GTIN=8713016000996",16,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/altavoz_audiosonic_SK-1539_00.jpg,http://dropshipping.bigbuy.eu/imgs/altavoz-cordón-SK-1511.jpg,http://dropshipping.bigbuy.eu/imgs/altavoz_SK-1511_004.jpg,http://dropshipping.bigbuy.eu/imgs/altavoz_SK-1511_02.jpg,http://dropshipping.bigbuy.eu/imgs/altavoz_SK-1511_0004.jpg,http://dropshipping.bigbuy.eu/imgs/altavoz_SK-1511_00.jpg,http://dropshipping.bigbuy.eu/imgs/altavoz_SK-1511_04.jpg","GTIN=8713016000996",,,,,,,,,,
+BB-I3505250,,Default,simple,"Default Category/Informatica Elettronica,Default Category/Informatica Elettronica/Audio e Hi-Fi,Default Category/Informatica Elettronica/Audio e Hi-Fi/Casse",base,"Altoparlante Bluetooth Portatile AudioSonic SK1512 Verde","Se
adori la musica e la tecnologia, l'altoparlante Bluetooth portatile AudioSonic è l'ideale per te! Riesci ad immaginare di indossare questo altoparlante intorno al collo mentre ascolti la tua musica preferita e rispondi alle chiamate del tuo smartphone? Con questo prodotto versatile è possibile! Lunghezza della corda in silicone: circa 40 cm. Dimensioni: circa 5,5 x 7 x 1 cm. Raggio del bluetooth: circa 10 m.Caratteristiche:
Batteria ricaricabile Li-ion Vita della batteria: 4 ore Batteria 300 mAh Microfono incorporato Controllo a mani libere Pulsanti di controllo Porta micro USB porta: 5 V Porta input Aux Potenza: 3 W Include:
Cavo USB + micro USB Cavo dual jack da 3,5 mm Dimenzioni per Altoparlante Bluetooth Portatile AudioSonic:
Altezza: 13 Cm Larghezza: 8 Cm Profondita': 4.6 Cm Peso: 0.143 Kg Codice Prodotto (EAN): 8713016000972
","Se adori la musica e la tecnologia, l'altoparlante Bluetooth portatile AudioSonic è l'ideale per te! Riesci ad immaginare di indossare questo altoparlante intorno al collo mentre ascolti la tua musica preferita e rispondi alle chiamate del tuo smartphone? Con questo prodotto versatile è possibile! Lunghezza della corda in silicone: circa 40 cm. Maggiori Informazioni ",0.143,1,"Taxable Goods","Catalog, Search",33.35,,,,Altoparlante-Bluetooth-Portatile-AudioSonic-SK1512 Verde,"Altoparlante Bluetooth Portatile AudioSonic SK1512 Verde","Informatica Elettronica,Informatica,Elettronica,Audio e Hi-Fi,Audio,Hi-Fi,Casse,Referenza e Colore SK1512 Verde,SK1512 Verde,","Se adori la musica e la tecnologia, l'altoparlante Bluetooth portatile AudioSonic è l'ideale per te! Riesci ad immaginare di indossare questo altoparlante intorno al collo mentre ascolti la tua musica preferita e rispondi alle chiamate del tuo smart",http://dropshipping.bigbuy.eu/imgs/altavoz-cordón-SK-1511.jpg,,http://dropshipping.bigbuy.eu/imgs/altavoz-cordón-SK-1511.jpg,,,,,,"2016-02-01 10:38:01",,,,,,,,,,,,,,,,,"GTIN=8713016000972",22,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/altavoz_audiosonic_SK-1539_00.jpg,http://dropshipping.bigbuy.eu/imgs/altavoz_SK-1511_01.jpg,http://dropshipping.bigbuy.eu/imgs/altavoz_SK-1511_004.jpg,http://dropshipping.bigbuy.eu/imgs/altavoz_SK-1511_02.jpg,http://dropshipping.bigbuy.eu/imgs/altavoz_SK-1511_0004.jpg,http://dropshipping.bigbuy.eu/imgs/altavoz_SK-1511_00.jpg,http://dropshipping.bigbuy.eu/imgs/altavoz_SK-1511_04.jpg","GTIN=8713016000972",,,,,,,,,,
+BB-I3505262,,Default,simple,"Default Category/Informatica Elettronica,Default Category/Informatica Elettronica/Audio e Hi-Fi,Default Category/Informatica Elettronica/Audio e Hi-Fi/Cuffie",base,"Auricolari da Corsa GoFit","Ora,
ascoltare la musica o fare una chiamata non saranno più scuse valide per non allenarsi, grazie agli auricolari da corsa GoFit ! Sono davvero comodi e pratici auricolari che si adattano completamente all'orecchio, Speciale design Europeo per l'utilizzo in allenamento. Materiali e suono di alta qualità. Include una piccola custodia in tessuto per conservare gli auricolari.Caratteristiche:
Flessibili e resistenti all'acqua Suono: stereo Connessione audio: cavo jack 3,5 mm Microfono incorporato Pulsante di risposta e termine chiamata Risposta di frequenza: 20-20000 Hz Livello sonoro: 93 dB Impedenza altoparlante: 32 Ω Adatti all'uso con iPhone, smartphone e altri cellulari Dimenzioni per Auricolari da Corsa GoFit:
Altezza: 20.5 Cm Larghezza: 9 Cm Profondita': 4 Cm Peso: 0.102 Kg Codice Prodotto (EAN): 8018417208119
","Ora, ascoltare la musica o fare una chiamata non saranno più scuse valide per non allenarsi, grazie agli auricolari da corsa GoFit! Sono davvero comodi e pratici auricolari che si adattano completamente all'orecchio, Speciale design Europeo per l'utilizzo in allenamento. Maggiori Informazioni ",0.102,1,"Taxable Goods","Catalog, Search",49.9,,,,Auricolari-da-Corsa-GoFit,"Auricolari da Corsa GoFit","Informatica Elettronica,Informatica,Elettronica,Audio e Hi-Fi,Audio,Hi-Fi,Cuffie,","Ora, ascoltare la musica o fare una chiamata non saranno più scuse valide per non allenarsi, grazie agli auricolari da corsa GoFit! Sono davvero comodi e pratici auricolari che si adattano completamente all'orecchio, Speciale design Europeo per l'ut",http://dropshipping.bigbuy.eu/imgs/I3505262_80647.jpg,,http://dropshipping.bigbuy.eu/imgs/I3505262_80647.jpg,,,,,,"2016-09-07 15:19:36",,,,,,,,,,,,,,,,,"GTIN=8018417208119",46,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/I3505262_80646.jpg,http://dropshipping.bigbuy.eu/imgs/I3505262_80645.jpg","GTIN=8018417208119",,,,,,,,,,
+BB-G0500185,,Default,simple,"Default Category/Informatica Elettronica,Default Category/Informatica Elettronica/Audio e Hi-Fi,Default Category/Informatica Elettronica/Audio e Hi-Fi/Cuffie",base,"Fascia Sportiva con Auricolari GoFit Verde","Se
adori gli sport e ti piace tenerti informato con gli ultimi accessori sportivi , non puoi perderti questa ottima fascia sportiva con auricolari GoFit . Con questa fascia per la testa, potrai ascoltare i tuoi brani musicali preferiti mentre fai jogging, inoltre potrai rispondere alle chiamate, semplicemente premendo il pulsante di risposta e chiusura chiamate incorporato nella doppia connessione, con cavo audio jack da 3,5 mm (lunghezza: circa 1 m). Altoparlanti rimovibili per permetterti di lavare la fascia. Ampiezza: circa 9,5 cm. Diametro: circa 27 cm. Esterno 100% poliestere. Interno in microfibra polare. Caratteristiche:Sensibilità: 5 dB Impedenza altoparlante: 32 Ω Frequenza: 20 Hz-20 kHz Adatto a smartphone e altri telefoni mobili Dimenzioni per Fascia Sportiva con Auricolari GoFit:
Altezza: 20 Cm Larghezza: 9 Cm Profondita': 4.5 Cm Peso: 0.102 Kg Codice Prodotto (EAN): 8018417209635
","Se adori gli sport e ti piace tenerti informato con gli ultimi accessori sportivi, non puoi perderti questa ottima fascia sportiva con auricolari GoFit. Maggiori Informazioni ",0.102,1,"Taxable Goods","Catalog, Search",49.99,,,,Fascia-Sportiva-con-Auricolari-GoFit-Verde,"Fascia Sportiva con Auricolari GoFit Verde","Informatica Elettronica,Informatica,Elettronica,Audio e Hi-Fi,Audio,Hi-Fi,Cuffie,Colore Verde,Verde,","Se adori gli sport e ti piace tenerti informato con gli ultimi accessori sportivi, non puoi perderti questa ottima fascia sportiva con auricolari GoFit",http://dropshipping.bigbuy.eu/imgs/G0500184_81112.jpg,,http://dropshipping.bigbuy.eu/imgs/G0500184_81112.jpg,,,,,,"2015-09-28 07:07:26",,,,,,,,,,,,,,,,,"GTIN=8018417209635",11,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/G0500184_81118.jpg,http://dropshipping.bigbuy.eu/imgs/G0500184_81117.jpg,http://dropshipping.bigbuy.eu/imgs/G0500184_81116.jpg,http://dropshipping.bigbuy.eu/imgs/G0500184_81115.jpg,http://dropshipping.bigbuy.eu/imgs/G0500184_81114.jpg,http://dropshipping.bigbuy.eu/imgs/G0500184_81113.jpg","GTIN=8018417209635",,,,,,,,,,
+BB-G0500186,,Default,simple,"Default Category/Informatica Elettronica,Default Category/Informatica Elettronica/Audio e Hi-Fi,Default Category/Informatica Elettronica/Audio e Hi-Fi/Cuffie",base,"Fascia Sportiva con Auricolari GoFit Arancio","Se
adori gli sport e ti piace tenerti informato con gli ultimi accessori sportivi , non puoi perderti questa ottima fascia sportiva con auricolari GoFit . Con questa fascia per la testa, potrai ascoltare i tuoi brani musicali preferiti mentre fai jogging, inoltre potrai rispondere alle chiamate, semplicemente premendo il pulsante di risposta e chiusura chiamate incorporato nella doppia connessione, con cavo audio jack da 3,5 mm (lunghezza: circa 1 m). Altoparlanti rimovibili per permetterti di lavare la fascia. Ampiezza: circa 9,5 cm. Diametro: circa 27 cm. Esterno 100% poliestere. Interno in microfibra polare. Caratteristiche:Sensibilità: 5 dB Impedenza altoparlante: 32 Ω Frequenza: 20 Hz-20 kHz Adatto a smartphone e altri telefoni mobili Dimenzioni per Fascia Sportiva con Auricolari GoFit:
Altezza: 20 Cm Larghezza: 9 Cm Profondita': 4.5 Cm Peso: 0.102 Kg Codice Prodotto (EAN): 8018417209505
","Se adori gli sport e ti piace tenerti informato con gli ultimi accessori sportivi, non puoi perderti questa ottima fascia sportiva con auricolari GoFit. Maggiori Informazioni ",0.102,1,"Taxable Goods","Catalog, Search",49.99,,,,Fascia-Sportiva-con-Auricolari-GoFit-Arancio,"Fascia Sportiva con Auricolari GoFit Arancio","Informatica Elettronica,Informatica,Elettronica,Audio e Hi-Fi,Audio,Hi-Fi,Cuffie,Colore Arancio,Arancio,","Se adori gli sport e ti piace tenerti informato con gli ultimi accessori sportivi, non puoi perderti questa ottima fascia sportiva con auricolari GoFit",http://dropshipping.bigbuy.eu/imgs/G0500184_81118.jpg,,http://dropshipping.bigbuy.eu/imgs/G0500184_81118.jpg,,,,,,"2015-09-28 07:07:51",,,,,,,,,,,,,,,,,"GTIN=8018417209505",32,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/G0500184_81112.jpg,http://dropshipping.bigbuy.eu/imgs/G0500184_81117.jpg,http://dropshipping.bigbuy.eu/imgs/G0500184_81116.jpg,http://dropshipping.bigbuy.eu/imgs/G0500184_81115.jpg,http://dropshipping.bigbuy.eu/imgs/G0500184_81114.jpg,http://dropshipping.bigbuy.eu/imgs/G0500184_81113.jpg","GTIN=8018417209505",,,,,,,,,,
+BB-I3505265,,Default,simple,"Default Category/Informatica Elettronica,Default Category/Informatica Elettronica/Audio e Hi-Fi,Default Category/Informatica Elettronica/Audio e Hi-Fi/Casse",base,"Altoparlante Sportivo Bluetooth GoFit","Sei
un amante dello sport e adori fare escursioni in montagna? Ti piace la musica? Allora questo prodotto ti starà a pennello! Questo favoloso altoparlante sportivo Bluetooth GoFit ti accompagnerà dove vuoi, permettendoti di ascoltare la tua musica preferita durante le tue uscite, così come rispondere alle chiamate attraverso la funzione Bluetooth. Resistente all'acqua. Include un cavo di ricarica USB. L'altoparlante ha una clip per inserirlo su una cintura e una banda elastica per indossarlo al polso, nello zaino, ecc. Misure (diametro x altezza) circa: 8,5 cm x 3 cm. Peso: circa 159 g.Caratteristiche:
Protezione impermeabile: IP4 Bluetooth 2.0 + EDR: distanza fino a circa 10 m Funzione mani libere Permette la ricezione di chiamate e terminarle Pulsanti di pausa, avanzamento e indietro Tempo di riproduzione: circa 2,5 ore Frequenza: 90 Hz-20 KHz Uscita altoparlante: 5 W Connessione per audio jack 3,5 mm
Dimenzioni per Altoparlante Sportivo Bluetooth GoFit:
Altezza: 20 Cm Larghezza: 6 Cm Profondita': 9.5 Cm Peso: 0.278 Kg Codice Prodotto (EAN): 8018417207747
","Sei un amante dello sport e adori fare escursioni in montagna? Ti piace la musica? Allora questo prodotto ti starà a pennello! Questo favoloso altoparlante sportivo Bluetooth GoFit ti accompagnerà dove vuoi, permettendoti di ascoltare la tua musica preferita durante le tue uscite, così come rispondere alle chiamate attraverso la funzione Bluetooth. Maggiori Informazioni ",0.278,1,"Taxable Goods","Catalog, Search",89.9,,,,Altoparlante-Sportivo-Bluetooth-GoFit,"Altoparlante Sportivo Bluetooth GoFit","Informatica Elettronica,Informatica,Elettronica,Audio e Hi-Fi,Audio,Hi-Fi,Casse,","Sei un amante dello sport e adori fare escursioni in montagna? Ti piace la musica? Allora questo prodotto ti starà a pennello! Questo favoloso altoparlante sportivo Bluetooth GoFit ti accompagnerà dove vuoi, permettendoti di ascoltare la tua musica ",http://dropshipping.bigbuy.eu/imgs/I3505265_81327.jpg,,http://dropshipping.bigbuy.eu/imgs/I3505265_81327.jpg,,,,,,"2016-08-08 21:04:27",,,,,,,,,,,,,,,,,"GTIN=8018417207747",10,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/I3505265_81169.jpg,http://dropshipping.bigbuy.eu/imgs/I3505265_81168.jpg,http://dropshipping.bigbuy.eu/imgs/I3505265_81167.jpg","GTIN=8018417207747",,,,,,,,,,
+BB-H1000173,,Default,simple,"Default Category/Informatica Elettronica,Default Category/Informatica Elettronica/Scooter Elettrici",base,"Mini Scooter Elettrico di Auto Equilibrio (2 ruote) Rover Droid Azzurro","Dimentica
i noiosi trasporti convenzionali e diventa il re delle strade con il mini scooter elettrico di auto equilibrio (2 ruote) Rover Droid! Questo pratico, intelligente ed originale veicolo motorizzato costituisce un modo rapido e comodo di spostarsi che chiunque noterà. Metti alla prova il tuo equilibrio e divertiti!www.roverdroid.com
Caratteristiche:
Batteria a litio: 160 Wh Pulsante on/off Indicatore luminoso del livello di carica sull'asse centrale Illuminazione di segnaletica anteriore LED Zona d'appoggio in gomma resistente e antiscivolo Velocità massima: 10 km/h circa Autonomia con carica completa: da 17 a 20 km circa Peso: 10 kg circa Tempo di carica: 3 ore circa Peso massimo supportato: 100 kg Dimensioni: 58 x 18 x 18 cm circa Diametro delle ruote: 7"" Borsa di trasporto e caricabatterie inclusi (CA: 100-240 V, 50-60 Hz, 1,2 A / DC: 36 V, 2 A) Dimenzioni per Mini Scooter Elettrico di Auto Equilibrio (2 ruote) Rover Droid:
Altezza: 22.5 Cm Larghezza: 64 Cm Profondita': 24 Cm Peso: 11.85 Kg Codice Prodotto (EAN): 4899888109204
","Dimentica i noiosi trasporti convenzionali e diventa il re delle strade con il mini scooter elettrico di auto equilibrio (2 ruote) Rover Droid! Questo pratico, intelligente ed originale veicolo motorizzato costituisce un modo rapido e comodo di spostarsi che chiunque noterà. Maggiori Informazioni ",11.85,1,"Taxable Goods","Catalog, Search",599,,,,Mini-Scooter-Elettrico-di-Auto-Equilibrio-(2-ruote)-Rover-Droid-Azzurro,"Mini Scooter Elettrico di Auto Equilibrio (2 ruote) Rover Droid Azzurro","Informatica Elettronica,Informatica,Elettronica,Scooter Elettrici,Scooter,Elettrici,Colore Azzurro,Azzurro,","Dimentica i noiosi trasporti convenzionali e diventa il re delle strade con il mini scooter elettrico di auto equilibrio (2 ruote) Rover Droid! Questo pratico, intelligente ed originale veicolo motorizzato costituisce un modo rapido e comodo di spos",http://dropshipping.bigbuy.eu/imgs/H1000172_90268.jpg,,http://dropshipping.bigbuy.eu/imgs/H1000172_90268.jpg,,,,,,"2016-02-25 15:50:21",,,,,,,,,,,,,,,,,"GTIN=4899888109204",60,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/H1000172_90282.jpg,http://dropshipping.bigbuy.eu/imgs/H1000172_90270.jpg,http://dropshipping.bigbuy.eu/imgs/H1000172_87995.jpg,http://dropshipping.bigbuy.eu/imgs/H1000172_87979.jpg,http://dropshipping.bigbuy.eu/imgs/H1000172_87978.jpg,http://dropshipping.bigbuy.eu/imgs/H1000172_87976.jpg,http://dropshipping.bigbuy.eu/imgs/H1000172_87975.jpg","GTIN=4899888109204",,,,,,,,,,
+BB-H1000174,,Default,simple,"Default Category/Informatica Elettronica,Default Category/Informatica Elettronica/Scooter Elettrici",base,"Mini Scooter Elettrico di Auto Equilibrio (2 ruote) Rover Droid Nero","Dimentica
i noiosi trasporti convenzionali e diventa il re delle strade con il mini scooter elettrico di auto equilibrio (2 ruote) Rover Droid! Questo pratico, intelligente ed originale veicolo motorizzato costituisce un modo rapido e comodo di spostarsi che chiunque noterà. Metti alla prova il tuo equilibrio e divertiti!www.roverdroid.com
Caratteristiche:
Batteria a litio: 160 Wh Pulsante on/off Indicatore luminoso del livello di carica sull'asse centrale Illuminazione di segnaletica anteriore LED Zona d'appoggio in gomma resistente e antiscivolo Velocità massima: 10 km/h circa Autonomia con carica completa: da 17 a 20 km circa Peso: 10 kg circa Tempo di carica: 3 ore circa Peso massimo supportato: 100 kg Dimensioni: 58 x 18 x 18 cm circa Diametro delle ruote: 7"" Borsa di trasporto e caricabatterie inclusi (CA: 100-240 V, 50-60 Hz, 1,2 A / DC: 36 V, 2 A) Dimenzioni per Mini Scooter Elettrico di Auto Equilibrio (2 ruote) Rover Droid:
Altezza: 22.5 Cm Larghezza: 64 Cm Profondita': 24 Cm Peso: 11.85 Kg Codice Prodotto (EAN): 4899888109273
","Dimentica i noiosi trasporti convenzionali e diventa il re delle strade con il mini scooter elettrico di auto equilibrio (2 ruote) Rover Droid! Questo pratico, intelligente ed originale veicolo motorizzato costituisce un modo rapido e comodo di spostarsi che chiunque noterà. Maggiori Informazioni ",11.85,1,"Taxable Goods","Catalog, Search",599,,,,Mini-Scooter-Elettrico-di-Auto-Equilibrio-(2-ruote)-Rover-Droid-Nero,"Mini Scooter Elettrico di Auto Equilibrio (2 ruote) Rover Droid Nero","Informatica Elettronica,Informatica,Elettronica,Scooter Elettrici,Scooter,Elettrici,Colore Nero,Nero,","Dimentica i noiosi trasporti convenzionali e diventa il re delle strade con il mini scooter elettrico di auto equilibrio (2 ruote) Rover Droid! Questo pratico, intelligente ed originale veicolo motorizzato costituisce un modo rapido e comodo di spos",http://dropshipping.bigbuy.eu/imgs/H1000172_90282.jpg,,http://dropshipping.bigbuy.eu/imgs/H1000172_90282.jpg,,,,,,"2016-02-25 15:50:21",,,,,,,,,,,,,,,,,"GTIN=4899888109273",131,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/H1000172_90268.jpg,http://dropshipping.bigbuy.eu/imgs/H1000172_90270.jpg,http://dropshipping.bigbuy.eu/imgs/H1000172_87995.jpg,http://dropshipping.bigbuy.eu/imgs/H1000172_87979.jpg,http://dropshipping.bigbuy.eu/imgs/H1000172_87978.jpg,http://dropshipping.bigbuy.eu/imgs/H1000172_87976.jpg,http://dropshipping.bigbuy.eu/imgs/H1000172_87975.jpg","GTIN=4899888109273",,,,,,,,,,
+BB-H1000182,,Default,simple,"Default Category/Informatica Elettronica,Default Category/Informatica Elettronica/Scooter Elettrici",base,"Mini Scooter Elettrico di Auto Equilibrio (2 ruote) Rover Droid Grafitti","Dimentica
i noiosi trasporti convenzionali e diventa il re delle strade con il mini scooter elettrico di auto equilibrio (2 ruote) Rover Droid! Questo pratico, intelligente ed originale veicolo motorizzato costituisce un modo rapido e comodo di spostarsi che chiunque noterà. Metti alla prova il tuo equilibrio e divertiti!www.roverdroid.com
Caratteristiche:
Batteria a litio: 160 Wh Pulsante on/off Indicatore luminoso del livello di carica sull'asse centrale Illuminazione di segnaletica anteriore LED Zona d'appoggio in gomma resistente e antiscivolo Velocità massima: 10 km/h circa Autonomia con carica completa: da 17 a 20 km circa Peso: 10 kg circa Tempo di carica: 3 ore circa Peso massimo supportato: 100 kg Dimensioni: 58 x 18 x 18 cm circa Diametro delle ruote: 7"" Borsa di trasporto e caricabatterie inclusi (CA: 100-240 V, 50-60 Hz, 1,2 A / DC: 36 V, 2 A) Dimenzioni per Mini Scooter Elettrico di Auto Equilibrio (2 ruote) Rover Droid:
Altezza: 22.5 Cm Larghezza: 64 Cm Profondita': 24 Cm Peso: 11.85 Kg Codice Prodotto (EAN): 4899888109747
","Dimentica i noiosi trasporti convenzionali e diventa il re delle strade con il mini scooter elettrico di auto equilibrio (2 ruote) Rover Droid! Questo pratico, intelligente ed originale veicolo motorizzato costituisce un modo rapido e comodo di spostarsi che chiunque noterà. Maggiori Informazioni ",11.85,1,"Taxable Goods","Catalog, Search",599,,,,Mini-Scooter-Elettrico-di-Auto-Equilibrio-(2-ruote)-Rover-Droid-Grafitti,"Mini Scooter Elettrico di Auto Equilibrio (2 ruote) Rover Droid Grafitti","Informatica Elettronica,Informatica,Elettronica,Scooter Elettrici,Scooter,Elettrici,Colore Grafitti,Grafitti,","Dimentica i noiosi trasporti convenzionali e diventa il re delle strade con il mini scooter elettrico di auto equilibrio (2 ruote) Rover Droid! Questo pratico, intelligente ed originale veicolo motorizzato costituisce un modo rapido e comodo di spos",http://dropshipping.bigbuy.eu/imgs/H1000172_90270.jpg,,http://dropshipping.bigbuy.eu/imgs/H1000172_90270.jpg,,,,,,"2016-02-25 16:33:57",,,,,,,,,,,,,,,,,"GTIN=4899888109747",92,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/H1000172_90268.jpg,http://dropshipping.bigbuy.eu/imgs/H1000172_90282.jpg,http://dropshipping.bigbuy.eu/imgs/H1000172_87995.jpg,http://dropshipping.bigbuy.eu/imgs/H1000172_87979.jpg,http://dropshipping.bigbuy.eu/imgs/H1000172_87978.jpg,http://dropshipping.bigbuy.eu/imgs/H1000172_87976.jpg,http://dropshipping.bigbuy.eu/imgs/H1000172_87975.jpg","GTIN=4899888109747",,,,,,,,,,
+BB-I2500322,,Default,simple,"Default Category/Informatica Elettronica,Default Category/Informatica Elettronica/Orologi e Sveglie,Default Category/Informatica Elettronica/Orologi e Sveglie/Smartwatch",base,"Orologio Intelligente Smartwatch BT110 con Audio Nero","Sfoggia
il tuo orologio intelligente Smartwatch BT110 con audio ! Sincronizzalo tramite Bluetooth al tuo smartphone e ti permette di realizzare e rispondere alle telefonate, accedere all'agenda e alla cronologia delle chiamate, ascoltare musica e usarlo come cronometro, barometro, altimetro e podometro. Inoltre, questo orologio dispone di varie funzioni autonome: allarme, calendario, calcolatrice, controllo del sonno...www.bitblin.com Caratteristiche:
Schermo touch Risoluzione: 128 x 128 pixel Batteria a litio: 3,7 V / 230 mA Durata appross. in attesa: 150 h Durata appross. in conversazione: 3 h Connessione micro USB Bluetooth 3.0 Vibrazione Dimensioni appross. della sfera: 4 x 4,5 x 1 cm Cavo USB da micro USB incluso Il menu è disponibile in spagnolo, inglese, francese, danese, polacco, portoghese, italiano, tedesco, turco, russo e svedese. Compatibile con smartphones Android
Con Smartphone Android da 4.0 a 5.0 è possibile ricevere notifiche di SMS, e-mails, WhatsApp e social network (scaricando l'applicazione indicata nella pagina web del prodotto).
Dimenzioni per Orologio Intelligente Smartwatch BT110 con Audio:
Altezza: 11 Cm Larghezza: 8 Cm Profondita': 5 Cm Peso: 0.145 Kg Codice Prodotto (EAN): 4899888109242
","Sfoggia il tuo orologio intelligente Smartwatch BT110 con audio! Sincronizzalo tramite Bluetooth al tuo smartphone e ti permette di realizzare e rispondere alle telefonate, accedere all'agenda e alla cronologia delle chiamate, ascoltare musica e usarlo come cronometro, barometro, altimetro e podometro. Maggiori Informazioni ",0.145,1,"Taxable Goods","Catalog, Search",94.9,,,,Orologio-Intelligente-Smartwatch-BT110-con-Audio-Nero,"Orologio Intelligente Smartwatch BT110 con Audio Nero","Informatica Elettronica,Informatica,Elettronica,Orologi e Sveglie,Orologi,Sveglie,Smartwatch,Colore Nero,Nero,","Sfoggia il tuo orologio intelligente Smartwatch BT110 con audio! Sincronizzalo tramite Bluetooth al tuo smartphone e ti permette di realizzare e rispondere alle telefonate, accedere all'agenda e alla cronologia delle chiamate, ascoltare musica e usa",http://dropshipping.bigbuy.eu/imgs/I2500321_84125.jpg,,http://dropshipping.bigbuy.eu/imgs/I2500321_84125.jpg,,,,,,"2016-02-11 08:36:39",,,,,,,,,,,,,,,,,"GTIN=4899888109242",2,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/I2500321_101196.jpg,http://dropshipping.bigbuy.eu/imgs/I2500321_101195.jpg,http://dropshipping.bigbuy.eu/imgs/I2500321_101194.jpg,http://dropshipping.bigbuy.eu/imgs/I2500321_101193.jpg,http://dropshipping.bigbuy.eu/imgs/I2500321_84129.jpg,http://dropshipping.bigbuy.eu/imgs/I2500321_84128.jpg,http://dropshipping.bigbuy.eu/imgs/I2500321_84127.jpg","GTIN=4899888109242",,,,,,,,,,
+BB-I2500323,,Default,simple,"Default Category/Informatica Elettronica,Default Category/Informatica Elettronica/Orologi e Sveglie,Default Category/Informatica Elettronica/Orologi e Sveglie/Smartwatch",base,"Orologio Intelligente Smartwatch BT110 con Audio Bianco","Sfoggia
il tuo orologio intelligente Smartwatch BT110 con audio ! Sincronizzalo tramite Bluetooth al tuo smartphone e ti permette di realizzare e rispondere alle telefonate, accedere all'agenda e alla cronologia delle chiamate, ascoltare musica e usarlo come cronometro, barometro, altimetro e podometro. Inoltre, questo orologio dispone di varie funzioni autonome: allarme, calendario, calcolatrice, controllo del sonno...www.bitblin.com Caratteristiche:
Schermo touch Risoluzione: 128 x 128 pixel Batteria a litio: 3,7 V / 230 mA Durata appross. in attesa: 150 h Durata appross. in conversazione: 3 h Connessione micro USB Bluetooth 3.0 Vibrazione Dimensioni appross. della sfera: 4 x 4,5 x 1 cm Cavo USB da micro USB incluso Il menu è disponibile in spagnolo, inglese, francese, danese, polacco, portoghese, italiano, tedesco, turco, russo e svedese. Compatibile con smartphones Android
Con Smartphone Android da 4.0 a 5.0 è possibile ricevere notifiche di SMS, e-mails, WhatsApp e social network (scaricando l'applicazione indicata nella pagina web del prodotto).
Dimenzioni per Orologio Intelligente Smartwatch BT110 con Audio:
Altezza: 11 Cm Larghezza: 8 Cm Profondita': 5 Cm Peso: 0.145 Kg Codice Prodotto (EAN): 4899888109259
","Sfoggia il tuo orologio intelligente Smartwatch BT110 con audio! Sincronizzalo tramite Bluetooth al tuo smartphone e ti permette di realizzare e rispondere alle telefonate, accedere all'agenda e alla cronologia delle chiamate, ascoltare musica e usarlo come cronometro, barometro, altimetro e podometro. Maggiori Informazioni ",0.145,1,"Taxable Goods","Catalog, Search",94.9,,,,Orologio-Intelligente-Smartwatch-BT110-con-Audio-Bianco,"Orologio Intelligente Smartwatch BT110 con Audio Bianco","Informatica Elettronica,Informatica,Elettronica,Orologi e Sveglie,Orologi,Sveglie,Smartwatch,Colore Bianco,Bianco,","Sfoggia il tuo orologio intelligente Smartwatch BT110 con audio! Sincronizzalo tramite Bluetooth al tuo smartphone e ti permette di realizzare e rispondere alle telefonate, accedere all'agenda e alla cronologia delle chiamate, ascoltare musica e usa",http://dropshipping.bigbuy.eu/imgs/I2500321_101196.jpg,,http://dropshipping.bigbuy.eu/imgs/I2500321_101196.jpg,,,,,,"2016-02-11 08:36:39",,,,,,,,,,,,,,,,,"GTIN=4899888109259",2,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/I2500321_84125.jpg,http://dropshipping.bigbuy.eu/imgs/I2500321_101195.jpg,http://dropshipping.bigbuy.eu/imgs/I2500321_101194.jpg,http://dropshipping.bigbuy.eu/imgs/I2500321_101193.jpg,http://dropshipping.bigbuy.eu/imgs/I2500321_84129.jpg,http://dropshipping.bigbuy.eu/imgs/I2500321_84128.jpg,http://dropshipping.bigbuy.eu/imgs/I2500321_84127.jpg","GTIN=4899888109259",,,,,,,,,,
+BB-I2500324,,Default,simple,"Default Category/Informatica Elettronica,Default Category/Informatica Elettronica/Orologi e Sveglie,Default Category/Informatica Elettronica/Orologi e Sveglie/Smartwatch",base,"Orologio Intelligente Smartwatch BT110 con Audio Rosso","Sfoggia
il tuo orologio intelligente Smartwatch BT110 con audio ! Sincronizzalo tramite Bluetooth al tuo smartphone e ti permette di realizzare e rispondere alle telefonate, accedere all'agenda e alla cronologia delle chiamate, ascoltare musica e usarlo come cronometro, barometro, altimetro e podometro. Inoltre, questo orologio dispone di varie funzioni autonome: allarme, calendario, calcolatrice, controllo del sonno...www.bitblin.com Caratteristiche:
Schermo touch Risoluzione: 128 x 128 pixel Batteria a litio: 3,7 V / 230 mA Durata appross. in attesa: 150 h Durata appross. in conversazione: 3 h Connessione micro USB Bluetooth 3.0 Vibrazione Dimensioni appross. della sfera: 4 x 4,5 x 1 cm Cavo USB da micro USB incluso Il menu è disponibile in spagnolo, inglese, francese, danese, polacco, portoghese, italiano, tedesco, turco, russo e svedese. Compatibile con smartphones Android
Con Smartphone Android da 4.0 a 5.0 è possibile ricevere notifiche di SMS, e-mails, WhatsApp e social network (scaricando l'applicazione indicata nella pagina web del prodotto).
Dimenzioni per Orologio Intelligente Smartwatch BT110 con Audio:
Altezza: 11 Cm Larghezza: 8 Cm Profondita': 5 Cm Peso: 0.145 Kg Codice Prodotto (EAN): 4899888109266
","Sfoggia il tuo orologio intelligente Smartwatch BT110 con audio! Sincronizzalo tramite Bluetooth al tuo smartphone e ti permette di realizzare e rispondere alle telefonate, accedere all'agenda e alla cronologia delle chiamate, ascoltare musica e usarlo come cronometro, barometro, altimetro e podometro. Maggiori Informazioni ",0.145,1,"Taxable Goods","Catalog, Search",94.9,,,,Orologio-Intelligente-Smartwatch-BT110-con-Audio-Rosso,"Orologio Intelligente Smartwatch BT110 con Audio Rosso","Informatica Elettronica,Informatica,Elettronica,Orologi e Sveglie,Orologi,Sveglie,Smartwatch,Colore Rosso,Rosso,","Sfoggia il tuo orologio intelligente Smartwatch BT110 con audio! Sincronizzalo tramite Bluetooth al tuo smartphone e ti permette di realizzare e rispondere alle telefonate, accedere all'agenda e alla cronologia delle chiamate, ascoltare musica e usa",http://dropshipping.bigbuy.eu/imgs/I2500321_101195.jpg,,http://dropshipping.bigbuy.eu/imgs/I2500321_101195.jpg,,,,,,"2016-02-11 08:36:39",,,,,,,,,,,,,,,,,"GTIN=4899888109266",0,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/I2500321_84125.jpg,http://dropshipping.bigbuy.eu/imgs/I2500321_101196.jpg,http://dropshipping.bigbuy.eu/imgs/I2500321_101194.jpg,http://dropshipping.bigbuy.eu/imgs/I2500321_101193.jpg,http://dropshipping.bigbuy.eu/imgs/I2500321_84129.jpg,http://dropshipping.bigbuy.eu/imgs/I2500321_84128.jpg,http://dropshipping.bigbuy.eu/imgs/I2500321_84127.jpg","GTIN=4899888109266",,,,,,,,,,
+BB-I4110022,,Default,simple,"Default Category/Informatica Elettronica,Default Category/Informatica Elettronica/Telefonia e Accessori,Default Category/Informatica Elettronica/Telefonia e Accessori/Cellulari",base,"Smartphone MyWigo UNO 5'' Bianco","Acquista
uno dei migliori telefoni cellulari sbloccati sul mercato in questo momento, lo smartphone MyWigo UNO 5'' ! Include caricabatterie e cavetto USB al cavetto micro USB.Caratteristiche:
Schermo Vetro Ricurvo 5'' HD IPS 2.5D Batteria a polimeri di litio: 2350 mAh Fotocamera anteriore: 5 Mpx Telecamera posteriore: 13 Mpx Sony, IMX 214 sensore con autofocus e flash LED Processore: MTK6753 Octa Core a 1.3 GHz di 64 Bit RAM: 2 GB DDR Memoria interna: 32 GB (16 GB + 16 GB micro SD) Dual SIM Sistema operativo: Android Lollipop 5.1 Wi-Fi Bluetooth 4.0 + HS GPS 2G: GSM a 850/900/1800/1900 MHz 3G: WCDMA 900/2100 MHz Tecnologia 4G (LTE) FDD 800/1800/2100/2600 MHz Caricabatterie: AC 110-240 V, DC 5 V, 1000 mA Dimensioni: 7 x 14 x 0,8 cm circa Dimensioni dello schermo: 6 x 11 cm circa Peso: 138 gr circa Dimenzioni per Smartphone MyWigo UNO 5'' :
Altezza: 10.5 Cm Larghezza: 18 Cm Profondita': 5 Cm Peso: 0.347 Kg Codice Prodotto (EAN): 8436533839565
","Acquista uno dei migliori telefoni cellulari sbloccati sul mercato in questo momento, lo smartphone MyWigo UNO 5''! Include caricabatterie e cavetto USB al cavetto micro USB. Maggiori Informazioni ",0.347,1,"Taxable Goods","Catalog, Search",412.5,,,,Smartphone-MyWigo-UNO-5''-Bianco,"Smartphone MyWigo UNO 5'' Bianco","Informatica Elettronica,Informatica,Elettronica,Telefonia e Accessori,Telefonia,Accessori,Cellulari,Colore Bianco,Bianco,","Acquista uno dei migliori telefoni cellulari sbloccati sul mercato in questo momento, lo smartphone MyWigo UNO 5''! Include caricabatterie e cavetto USB al cavetto micro USB",http://dropshipping.bigbuy.eu/imgs/I4110021_87809.jpg,,http://dropshipping.bigbuy.eu/imgs/I4110021_87809.jpg,,,,,,"2015-12-16 14:44:27",,,,,,,,,,,,,,,,,"GTIN=8436533839565",0,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/I4110021_87813.jpg,http://dropshipping.bigbuy.eu/imgs/I4110021_87812.jpg,http://dropshipping.bigbuy.eu/imgs/I4110021_87811.jpg,http://dropshipping.bigbuy.eu/imgs/I4110021_87810.jpg,http://dropshipping.bigbuy.eu/imgs/I4110021_87808.jpg,http://dropshipping.bigbuy.eu/imgs/I4110021_87807.jpg","GTIN=8436533839565",,,,,,,,,,
+BB-I4110023,,Default,simple,"Default Category/Informatica Elettronica,Default Category/Informatica Elettronica/Telefonia e Accessori,Default Category/Informatica Elettronica/Telefonia e Accessori/Cellulari",base,"Smartphone MyWigo UNO 5'' Nero","Acquista
uno dei migliori telefoni cellulari sbloccati sul mercato in questo momento, lo smartphone MyWigo UNO 5'' ! Include caricabatterie e cavetto USB al cavetto micro USB.Caratteristiche:
Schermo Vetro Ricurvo 5'' HD IPS 2.5D Batteria a polimeri di litio: 2350 mAh Fotocamera anteriore: 5 Mpx Telecamera posteriore: 13 Mpx Sony, IMX 214 sensore con autofocus e flash LED Processore: MTK6753 Octa Core a 1.3 GHz di 64 Bit RAM: 2 GB DDR Memoria interna: 32 GB (16 GB + 16 GB micro SD) Dual SIM Sistema operativo: Android Lollipop 5.1 Wi-Fi Bluetooth 4.0 + HS GPS 2G: GSM a 850/900/1800/1900 MHz 3G: WCDMA 900/2100 MHz Tecnologia 4G (LTE) FDD 800/1800/2100/2600 MHz Caricabatterie: AC 110-240 V, DC 5 V, 1000 mA Dimensioni: 7 x 14 x 0,8 cm circa Dimensioni dello schermo: 6 x 11 cm circa Peso: 138 gr circa Dimenzioni per Smartphone MyWigo UNO 5'' :
Altezza: 10.5 Cm Larghezza: 18 Cm Profondita': 5 Cm Peso: 0.347 Kg Codice Prodotto (EAN): 8436533839558
","Acquista uno dei migliori telefoni cellulari sbloccati sul mercato in questo momento, lo smartphone MyWigo UNO 5''! Include caricabatterie e cavetto USB al cavetto micro USB. Maggiori Informazioni ",0.347,1,"Taxable Goods","Catalog, Search",412.5,,,,Smartphone-MyWigo-UNO-5''-Nero,"Smartphone MyWigo UNO 5'' Nero","Informatica Elettronica,Informatica,Elettronica,Telefonia e Accessori,Telefonia,Accessori,Cellulari,Colore Nero,Nero,","Acquista uno dei migliori telefoni cellulari sbloccati sul mercato in questo momento, lo smartphone MyWigo UNO 5''! Include caricabatterie e cavetto USB al cavetto micro USB",http://dropshipping.bigbuy.eu/imgs/I4110021_87813.jpg,,http://dropshipping.bigbuy.eu/imgs/I4110021_87813.jpg,,,,,,"2015-12-16 14:44:27",,,,,,,,,,,,,,,,,"GTIN=8436533839558",0,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/I4110021_87809.jpg,http://dropshipping.bigbuy.eu/imgs/I4110021_87812.jpg,http://dropshipping.bigbuy.eu/imgs/I4110021_87811.jpg,http://dropshipping.bigbuy.eu/imgs/I4110021_87810.jpg,http://dropshipping.bigbuy.eu/imgs/I4110021_87808.jpg,http://dropshipping.bigbuy.eu/imgs/I4110021_87807.jpg","GTIN=8436533839558",,,,,,,,,,
+BB-V1400101,,Default,simple,"Default Category/Informatica Elettronica,Default Category/Informatica Elettronica/Telefonia e Accessori,Default Category/Informatica Elettronica/Telefonia e Accessori/Cellulari",base,"Telefono Cellulare Thomson Tlink11 Bianco","Se
sei alla ricerca di un telefono cellulare user-friendly per le persone anziane o per chi è agli inizi nel mondo della telefonia mobile, il telefono cellulare Thomson Tlink11 è ciò che stai cercando!Caratteristiche:
Telefono cellulare sbloccato Schermo: 1.77"" 128 x 160, colori 65 K Reti: GSM-EDGE 850/900/1800/1900 MHz Dual SIM Bluetooth MP3 Radio FM Micro USB Micro SD (scheda non inclusa) Connessione per auricolari (non inclusi) Lista contatti: 200 nomi Funzione SMS Mani-libere Batteria Li-ion 600 mAh Include: batteria e caricabatterie Dimensioni: 4.5 x 11 x 1 cm circa Dimenzioni per Telefono Cellulare Thomson Tlink11:
Altezza: 17 Cm Larghezza: 11 Cm Profondita': 5 Cm Peso: 0.167 Kg Codice Prodotto (EAN): 3527570047688
","Se sei alla ricerca di un telefono cellulare user-friendly per le persone anziane o per chi è agli inizi nel mondo della telefonia mobile, il telefono cellulare Thomson Tlink11 è ciò che stai cercando!Caratteristiche:Telefono cellulare sbloccatoSchermo: 1. Maggiori Informazioni ",0.167,1,"Taxable Goods","Catalog, Search",43.5,,,,Telefono-Cellulare-Thomson-Tlink11-Bianco,"Telefono Cellulare Thomson Tlink11 Bianco","Informatica Elettronica,Informatica,Elettronica,Telefonia e Accessori,Telefonia,Accessori,Cellulari,Colore Bianco,Bianco,","Se sei alla ricerca di un telefono cellulare user-friendly per le persone anziane o per chi è agli inizi nel mondo della telefonia mobile, il telefono cellulare Thomson Tlink11 è ciò che stai cercando!Caratteristiche:Telefono cellulare sbloccatoSche",http://dropshipping.bigbuy.eu/imgs/V1400100_91205.jpg,,http://dropshipping.bigbuy.eu/imgs/V1400100_91205.jpg,,,,,,"-0001-11-30 00:00:00",,,,,,,,,,,,,,,,,"GTIN=3527570047688",0,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/V1400100_91204.jpg,http://dropshipping.bigbuy.eu/imgs/V1400100_91203.jpg","GTIN=3527570047688",,,,,,,,,,
+BB-V1400102,,Default,simple,"Default Category/Informatica Elettronica,Default Category/Informatica Elettronica/Telefonia e Accessori,Default Category/Informatica Elettronica/Telefonia e Accessori/Cellulari",base,"Telefono Cellulare Thomson Tlink11 Nero","Se
sei alla ricerca di un telefono cellulare user-friendly per le persone anziane o per chi è agli inizi nel mondo della telefonia mobile, il telefono cellulare Thomson Tlink11 è ciò che stai cercando!Caratteristiche:
Telefono cellulare sbloccato Schermo: 1.77"" 128 x 160, colori 65 K Reti: GSM-EDGE 850/900/1800/1900 MHz Dual SIM Bluetooth MP3 Radio FM Micro USB Micro SD (scheda non inclusa) Connessione per auricolari (non inclusi) Lista contatti: 200 nomi Funzione SMS Mani-libere Batteria Li-ion 600 mAh Include: batteria e caricabatterie Dimensioni: 4.5 x 11 x 1 cm circa Dimenzioni per Telefono Cellulare Thomson Tlink11:
Altezza: 17 Cm Larghezza: 11 Cm Profondita': 5 Cm Peso: 0.167 Kg Codice Prodotto (EAN): 3527570047596
","Se sei alla ricerca di un telefono cellulare user-friendly per le persone anziane o per chi è agli inizi nel mondo della telefonia mobile, il telefono cellulare Thomson Tlink11 è ciò che stai cercando!Caratteristiche:Telefono cellulare sbloccatoSchermo: 1. Maggiori Informazioni ",0.167,1,"Taxable Goods","Catalog, Search",43.5,,,,Telefono-Cellulare-Thomson-Tlink11-Nero,"Telefono Cellulare Thomson Tlink11 Nero","Informatica Elettronica,Informatica,Elettronica,Telefonia e Accessori,Telefonia,Accessori,Cellulari,Colore Nero,Nero,","Se sei alla ricerca di un telefono cellulare user-friendly per le persone anziane o per chi è agli inizi nel mondo della telefonia mobile, il telefono cellulare Thomson Tlink11 è ciò che stai cercando!Caratteristiche:Telefono cellulare sbloccatoSche",http://dropshipping.bigbuy.eu/imgs/V1400100_91204.jpg,,http://dropshipping.bigbuy.eu/imgs/V1400100_91204.jpg,,,,,,"-0001-11-30 00:00:00",,,,,,,,,,,,,,,,,"GTIN=3527570047596",0,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/V1400100_91205.jpg,http://dropshipping.bigbuy.eu/imgs/V1400100_91203.jpg","GTIN=3527570047596",,,,,,,,,,
+BB-V1400104,,Default,simple,"Default Category/Informatica Elettronica,Default Category/Informatica Elettronica/Telefonia e Accessori,Default Category/Informatica Elettronica/Telefonia e Accessori/Cellulari",base,"Telefono Cellulare Thomson Serea51 Bianco","In
arrivo il telefono cellulare Thomson Serea51 per gli amanti dei cellulari semplici e funzionali, per le persone anziane o per coloro che si avviciano per la prima volta al mondo della telefonia mobile!Caratteristiche:
Cellulare sbloccato Schermo: 1,77"" 160 x 128, 65 K colori Reti: GSM-EDGE 850/900/1800/1900 MHz Tasto per le chiamate d'emergenza Tasti di grandi dimensioni Luce LED Fotocamera VGA Bluetooth MP3 Radio FM Micro USB Micro SD (scheda non inclusa) Agenda: 250 voci Funzione SMS, MMS kit auricolare mani libere Batteria Li-ion 800 mAh Durata della batteria: 220 h in standby / 5,5 h in conversazione Include: batteria, base di ricarica, adattatore di CA, cavo dati USB e auricolari Dimensioni (senza base): 5 x 11 x 1,4 cm circa Dimenzioni per Telefono Cellulare Thomson Serea51:
Altezza: 18 Cm Larghezza: 11.5 Cm Profondita': 7.5 Cm Peso: 0.288 Kg Codice Prodotto (EAN): 3527570046964
","In arrivo il telefono cellulare Thomson Serea51 per gli amanti dei cellulari semplici e funzionali, per le persone anziane o per coloro che si avviciano per la prima volta al mondo della telefonia mobile!Caratteristiche:Cellulare sbloccatoSchermo: 1,77" 160 x 128, 65 K coloriReti: GSM-EDGE 850/900/1800/1900 MHzTasto per le chiamate d'emergenzaTasti di grandi dimensioniLuce LEDFotocamera VGABluetoothMP3Radio FMMicro USBMicro SD (scheda non inclusa)Agenda: 250 vociFunzione SMS, MMSkit auricolare mani libereBatteria Li-ion 800 mAhDurata della batteria: 220 h in standby / 5,5 h in conversazioneInclude: batteria, base di ricarica, adattatore di CA, cavo dati USB e auricolariDimensioni (senza base): 5 x 11 x 1,4 cm circa. Maggiori Informazioni ",0.288,1,"Taxable Goods","Catalog, Search",85.9,,,,Telefono-Cellulare-Thomson-Serea51-Bianco,"Telefono Cellulare Thomson Serea51 Bianco","Informatica Elettronica,Informatica,Elettronica,Telefonia e Accessori,Telefonia,Accessori,Cellulari,Colore Bianco,Bianco,","In arrivo il telefono cellulare Thomson Serea51 per gli amanti dei cellulari semplici e funzionali, per le persone anziane o per coloro che si avviciano per la prima volta al mondo della telefonia mobile!Caratteristiche:Cellulare sbloccatoSchermo: 1",http://dropshipping.bigbuy.eu/imgs/V1400103_91207.jpg,,http://dropshipping.bigbuy.eu/imgs/V1400103_91207.jpg,,,,,,"-0001-11-30 00:00:00",,,,,,,,,,,,,,,,,"GTIN=3527570046964",42,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/V1400103_91208.jpg,http://dropshipping.bigbuy.eu/imgs/V1400103_91206.jpg","GTIN=3527570046964",,,,,,,,,,
+BB-V1400105,,Default,simple,"Default Category/Informatica Elettronica,Default Category/Informatica Elettronica/Telefonia e Accessori,Default Category/Informatica Elettronica/Telefonia e Accessori/Cellulari",base,"Telefono Cellulare Thomson Serea51 Nero","In
arrivo il telefono cellulare Thomson Serea51 per gli amanti dei cellulari semplici e funzionali, per le persone anziane o per coloro che si avviciano per la prima volta al mondo della telefonia mobile!Caratteristiche:
Cellulare sbloccato Schermo: 1,77"" 160 x 128, 65 K colori Reti: GSM-EDGE 850/900/1800/1900 MHz Tasto per le chiamate d'emergenza Tasti di grandi dimensioni Luce LED Fotocamera VGA Bluetooth MP3 Radio FM Micro USB Micro SD (scheda non inclusa) Agenda: 250 voci Funzione SMS, MMS kit auricolare mani libere Batteria Li-ion 800 mAh Durata della batteria: 220 h in standby / 5,5 h in conversazione Include: batteria, base di ricarica, adattatore di CA, cavo dati USB e auricolari Dimensioni (senza base): 5 x 11 x 1,4 cm circa Dimenzioni per Telefono Cellulare Thomson Serea51:
Altezza: 18 Cm Larghezza: 11.5 Cm Profondita': 7.5 Cm Peso: 0.288 Kg Codice Prodotto (EAN): 3527570046186
","In arrivo il telefono cellulare Thomson Serea51 per gli amanti dei cellulari semplici e funzionali, per le persone anziane o per coloro che si avviciano per la prima volta al mondo della telefonia mobile!Caratteristiche:Cellulare sbloccatoSchermo: 1,77" 160 x 128, 65 K coloriReti: GSM-EDGE 850/900/1800/1900 MHzTasto per le chiamate d'emergenzaTasti di grandi dimensioniLuce LEDFotocamera VGABluetoothMP3Radio FMMicro USBMicro SD (scheda non inclusa)Agenda: 250 vociFunzione SMS, MMSkit auricolare mani libereBatteria Li-ion 800 mAhDurata della batteria: 220 h in standby / 5,5 h in conversazioneInclude: batteria, base di ricarica, adattatore di CA, cavo dati USB e auricolariDimensioni (senza base): 5 x 11 x 1,4 cm circa. Maggiori Informazioni ",0.288,1,"Taxable Goods","Catalog, Search",85.9,,,,Telefono-Cellulare-Thomson-Serea51-Nero,"Telefono Cellulare Thomson Serea51 Nero","Informatica Elettronica,Informatica,Elettronica,Telefonia e Accessori,Telefonia,Accessori,Cellulari,Colore Nero,Nero,","In arrivo il telefono cellulare Thomson Serea51 per gli amanti dei cellulari semplici e funzionali, per le persone anziane o per coloro che si avviciano per la prima volta al mondo della telefonia mobile!Caratteristiche:Cellulare sbloccatoSchermo: 1",http://dropshipping.bigbuy.eu/imgs/V1400103_91208.jpg,,http://dropshipping.bigbuy.eu/imgs/V1400103_91208.jpg,,,,,,"-0001-11-30 00:00:00",,,,,,,,,,,,,,,,,"GTIN=3527570046186",33,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/V1400103_91207.jpg,http://dropshipping.bigbuy.eu/imgs/V1400103_91206.jpg","GTIN=3527570046186",,,,,,,,,,
+BB-V1400107,,Default,simple,"Default Category/Informatica Elettronica,Default Category/Informatica Elettronica/Telefonia e Accessori,Default Category/Informatica Elettronica/Telefonia e Accessori/Cellulari",base,"Telefono Cellularel Thomson Serea62 Nero","Se
sei alla ricerca di un cellulare semplice ma dal design impeccabile, non puoi lasciarti sfuggire il telefono cellulare Thomson Serea62 . È studiato anche per le persone anziane che vogliono avvicinarsi al mondo della telefonia mobile . Caratteristiche:
Schermo: 2,4"" 240 x 320, 262 K a colori Reti: GSM-EDGE 850/900/1800/1900 MHz Tasto per le chiamate d'emergenza Menù semplificato e facile da usare Tasti di grandi dimensioni Fotocamera VGA Bluetooth MP3 Radio FM Luce LED Micro USB Micro SD (carta non inclusa) Agenda: 250 voci Funzione SMS, MMS kit auricolare mani libere Batteria Li-ion 800 mAh Durata della batteria: 480 h in standby / 5,5 h in conversazione Include: batteria, base di ricarica, adattatore di CA, cavo dati USB e auricolari Dimensioni (senza base): 5,5 x 10,5 x 2 cm circa Dimenzioni per Telefono Cellularel Thomson Serea62:
Altezza: 5.2 Cm Larghezza: 11.3 Cm Profondita': 18.6 Cm Peso: 0.284 Kg Codice Prodotto (EAN): 3527570046094
","Se sei alla ricerca di un cellulare semplice ma dal design impeccabile, non puoi lasciarti sfuggire il telefono cellulare Thomson Serea62. Maggiori Informazioni ",0.284,1,"Taxable Goods","Catalog, Search",99.5,,,,Telefono-Cellularel-Thomson-Serea62-Nero,"Telefono Cellularel Thomson Serea62 Nero","Informatica Elettronica,Informatica,Elettronica,Telefonia e Accessori,Telefonia,Accessori,Cellulari,Colore Nero,Nero,","Se sei alla ricerca di un cellulare semplice ma dal design impeccabile, non puoi lasciarti sfuggire il telefono cellulare Thomson Serea62",http://dropshipping.bigbuy.eu/imgs/V1400106_91213.jpg,,http://dropshipping.bigbuy.eu/imgs/V1400106_91213.jpg,,,,,,"-0001-11-30 00:00:00",,,,,,,,,,,,,,,,,"GTIN=3527570046094",0,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/V1400106_91215.jpg,http://dropshipping.bigbuy.eu/imgs/V1400106_91214.jpg,http://dropshipping.bigbuy.eu/imgs/V1400106_91212.jpg,http://dropshipping.bigbuy.eu/imgs/V1400106_91211.jpg,http://dropshipping.bigbuy.eu/imgs/V1400106_91210.jpg,http://dropshipping.bigbuy.eu/imgs/V1400106_91209.jpg","GTIN=3527570046094",,,,,,,,,,
+BB-V1400108,,Default,simple,"Default Category/Informatica Elettronica,Default Category/Informatica Elettronica/Telefonia e Accessori,Default Category/Informatica Elettronica/Telefonia e Accessori/Cellulari",base,"Telefono Cellularel Thomson Serea62 Bianco","Se
sei alla ricerca di un cellulare semplice ma dal design impeccabile, non puoi lasciarti sfuggire il telefono cellulare Thomson Serea62 . È studiato anche per le persone anziane che vogliono avvicinarsi al mondo della telefonia mobile . Caratteristiche:
Schermo: 2,4"" 240 x 320, 262 K a colori Reti: GSM-EDGE 850/900/1800/1900 MHz Tasto per le chiamate d'emergenza Menù semplificato e facile da usare Tasti di grandi dimensioni Fotocamera VGA Bluetooth MP3 Radio FM Luce LED Micro USB Micro SD (carta non inclusa) Agenda: 250 voci Funzione SMS, MMS kit auricolare mani libere Batteria Li-ion 800 mAh Durata della batteria: 480 h in standby / 5,5 h in conversazione Include: batteria, base di ricarica, adattatore di CA, cavo dati USB e auricolari Dimensioni (senza base): 5,5 x 10,5 x 2 cm circa Dimenzioni per Telefono Cellularel Thomson Serea62:
Altezza: 5.2 Cm Larghezza: 11.3 Cm Profondita': 18.6 Cm Peso: 0.284 Kg Codice Prodotto (EAN): 3527570046100
","Se sei alla ricerca di un cellulare semplice ma dal design impeccabile, non puoi lasciarti sfuggire il telefono cellulare Thomson Serea62. Maggiori Informazioni ",0.284,1,"Taxable Goods","Catalog, Search",99.5,,,,Telefono-Cellularel-Thomson-Serea62-Bianco,"Telefono Cellularel Thomson Serea62 Bianco","Informatica Elettronica,Informatica,Elettronica,Telefonia e Accessori,Telefonia,Accessori,Cellulari,Colore Bianco,Bianco,","Se sei alla ricerca di un cellulare semplice ma dal design impeccabile, non puoi lasciarti sfuggire il telefono cellulare Thomson Serea62",http://dropshipping.bigbuy.eu/imgs/V1400106_91215.jpg,,http://dropshipping.bigbuy.eu/imgs/V1400106_91215.jpg,,,,,,"-0001-11-30 00:00:00",,,,,,,,,,,,,,,,,"GTIN=3527570046100",13,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/V1400106_91213.jpg,http://dropshipping.bigbuy.eu/imgs/V1400106_91214.jpg,http://dropshipping.bigbuy.eu/imgs/V1400106_91212.jpg,http://dropshipping.bigbuy.eu/imgs/V1400106_91211.jpg,http://dropshipping.bigbuy.eu/imgs/V1400106_91210.jpg,http://dropshipping.bigbuy.eu/imgs/V1400106_91209.jpg","GTIN=3527570046100",,,,,,,,,,
+BB-V1400109,,Default,simple,"Default Category/Informatica Elettronica,Default Category/Informatica Elettronica/Telefonia e Accessori,Default Category/Informatica Elettronica/Telefonia e Accessori/Cellulari",base,"Telefono Cellularel Thomson Serea62 Rosso","Se
sei alla ricerca di un cellulare semplice ma dal design impeccabile, non puoi lasciarti sfuggire il telefono cellulare Thomson Serea62 . È studiato anche per le persone anziane che vogliono avvicinarsi al mondo della telefonia mobile . Caratteristiche:
Schermo: 2,4"" 240 x 320, 262 K a colori Reti: GSM-EDGE 850/900/1800/1900 MHz Tasto per le chiamate d'emergenza Menù semplificato e facile da usare Tasti di grandi dimensioni Fotocamera VGA Bluetooth MP3 Radio FM Luce LED Micro USB Micro SD (carta non inclusa) Agenda: 250 voci Funzione SMS, MMS kit auricolare mani libere Batteria Li-ion 800 mAh Durata della batteria: 480 h in standby / 5,5 h in conversazione Include: batteria, base di ricarica, adattatore di CA, cavo dati USB e auricolari Dimensioni (senza base): 5,5 x 10,5 x 2 cm circa Dimenzioni per Telefono Cellularel Thomson Serea62:
Altezza: 5.2 Cm Larghezza: 11.3 Cm Profondita': 18.6 Cm Peso: 0.284 Kg Codice Prodotto (EAN): 3527570046117
","Se sei alla ricerca di un cellulare semplice ma dal design impeccabile, non puoi lasciarti sfuggire il telefono cellulare Thomson Serea62. Maggiori Informazioni ",0.284,1,"Taxable Goods","Catalog, Search",99.5,,,,Telefono-Cellularel-Thomson-Serea62-Rosso,"Telefono Cellularel Thomson Serea62 Rosso","Informatica Elettronica,Informatica,Elettronica,Telefonia e Accessori,Telefonia,Accessori,Cellulari,Colore Rosso,Rosso,","Se sei alla ricerca di un cellulare semplice ma dal design impeccabile, non puoi lasciarti sfuggire il telefono cellulare Thomson Serea62",http://dropshipping.bigbuy.eu/imgs/V1400106_91214.jpg,,http://dropshipping.bigbuy.eu/imgs/V1400106_91214.jpg,,,,,,"-0001-11-30 00:00:00",,,,,,,,,,,,,,,,,"GTIN=3527570046117",17,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/V1400106_91213.jpg,http://dropshipping.bigbuy.eu/imgs/V1400106_91215.jpg,http://dropshipping.bigbuy.eu/imgs/V1400106_91212.jpg,http://dropshipping.bigbuy.eu/imgs/V1400106_91211.jpg,http://dropshipping.bigbuy.eu/imgs/V1400106_91210.jpg,http://dropshipping.bigbuy.eu/imgs/V1400106_91209.jpg","GTIN=3527570046117",,,,,,,,,,
+BB-V0100186,,Default,simple,"Default Category/Informatica Elettronica,Default Category/Informatica Elettronica/Audio e Hi-Fi,Default Category/Informatica Elettronica/Audio e Hi-Fi/Cuffie",base,"Cuffie Fatina maginca Playz Kidz","Le
cuffie Fatina Magica Playz Kidz son perfetti per i piccoli di casa! Queste cuffie per bambini sono ideali come regalo per i re della casa!www.playzkidz.com
Auricolari stereo Cuffie imbottite Compatibili con MP3, MP4, CD, radio e PC Età raccomandata: +4 anni Dimenzioni per Cuffie Fatina maginca Playz Kidz:
Altezza: 22.2 Cm Larghezza: 9.5 Cm Profondita': 26.7 Cm Peso: 0.243 Kg Codice Prodotto (EAN): 4899888111122
","Le cuffie Fatina Magica Playz Kidz son perfetti per i piccoli di casa! Queste cuffie per bambini sono ideali come regalo per i re della casa!www. Maggiori Informazioni ",0.243,1,"Taxable Goods","Catalog, Search",18.9,,,,Cuffie-Fatina-maginca-Playz-Kidz,"Cuffie Fatina maginca Playz Kidz","Informatica Elettronica,Informatica,Elettronica,Audio e Hi-Fi,Audio,Hi-Fi,Cuffie,","Le cuffie Fatina Magica Playz Kidz son perfetti per i piccoli di casa! Queste cuffie per bambini sono ideali come regalo per i re della casa!www",http://dropshipping.bigbuy.eu/imgs/V0100186_93443.jpg,,http://dropshipping.bigbuy.eu/imgs/V0100186_93443.jpg,,,,,,"2016-08-16 05:37:23",,,,,,,,,,,,,,,,,"GTIN=4899888111122",2436,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/V0100186_93379.jpg,http://dropshipping.bigbuy.eu/imgs/V0100186_93377.jpg,http://dropshipping.bigbuy.eu/imgs/V0100186_93376.jpg,http://dropshipping.bigbuy.eu/imgs/V0100186_93375.jpg","GTIN=4899888111122",,,,,,,,,,
+BB-V0100187,,Default,simple,"Default Category/Informatica Elettronica,Default Category/Informatica Elettronica/Audio e Hi-Fi,Default Category/Informatica Elettronica/Audio e Hi-Fi/Cuffie",base,"Cuffie Mostriciattoli Playz Kidz","I
piccoli di casa impazziranno per le cuffie Mostriciattoli Playz Kidz ! Grazie al loro design originale e divertente, queste cuffie per bambini sono il regalo perfetto!www.playzkidz.com
Auricolari stereo Cuffie imbottite Compatibili con MP3, MP4, CD, radio e PC Età raccomandata: +4 anni Dimenzioni per Cuffie Mostriciattoli Playz Kidz:
Altezza: 22.2 Cm Larghezza: 9.5 Cm Profondita': 26.7 Cm Peso: 0.245 Kg Codice Prodotto (EAN): 4899888111139
","I piccoli di casa impazziranno per le cuffie Mostriciattoli Playz Kidz! Grazie al loro design originale e divertente, queste cuffie per bambini sono il regalo perfetto!www. Maggiori Informazioni ",0.245,1,"Taxable Goods","Catalog, Search",18.9,,,,Cuffie-Mostriciattoli-Playz-Kidz,"Cuffie Mostriciattoli Playz Kidz","Informatica Elettronica,Informatica,Elettronica,Audio e Hi-Fi,Audio,Hi-Fi,Cuffie,","I piccoli di casa impazziranno per le cuffie Mostriciattoli Playz Kidz! Grazie al loro design originale e divertente, queste cuffie per bambini sono il regalo perfetto!www",http://dropshipping.bigbuy.eu/imgs/V0100187_93370.jpg,,http://dropshipping.bigbuy.eu/imgs/V0100187_93370.jpg,,,,,,"2016-08-30 08:26:19",,,,,,,,,,,,,,,,,"GTIN=4899888111139",2438,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/V0100187_93374.jpg,http://dropshipping.bigbuy.eu/imgs/V0100187_93373.jpg,http://dropshipping.bigbuy.eu/imgs/V0100187_93372.jpg,http://dropshipping.bigbuy.eu/imgs/V0100187_93371.jpg","GTIN=4899888111139",,,,,,,,,,
+BB-V1300174,,Default,simple,"Default Category/Informatica Elettronica,Default Category/Informatica Elettronica/Orologi e Sveglie,Default Category/Informatica Elettronica/Orologi e Sveglie/Sveglie",base,"Orologio Sveglia con Contasecondi Star Wars R2-D2","Sorprendi
i tuoi familiari ed amici con un regalo originale che li lascerà a bocca aperta, l'o rologio sveglia con contasecondi Star Wars ! Una sveglia ideale per gli appassionati della famosa saga e dei suoi personaggi.Dispone di segnale acustico d'allarme e di pulsante per spegnerlo Funziona a batterie (1 x AA, non inclusa) Dimensioni: circa 10,5 x 13,5 x 6 cm Età consigliata: +3 anni Dimenzioni per Orologio Sveglia con Contasecondi Star Wars:
Altezza: 0.13 Cm Larghezza: 0.1 Cm Profondita': 0.5 Cm Peso: 0.15 Kg Codice Prodotto (EAN): 8427934787128
","Sorprendi i tuoi familiari ed amici con un regalo originale che li lascerà a bocca aperta, l'orologio sveglia con contasecondi Star Wars! Una sveglia ideale per gli appassionati della famosa saga e dei suoi personaggi. Maggiori Informazioni ",0.15,1,"Taxable Goods","Catalog, Search",15.8,,,,Orologio-Sveglia-con-Contasecondi-Star-Wars-R2-D2,"Orologio Sveglia con Contasecondi Star Wars R2-D2","Informatica Elettronica,Informatica,Elettronica,Orologi e Sveglie,Orologi,Sveglie,Sveglie,Design R2-D2,R2-D2,","Sorprendi i tuoi familiari ed amici con un regalo originale che li lascerà a bocca aperta, l'orologio sveglia con contasecondi Star Wars! Una sveglia ideale per gli appassionati della famosa saga e dei suoi personaggi",http://dropshipping.bigbuy.eu/imgs/V1300173_102640.jpg,,http://dropshipping.bigbuy.eu/imgs/V1300173_102640.jpg,,,,,,"-0001-11-30 00:00:00",,,,,,,,,,,,,,,,,"GTIN=8427934787128",69,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/V1300173_102644.jpg,http://dropshipping.bigbuy.eu/imgs/V1300173_102643.jpg,http://dropshipping.bigbuy.eu/imgs/V1300173_102642.jpg,http://dropshipping.bigbuy.eu/imgs/V1300173_102641.jpg,http://dropshipping.bigbuy.eu/imgs/V1300173_102639.jpg","GTIN=8427934787128",,,,,,,,,,
+BB-V1300175,,Default,simple,"Default Category/Informatica Elettronica,Default Category/Informatica Elettronica/Orologi e Sveglie,Default Category/Informatica Elettronica/Orologi e Sveglie/Sveglie",base,"Orologio Sveglia con Contasecondi Star Wars Stormtrooper","Sorprendi
i tuoi familiari ed amici con un regalo originale che li lascerà a bocca aperta, l'o rologio sveglia con contasecondi Star Wars ! Una sveglia ideale per gli appassionati della famosa saga e dei suoi personaggi.Dispone di segnale acustico d'allarme e di pulsante per spegnerlo Funziona a batterie (1 x AA, non inclusa) Dimensioni: circa 10,5 x 13,5 x 6 cm Età consigliata: +3 anni Dimenzioni per Orologio Sveglia con Contasecondi Star Wars:
Altezza: 0.13 Cm Larghezza: 0.1 Cm Profondita': 0.5 Cm Peso: 0.15 Kg Codice Prodotto (EAN): 8427934787135
","Sorprendi i tuoi familiari ed amici con un regalo originale che li lascerà a bocca aperta, l'orologio sveglia con contasecondi Star Wars! Una sveglia ideale per gli appassionati della famosa saga e dei suoi personaggi. Maggiori Informazioni ",0.15,1,"Taxable Goods","Catalog, Search",15.8,,,,Orologio-Sveglia-con-Contasecondi-Star-Wars-Stormtrooper,"Orologio Sveglia con Contasecondi Star Wars Stormtrooper","Informatica Elettronica,Informatica,Elettronica,Orologi e Sveglie,Orologi,Sveglie,Sveglie,Design Stormtrooper,Stormtrooper,","Sorprendi i tuoi familiari ed amici con un regalo originale che li lascerà a bocca aperta, l'orologio sveglia con contasecondi Star Wars! Una sveglia ideale per gli appassionati della famosa saga e dei suoi personaggi",http://dropshipping.bigbuy.eu/imgs/V1300173_102644.jpg,,http://dropshipping.bigbuy.eu/imgs/V1300173_102644.jpg,,,,,,"-0001-11-30 00:00:00",,,,,,,,,,,,,,,,,"GTIN=8427934787135",69,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/V1300173_102640.jpg,http://dropshipping.bigbuy.eu/imgs/V1300173_102643.jpg,http://dropshipping.bigbuy.eu/imgs/V1300173_102642.jpg,http://dropshipping.bigbuy.eu/imgs/V1300173_102641.jpg,http://dropshipping.bigbuy.eu/imgs/V1300173_102639.jpg","GTIN=8427934787135",,,,,,,,,,
+BB-V1300176,,Default,simple,"Default Category/Informatica Elettronica,Default Category/Informatica Elettronica/Orologi e Sveglie,Default Category/Informatica Elettronica/Orologi e Sveglie/Sveglie",base,"Orologio Sveglia con Contasecondi Star Wars Yoda","Sorprendi
i tuoi familiari ed amici con un regalo originale che li lascerà a bocca aperta, l'o rologio sveglia con contasecondi Star Wars ! Una sveglia ideale per gli appassionati della famosa saga e dei suoi personaggi.Dispone di segnale acustico d'allarme e di pulsante per spegnerlo Funziona a batterie (1 x AA, non inclusa) Dimensioni: circa 10,5 x 13,5 x 6 cm Età consigliata: +3 anni Dimenzioni per Orologio Sveglia con Contasecondi Star Wars:
Altezza: 0.13 Cm Larghezza: 0.1 Cm Profondita': 0.5 Cm Peso: 0.15 Kg Codice Prodotto (EAN): 8427934787142
","Sorprendi i tuoi familiari ed amici con un regalo originale che li lascerà a bocca aperta, l'orologio sveglia con contasecondi Star Wars! Una sveglia ideale per gli appassionati della famosa saga e dei suoi personaggi. Maggiori Informazioni ",0.15,1,"Taxable Goods","Catalog, Search",15.8,,,,Orologio-Sveglia-con-Contasecondi-Star-Wars-Yoda,"Orologio Sveglia con Contasecondi Star Wars Yoda","Informatica Elettronica,Informatica,Elettronica,Orologi e Sveglie,Orologi,Sveglie,Sveglie,Design Yoda,Yoda,","Sorprendi i tuoi familiari ed amici con un regalo originale che li lascerà a bocca aperta, l'orologio sveglia con contasecondi Star Wars! Una sveglia ideale per gli appassionati della famosa saga e dei suoi personaggi",http://dropshipping.bigbuy.eu/imgs/V1300173_102643.jpg,,http://dropshipping.bigbuy.eu/imgs/V1300173_102643.jpg,,,,,,"-0001-11-30 00:00:00",,,,,,,,,,,,,,,,,"GTIN=8427934787142",68,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/V1300173_102640.jpg,http://dropshipping.bigbuy.eu/imgs/V1300173_102644.jpg,http://dropshipping.bigbuy.eu/imgs/V1300173_102642.jpg,http://dropshipping.bigbuy.eu/imgs/V1300173_102641.jpg,http://dropshipping.bigbuy.eu/imgs/V1300173_102639.jpg","GTIN=8427934787142",,,,,,,,,,
+BB-V1300177,,Default,simple,"Default Category/Informatica Elettronica,Default Category/Informatica Elettronica/Orologi e Sveglie,Default Category/Informatica Elettronica/Orologi e Sveglie/Sveglie",base,"Orologio Sveglia con Contasecondi Star Wars Chewbacca","Sorprendi
i tuoi familiari ed amici con un regalo originale che li lascerà a bocca aperta, l'o rologio sveglia con contasecondi Star Wars ! Una sveglia ideale per gli appassionati della famosa saga e dei suoi personaggi.Dispone di segnale acustico d'allarme e di pulsante per spegnerlo Funziona a batterie (1 x AA, non inclusa) Dimensioni: circa 10,5 x 13,5 x 6 cm Età consigliata: +3 anni Dimenzioni per Orologio Sveglia con Contasecondi Star Wars:
Altezza: 0.13 Cm Larghezza: 0.1 Cm Profondita': 0.5 Cm Peso: 0.15 Kg Codice Prodotto (EAN): 8427934787159
","Sorprendi i tuoi familiari ed amici con un regalo originale che li lascerà a bocca aperta, l'orologio sveglia con contasecondi Star Wars! Una sveglia ideale per gli appassionati della famosa saga e dei suoi personaggi. Maggiori Informazioni ",0.15,1,"Taxable Goods","Catalog, Search",15.8,,,,Orologio-Sveglia-con-Contasecondi-Star-Wars-Chewbacca,"Orologio Sveglia con Contasecondi Star Wars Chewbacca","Informatica Elettronica,Informatica,Elettronica,Orologi e Sveglie,Orologi,Sveglie,Sveglie,Design Chewbacca,Chewbacca,","Sorprendi i tuoi familiari ed amici con un regalo originale che li lascerà a bocca aperta, l'orologio sveglia con contasecondi Star Wars! Una sveglia ideale per gli appassionati della famosa saga e dei suoi personaggi",http://dropshipping.bigbuy.eu/imgs/V1300173_102642.jpg,,http://dropshipping.bigbuy.eu/imgs/V1300173_102642.jpg,,,,,,"-0001-11-30 00:00:00",,,,,,,,,,,,,,,,,"GTIN=8427934787159",69,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/V1300173_102640.jpg,http://dropshipping.bigbuy.eu/imgs/V1300173_102644.jpg,http://dropshipping.bigbuy.eu/imgs/V1300173_102643.jpg,http://dropshipping.bigbuy.eu/imgs/V1300173_102641.jpg,http://dropshipping.bigbuy.eu/imgs/V1300173_102639.jpg","GTIN=8427934787159",,,,,,,,,,
+BB-G1000110,,Default,simple,"Default Category/Outlet Offerte,Default Category/Outlet Offerte/Offerte",base,"Attrezzo da Ginnastica Body Rocker","Non
perdere tempo e denaro andandoin palestra e procurarti ora l'attrezzo da ginnastica Body Rocker! Una forma facile ed efficace di rimettresi in forma facendo esercizio in casa. Grazie al suo sistema di oscillazione, è perfetto per lavorare e rafforzare, spalle, braccia, schiena, petto, glutei, ecc. Fatto in acciaio con impugnature in gomma. Include manuale d'istruzioni e DVD dimostrativo. (Questo prodotto può può presentare lievi danni che non impediscono il funzionamento del prodotto: impugnature in gomma piuma scollate). Dimenzioni per Attrezzo da Ginnastica Body Rocker :
Altezza: 21 Cm Larghezza: 20 Cm Profondita': 78 Cm Peso: 2.13 Kg Codice Prodotto (EAN): 4899888101314
","Non perdere tempo e denaro andandoin palestra e procurarti ora l'attrezzo da ginnastica Body Rocker! Una forma facile ed efficace di rimettresi in forma facendo esercizio in casa. Maggiori Informazioni ",2.13,1,"Taxable Goods","Catalog, Search",79,,,,Attrezzo-da-Ginnastica-Body-Rocker,"Attrezzo da Ginnastica Body Rocker","Outlet Offerte,Outlet,Offerte,Offerte,","Non perdere tempo e denaro andandoin palestra e procurarti ora l'attrezzo da ginnastica Body Rocker! Una forma facile ed efficace di rimettresi in forma facendo esercizio in casa",http://dropshipping.bigbuy.eu/imgs/bodirocker-00.jpg,,http://dropshipping.bigbuy.eu/imgs/bodirocker-00.jpg,,,,,,"2016-08-08 21:04:27",,,,,,,,,,,,,,,,,"GTIN=4899888101314",121,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/bodirocker-03.jpg,http://dropshipping.bigbuy.eu/imgs/bodirocker-06.jpg,http://dropshipping.bigbuy.eu/imgs/bodirocker-05.jpg,http://dropshipping.bigbuy.eu/imgs/bodirocker-07.jpg,http://dropshipping.bigbuy.eu/imgs/bodirocker-02.jpg,http://dropshipping.bigbuy.eu/imgs/bodirocker-01.jpg,http://dropshipping.bigbuy.eu/imgs/bodirocker-04.jpg","GTIN=4899888101314",,,,,,,,,,
+BB-J2000066,,Default,simple,"Default Category/Outlet Offerte,Default Category/Outlet Offerte/Senza imballaggio",base,"OUTLET Coperta super soffice Kangoo Snug Snug con maniche per adulti | Decorazioni originali (Senza imballaggio) Lovely Arancio","Acquista
la coperta super soffice Kangoo Snug Snug con maniche per adulti | Decorazioni originali. La coperta Snug Snug con le maniche ti riscalderà senza aver bisogno del riscaldamento per tutto il giorno. Risparmierai i soldi e starai comodo grazie alla coperta extra morbida Kangoo Snug Snug con le maniche , poiché potrai fare tutto ciò che vuoi mentre sei coperto.La coperta Snug Snug con le maniche è il regalo perfetto per qualsiasi occasione. Nessuno si aspetta un regalo così straordinario! Questa coperta con le maniche è l'ideale per quei momenti in cui fa freddo fuori e vuoi solo stare a casa a leggere, usare il computer o semplicemente a rilassarti sul divano. Fino ad ora, non è era facile raggomitolarsi sul divano e voler fare qualcosa, perché dovevi tirare fuori le braccia, ma faceva freddo. Tutto questo è finito grazie alla coperta Kangoo Snug Snug con le maniche!
Caratteristiche:
Fatto di pile ultra soffice Lavabile in lavatrice Dimensioni: lunghezza 185 cm, larghezza 160 cm | Dimensioni manica: 60cm www.snugsnug.com
NOTA: Questo prodotto presenta lievi danni estetici, quali graffi o sfregature, che non influiscono sul suo funzionamento. Spedito in confezione standard.
Dimenzioni per OUTLET Coperta super soffice Kangoo Snug Snug con maniche per adulti | Decorazioni originali (Senza imballaggio):
Altezza: 28 Cm Larghezza: 26 Cm Profondita': 12 Cm Peso: 0.8 Kg Codice Prodotto (EAN): 4899888102731
","Acquista la coperta super soffice Kangoo Snug Snug con maniche per adulti | Decorazioni originali. Maggiori Informazioni ",0.8,1,"Taxable Goods","Catalog, Search",22.9,,,,OUTLET-Coperta-super-soffice-Kangoo-Snug-Snug-con-maniche-per-adulti-|-Decorazioni-originali-(Senza-imballaggio)-Lovely Arancio,"OUTLET Coperta super soffice Kangoo Snug Snug con maniche per adulti | Decorazioni originali (Senza imballaggio) Lovely Arancio","Outlet Offerte,Outlet,Offerte,Senza imballaggio,Senza,imballaggio,Colore Lovely Arancio,Lovely Arancio,","Acquista la coperta super soffice Kangoo Snug Snug con maniche per adulti | Decorazioni originali",http://dropshipping.bigbuy.eu/imgs/J2000065_91715.jpg,,http://dropshipping.bigbuy.eu/imgs/J2000065_91715.jpg,,,,,,"2016-02-11 15:49:04",,,,,,,,,,,,,,,,,"GTIN=4899888102731",0,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/J2000065_91719.jpg,http://dropshipping.bigbuy.eu/imgs/J2000065_91718.jpg,http://dropshipping.bigbuy.eu/imgs/J2000065_91717.jpg,http://dropshipping.bigbuy.eu/imgs/J2000065_91716.jpg","GTIN=4899888102731",,,,,,,,,,
+BB-J2000239,,Default,simple,"Default Category/Outlet Offerte,Default Category/Outlet Offerte/Senza imballaggio",base,"OUTLET Coperta super soffice Kangoo Snug Snug con maniche per adulti | Decorazioni originali (Senza imballaggio) Commando","Acquista
la coperta super soffice Kangoo Snug Snug con maniche per adulti | Decorazioni originali. La coperta Snug Snug con le maniche ti riscalderà senza aver bisogno del riscaldamento per tutto il giorno. Risparmierai i soldi e starai comodo grazie alla coperta extra morbida Kangoo Snug Snug con le maniche , poiché potrai fare tutto ciò che vuoi mentre sei coperto.La coperta Snug Snug con le maniche è il regalo perfetto per qualsiasi occasione. Nessuno si aspetta un regalo così straordinario! Questa coperta con le maniche è l'ideale per quei momenti in cui fa freddo fuori e vuoi solo stare a casa a leggere, usare il computer o semplicemente a rilassarti sul divano. Fino ad ora, non è era facile raggomitolarsi sul divano e voler fare qualcosa, perché dovevi tirare fuori le braccia, ma faceva freddo. Tutto questo è finito grazie alla coperta Kangoo Snug Snug con le maniche!
Caratteristiche:
Fatto di pile ultra soffice Lavabile in lavatrice Dimensioni: lunghezza 185 cm, larghezza 160 cm | Dimensioni manica: 60cm www.snugsnug.com
NOTA: Questo prodotto presenta lievi danni estetici, quali graffi o sfregature, che non influiscono sul suo funzionamento. Spedito in confezione standard.
Dimenzioni per OUTLET Coperta super soffice Kangoo Snug Snug con maniche per adulti | Decorazioni originali (Senza imballaggio):
Altezza: 28 Cm Larghezza: 26 Cm Profondita': 12 Cm Peso: 0.8 Kg Codice Prodotto (EAN): 4899888102731
","Acquista la coperta super soffice Kangoo Snug Snug con maniche per adulti | Decorazioni originali. Maggiori Informazioni ",0.8,1,"Taxable Goods","Catalog, Search",22.9,,,,OUTLET-Coperta-super-soffice-Kangoo-Snug-Snug-con-maniche-per-adulti-|-Decorazioni-originali-(Senza-imballaggio)-Commando,"OUTLET Coperta super soffice Kangoo Snug Snug con maniche per adulti | Decorazioni originali (Senza imballaggio) Commando","Outlet Offerte,Outlet,Offerte,Senza imballaggio,Senza,imballaggio,Colore Commando,Commando,","Acquista la coperta super soffice Kangoo Snug Snug con maniche per adulti | Decorazioni originali",http://dropshipping.bigbuy.eu/imgs/J2000065_91719.jpg,,http://dropshipping.bigbuy.eu/imgs/J2000065_91719.jpg,,,,,,"2016-02-11 15:49:04",,,,,,,,,,,,,,,,,"GTIN=4899888102731",0,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/J2000065_91715.jpg,http://dropshipping.bigbuy.eu/imgs/J2000065_91718.jpg,http://dropshipping.bigbuy.eu/imgs/J2000065_91717.jpg,http://dropshipping.bigbuy.eu/imgs/J2000065_91716.jpg","GTIN=4899888102731",,,,,,,,,,
+BB-J2000240,,Default,simple,"Default Category/Outlet Offerte,Default Category/Outlet Offerte/Senza imballaggio",base,"OUTLET Coperta super soffice Kangoo Snug Snug con maniche per adulti | Decorazioni originali (Senza imballaggio) Galaktic","Acquista
la coperta super soffice Kangoo Snug Snug con maniche per adulti | Decorazioni originali. La coperta Snug Snug con le maniche ti riscalderà senza aver bisogno del riscaldamento per tutto il giorno. Risparmierai i soldi e starai comodo grazie alla coperta extra morbida Kangoo Snug Snug con le maniche , poiché potrai fare tutto ciò che vuoi mentre sei coperto.La coperta Snug Snug con le maniche è il regalo perfetto per qualsiasi occasione. Nessuno si aspetta un regalo così straordinario! Questa coperta con le maniche è l'ideale per quei momenti in cui fa freddo fuori e vuoi solo stare a casa a leggere, usare il computer o semplicemente a rilassarti sul divano. Fino ad ora, non è era facile raggomitolarsi sul divano e voler fare qualcosa, perché dovevi tirare fuori le braccia, ma faceva freddo. Tutto questo è finito grazie alla coperta Kangoo Snug Snug con le maniche!
Caratteristiche:
Fatto di pile ultra soffice Lavabile in lavatrice Dimensioni: lunghezza 185 cm, larghezza 160 cm | Dimensioni manica: 60cm www.snugsnug.com
NOTA: Questo prodotto presenta lievi danni estetici, quali graffi o sfregature, che non influiscono sul suo funzionamento. Spedito in confezione standard.
Dimenzioni per OUTLET Coperta super soffice Kangoo Snug Snug con maniche per adulti | Decorazioni originali (Senza imballaggio):
Altezza: 28 Cm Larghezza: 26 Cm Profondita': 12 Cm Peso: 0.8 Kg Codice Prodotto (EAN): 4899888102731
","Acquista la coperta super soffice Kangoo Snug Snug con maniche per adulti | Decorazioni originali. Maggiori Informazioni ",0.8,1,"Taxable Goods","Catalog, Search",22.9,,,,OUTLET-Coperta-super-soffice-Kangoo-Snug-Snug-con-maniche-per-adulti-|-Decorazioni-originali-(Senza-imballaggio)-Galaktic,"OUTLET Coperta super soffice Kangoo Snug Snug con maniche per adulti | Decorazioni originali (Senza imballaggio) Galaktic","Outlet Offerte,Outlet,Offerte,Senza imballaggio,Senza,imballaggio,Colore Galaktic,Galaktic,","Acquista la coperta super soffice Kangoo Snug Snug con maniche per adulti | Decorazioni originali",http://dropshipping.bigbuy.eu/imgs/J2000065_91718.jpg,,http://dropshipping.bigbuy.eu/imgs/J2000065_91718.jpg,,,,,,"2016-02-11 15:49:04",,,,,,,,,,,,,,,,,"GTIN=4899888102731",14,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/J2000065_91715.jpg,http://dropshipping.bigbuy.eu/imgs/J2000065_91719.jpg,http://dropshipping.bigbuy.eu/imgs/J2000065_91717.jpg,http://dropshipping.bigbuy.eu/imgs/J2000065_91716.jpg","GTIN=4899888102731",,,,,,,,,,
+BB-J2000329,,Default,simple,"Default Category/Outlet Offerte,Default Category/Outlet Offerte/Senza imballaggio",base,"OUTLET Coperta super soffice Kangoo Snug Snug con maniche per adulti | Decorazioni originali (Senza imballaggio) Lovely Blu","Acquista
la coperta super soffice Kangoo Snug Snug con maniche per adulti | Decorazioni originali. La coperta Snug Snug con le maniche ti riscalderà senza aver bisogno del riscaldamento per tutto il giorno. Risparmierai i soldi e starai comodo grazie alla coperta extra morbida Kangoo Snug Snug con le maniche , poiché potrai fare tutto ciò che vuoi mentre sei coperto.La coperta Snug Snug con le maniche è il regalo perfetto per qualsiasi occasione. Nessuno si aspetta un regalo così straordinario! Questa coperta con le maniche è l'ideale per quei momenti in cui fa freddo fuori e vuoi solo stare a casa a leggere, usare il computer o semplicemente a rilassarti sul divano. Fino ad ora, non è era facile raggomitolarsi sul divano e voler fare qualcosa, perché dovevi tirare fuori le braccia, ma faceva freddo. Tutto questo è finito grazie alla coperta Kangoo Snug Snug con le maniche!
Caratteristiche:
Fatto di pile ultra soffice Lavabile in lavatrice Dimensioni: lunghezza 185 cm, larghezza 160 cm | Dimensioni manica: 60cm www.snugsnug.com
NOTA: Questo prodotto presenta lievi danni estetici, quali graffi o sfregature, che non influiscono sul suo funzionamento. Spedito in confezione standard.
Dimenzioni per OUTLET Coperta super soffice Kangoo Snug Snug con maniche per adulti | Decorazioni originali (Senza imballaggio):
Altezza: 28 Cm Larghezza: 26 Cm Profondita': 12 Cm Peso: 0.8 Kg Codice Prodotto (EAN): 4899888102731
","Acquista la coperta super soffice Kangoo Snug Snug con maniche per adulti | Decorazioni originali. Maggiori Informazioni ",0.8,1,"Taxable Goods","Catalog, Search",22.9,,,,OUTLET-Coperta-super-soffice-Kangoo-Snug-Snug-con-maniche-per-adulti-|-Decorazioni-originali-(Senza-imballaggio)-Lovely Blu,"OUTLET Coperta super soffice Kangoo Snug Snug con maniche per adulti | Decorazioni originali (Senza imballaggio) Lovely Blu","Outlet Offerte,Outlet,Offerte,Senza imballaggio,Senza,imballaggio,Colore Lovely Blu,Lovely Blu,","Acquista la coperta super soffice Kangoo Snug Snug con maniche per adulti | Decorazioni originali",http://dropshipping.bigbuy.eu/imgs/J2000065_91717.jpg,,http://dropshipping.bigbuy.eu/imgs/J2000065_91717.jpg,,,,,,"-0001-11-30 00:00:00",,,,,,,,,,,,,,,,,"GTIN=4899888102731",1,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/J2000065_91715.jpg,http://dropshipping.bigbuy.eu/imgs/J2000065_91719.jpg,http://dropshipping.bigbuy.eu/imgs/J2000065_91718.jpg,http://dropshipping.bigbuy.eu/imgs/J2000065_91716.jpg","GTIN=4899888102731",,,,,,,,,,
+BB-J2000085,,Default,simple,"Default Category/Outlet Offerte,Default Category/Outlet Offerte/Senza imballaggio",base,"OUTLET Warm Hug Feet Stivali Riscaldabili al Microonde (Senza imballaggio) Rosa S","Acquista
Warm Hug Feet Stivali Riscaldabili al Microonde al miglior prezzo. Scopri il modo più facile per mantenerti caldo a casa quando c'è freddo! Devi solo riscaldare questi stivali rilassanti nel microonde per godere immediatamente del calore e del rilassamento ai tuoi piedi. Sono fatti di morbido tessuto polare e di un rivestimento in semi di lavanda che emana un profumo straordinario quando riscaldato. Goditi semplicemente il profumo rilassante! I Warm Hug Feet Stivali Riscaldabili al Microonde mantengono il calore per lungo tempo grazie ai semi di lavanda contenuti all'interno. Per pulire questi stivali riscaldabili, passaci sopra un panno umido. Non riscaldarmi mai per più di 2 minuti e non usarli se sono troppo caldi. Disponibili in rosa e blu.Taglie (equivalenze approssimative)
S (35 a 38) M (38 a 41) L (41 a 43) Rispettare sempre i limiti nel microonde
NOTA: Questo prodotto presenta lievi danni estetici, quali graffi o sfregature, che non influiscono sul suo funzionamento. Spedito in confezione standard.
Dimenzioni per OUTLET Warm Hug Feet Stivali Riscaldabili al Microonde (Senza imballaggio):
Altezza: 27 Cm Larghezza: 10.5 Cm Profondita': 29 Cm Peso: 0.67 Kg Codice Prodotto (EAN): 4899881028786
","Acquista Warm Hug Feet Stivali Riscaldabili al Microonde al miglior prezzo. Maggiori Informazioni ",0.67,1,"Taxable Goods","Catalog, Search",33.5,,,,OUTLET-Warm-Hug-Feet-Stivali-Riscaldabili-al-Microonde-(Senza-imballaggio)-Rosa-S,"OUTLET Warm Hug Feet Stivali Riscaldabili al Microonde (Senza imballaggio) Rosa S","Outlet Offerte,Outlet,Offerte,Senza imballaggio,Senza,imballaggio,Colore Rosa,Rosa,Taglia S,S,","Acquista Warm Hug Feet Stivali Riscaldabili al Microonde al miglior prezzo",http://dropshipping.bigbuy.eu/imgs/warm-hugh-feet-boots-00.jpg,,http://dropshipping.bigbuy.eu/imgs/warm-hugh-feet-boots-00.jpg,,,,,,"2016-02-02 10:45:18",,,,,,,,,,,,,,,,,"GTIN=4899881028786",0,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/warm-hugh-feet-boots-03.jpg,http://dropshipping.bigbuy.eu/imgs/warm-hugh-feet-boots-01.jpg,http://dropshipping.bigbuy.eu/imgs/warm-hugh-feet-boots-02.jpg,http://dropshipping.bigbuy.eu/imgs/warm-hugh-feet-boots-04.jpg,http://dropshipping.bigbuy.eu/imgs/warm-hugh-feet-boots-05.jpg","GTIN=4899881028786",,,,,,,,,,
+BB-J2000086,,Default,simple,"Default Category/Outlet Offerte,Default Category/Outlet Offerte/Senza imballaggio",base,"OUTLET Warm Hug Feet Stivali Riscaldabili al Microonde (Senza imballaggio) Viola M","Acquista
Warm Hug Feet Stivali Riscaldabili al Microonde al miglior prezzo. Scopri il modo più facile per mantenerti caldo a casa quando c'è freddo! Devi solo riscaldare questi stivali rilassanti nel microonde per godere immediatamente del calore e del rilassamento ai tuoi piedi. Sono fatti di morbido tessuto polare e di un rivestimento in semi di lavanda che emana un profumo straordinario quando riscaldato. Goditi semplicemente il profumo rilassante! I Warm Hug Feet Stivali Riscaldabili al Microonde mantengono il calore per lungo tempo grazie ai semi di lavanda contenuti all'interno. Per pulire questi stivali riscaldabili, passaci sopra un panno umido. Non riscaldarmi mai per più di 2 minuti e non usarli se sono troppo caldi. Disponibili in rosa e blu.Taglie (equivalenze approssimative)
S (35 a 38) M (38 a 41) L (41 a 43) Rispettare sempre i limiti nel microonde
NOTA: Questo prodotto presenta lievi danni estetici, quali graffi o sfregature, che non influiscono sul suo funzionamento. Spedito in confezione standard.
Dimenzioni per OUTLET Warm Hug Feet Stivali Riscaldabili al Microonde (Senza imballaggio):
Altezza: 27 Cm Larghezza: 10.5 Cm Profondita': 29 Cm Peso: 0.67 Kg Codice Prodotto (EAN): 4899881028786
","Acquista Warm Hug Feet Stivali Riscaldabili al Microonde al miglior prezzo. Maggiori Informazioni ",0.67,1,"Taxable Goods","Catalog, Search",33.5,,,,OUTLET-Warm-Hug-Feet-Stivali-Riscaldabili-al-Microonde-(Senza-imballaggio)-Viola-M,"OUTLET Warm Hug Feet Stivali Riscaldabili al Microonde (Senza imballaggio) Viola M","Outlet Offerte,Outlet,Offerte,Senza imballaggio,Senza,imballaggio,Colore Viola,Viola,Taglia M,M,","Acquista Warm Hug Feet Stivali Riscaldabili al Microonde al miglior prezzo",http://dropshipping.bigbuy.eu/imgs/warm-hugh-feet-boots-03.jpg,,http://dropshipping.bigbuy.eu/imgs/warm-hugh-feet-boots-03.jpg,,,,,,"2016-02-02 10:45:18",,,,,,,,,,,,,,,,,"GTIN=4899881028786",0,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/warm-hugh-feet-boots-00.jpg,http://dropshipping.bigbuy.eu/imgs/warm-hugh-feet-boots-01.jpg,http://dropshipping.bigbuy.eu/imgs/warm-hugh-feet-boots-02.jpg,http://dropshipping.bigbuy.eu/imgs/warm-hugh-feet-boots-04.jpg,http://dropshipping.bigbuy.eu/imgs/warm-hugh-feet-boots-05.jpg","GTIN=4899881028786",,,,,,,,,,
+BB-J2000188,,Default,simple,"Default Category/Outlet Offerte,Default Category/Outlet Offerte/Senza imballaggio",base,"OUTLET Warm Hug Feet Stivali Riscaldabili al Microonde (Senza imballaggio) Viola L","Acquista
Warm Hug Feet Stivali Riscaldabili al Microonde al miglior prezzo. Scopri il modo più facile per mantenerti caldo a casa quando c'è freddo! Devi solo riscaldare questi stivali rilassanti nel microonde per godere immediatamente del calore e del rilassamento ai tuoi piedi. Sono fatti di morbido tessuto polare e di un rivestimento in semi di lavanda che emana un profumo straordinario quando riscaldato. Goditi semplicemente il profumo rilassante! I Warm Hug Feet Stivali Riscaldabili al Microonde mantengono il calore per lungo tempo grazie ai semi di lavanda contenuti all'interno. Per pulire questi stivali riscaldabili, passaci sopra un panno umido. Non riscaldarmi mai per più di 2 minuti e non usarli se sono troppo caldi. Disponibili in rosa e blu.Taglie (equivalenze approssimative)
S (35 a 38) M (38 a 41) L (41 a 43) Rispettare sempre i limiti nel microonde
NOTA: Questo prodotto presenta lievi danni estetici, quali graffi o sfregature, che non influiscono sul suo funzionamento. Spedito in confezione standard.
Dimenzioni per OUTLET Warm Hug Feet Stivali Riscaldabili al Microonde (Senza imballaggio):
Altezza: 27 Cm Larghezza: 10.5 Cm Profondita': 29 Cm Peso: 0.67 Kg Codice Prodotto (EAN): 4899881028786
","Acquista Warm Hug Feet Stivali Riscaldabili al Microonde al miglior prezzo. Maggiori Informazioni ",0.67,1,"Taxable Goods","Catalog, Search",33.5,,,,OUTLET-Warm-Hug-Feet-Stivali-Riscaldabili-al-Microonde-(Senza-imballaggio)-Viola-L,"OUTLET Warm Hug Feet Stivali Riscaldabili al Microonde (Senza imballaggio) Viola L","Outlet Offerte,Outlet,Offerte,Senza imballaggio,Senza,imballaggio,Colore Viola,Viola,Taglia L,L,","Acquista Warm Hug Feet Stivali Riscaldabili al Microonde al miglior prezzo",http://dropshipping.bigbuy.eu/imgs/warm-hugh-feet-boots-01.jpg,,http://dropshipping.bigbuy.eu/imgs/warm-hugh-feet-boots-01.jpg,,,,,,"2016-02-02 10:45:18",,,,,,,,,,,,,,,,,"GTIN=4899881028786",1,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/warm-hugh-feet-boots-00.jpg,http://dropshipping.bigbuy.eu/imgs/warm-hugh-feet-boots-03.jpg,http://dropshipping.bigbuy.eu/imgs/warm-hugh-feet-boots-02.jpg,http://dropshipping.bigbuy.eu/imgs/warm-hugh-feet-boots-04.jpg,http://dropshipping.bigbuy.eu/imgs/warm-hugh-feet-boots-05.jpg","GTIN=4899881028786",,,,,,,,,,
+BB-J2000123,,Default,simple,"Default Category/Outlet Offerte,Default Category/Outlet Offerte/Senza imballaggio",base,"OUTLET Macchina per Gelato Princess 282602 (Senza imballaggio)","Avviso
per gli amanti del gelato: ecco la nuovissima macchina per gelato Princess 282602 . Una gelatiera diversa dalle altre, che ti permetterà di preparare in un batter d'occhio gelati dolci o salati per i grandi e i più piccini! Al naturale o con salsa di frutta, pepite o qualsiasi altra guarnizione...le tue papille ti ringrazieranno! Indispensabile per un'estate al fresco!Basta mettere in freezer, per 12 ore circa, il recipiente rimovibile a forma di secchiello con manico integrato di 17,5 x 14,5 cm (diametro x altezza) ed è fatto! Il gelato 100% naturale è servito!
Caratteristiche:
Potenza: 5 W Frequenza: 50 Hz Tensione: 220-240 V Pulsante On/Off Gommini antiscivolo Scomparto per cavo di alimentazione Mescolatore rimovibile Facile da pulire Apertura di riempimento (dimensioni approssimative: 5 x 5,5 cm) Dimensioni approssimative: 22 x 25 x 22 cm NOTA: Questo prodotto presenta lievi danni estetici, quali graffi o sfregature, che non influiscono sul suo funzionamento. Spedito in confezione standard.
Dimenzioni per OUTLET Macchina per Gelato Princess 282602 (Senza imballaggio):
Altezza: 31 Cm Larghezza: 23.4 Cm Profondita': 23.5 Cm Peso: 3.26 Kg Codice Prodotto (EAN): 8712836304895
","Avviso per gli amanti del gelato: ecco la nuovissima macchina per gelato Princess 282602. Maggiori Informazioni ",3.26,1,"Taxable Goods","Catalog, Search",110.88,,,,OUTLET-Macchina-per-Gelato-Princess-282602-(Senza-imballaggio),"OUTLET Macchina per Gelato Princess 282602 (Senza imballaggio)","Outlet Offerte,Outlet,Offerte,Senza imballaggio,Senza,imballaggio,","Avviso per gli amanti del gelato: ecco la nuovissima macchina per gelato Princess 282602",http://dropshipping.bigbuy.eu/imgs/J2000123_88610.jpg,,http://dropshipping.bigbuy.eu/imgs/J2000123_88610.jpg,,,,,,"2016-08-09 01:54:36",,,,,,,,,,,,,,,,,"GTIN=8712836304895",1,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/J2000123_88612.jpg,http://dropshipping.bigbuy.eu/imgs/J2000123_88611.jpg","GTIN=8712836304895",,,,,,,,,,
+BB-J2000176,,Default,simple,"Default Category/Outlet Offerte,Default Category/Outlet Offerte/Senza imballaggio",base,"OUTLET Coperta Eden Deluxe 160 x 240 (Senza imballaggio) Celeste","Acquistare
Coperta Eden Deluxe 160 x 240 al miglior prezzo. Questa fantastica coperta Eden Deluxe è perfetta per il tuo letto. La coperta Eden Dexuxe misura 160 x 240 cm. Questa coperta è veramente soffice e confortevole. La coperta Eden Deluxe è l'ideale per godere di un caldo inverno. 100% poliestere. Con comoda maniglia da trasporto.NOTA: Questo prodotto presenta lievi danni estetici, quali graffi o sfregature, che non influiscono sul suo funzionamento. Spedito in confezione standard.
Dimenzioni per OUTLET Coperta Eden Deluxe 160 x 240 (Senza imballaggio):
Altezza: 43 Cm Larghezza: 14 Cm Profondita': 51.5 Cm Peso: 2.183 Kg Codice Prodotto (EAN): 8436045510426
","Acquistare Coperta Eden Deluxe 160 x 240 al miglior prezzo. Maggiori Informazioni ",2.183,1,"Taxable Goods","Catalog, Search",57.9,,,,OUTLET-Coperta-Eden-Deluxe-160-x-240-(Senza-imballaggio)-Celeste,"OUTLET Coperta Eden Deluxe 160 x 240 (Senza imballaggio) Celeste","Outlet Offerte,Outlet,Offerte,Senza imballaggio,Senza,imballaggio,Design Celeste,Celeste,","Acquistare Coperta Eden Deluxe 160 x 240 al miglior prezzo",http://dropshipping.bigbuy.eu/imgs/J2000175_88981.jpg,,http://dropshipping.bigbuy.eu/imgs/J2000175_88981.jpg,,,,,,"2016-02-17 15:45:14",,,,,,,,,,,,,,,,,"GTIN=8436045510426",5,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/J2000175_88987.jpg,http://dropshipping.bigbuy.eu/imgs/J2000175_88986.jpg,http://dropshipping.bigbuy.eu/imgs/J2000175_88985.jpg,http://dropshipping.bigbuy.eu/imgs/J2000175_88984.jpg,http://dropshipping.bigbuy.eu/imgs/J2000175_88983.jpg,http://dropshipping.bigbuy.eu/imgs/J2000175_88982.jpg","GTIN=8436045510426",,,,,,,,,,
+BB-J2000178,,Default,simple,"Default Category/Outlet Offerte,Default Category/Outlet Offerte/Senza imballaggio",base,"OUTLET Coperta Eden Deluxe 160 x 240 (Senza imballaggio) Rosso","Acquistare
Coperta Eden Deluxe 160 x 240 al miglior prezzo. Questa fantastica coperta Eden Deluxe è perfetta per il tuo letto. La coperta Eden Dexuxe misura 160 x 240 cm. Questa coperta è veramente soffice e confortevole. La coperta Eden Deluxe è l'ideale per godere di un caldo inverno. 100% poliestere. Con comoda maniglia da trasporto.NOTA: Questo prodotto presenta lievi danni estetici, quali graffi o sfregature, che non influiscono sul suo funzionamento. Spedito in confezione standard.
Dimenzioni per OUTLET Coperta Eden Deluxe 160 x 240 (Senza imballaggio):
Altezza: 43 Cm Larghezza: 14 Cm Profondita': 51.5 Cm Peso: 2.183 Kg Codice Prodotto (EAN): 8436045510426
","Acquistare Coperta Eden Deluxe 160 x 240 al miglior prezzo. Maggiori Informazioni ",2.183,1,"Taxable Goods","Catalog, Search",57.9,,,,OUTLET-Coperta-Eden-Deluxe-160-x-240-(Senza-imballaggio)-Rosso,"OUTLET Coperta Eden Deluxe 160 x 240 (Senza imballaggio) Rosso","Outlet Offerte,Outlet,Offerte,Senza imballaggio,Senza,imballaggio,Design Rosso,Rosso,","Acquistare Coperta Eden Deluxe 160 x 240 al miglior prezzo",http://dropshipping.bigbuy.eu/imgs/J2000175_88987.jpg,,http://dropshipping.bigbuy.eu/imgs/J2000175_88987.jpg,,,,,,"2016-02-17 15:45:14",,,,,,,,,,,,,,,,,"GTIN=8436045510426",3,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/J2000175_88981.jpg,http://dropshipping.bigbuy.eu/imgs/J2000175_88986.jpg,http://dropshipping.bigbuy.eu/imgs/J2000175_88985.jpg,http://dropshipping.bigbuy.eu/imgs/J2000175_88984.jpg,http://dropshipping.bigbuy.eu/imgs/J2000175_88983.jpg,http://dropshipping.bigbuy.eu/imgs/J2000175_88982.jpg","GTIN=8436045510426",,,,,,,,,,
+BB-J2000179,,Default,simple,"Default Category/Outlet Offerte,Default Category/Outlet Offerte/Senza imballaggio",base,"OUTLET Coperta Eden Deluxe 160 x 240 (Senza imballaggio) Cioccolato","Acquistare
Coperta Eden Deluxe 160 x 240 al miglior prezzo. Questa fantastica coperta Eden Deluxe è perfetta per il tuo letto. La coperta Eden Dexuxe misura 160 x 240 cm. Questa coperta è veramente soffice e confortevole. La coperta Eden Deluxe è l'ideale per godere di un caldo inverno. 100% poliestere. Con comoda maniglia da trasporto.NOTA: Questo prodotto presenta lievi danni estetici, quali graffi o sfregature, che non influiscono sul suo funzionamento. Spedito in confezione standard.
Dimenzioni per OUTLET Coperta Eden Deluxe 160 x 240 (Senza imballaggio):
Altezza: 43 Cm Larghezza: 14 Cm Profondita': 51.5 Cm Peso: 2.183 Kg Codice Prodotto (EAN): 8436045510426
","Acquistare Coperta Eden Deluxe 160 x 240 al miglior prezzo. Maggiori Informazioni ",2.183,1,"Taxable Goods","Catalog, Search",57.9,,,,OUTLET-Coperta-Eden-Deluxe-160-x-240-(Senza-imballaggio)-Cioccolato,"OUTLET Coperta Eden Deluxe 160 x 240 (Senza imballaggio) Cioccolato","Outlet Offerte,Outlet,Offerte,Senza imballaggio,Senza,imballaggio,Design Cioccolato,Cioccolato,","Acquistare Coperta Eden Deluxe 160 x 240 al miglior prezzo",http://dropshipping.bigbuy.eu/imgs/J2000175_88986.jpg,,http://dropshipping.bigbuy.eu/imgs/J2000175_88986.jpg,,,,,,"2016-02-17 15:45:14",,,,,,,,,,,,,,,,,"GTIN=8436045510426",5,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/J2000175_88981.jpg,http://dropshipping.bigbuy.eu/imgs/J2000175_88987.jpg,http://dropshipping.bigbuy.eu/imgs/J2000175_88985.jpg,http://dropshipping.bigbuy.eu/imgs/J2000175_88984.jpg,http://dropshipping.bigbuy.eu/imgs/J2000175_88983.jpg,http://dropshipping.bigbuy.eu/imgs/J2000175_88982.jpg","GTIN=8436045510426",,,,,,,,,,
+BB-J2000180,,Default,simple,"Default Category/Outlet Offerte,Default Category/Outlet Offerte/Senza imballaggio",base,"OUTLET Coperta Eden Deluxe 160 x 240 (Senza imballaggio) Crudo","Acquistare
Coperta Eden Deluxe 160 x 240 al miglior prezzo. Questa fantastica coperta Eden Deluxe è perfetta per il tuo letto. La coperta Eden Dexuxe misura 160 x 240 cm. Questa coperta è veramente soffice e confortevole. La coperta Eden Deluxe è l'ideale per godere di un caldo inverno. 100% poliestere. Con comoda maniglia da trasporto.NOTA: Questo prodotto presenta lievi danni estetici, quali graffi o sfregature, che non influiscono sul suo funzionamento. Spedito in confezione standard.
Dimenzioni per OUTLET Coperta Eden Deluxe 160 x 240 (Senza imballaggio):
Altezza: 43 Cm Larghezza: 14 Cm Profondita': 51.5 Cm Peso: 2.183 Kg Codice Prodotto (EAN): 8436045510426
","Acquistare Coperta Eden Deluxe 160 x 240 al miglior prezzo. Maggiori Informazioni ",2.183,1,"Taxable Goods","Catalog, Search",57.9,,,,OUTLET-Coperta-Eden-Deluxe-160-x-240-(Senza-imballaggio)-Crudo,"OUTLET Coperta Eden Deluxe 160 x 240 (Senza imballaggio) Crudo","Outlet Offerte,Outlet,Offerte,Senza imballaggio,Senza,imballaggio,Design Crudo,Crudo,","Acquistare Coperta Eden Deluxe 160 x 240 al miglior prezzo",http://dropshipping.bigbuy.eu/imgs/J2000175_88985.jpg,,http://dropshipping.bigbuy.eu/imgs/J2000175_88985.jpg,,,,,,"2016-02-17 15:45:14",,,,,,,,,,,,,,,,,"GTIN=8436045510426",9,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/J2000175_88981.jpg,http://dropshipping.bigbuy.eu/imgs/J2000175_88987.jpg,http://dropshipping.bigbuy.eu/imgs/J2000175_88986.jpg,http://dropshipping.bigbuy.eu/imgs/J2000175_88984.jpg,http://dropshipping.bigbuy.eu/imgs/J2000175_88983.jpg,http://dropshipping.bigbuy.eu/imgs/J2000175_88982.jpg","GTIN=8436045510426",,,,,,,,,,
+BB-J2000181,,Default,simple,"Default Category/Outlet Offerte,Default Category/Outlet Offerte/Senza imballaggio",base,"OUTLET Coperta Eden Deluxe 160 x 240 (Senza imballaggio) Fragola","Acquistare
Coperta Eden Deluxe 160 x 240 al miglior prezzo. Questa fantastica coperta Eden Deluxe è perfetta per il tuo letto. La coperta Eden Dexuxe misura 160 x 240 cm. Questa coperta è veramente soffice e confortevole. La coperta Eden Deluxe è l'ideale per godere di un caldo inverno. 100% poliestere. Con comoda maniglia da trasporto.NOTA: Questo prodotto presenta lievi danni estetici, quali graffi o sfregature, che non influiscono sul suo funzionamento. Spedito in confezione standard.
Dimenzioni per OUTLET Coperta Eden Deluxe 160 x 240 (Senza imballaggio):
Altezza: 43 Cm Larghezza: 14 Cm Profondita': 51.5 Cm Peso: 2.183 Kg Codice Prodotto (EAN): 8436045510426
","Acquistare Coperta Eden Deluxe 160 x 240 al miglior prezzo. Maggiori Informazioni ",2.183,1,"Taxable Goods","Catalog, Search",57.9,,,,OUTLET-Coperta-Eden-Deluxe-160-x-240-(Senza-imballaggio)-Fragola,"OUTLET Coperta Eden Deluxe 160 x 240 (Senza imballaggio) Fragola","Outlet Offerte,Outlet,Offerte,Senza imballaggio,Senza,imballaggio,Design Fragola,Fragola,","Acquistare Coperta Eden Deluxe 160 x 240 al miglior prezzo",http://dropshipping.bigbuy.eu/imgs/J2000175_88984.jpg,,http://dropshipping.bigbuy.eu/imgs/J2000175_88984.jpg,,,,,,"2016-02-17 15:45:14",,,,,,,,,,,,,,,,,"GTIN=8436045510426",8,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/J2000175_88981.jpg,http://dropshipping.bigbuy.eu/imgs/J2000175_88987.jpg,http://dropshipping.bigbuy.eu/imgs/J2000175_88986.jpg,http://dropshipping.bigbuy.eu/imgs/J2000175_88985.jpg,http://dropshipping.bigbuy.eu/imgs/J2000175_88983.jpg,http://dropshipping.bigbuy.eu/imgs/J2000175_88982.jpg","GTIN=8436045510426",,,,,,,,,,
+BB-J2000182,,Default,simple,"Default Category/Outlet Offerte,Default Category/Outlet Offerte/Senza imballaggio",base,"OUTLET Coperta Eden Deluxe 160 x 240 (Senza imballaggio) Cardinale","Acquistare
Coperta Eden Deluxe 160 x 240 al miglior prezzo. Questa fantastica coperta Eden Deluxe è perfetta per il tuo letto. La coperta Eden Dexuxe misura 160 x 240 cm. Questa coperta è veramente soffice e confortevole. La coperta Eden Deluxe è l'ideale per godere di un caldo inverno. 100% poliestere. Con comoda maniglia da trasporto.NOTA: Questo prodotto presenta lievi danni estetici, quali graffi o sfregature, che non influiscono sul suo funzionamento. Spedito in confezione standard.
Dimenzioni per OUTLET Coperta Eden Deluxe 160 x 240 (Senza imballaggio):
Altezza: 43 Cm Larghezza: 14 Cm Profondita': 51.5 Cm Peso: 2.183 Kg Codice Prodotto (EAN): 8436045510426
","Acquistare Coperta Eden Deluxe 160 x 240 al miglior prezzo. Maggiori Informazioni ",2.183,1,"Taxable Goods","Catalog, Search",57.9,,,,OUTLET-Coperta-Eden-Deluxe-160-x-240-(Senza-imballaggio)-Cardinale,"OUTLET Coperta Eden Deluxe 160 x 240 (Senza imballaggio) Cardinale","Outlet Offerte,Outlet,Offerte,Senza imballaggio,Senza,imballaggio,Design Cardinale,Cardinale,","Acquistare Coperta Eden Deluxe 160 x 240 al miglior prezzo",http://dropshipping.bigbuy.eu/imgs/J2000175_88983.jpg,,http://dropshipping.bigbuy.eu/imgs/J2000175_88983.jpg,,,,,,"2016-02-17 15:45:14",,,,,,,,,,,,,,,,,"GTIN=8436045510426",1,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/J2000175_88981.jpg,http://dropshipping.bigbuy.eu/imgs/J2000175_88987.jpg,http://dropshipping.bigbuy.eu/imgs/J2000175_88986.jpg,http://dropshipping.bigbuy.eu/imgs/J2000175_88985.jpg,http://dropshipping.bigbuy.eu/imgs/J2000175_88984.jpg,http://dropshipping.bigbuy.eu/imgs/J2000175_88982.jpg","GTIN=8436045510426",,,,,,,,,,
+BB-J2000247,,Default,simple,"Default Category/Outlet Offerte,Default Category/Outlet Offerte/Senza imballaggio",base,"OUTLET Coperta Eden Deluxe 160 x 240 (Senza imballaggio) Turchese","Acquistare
Coperta Eden Deluxe 160 x 240 al miglior prezzo. Questa fantastica coperta Eden Deluxe è perfetta per il tuo letto. La coperta Eden Dexuxe misura 160 x 240 cm. Questa coperta è veramente soffice e confortevole. La coperta Eden Deluxe è l'ideale per godere di un caldo inverno. 100% poliestere. Con comoda maniglia da trasporto.NOTA: Questo prodotto presenta lievi danni estetici, quali graffi o sfregature, che non influiscono sul suo funzionamento. Spedito in confezione standard.
Dimenzioni per OUTLET Coperta Eden Deluxe 160 x 240 (Senza imballaggio):
Altezza: 43 Cm Larghezza: 14 Cm Profondita': 51.5 Cm Peso: 2.183 Kg Codice Prodotto (EAN): 8436045510426
","Acquistare Coperta Eden Deluxe 160 x 240 al miglior prezzo. Maggiori Informazioni ",2.183,1,"Taxable Goods","Catalog, Search",57.9,,,,OUTLET-Coperta-Eden-Deluxe-160-x-240-(Senza-imballaggio)-Turchese,"OUTLET Coperta Eden Deluxe 160 x 240 (Senza imballaggio) Turchese","Outlet Offerte,Outlet,Offerte,Senza imballaggio,Senza,imballaggio,Design Turchese,Turchese,","Acquistare Coperta Eden Deluxe 160 x 240 al miglior prezzo",http://dropshipping.bigbuy.eu/imgs/J2000175_88982.jpg,,http://dropshipping.bigbuy.eu/imgs/J2000175_88982.jpg,,,,,,"2016-02-17 15:45:14",,,,,,,,,,,,,,,,,"GTIN=8436045510426",7,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/J2000175_88981.jpg,http://dropshipping.bigbuy.eu/imgs/J2000175_88987.jpg,http://dropshipping.bigbuy.eu/imgs/J2000175_88986.jpg,http://dropshipping.bigbuy.eu/imgs/J2000175_88985.jpg,http://dropshipping.bigbuy.eu/imgs/J2000175_88984.jpg,http://dropshipping.bigbuy.eu/imgs/J2000175_88983.jpg","GTIN=8436045510426",,,,,,,,,,
+BB-J2000177,,Default,simple,"Default Category/Outlet Offerte,Default Category/Outlet Offerte/Senza imballaggio",base,"OUTLET Macchina RC Ferrari 599 GTO (Senza imballaggio)","Hai
visto la macchina RC Ferrari 599 GTO ? Puoi facilmente usare questo divertente giocattolo autorizzato Ferrari grazie al suo telecomando. La macchina funziona a batterie 5 x AA (non incluse) e il telecomando a batteria 1 x 6F22 9V (non inclusa). Giocattolo adatto per bambini di età superiore ai 6 anni. Funzioni della macchina radiocontrollata Ferrari:Avanti e indietro Gira a sinistra e a destra Fari e Fanali posteriori NOTA: Questo prodotto presenta lievi danni estetici, quali graffi o sfregature, che non influiscono sul suo funzionamento. Spedito in confezione standard.
Dimenzioni per OUTLET Macchina RC Ferrari 599 GTO (Senza imballaggio):
Altezza: 17.5 Cm Larghezza: 43.5 Cm Profondita': 22.7 Cm Peso: 1.244 Kg Codice Prodotto (EAN): 8718158011299
","Hai visto la macchina RC Ferrari 599 GTO? Puoi facilmente usare questo divertente giocattolo autorizzato Ferrari grazie al suo telecomando. Maggiori Informazioni ",1.244,1,"Taxable Goods","Catalog, Search",119,,,,OUTLET-Macchina-RC-Ferrari-599-GTO--(Senza-imballaggio),"OUTLET Macchina RC Ferrari 599 GTO (Senza imballaggio)","Outlet Offerte,Outlet,Offerte,Senza imballaggio,Senza,imballaggio,","Hai visto la macchina RC Ferrari 599 GTO? Puoi facilmente usare questo divertente giocattolo autorizzato Ferrari grazie al suo telecomando",http://dropshipping.bigbuy.eu/imgs/J2000177_89020.jpg,,http://dropshipping.bigbuy.eu/imgs/J2000177_89020.jpg,,,,,,"2016-07-22 06:19:54",,,,,,,,,,,,,,,,,"GTIN=8718158011299",1,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/J2000177_89022.jpg,http://dropshipping.bigbuy.eu/imgs/J2000177_89021.jpg","GTIN=8718158011299",,,,,,,,,,
+BB-J2000255,,Default,simple,"Default Category/Outlet Offerte,Default Category/Outlet Offerte/Senza imballaggio",base,"OUTLET Canottiera Modellante con Reggiseno Booby & Tummy (Senza imballaggio) Beige S","Metti
in luce un corpo scultoreo con la Canottiera Modellante con Reggiseno Booby & Tummy! Discreta, comod. Sostiene il seno e offre una grande capacità di sostegno. Prodotta il un tessuto delicato, flessibile e traspirante che si adatta perfettamente al tuo corpo e offre una copertura completa (seno, fianchi e glutei). Equivalenza di taglie: S: 36-38, M: 38-40, L: 40-42.www.boobyandtummy.com
NOTA: Questo prodotto presenta lievi danni estetici, quali graffi o sfregature, che non influiscono sul suo funzionamento. Spedito in confezione standard.
Dimenzioni per OUTLET Canottiera Modellante con Reggiseno Booby & Tummy (Senza imballaggio):
Altezza: 17 Cm Larghezza: 13.5 Cm Profondita': 7 Cm Peso: 0.14 Kg Codice Prodotto (EAN): 4899888101352
","Metti in luce un corpo scultoreo con la Canottiera Modellante con Reggiseno Booby & Tummy! Discreta, comod. Maggiori Informazioni ",0.14,1,"Taxable Goods","Catalog, Search",23.1,,,,OUTLET-Canottiera-Modellante-con-Reggiseno-Booby-&-Tummy--(Senza-imballaggio)-Beige-S,"OUTLET Canottiera Modellante con Reggiseno Booby & Tummy (Senza imballaggio) Beige S","Outlet Offerte,Outlet,Offerte,Senza imballaggio,Senza,imballaggio,Colore Beige,Beige,Taglia S,S,","Metti in luce un corpo scultoreo con la Canottiera Modellante con Reggiseno Booby & Tummy! Discreta, comod",http://dropshipping.bigbuy.eu/imgs/J2000254_89903.jpg,,http://dropshipping.bigbuy.eu/imgs/J2000254_89903.jpg,,,,,,"2016-02-12 08:36:52",,,,,,,,,,,,,,,,,"GTIN=4899888101352",1,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/J2000254_89906.jpg,http://dropshipping.bigbuy.eu/imgs/J2000254_89905.jpg,http://dropshipping.bigbuy.eu/imgs/J2000254_89904.jpg","GTIN=4899888101352",,,,,,,,,,
+BB-J2000285,,Default,simple,"Default Category/Outlet Offerte,Default Category/Outlet Offerte/Senza imballaggio",base,"OUTLET Canottiera Modellante con Reggiseno Booby & Tummy (Senza imballaggio) Beige L","Metti
in luce un corpo scultoreo con la Canottiera Modellante con Reggiseno Booby & Tummy! Discreta, comod. Sostiene il seno e offre una grande capacità di sostegno. Prodotta il un tessuto delicato, flessibile e traspirante che si adatta perfettamente al tuo corpo e offre una copertura completa (seno, fianchi e glutei). Equivalenza di taglie: S: 36-38, M: 38-40, L: 40-42.www.boobyandtummy.com
NOTA: Questo prodotto presenta lievi danni estetici, quali graffi o sfregature, che non influiscono sul suo funzionamento. Spedito in confezione standard.
Dimenzioni per OUTLET Canottiera Modellante con Reggiseno Booby & Tummy (Senza imballaggio):
Altezza: 17 Cm Larghezza: 13.5 Cm Profondita': 7 Cm Peso: 0.14 Kg Codice Prodotto (EAN): 4899888101352
","Metti in luce un corpo scultoreo con la Canottiera Modellante con Reggiseno Booby & Tummy! Discreta, comod. Maggiori Informazioni ",0.14,1,"Taxable Goods","Catalog, Search",23.1,,,,OUTLET-Canottiera-Modellante-con-Reggiseno-Booby-&-Tummy--(Senza-imballaggio)-Beige-L,"OUTLET Canottiera Modellante con Reggiseno Booby & Tummy (Senza imballaggio) Beige L","Outlet Offerte,Outlet,Offerte,Senza imballaggio,Senza,imballaggio,Colore Beige,Beige,Taglia L,L,","Metti in luce un corpo scultoreo con la Canottiera Modellante con Reggiseno Booby & Tummy! Discreta, comod",http://dropshipping.bigbuy.eu/imgs/J2000254_89906.jpg,,http://dropshipping.bigbuy.eu/imgs/J2000254_89906.jpg,,,,,,"-0001-11-30 00:00:00",,,,,,,,,,,,,,,,,"GTIN=4899888101352",0,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/J2000254_89903.jpg,http://dropshipping.bigbuy.eu/imgs/J2000254_89905.jpg,http://dropshipping.bigbuy.eu/imgs/J2000254_89904.jpg","GTIN=4899888101352",,,,,,,,,,
+BB-J2000279,,Default,simple,"Default Category/Outlet Offerte,Default Category/Outlet Offerte/Senza imballaggio",base,"OUTLET Canottiera Modellante con Reggiseno Booby & Tummy (Senza imballaggio) Beige M","Metti
in luce un corpo scultoreo con la Canottiera Modellante con Reggiseno Booby & Tummy! Discreta, comod. Sostiene il seno e offre una grande capacità di sostegno. Prodotta il un tessuto delicato, flessibile e traspirante che si adatta perfettamente al tuo corpo e offre una copertura completa (seno, fianchi e glutei). Equivalenza di taglie: S: 36-38, M: 38-40, L: 40-42.www.boobyandtummy.com
NOTA: Questo prodotto presenta lievi danni estetici, quali graffi o sfregature, che non influiscono sul suo funzionamento. Spedito in confezione standard.
Dimenzioni per OUTLET Canottiera Modellante con Reggiseno Booby & Tummy (Senza imballaggio):
Altezza: 17 Cm Larghezza: 13.5 Cm Profondita': 7 Cm Peso: 0.14 Kg Codice Prodotto (EAN): 4899888101352
","Metti in luce un corpo scultoreo con la Canottiera Modellante con Reggiseno Booby & Tummy! Discreta, comod. Maggiori Informazioni ",0.14,1,"Taxable Goods","Catalog, Search",23.1,,,,OUTLET-Canottiera-Modellante-con-Reggiseno-Booby-&-Tummy--(Senza-imballaggio)-Beige-M,"OUTLET Canottiera Modellante con Reggiseno Booby & Tummy (Senza imballaggio) Beige M","Outlet Offerte,Outlet,Offerte,Senza imballaggio,Senza,imballaggio,Colore Beige,Beige,Taglia M,M,","Metti in luce un corpo scultoreo con la Canottiera Modellante con Reggiseno Booby & Tummy! Discreta, comod",http://dropshipping.bigbuy.eu/imgs/J2000254_89905.jpg,,http://dropshipping.bigbuy.eu/imgs/J2000254_89905.jpg,,,,,,"-0001-11-30 00:00:00",,,,,,,,,,,,,,,,,"GTIN=4899888101352",0,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/J2000254_89903.jpg,http://dropshipping.bigbuy.eu/imgs/J2000254_89906.jpg,http://dropshipping.bigbuy.eu/imgs/J2000254_89904.jpg","GTIN=4899888101352",,,,,,,,,,
+BB-J2000264,,Default,simple,"Default Category/Outlet Offerte,Default Category/Outlet Offerte/Senza imballaggio",base,"OUTLET Scopa elettrica triangolare senza fili 360 Sweep (Senza imballaggio)","La scopa
elettrica triangolare 360 Sweep è perfetta per pulire in modo facile, rapido ed efficace. Grazie alla sua tecnologia innovativa, le setole ruotano automaticamente per rimuovere a fondo tutto lo sporco. Inoltre, questa scopa elettrica è leggera e facile da usare, il che la rende molto comoda e pratica. La scopa elettrica Sweep ruota di 360º e raggiunge facilmente qualsiasi angolo di casa.Prova la nuova scopa elettrica triangolare 360 Sweep e scopri un modo migliore per pulire!
Caratteristiche della Scopa elettrica triangolare 360 Sweep:
Scopa elettrica senza fili Setole rotanti Bastone in alluminio removibile (c.ca 115cm) Base piatta triangolare (3 lati identici: circa 33cm di lunghezza x 3cm di altezza) Batteria ricaricabile 7.2V Caricabatteria (230V, 50Hz) Durata batteria: Approx. 30 min Scopartimento interno raccogli-polvere Leggera, facile da usare, svuotare e pulire Estremamente silenziosa www.360sweep.com
NOTA: Questo prodotto presenta lievi danni estetici, quali graffi o sfregature, che non influiscono sul suo funzionamento. Spedito in confezione standard.
Dimenzioni per OUTLET Scopa elettrica triangolare senza fili 360 Sweep (Senza imballaggio):
Altezza: 32 Cm Larghezza: 39.5 Cm Profondita': 9.5 Cm Peso: 1.625 Kg Codice Prodotto (EAN): 4899888102458
","La scopa elettrica triangolare 360 Sweep è perfetta per pulire in modo facile, rapido ed efficace. Maggiori Informazioni ",1.625,1,"Taxable Goods","Catalog, Search",89.9,,,,OUTLET-Scopa-elettrica-triangolare-senza-fili-360-Sweep-(Senza-imballaggio),"OUTLET Scopa elettrica triangolare senza fili 360 Sweep (Senza imballaggio)","Outlet Offerte,Outlet,Offerte,Senza imballaggio,Senza,imballaggio,","La scopa elettrica triangolare 360 Sweep è perfetta per pulire in modo facile, rapido ed efficace",http://dropshipping.bigbuy.eu/imgs/J2000264_89527.jpg,,http://dropshipping.bigbuy.eu/imgs/J2000264_89527.jpg,,,,,,"2016-09-01 06:15:11",,,,,,,,,,,,,,,,,"GTIN=4899888102458",2,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/J2000264_89533.jpg,http://dropshipping.bigbuy.eu/imgs/J2000264_89532.jpg,http://dropshipping.bigbuy.eu/imgs/J2000264_89531.jpg,http://dropshipping.bigbuy.eu/imgs/J2000264_89530.jpg,http://dropshipping.bigbuy.eu/imgs/J2000264_89529.jpg,http://dropshipping.bigbuy.eu/imgs/J2000264_89528.jpg","GTIN=4899888102458",,,,,,,,,,
+BB-J2000291,,Default,simple,"Default Category/Outlet Offerte,Default Category/Outlet Offerte/Senza imballaggio",base,"OUTLET Sabbia Kinetic per Bambini Playz Kidz (Senza imballaggio)","Porta
la spiaggia a casa con la sabbia kinetic per bambini Playz Kidz ! Il regalo perfetto per sorprendere i tuoi piccoli, che si divertiranno a costruire ogni tipo di castello e forma di sabbia. Questo divertente ed originale gioco sviluppa i talenti artistici e la creatività dei bambini. Comprende circa 0,5 kg di sabbia kinetic e 3 accessori in plastica: un rullo, una forcella e una spatola. Non tossico. Non macchia i vestiti o si attacca alle mani. Età consigliata: 3+ anniwww.playzkidz.com
NOTA: Questo prodotto presenta lievi danni estetici, quali graffi o sfregature, che non influiscono sul suo funzionamento. Spedito in confezione standard.
Dimenzioni per OUTLET Sabbia Kinetic per Bambini Playz Kidz (Senza imballaggio):
Altezza: 17 Cm Larghezza: 14 Cm Profondita': 14 Cm Peso: 0.65 Kg Codice Prodotto (EAN): 4899888108085
","Porta la spiaggia a casa con la sabbia kinetic per bambini Playz Kidz! Il regalo perfetto per sorprendere i tuoi piccoli, che si divertiranno a costruire ogni tipo di castello e forma di sabbia. Maggiori Informazioni ",0.65,1,"Taxable Goods","Catalog, Search",11.9,,,,OUTLET-Sabbia-Kinetic-per-Bambini-Playz-Kidz--(Senza-imballaggio),"OUTLET Sabbia Kinetic per Bambini Playz Kidz (Senza imballaggio)","Outlet Offerte,Outlet,Offerte,Senza imballaggio,Senza,imballaggio,","Porta la spiaggia a casa con la sabbia kinetic per bambini Playz Kidz! Il regalo perfetto per sorprendere i tuoi piccoli, che si divertiranno a costruire ogni tipo di castello e forma di sabbia",http://dropshipping.bigbuy.eu/imgs/J2000291_90163.jpg,,http://dropshipping.bigbuy.eu/imgs/J2000291_90163.jpg,,,,,,"2016-08-09 01:48:11",,,,,,,,,,,,,,,,,"GTIN=4899888108085",778,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/J2000291_90165.jpg,http://dropshipping.bigbuy.eu/imgs/J2000291_90164.jpg","GTIN=4899888108085",,,,,,,,,,
+BB-J2000350,,Default,simple,"Default Category/Outlet Offerte,Default Category/Outlet Offerte/Senza imballaggio",base,"OUTLET Reggiseno Crochet Bra (3 Pezzi) (Senza imballaggio) S","Acquista
il Reggiseno Crochet (3 pezzi) al miglior prezzo. Sentiti fantastica e sexy per tutto il giorno! Dimentica i fili, fascette o spalline. Il Crochet Bra utilizza la tecnologia Woven Everlast per un comfort massimo. Questi reggiseni sono stati elaborati senza tutti quegli elementi in modo da essere usato comodamente dimenticando che lo stai indossando. Questo reggiseno si adatta al tuo seno, sollevandolo e sostenendolo. Il Crochet Bra si adatta perfettamente al tuo corpo e forma , senza lasciare segni o pieghe. In più è morbido, flessibile e molto comodo, e si adatta ad ogni coppa, sollevando il tio seno in modo significativo.www.crochetbra.com Caratteristiche:
Lavabile in lavatrice Bretelle comode Fatto al 96% di nylon e 4% di spandex Adattabile alla forma del tuo seno Solleva il tuo seno La confezione include 3 reggiseni (1 beige, 1 nero and 1 bianco) Equivalenza taglie appross.: S: 80/85 - M: 90/95 - L: 100/105 NOTA: Questo prodotto presenta lievi danni estetici, quali graffi o sfregature, che non influiscono sul suo funzionamento. Spedito in confezione standard.
Dimenzioni per OUTLET Reggiseno Crochet Bra (3 Pezzi) (Senza imballaggio):
Altezza: 4.5 Cm Larghezza: 15.5 Cm Profondita': 27 Cm Peso: 0.269 Kg Codice Prodotto (EAN): 4899888101345
","Acquista il Reggiseno Crochet (3 pezzi) al miglior prezzo. Maggiori Informazioni ",0.269,1,"Taxable Goods","Catalog, Search",34.9,,,,OUTLET-Reggiseno-Crochet-Bra-(3-Pezzi)-(Senza-imballaggio)-S,"OUTLET Reggiseno Crochet Bra (3 Pezzi) (Senza imballaggio) S","Outlet Offerte,Outlet,Offerte,Senza imballaggio,Senza,imballaggio,Taglia S,S,","Acquista il Reggiseno Crochet (3 pezzi) al miglior prezzo",http://dropshipping.bigbuy.eu/imgs/J2000349_93435.jpg,,http://dropshipping.bigbuy.eu/imgs/J2000349_93435.jpg,,,,,,"-0001-11-30 00:00:00",,,,,,,,,,,,,,,,,"GTIN=4899888101345",8,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/J2000349_93438.jpg,http://dropshipping.bigbuy.eu/imgs/J2000349_93437.jpg,http://dropshipping.bigbuy.eu/imgs/J2000349_93436.jpg","GTIN=4899888101345",,,,,,,,,,
diff --git a/dev/tests/acceptance/tests/_data/BB-ProductsWorking.csv b/dev/tests/acceptance/tests/_data/BB-ProductsWorking.csv
new file mode 100644
index 0000000000000..0ea052a043526
--- /dev/null
+++ b/dev/tests/acceptance/tests/_data/BB-ProductsWorking.csv
@@ -0,0 +1,29 @@
+sku,store_view_code,attribute_set_code,product_type,categories,product_websites,name,description,short_description,weight,product_online,tax_class_name,visibility,price,special_price,special_price_from_date,special_price_to_date,url_key,meta_title,meta_keywords,meta_description,base_image,base_image_label,small_image,small_image_label,thumbnail_image,thumbnail_image_label,swatch_image,swatch_image_label,created_at,updated_at,new_from_date,new_to_date,display_product_options_in,map_price,msrp_price,map_enabled,gift_message_available,custom_design,custom_design_from,custom_design_to,custom_layout_update,page_layout,product_options_container,msrp_display_actual_price_type,country_of_manufacture,additional_attributes,qty,out_of_stock_qty,use_config_min_qty,is_qty_decimal,allow_backorders,use_config_backorders,min_cart_qty,use_config_min_sale_qty,max_cart_qty,use_config_max_sale_qty,is_in_stock,notify_on_stock_below,use_config_notify_stock_qty,manage_stock,use_config_manage_stock,use_config_qty_increments,qty_increments,use_config_enable_qty_inc,enable_qty_increments,is_decimal_divided,website_id,related_skus,related_position,crosssell_skus,crosssell_position,upsell_skus,upsell_position,additional_images,additional_image_labels,hide_from_product_page,bundle_price_type,bundle_sku_type,bundle_price_view,bundle_weight_type,bundle_values,bundle_shipment_type,configurable_variations,configurable_variation_labels,associated_skus
+BB-D2010129,,Default,simple,"Default Category/Casa Giardino,Default Category/Casa Giardino/Sistemi di Climatizzazione,Default Category/Casa Giardino/Sistemi di Climatizzazione/Aria condizionata e ventilatori",base,"Ventilatore Portatile Spray FunFan Nero","Se
sei il tipo di persona che è sempre alla ricerca di prodotti innovativi per combattere il caldo estivo, non perderti il ventilatore portatile spray FunFan . Si tratta di una soluzione pratica per mantenersi al fresco in una moltitudine di situazioni, come escursioni, gite in spiaggia, mentre si fa sport, ecc. Inoltre, grazie alle sue dimensioni ridotte (dimensioni: circa 9 x 26 x 6,5 cm) e peso ridotto (circa 130 g), lo puoi portare ovunque!www.myfunfan.com Questo ventilatore portatile originale ha un pulsante per attivare le eliche in PVC malleabili e una leva che spruzza l'acqua. Cosa c'è di più, puoi aggiungere il ghiaccio per aumentare la sensazione di freddo! Include 1 cacciavite a croce per inserire le batterie. Realizzato in PVC. Funzionamento a batterie (2 x AA, non incluse). Dimenzioni per Ventilatore Portatile Spray FunFan :
Altezza: 10 Cm Larghezza: 28 Cm Profondita': 7.5 Cm Peso: 0.185 Kg Codice Prodotto (EAN): 4899888101772
","Se sei il tipo di persona che è sempre alla ricerca di prodotti innovativi per combattere il caldo estivo, non perderti il ventilatore portatile spray FunFan. Maggiori Informazioni ",0.185,1,"Taxable Goods","Catalog, Search",19.9,,,,Ventilatore-Portatile-Spray-FunFan-Nero,"Ventilatore Portatile Spray FunFan Nero","Casa Giardino,Casa,Giardino,Sistemi di Climatizzazione,Sistemi,Climatizzazione,Aria condizionata e ventilatori,Aria,condizionata,ventilatori,Colore Nero,Nero,","Se sei il tipo di persona che è sempre alla ricerca di prodotti innovativi per combattere il caldo estivo, non perderti il ventilatore portatile spray FunFan",http://dropshipping.bigbuy.eu/imgs/D2010128_78887.jpg,,http://dropshipping.bigbuy.eu/imgs/D2010128_78887.jpg,,,,,,"2016-01-12 09:56:53",,,,,,,,,,,,,,,,,"GTIN=4899888101772",41,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/D2010128_78898.jpg,http://dropshipping.bigbuy.eu/imgs/D2010128_78890.jpg,http://dropshipping.bigbuy.eu/imgs/D2010128_78889.jpg,http://dropshipping.bigbuy.eu/imgs/D2010128_78888.jpg,http://dropshipping.bigbuy.eu/imgs/D2010128_78886.jpg","GTIN=4899888101772",,,,,,,,,,
+BB-D2010130,,Default,simple,"Default Category/Casa Giardino,Default Category/Casa Giardino/Sistemi di Climatizzazione,Default Category/Casa Giardino/Sistemi di Climatizzazione/Aria condizionata e ventilatori",base,"Ventilatore Portatile Spray FunFan Bianco","Se
sei il tipo di persona che è sempre alla ricerca di prodotti innovativi per combattere il caldo estivo, non perderti il ventilatore portatile spray FunFan . Si tratta di una soluzione pratica per mantenersi al fresco in una moltitudine di situazioni, come escursioni, gite in spiaggia, mentre si fa sport, ecc. Inoltre, grazie alle sue dimensioni ridotte (dimensioni: circa 9 x 26 x 6,5 cm) e peso ridotto (circa 130 g), lo puoi portare ovunque!www.myfunfan.com Questo ventilatore portatile originale ha un pulsante per attivare le eliche in PVC malleabili e una leva che spruzza l'acqua. Cosa c'è di più, puoi aggiungere il ghiaccio per aumentare la sensazione di freddo! Include 1 cacciavite a croce per inserire le batterie. Realizzato in PVC. Funzionamento a batterie (2 x AA, non incluse). Dimenzioni per Ventilatore Portatile Spray FunFan :
Altezza: 10 Cm Larghezza: 28 Cm Profondita': 7.5 Cm Peso: 0.185 Kg Codice Prodotto (EAN): 4899888107965
","Se sei il tipo di persona che è sempre alla ricerca di prodotti innovativi per combattere il caldo estivo, non perderti il ventilatore portatile spray FunFan. Maggiori Informazioni ",0.185,1,"Taxable Goods","Catalog, Search",19.9,,,,Ventilatore-Portatile-Spray-FunFan-Bianco,"Ventilatore Portatile Spray FunFan Bianco","Casa Giardino,Casa,Giardino,Sistemi di Climatizzazione,Sistemi,Climatizzazione,Aria condizionata e ventilatori,Aria,condizionata,ventilatori,Colore Bianco,Bianco,","Se sei il tipo di persona che è sempre alla ricerca di prodotti innovativi per combattere il caldo estivo, non perderti il ventilatore portatile spray FunFan",http://dropshipping.bigbuy.eu/imgs/D2010128_78898.jpg,,http://dropshipping.bigbuy.eu/imgs/D2010128_78898.jpg,,,,,,"2016-01-12 09:56:53",,,,,,,,,,,,,,,,,"GTIN=4899888107965",741,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/D2010128_78887.jpg,http://dropshipping.bigbuy.eu/imgs/D2010128_78890.jpg,http://dropshipping.bigbuy.eu/imgs/D2010128_78889.jpg,http://dropshipping.bigbuy.eu/imgs/D2010128_78888.jpg,http://dropshipping.bigbuy.eu/imgs/D2010128_78886.jpg","GTIN=4899888107965",,,,,,,,,,
+BB-D2010131,,Default,simple,"Default Category/Casa Giardino,Default Category/Casa Giardino/Sistemi di Climatizzazione,Default Category/Casa Giardino/Sistemi di Climatizzazione/Aria condizionata e ventilatori",base,"Ventilatore Portatile Spray FunFan Rosso","Se
sei il tipo di persona che è sempre alla ricerca di prodotti innovativi per combattere il caldo estivo, non perderti il ventilatore portatile spray FunFan . Si tratta di una soluzione pratica per mantenersi al fresco in una moltitudine di situazioni, come escursioni, gite in spiaggia, mentre si fa sport, ecc. Inoltre, grazie alle sue dimensioni ridotte (dimensioni: circa 9 x 26 x 6,5 cm) e peso ridotto (circa 130 g), lo puoi portare ovunque!www.myfunfan.com Questo ventilatore portatile originale ha un pulsante per attivare le eliche in PVC malleabili e una leva che spruzza l'acqua. Cosa c'è di più, puoi aggiungere il ghiaccio per aumentare la sensazione di freddo! Include 1 cacciavite a croce per inserire le batterie. Realizzato in PVC. Funzionamento a batterie (2 x AA, non incluse). Dimenzioni per Ventilatore Portatile Spray FunFan :
Altezza: 10 Cm Larghezza: 28 Cm Profondita': 7.5 Cm Peso: 0.185 Kg Codice Prodotto (EAN): 4899888107972
","Se sei il tipo di persona che è sempre alla ricerca di prodotti innovativi per combattere il caldo estivo, non perderti il ventilatore portatile spray FunFan. Maggiori Informazioni ",0.185,1,"Taxable Goods","Catalog, Search",19.9,,,,Ventilatore-Portatile-Spray-FunFan-Rosso,"Ventilatore Portatile Spray FunFan Rosso","Casa Giardino,Casa,Giardino,Sistemi di Climatizzazione,Sistemi,Climatizzazione,Aria condizionata e ventilatori,Aria,condizionata,ventilatori,Colore Rosso,Rosso,","Se sei il tipo di persona che è sempre alla ricerca di prodotti innovativi per combattere il caldo estivo, non perderti il ventilatore portatile spray FunFan",http://dropshipping.bigbuy.eu/imgs/D2010128_78890.jpg,,http://dropshipping.bigbuy.eu/imgs/D2010128_78890.jpg,,,,,,"2016-01-12 09:56:53",,,,,,,,,,,,,,,,,"GTIN=4899888107972",570,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/D2010128_78887.jpg,http://dropshipping.bigbuy.eu/imgs/D2010128_78898.jpg,http://dropshipping.bigbuy.eu/imgs/D2010128_78889.jpg,http://dropshipping.bigbuy.eu/imgs/D2010128_78888.jpg,http://dropshipping.bigbuy.eu/imgs/D2010128_78886.jpg","GTIN=4899888107972",,,,,,,,,,
+BB-H1000163,,Default,simple,"Default Category/Casa Giardino,Default Category/Casa Giardino/Giardino e Terrazza,Default Category/Casa Giardino/Giardino e Terrazza/Decorazione, illuminazione e mobili",base,"Sedia Pieghevole Campart Travel CH0592 Blu Marino","Se
stai cercando comfort e convenienza allo stesso tempo, probabilmente adorerai la sedia pieghevole Campart Travel ! Questa sedia da campeggio imbottita è perfetta per i luoghi di campeggio, cortili, giardini, ecc. Ideale per il riposo e il relax. Può portare fino a 120 kg. Dimensioni: 66 x 70 / 120 x 87 / 115 cm circa. Semplice da trasportare ovunque, grazie al suo design funzionale ed elegante (dimensioni quando piegato: circa 66 x 110 x 10 cm). 7 posizioni regolabili e un poggiatesta incorporato. Struttura in alluminio e stoffa imbottita in poliestere. Altezza sedia: circa 50 cm. Dimenzioni per Sedia Pieghevole Campart Travel:
Altezza: 10 Cm Larghezza: 66 Cm Profondita': 110 Cm Peso: 5.3 Kg Codice Prodotto (EAN): 8713016005922
","Se stai cercando comfort e convenienza allo stesso tempo, probabilmente adorerai la sedia pieghevole Campart Travel! Questa sedia da campeggio imbottita è perfetta per i luoghi di campeggio, cortili, giardini, ecc. Maggiori Informazioni ",5.3,1,"Taxable Goods","Catalog, Search",129,,,,Sedia-Pieghevole-Campart-Travel-CH0592 Blu Marino,"Sedia Pieghevole Campart Travel CH0592 Blu Marino","Casa Giardino,Casa,Giardino,Giardino e Terrazza,Giardino,Terrazza,Decorazione, illuminazione e mobili,Decorazione,,illuminazione,mobili,Referenza e Colore CH0592 Blu Marino,CH0592 Blu Marino,","Se stai cercando comfort e convenienza allo stesso tempo, probabilmente adorerai la sedia pieghevole Campart Travel! Questa sedia da campeggio imbottita è perfetta per i luoghi di campeggio, cortili, giardini, ecc",http://dropshipping.bigbuy.eu/imgs/silla_plegable_camping_00.jpg,,http://dropshipping.bigbuy.eu/imgs/silla_plegable_camping_00.jpg,,,,,,"2015-09-21 15:58:54",,,,,,,,,,,,,,,,,"GTIN=8713016005922",1,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/silla_plegable_camping_02.jpg,http://dropshipping.bigbuy.eu/imgs/silla_plegable_camping_04.jpg,http://dropshipping.bigbuy.eu/imgs/silla_plegable_camping_03.jpg,http://dropshipping.bigbuy.eu/imgs/silla_plegable_camping_01.jpg","GTIN=8713016005922",,,,,,,,,,
+BB-H1000162,,Default,simple,"Default Category/Casa Giardino,Default Category/Casa Giardino/Giardino e Terrazza,Default Category/Casa Giardino/Giardino e Terrazza/Decorazione, illuminazione e mobili",base,"Sedia Pieghevole Campart Travel CH0596 Grigio","Se
stai cercando comfort e convenienza allo stesso tempo, probabilmente adorerai la sedia pieghevole Campart Travel ! Questa sedia da campeggio imbottita è perfetta per i luoghi di campeggio, cortili, giardini, ecc. Ideale per il riposo e il relax. Può portare fino a 120 kg. Dimensioni: 66 x 70 / 120 x 87 / 115 cm circa. Semplice da trasportare ovunque, grazie al suo design funzionale ed elegante (dimensioni quando piegato: circa 66 x 110 x 10 cm). 7 posizioni regolabili e un poggiatesta incorporato. Struttura in alluminio e stoffa imbottita in poliestere. Altezza sedia: circa 50 cm. Dimenzioni per Sedia Pieghevole Campart Travel:
Altezza: 10 Cm Larghezza: 66 Cm Profondita': 110 Cm Peso: 5.3 Kg Codice Prodotto (EAN): 8713016005960
","Se stai cercando comfort e convenienza allo stesso tempo, probabilmente adorerai la sedia pieghevole Campart Travel! Questa sedia da campeggio imbottita è perfetta per i luoghi di campeggio, cortili, giardini, ecc. Maggiori Informazioni ",5.3,1,"Taxable Goods","Catalog, Search",129,,,,Sedia-Pieghevole-Campart-Travel-CH0596 Grigio,"Sedia Pieghevole Campart Travel CH0596 Grigio","Casa Giardino,Casa,Giardino,Giardino e Terrazza,Giardino,Terrazza,Decorazione, illuminazione e mobili,Decorazione,,illuminazione,mobili,Referenza e Colore CH0596 Grigio,CH0596 Grigio,","Se stai cercando comfort e convenienza allo stesso tempo, probabilmente adorerai la sedia pieghevole Campart Travel! Questa sedia da campeggio imbottita è perfetta per i luoghi di campeggio, cortili, giardini, ecc",http://dropshipping.bigbuy.eu/imgs/silla_plegable_camping_02.jpg,,http://dropshipping.bigbuy.eu/imgs/silla_plegable_camping_02.jpg,,,,,,"2015-09-21 15:58:54",,,,,,,,,,,,,,,,,"GTIN=8713016005960",2,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/silla_plegable_camping_00.jpg,http://dropshipping.bigbuy.eu/imgs/silla_plegable_camping_04.jpg,http://dropshipping.bigbuy.eu/imgs/silla_plegable_camping_03.jpg,http://dropshipping.bigbuy.eu/imgs/silla_plegable_camping_01.jpg","GTIN=8713016005960",,,,,,,,,,
+BB-F1520329,,Default,simple,"Default Category/Casa Giardino,Default Category/Casa Giardino/Giardino e Terrazza,Default Category/Casa Giardino/Giardino e Terrazza/Decorazione, illuminazione e mobili",base,"Poggiapiedi Pieghevole Campart Travel CH0593 Blu Marino","Approfitta
di un'esperienza rilassante con l'aiuto del poggiapiedi pieghevole Campart Travel ! Questo poggiapiedi imbottito è l'accessorio ideale per sedie da cortile, terrazzo, giardini, luoghi da campeggio, ecc. Possiede 2 ganci di circa 3 cm di diametro che possono essere facilmente attaccate alla barra inferiore delle sedie (utilizzabile solo per sedie con una barra inferiore di circa 2 cm di diametro). Struttura in alluminio. Tessuto: poliestere. Dimensioni: circa 51 x 47 x 96 cm (dimensioni quando ripiegato: circa 51 x 12 x 96 cm). Ideale per le sedie pieghevoli Campart Travel CH0592 e CH0596. Dimenzioni per Poggiapiedi Pieghevole Campart Travel:
Altezza: 13 Cm Larghezza: 53 Cm Profondita': 97 Cm Peso: 1.377 Kg Codice Prodotto (EAN): 8713016005939
","Approfitta di un'esperienza rilassante con l'aiuto del poggiapiedi pieghevole Campart Travel! Questo poggiapiedi imbottito è l'accessorio ideale per sedie da cortile, terrazzo, giardini, luoghi da campeggio, ecc. Maggiori Informazioni ",1.377,1,"Taxable Goods","Catalog, Search",46.6,,,,Poggiapiedi-Pieghevole-Campart-Travel-CH0593 Blu Marino,"Poggiapiedi Pieghevole Campart Travel CH0593 Blu Marino","Casa Giardino,Casa,Giardino,Giardino e Terrazza,Giardino,Terrazza,Decorazione, illuminazione e mobili,Decorazione,,illuminazione,mobili,Referenza e Colore CH0593 Blu Marino,CH0593 Blu Marino,","Approfitta di un'esperienza rilassante con l'aiuto del poggiapiedi pieghevole Campart Travel! Questo poggiapiedi imbottito è l'accessorio ideale per sedie da cortile, terrazzo, giardini, luoghi da campeggio, ecc",http://dropshipping.bigbuy.eu/imgs/reposapies_CH-0609_00.jpg,,http://dropshipping.bigbuy.eu/imgs/reposapies_CH-0609_00.jpg,,,,,,"2015-09-21 15:58:54",,,,,,,,,,,,,,,,,"GTIN=8713016005939",1,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/reposapies_CH-0609_01.jpg,http://dropshipping.bigbuy.eu/imgs/reposapies_CH-0609_02.jpg,http://dropshipping.bigbuy.eu/imgs/reposapies_CH-0609_08.jpg,http://dropshipping.bigbuy.eu/imgs/reposapies_CH-0609_07.jpg,http://dropshipping.bigbuy.eu/imgs/reposapies_CH-0609_06.jpg,http://dropshipping.bigbuy.eu/imgs/reposapies_CH-0609_05.jpg,http://dropshipping.bigbuy.eu/imgs/reposapies_CH-0609_04.jpg","GTIN=8713016005939",,,,,,,,,,
+BB-F1520328,,Default,simple,"Default Category/Casa Giardino,Default Category/Casa Giardino/Giardino e Terrazza,Default Category/Casa Giardino/Giardino e Terrazza/Decorazione, illuminazione e mobili",base,"Poggiapiedi Pieghevole Campart Travel CH0597 Grigio","Approfitta
di un'esperienza rilassante con l'aiuto del poggiapiedi pieghevole Campart Travel ! Questo poggiapiedi imbottito è l'accessorio ideale per sedie da cortile, terrazzo, giardini, luoghi da campeggio, ecc. Possiede 2 ganci di circa 3 cm di diametro che possono essere facilmente attaccate alla barra inferiore delle sedie (utilizzabile solo per sedie con una barra inferiore di circa 2 cm di diametro). Struttura in alluminio. Tessuto: poliestere. Dimensioni: circa 51 x 47 x 96 cm (dimensioni quando ripiegato: circa 51 x 12 x 96 cm). Ideale per le sedie pieghevoli Campart Travel CH0592 e CH0596. Dimenzioni per Poggiapiedi Pieghevole Campart Travel:
Altezza: 13 Cm Larghezza: 53 Cm Profondita': 97 Cm Peso: 1.377 Kg Codice Prodotto (EAN): 8713016005977
","Approfitta di un'esperienza rilassante con l'aiuto del poggiapiedi pieghevole Campart Travel! Questo poggiapiedi imbottito è l'accessorio ideale per sedie da cortile, terrazzo, giardini, luoghi da campeggio, ecc. Maggiori Informazioni ",1.377,1,"Taxable Goods","Catalog, Search",46.6,,,,Poggiapiedi-Pieghevole-Campart-Travel-CH0597 Grigio,"Poggiapiedi Pieghevole Campart Travel CH0597 Grigio","Casa Giardino,Casa,Giardino,Giardino e Terrazza,Giardino,Terrazza,Decorazione, illuminazione e mobili,Decorazione,,illuminazione,mobili,Referenza e Colore CH0597 Grigio,CH0597 Grigio,","Approfitta di un'esperienza rilassante con l'aiuto del poggiapiedi pieghevole Campart Travel! Questo poggiapiedi imbottito è l'accessorio ideale per sedie da cortile, terrazzo, giardini, luoghi da campeggio, ecc",http://dropshipping.bigbuy.eu/imgs/reposapies_CH-0609_01.jpg,,http://dropshipping.bigbuy.eu/imgs/reposapies_CH-0609_01.jpg,,,,,,"2015-09-21 15:58:54",,,,,,,,,,,,,,,,,"GTIN=8713016005977",7,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/reposapies_CH-0609_00.jpg,http://dropshipping.bigbuy.eu/imgs/reposapies_CH-0609_02.jpg,http://dropshipping.bigbuy.eu/imgs/reposapies_CH-0609_08.jpg,http://dropshipping.bigbuy.eu/imgs/reposapies_CH-0609_07.jpg,http://dropshipping.bigbuy.eu/imgs/reposapies_CH-0609_06.jpg,http://dropshipping.bigbuy.eu/imgs/reposapies_CH-0609_05.jpg,http://dropshipping.bigbuy.eu/imgs/reposapies_CH-0609_04.jpg","GTIN=8713016005977",,,,,,,,,,
+BB-H4502058,,Default,simple,"Default Category/Casa Giardino,Default Category/Casa Giardino/Decorazione e Illuminazione,Default Category/Casa Giardino/Decorazione e Illuminazione/Orologi da parete e da tavolo",base,"Orologio da Parete Star Wars","I
fan di Star Wars non potranno fare a meno di appendere l'orologio da parete Star Wars in casa loro! Realizzato in plastica. Funziona a batterie (1 x AA, non incluse). Diametro circa: 25,5 cm. Spessore circa: 3,5 cm. Dimenzioni per Orologio da Parete Star Wars:
Altezza: 25.5 Cm Larghezza: 26 Cm Profondita': 3.8 Cm Peso: 0.287 Kg Codice Prodotto (EAN): 6950687214204
","I fan di Star Wars non potranno fare a meno di appendere l'orologio da parete Star Wars in casa loro! Realizzato in plastica. Maggiori Informazioni ",0.287,1,"Taxable Goods","Catalog, Search",22.5,,,,Orologio-da-Parete-Star-Wars,"Orologio da Parete Star Wars","Casa Giardino,Casa,Giardino,Decorazione e Illuminazione,Decorazione,Illuminazione,Orologi da parete e da tavolo,Orologi,parete,tavolo,","I fan di Star Wars non potranno fare a meno di appendere l'orologio da parete Star Wars in casa loro! Realizzato in plastica",http://dropshipping.bigbuy.eu/imgs/H4502058_84712.jpg,,http://dropshipping.bigbuy.eu/imgs/H4502058_84712.jpg,,,,,,"2016-08-08 21:09:24",,,,,,,,,,,,,,,,,"GTIN=6950687214204",130,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/H4502058_84713.jpg,http://dropshipping.bigbuy.eu/imgs/H4502058_84711.jpg,http://dropshipping.bigbuy.eu/imgs/H4502058_84710.jpg","GTIN=6950687214204",,,,,,,,,,
+BB-G0500195,,Default,simple,"Default Category/Casa Giardino,Default Category/Casa Giardino/Decorazione e Illuminazione,Default Category/Casa Giardino/Decorazione e Illuminazione/Illuminazione LED",base,"Braccialetto Sportivo a LED MegaLed Rosso","Se
ti piace praticare la corsa, il ciclismo, o qualunque sport all'aria aperta, non può mancare tra i tuoi accessori il braccialetto per lo sport a LED MegaLed. Con questo braccialetto di sicurezza sarai visibile ai motorini e alle auto nell'oscurità, così da poter stare molto più sicuro e tranquillo. È dotato di 2 luci a LED con 2 possibili soluzioni (luce fissa ed intermittente). La lunghezza massima è di circa 55 cm e quella minima è di circa 42 cm. Molto leggero (circa 50 g). Autonomia circa: 24-40 ore. Funziona a batterie (2 x CR2023, incluse).
Dimenzioni per Braccialetto Sportivo a LED MegaLed:
Altezza: 3 Cm Larghezza: 20 Cm Profondita': 4 Cm Peso: 0.049 Kg Codice Prodotto (EAN): 8436545443507
","Se ti piace praticare la corsa, il ciclismo, o qualunque sport all'aria aperta, non può mancare tra i tuoi accessori il braccialetto per lo sport a LED MegaLed. Maggiori Informazioni ",0.049,1,"Taxable Goods","Catalog, Search",22,,,,Braccialetto-Sportivo-a-LED-MegaLed-Rosso,"Braccialetto Sportivo a LED MegaLed Rosso","Casa Giardino,Casa,Giardino,Decorazione e Illuminazione,Decorazione,Illuminazione,Illuminazione LED,Illuminazione,LED,Colore Rosso,Rosso,","Se ti piace praticare la corsa, il ciclismo, o qualunque sport all'aria aperta, non può mancare tra i tuoi accessori il braccialetto per lo sport a LED MegaLed",http://dropshipping.bigbuy.eu/imgs/G0500194_87774.jpg,,http://dropshipping.bigbuy.eu/imgs/G0500194_87774.jpg,,,,,,"2016-01-08 12:34:41",,,,,,,,,,,,,,,,,"GTIN=8436545443507",22,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/G0500194_87775.jpg,http://dropshipping.bigbuy.eu/imgs/G0500194_87773.jpg,http://dropshipping.bigbuy.eu/imgs/G0500194_87772.jpg","GTIN=8436545443507",,,,,,,,,,
+BB-G0500196,,Default,simple,"Default Category/Casa Giardino,Default Category/Casa Giardino/Decorazione e Illuminazione,Default Category/Casa Giardino/Decorazione e Illuminazione/Illuminazione LED",base,"Braccialetto Sportivo a LED MegaLed Verde","Se
ti piace praticare la corsa, il ciclismo, o qualunque sport all'aria aperta, non può mancare tra i tuoi accessori il braccialetto per lo sport a LED MegaLed. Con questo braccialetto di sicurezza sarai visibile ai motorini e alle auto nell'oscurità, così da poter stare molto più sicuro e tranquillo. È dotato di 2 luci a LED con 2 possibili soluzioni (luce fissa ed intermittente). La lunghezza massima è di circa 55 cm e quella minima è di circa 42 cm. Molto leggero (circa 50 g). Autonomia circa: 24-40 ore. Funziona a batterie (2 x CR2023, incluse).
Dimenzioni per Braccialetto Sportivo a LED MegaLed:
Altezza: 3 Cm Larghezza: 20 Cm Profondita': 4 Cm Peso: 0.049 Kg Codice Prodotto (EAN): 8436545443507
","Se ti piace praticare la corsa, il ciclismo, o qualunque sport all'aria aperta, non può mancare tra i tuoi accessori il braccialetto per lo sport a LED MegaLed. Maggiori Informazioni ",0.049,1,"Taxable Goods","Catalog, Search",22,,,,Braccialetto-Sportivo-a-LED-MegaLed-Verde,"Braccialetto Sportivo a LED MegaLed Verde","Casa Giardino,Casa,Giardino,Decorazione e Illuminazione,Decorazione,Illuminazione,Illuminazione LED,Illuminazione,LED,Colore Verde,Verde,","Se ti piace praticare la corsa, il ciclismo, o qualunque sport all'aria aperta, non può mancare tra i tuoi accessori il braccialetto per lo sport a LED MegaLed",http://dropshipping.bigbuy.eu/imgs/G0500194_87775.jpg,,http://dropshipping.bigbuy.eu/imgs/G0500194_87775.jpg,,,,,,"2016-01-08 12:34:41",,,,,,,,,,,,,,,,,"GTIN=8436545443507",37,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/G0500194_87774.jpg,http://dropshipping.bigbuy.eu/imgs/G0500194_87773.jpg,http://dropshipping.bigbuy.eu/imgs/G0500194_87772.jpg","GTIN=8436545443507",,,,,,,,,,
+BB-I2500333,,Default,simple,"Default Category/Casa Giardino,Default Category/Casa Giardino/Decorazione e Illuminazione,Default Category/Casa Giardino/Decorazione e Illuminazione/Orologi da parete e da tavolo",base,"Orologio da Parete Mom's Diner","Decora
la tua cucina con l'originale orologio da parete Mom's Diner in stile vintage! È realizzato in legno. Diametro: 58 cm circa. Spessore: 0,8 cm circa. Funziona a pile (1 x AA, non inclusa). Dimenzioni per Orologio da Parete Mom's Diner:
Altezza: 59 Cm Larghezza: 59 Cm Profondita': 6 Cm Peso: 2.1 Kg Codice Prodotto (EAN): 4029811345052
","Decora la tua cucina con l'originale orologio da parete Mom's Diner in stile vintage! È realizzato in legno. Maggiori Informazioni ",2.1,1,"Taxable Goods","Catalog, Search",42.5,,,,Orologio-da-Parete-Mom's-Diner,"Orologio da Parete Mom's Diner","Casa Giardino,Casa,Giardino,Decorazione e Illuminazione,Decorazione,Illuminazione,Orologi da parete e da tavolo,Orologi,parete,tavolo,","Decora la tua cucina con l'originale orologio da parete Mom's Diner in stile vintage! È realizzato in legno",http://dropshipping.bigbuy.eu/imgs/I2500333_88061.jpg,,http://dropshipping.bigbuy.eu/imgs/I2500333_88061.jpg,,,,,,"2016-07-21 13:05:12",,,,,,,,,,,,,,,,,"GTIN=4029811345052",2,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/I2500333_88060.jpg,http://dropshipping.bigbuy.eu/imgs/I2500333_88059.jpg,http://dropshipping.bigbuy.eu/imgs/I2500333_88058.jpg","GTIN=4029811345052",,,,,,,,,,
+BB-I2500334,,Default,simple,"Default Category/Casa Giardino,Default Category/Casa Giardino/Decorazione e Illuminazione,Default Category/Casa Giardino/Decorazione e Illuminazione/Orologi da parete e da tavolo",base,"Orologio da Parete Coffee Endless Cup","Se
sei un appassionato di caffè, non puoi rimanere senza l'orologio da parete Coffee Endless Cup ! Un orologio vintage in legno con un design in perfetto stile caffettoso! Diametro: 58 cm circa. Spessore: 0,8 cm circa. Funziona a pile (1 x AA, non inclusa). Dimenzioni per Orologio da Parete Coffee Endless Cup:
Altezza: 59 Cm Larghezza: 59 Cm Profondita': 6 Cm Peso: 2.1 Kg Codice Prodotto (EAN): 4029811345069
","Se sei un appassionato di caffè, non puoi rimanere senza l'orologio da parete Coffee Endless Cup! Un orologio vintage in legno con un design in perfetto stile caffettoso! Diametro: 58 cm circa. Maggiori Informazioni ",2.1,1,"Taxable Goods","Catalog, Search",42.5,,,,Orologio-da-Parete-Coffee-Endless-Cup,"Orologio da Parete Coffee Endless Cup","Casa Giardino,Casa,Giardino,Decorazione e Illuminazione,Decorazione,Illuminazione,Orologi da parete e da tavolo,Orologi,parete,tavolo,","Se sei un appassionato di caffè, non puoi rimanere senza l'orologio da parete Coffee Endless Cup! Un orologio vintage in legno con un design in perfetto stile caffettoso! Diametro: 58 cm circa",http://dropshipping.bigbuy.eu/imgs/I2500334_88065.jpg,,http://dropshipping.bigbuy.eu/imgs/I2500334_88065.jpg,,,,,,"2016-08-30 13:41:52",,,,,,,,,,,,,,,,,"GTIN=4029811345069",4,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/I2500334_88064.jpg,http://dropshipping.bigbuy.eu/imgs/I2500334_88063.jpg,http://dropshipping.bigbuy.eu/imgs/I2500334_88062.jpg","GTIN=4029811345069",,,,,,,,,,
+BB-V0000252,,Default,simple,"Default Category/Casa Giardino,Default Category/Casa Giardino/Decorazione e Illuminazione,Default Category/Casa Giardino/Decorazione e Illuminazione/Altri articoli decorativi",base,"Insegna Dito Vintage Look Stop!","Se
sei alla ricerca di una decorazione vintage originale e divertente per la tua casa, l'insegna dito Vintage Look ti conquisterà con il suo stile e i suoi simpatici messaggi! Realizzata in legno. Dimensioni: 69 x 17 x 1 cm circa. Dimenzioni per Insegna Dito Vintage Look:
Altezza: 17 Cm Larghezza: 69 Cm Profondita': 1 Cm Peso: 0.63 Kg Codice Prodotto (EAN): 4029811346196
","Se sei alla ricerca di una decorazione vintage originale e divertente per la tua casa, l'insegna dito Vintage Look ti conquisterà con il suo stile e i suoi simpatici messaggi! Realizzata in legno. Maggiori Informazioni ",0.63,1,"Taxable Goods","Catalog, Search",15.99,,,,Insegna-Dito-Vintage-Look-Stop!,"Insegna Dito Vintage Look Stop!","Casa Giardino,Casa,Giardino,Decorazione e Illuminazione,Decorazione,Illuminazione,Altri articoli decorativi,Altri,articoli,decorativi,Design Stop!,Stop!,","Se sei alla ricerca di una decorazione vintage originale e divertente per la tua casa, l'insegna dito Vintage Look ti conquisterà con il suo stile e i suoi simpatici messaggi! Realizzata in legno",http://dropshipping.bigbuy.eu/imgs/V0000251_89745.jpg,,http://dropshipping.bigbuy.eu/imgs/V0000251_89745.jpg,,,,,,"2016-02-29 09:49:10",,,,,,,,,,,,,,,,,"GTIN=4029811346196",21,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/V0000251_89746.jpg,http://dropshipping.bigbuy.eu/imgs/V0000251_89744.jpg,http://dropshipping.bigbuy.eu/imgs/V0000251_89743.jpg,http://dropshipping.bigbuy.eu/imgs/V0000251_89742.jpg,http://dropshipping.bigbuy.eu/imgs/V0000251_89741.jpg","GTIN=4029811346196",,,,,,,,,,
+BB-V0000253,,Default,simple,"Default Category/Casa Giardino,Default Category/Casa Giardino/Decorazione e Illuminazione,Default Category/Casa Giardino/Decorazione e Illuminazione/Altri articoli decorativi",base,"Insegna Dito Vintage Look Adults Only","Se
sei alla ricerca di una decorazione vintage originale e divertente per la tua casa, l'insegna dito Vintage Look ti conquisterà con il suo stile e i suoi simpatici messaggi! Realizzata in legno. Dimensioni: 69 x 17 x 1 cm circa. Dimenzioni per Insegna Dito Vintage Look:
Altezza: 17 Cm Larghezza: 69 Cm Profondita': 1 Cm Peso: 0.63 Kg Codice Prodotto (EAN): 4029811346202
","Se sei alla ricerca di una decorazione vintage originale e divertente per la tua casa, l'insegna dito Vintage Look ti conquisterà con il suo stile e i suoi simpatici messaggi! Realizzata in legno. Maggiori Informazioni ",0.63,1,"Taxable Goods","Catalog, Search",15.99,,,,Insegna-Dito-Vintage-Look-Adults Only,"Insegna Dito Vintage Look Adults Only","Casa Giardino,Casa,Giardino,Decorazione e Illuminazione,Decorazione,Illuminazione,Altri articoli decorativi,Altri,articoli,decorativi,Design Adults Only,Adults Only,","Se sei alla ricerca di una decorazione vintage originale e divertente per la tua casa, l'insegna dito Vintage Look ti conquisterà con il suo stile e i suoi simpatici messaggi! Realizzata in legno",http://dropshipping.bigbuy.eu/imgs/V0000251_89746.jpg,,http://dropshipping.bigbuy.eu/imgs/V0000251_89746.jpg,,,,,,"2016-02-29 09:49:10",,,,,,,,,,,,,,,,,"GTIN=4029811346202",18,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/V0000251_89745.jpg,http://dropshipping.bigbuy.eu/imgs/V0000251_89744.jpg,http://dropshipping.bigbuy.eu/imgs/V0000251_89743.jpg,http://dropshipping.bigbuy.eu/imgs/V0000251_89742.jpg,http://dropshipping.bigbuy.eu/imgs/V0000251_89741.jpg","GTIN=4029811346202",,,,,,,,,,
+BB-V0000254,,Default,simple,"Default Category/Casa Giardino,Default Category/Casa Giardino/Decorazione e Illuminazione,Default Category/Casa Giardino/Decorazione e Illuminazione/Altri articoli decorativi",base,"Insegna Dito Vintage Look Talk","Se
sei alla ricerca di una decorazione vintage originale e divertente per la tua casa, l'insegna dito Vintage Look ti conquisterà con il suo stile e i suoi simpatici messaggi! Realizzata in legno. Dimensioni: 69 x 17 x 1 cm circa. Dimenzioni per Insegna Dito Vintage Look:
Altezza: 17 Cm Larghezza: 69 Cm Profondita': 1 Cm Peso: 0.63 Kg Codice Prodotto (EAN): 4029811346318
","Se sei alla ricerca di una decorazione vintage originale e divertente per la tua casa, l'insegna dito Vintage Look ti conquisterà con il suo stile e i suoi simpatici messaggi! Realizzata in legno. Maggiori Informazioni ",0.63,1,"Taxable Goods","Catalog, Search",15.99,,,,Insegna-Dito-Vintage-Look-Talk,"Insegna Dito Vintage Look Talk","Casa Giardino,Casa,Giardino,Decorazione e Illuminazione,Decorazione,Illuminazione,Altri articoli decorativi,Altri,articoli,decorativi,Design Talk,Talk,","Se sei alla ricerca di una decorazione vintage originale e divertente per la tua casa, l'insegna dito Vintage Look ti conquisterà con il suo stile e i suoi simpatici messaggi! Realizzata in legno",http://dropshipping.bigbuy.eu/imgs/V0000251_89744.jpg,,http://dropshipping.bigbuy.eu/imgs/V0000251_89744.jpg,,,,,,"2016-02-29 09:49:10",,,,,,,,,,,,,,,,,"GTIN=4029811346318",8,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/V0000251_89745.jpg,http://dropshipping.bigbuy.eu/imgs/V0000251_89746.jpg,http://dropshipping.bigbuy.eu/imgs/V0000251_89743.jpg,http://dropshipping.bigbuy.eu/imgs/V0000251_89742.jpg,http://dropshipping.bigbuy.eu/imgs/V0000251_89741.jpg","GTIN=4029811346318",,,,,,,,,,
+BB-V0000256,,Default,simple,"Default Category/Casa Giardino,Default Category/Casa Giardino/Decorazione e Illuminazione,Default Category/Casa Giardino/Decorazione e Illuminazione/Altri articoli decorativi",base,"Freccia Decorativa Vintage Look Go Left","Stupisci
tutti con la divertente ed originale freccia decorativa Vintage Look ! Le pareti di casa tua non resteranno indifferenti a nessuno! Fabbricata in legno. Misure appross.: 25 x 40 x 1 cm. Dimenzioni per Freccia Decorativa Vintage Look:
Altezza: 25.5 Cm Larghezza: 0.8 Cm Profondita': 40 Cm Peso: 0.376 Kg Codice Prodotto (EAN): 4029811346325
","Stupisci tutti con la divertente ed originale freccia decorativa Vintage Look! Le pareti di casa tua non resteranno indifferenti a nessuno! Fabbricata in legno. Maggiori Informazioni ",0.376,1,"Taxable Goods","Catalog, Search",13.9,,,,Freccia-Decorativa-Vintage-Look-Go Left,"Freccia Decorativa Vintage Look Go Left","Casa Giardino,Casa,Giardino,Decorazione e Illuminazione,Decorazione,Illuminazione,Altri articoli decorativi,Altri,articoli,decorativi,Design Go Left,Go Left,","Stupisci tutti con la divertente ed originale freccia decorativa Vintage Look! Le pareti di casa tua non resteranno indifferenti a nessuno! Fabbricata in legno",http://dropshipping.bigbuy.eu/imgs/V0000255_89756.jpg,,http://dropshipping.bigbuy.eu/imgs/V0000255_89756.jpg,,,,,,"2016-02-29 10:39:59",,,,,,,,,,,,,,,,,"GTIN=4029811346325",4,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/V0000255_89761.jpg,http://dropshipping.bigbuy.eu/imgs/V0000255_89760.jpg,http://dropshipping.bigbuy.eu/imgs/V0000255_89759.jpg,http://dropshipping.bigbuy.eu/imgs/V0000255_89758.jpg,http://dropshipping.bigbuy.eu/imgs/V0000255_89757.jpg","GTIN=4029811346325",,,,,,,,,,
+BB-V0000257,,Default,simple,"Default Category/Casa Giardino,Default Category/Casa Giardino/Decorazione e Illuminazione,Default Category/Casa Giardino/Decorazione e Illuminazione/Altri articoli decorativi",base,"Freccia Decorativa Vintage Look Exit","Stupisci
tutti con la divertente ed originale freccia decorativa Vintage Look ! Le pareti di casa tua non resteranno indifferenti a nessuno! Fabbricata in legno. Misure appross.: 25 x 40 x 1 cm. Dimenzioni per Freccia Decorativa Vintage Look:
Altezza: 25.5 Cm Larghezza: 0.8 Cm Profondita': 40 Cm Peso: 0.376 Kg Codice Prodotto (EAN): 4029811346332
","Stupisci tutti con la divertente ed originale freccia decorativa Vintage Look! Le pareti di casa tua non resteranno indifferenti a nessuno! Fabbricata in legno. Maggiori Informazioni ",0.376,1,"Taxable Goods","Catalog, Search",13.9,,,,Freccia-Decorativa-Vintage-Look-Exit,"Freccia Decorativa Vintage Look Exit","Casa Giardino,Casa,Giardino,Decorazione e Illuminazione,Decorazione,Illuminazione,Altri articoli decorativi,Altri,articoli,decorativi,Design Exit,Exit,","Stupisci tutti con la divertente ed originale freccia decorativa Vintage Look! Le pareti di casa tua non resteranno indifferenti a nessuno! Fabbricata in legno",http://dropshipping.bigbuy.eu/imgs/V0000255_89761.jpg,,http://dropshipping.bigbuy.eu/imgs/V0000255_89761.jpg,,,,,,"2016-02-29 10:39:59",,,,,,,,,,,,,,,,,"GTIN=4029811346332",19,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/V0000255_89756.jpg,http://dropshipping.bigbuy.eu/imgs/V0000255_89760.jpg,http://dropshipping.bigbuy.eu/imgs/V0000255_89759.jpg,http://dropshipping.bigbuy.eu/imgs/V0000255_89758.jpg,http://dropshipping.bigbuy.eu/imgs/V0000255_89757.jpg","GTIN=4029811346332",,,,,,,,,,
+BB-V0000258,,Default,simple,"Default Category/Casa Giardino,Default Category/Casa Giardino/Decorazione e Illuminazione,Default Category/Casa Giardino/Decorazione e Illuminazione/Altri articoli decorativi",base,"Freccia Decorativa Vintage Look Cold beer here","Stupisci
tutti con la divertente ed originale freccia decorativa Vintage Look ! Le pareti di casa tua non resteranno indifferenti a nessuno! Fabbricata in legno. Misure appross.: 25 x 40 x 1 cm. Dimenzioni per Freccia Decorativa Vintage Look:
Altezza: 25.5 Cm Larghezza: 0.8 Cm Profondita': 40 Cm Peso: 0.376 Kg Codice Prodotto (EAN): 4029811346349
","Stupisci tutti con la divertente ed originale freccia decorativa Vintage Look! Le pareti di casa tua non resteranno indifferenti a nessuno! Fabbricata in legno. Maggiori Informazioni ",0.376,1,"Taxable Goods","Catalog, Search",13.9,,,,Freccia-Decorativa-Vintage-Look-Cold beer here,"Freccia Decorativa Vintage Look Cold beer here","Casa Giardino,Casa,Giardino,Decorazione e Illuminazione,Decorazione,Illuminazione,Altri articoli decorativi,Altri,articoli,decorativi,Design Cold beer here,Cold beer here,","Stupisci tutti con la divertente ed originale freccia decorativa Vintage Look! Le pareti di casa tua non resteranno indifferenti a nessuno! Fabbricata in legno",http://dropshipping.bigbuy.eu/imgs/V0000255_89760.jpg,,http://dropshipping.bigbuy.eu/imgs/V0000255_89760.jpg,,,,,,"2016-02-29 10:39:59",,,,,,,,,,,,,,,,,"GTIN=4029811346349",20,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/V0000255_89756.jpg,http://dropshipping.bigbuy.eu/imgs/V0000255_89761.jpg,http://dropshipping.bigbuy.eu/imgs/V0000255_89759.jpg,http://dropshipping.bigbuy.eu/imgs/V0000255_89758.jpg,http://dropshipping.bigbuy.eu/imgs/V0000255_89757.jpg","GTIN=4029811346349",,,,,,,,,,
+BB-V0200190,,Default,simple,"Default Category/Casa Giardino,Default Category/Casa Giardino/Decorazione e Illuminazione,Default Category/Casa Giardino/Decorazione e Illuminazione/Centrotavola e Vasi",base,"Ciotola in Bambù TakeTokio Bianco","Arricchisci
la selezione dei tuoi utensili da cucina con la ciotola in bambù TakeTokio , una ciotola da cucina funzionale e dal design moderno è perfetta come insalatiera , portafrutta, ecc. Realizzata in pregiato legno di bambù. Dimensioni (diametro x altezza): 25 x 15 cm circa. Diametro della base: 9 cm circa.www.taketokio.com
Dimenzioni per Ciotola in Bambù TakeTokio:
Altezza: 25 Cm Larghezza: 25 Cm Profondita': 15 Cm Peso: 0.39 Kg Codice Prodotto (EAN): 8718158904577
","Arricchisci la selezione dei tuoi utensili da cucina con la ciotola in bambù TakeTokio, una ciotola da cucina funzionale e dal design moderno è perfetta come insalatiera, portafrutta, ecc. Maggiori Informazioni ",0.39,1,"Taxable Goods","Catalog, Search",19.8,,,,Ciotola-in-Bambù-TakeTokio-Bianco,"Ciotola in Bambù TakeTokio Bianco","Casa Giardino,Casa,Giardino,Decorazione e Illuminazione,Decorazione,Illuminazione,Centrotavola e Vasi,Centrotavola,Vasi,Colore Bianco,Bianco,","Arricchisci la selezione dei tuoi utensili da cucina con la ciotola in bambù TakeTokio, una ciotola da cucina funzionale e dal design moderno è perfetta come insalatiera, portafrutta, ecc",http://dropshipping.bigbuy.eu/imgs/V0200189_90746.jpg,,http://dropshipping.bigbuy.eu/imgs/V0200189_90746.jpg,,,,,,"-0001-11-30 00:00:00",,,,,,,,,,,,,,,,,"GTIN=8718158904577",0,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/V0200189_90747.jpg,http://dropshipping.bigbuy.eu/imgs/V0200189_90745.jpg,http://dropshipping.bigbuy.eu/imgs/V0200189_90744.jpg,http://dropshipping.bigbuy.eu/imgs/V0200189_90743.jpg,http://dropshipping.bigbuy.eu/imgs/V0200189_90742.jpg","GTIN=8718158904577",,,,,,,,,,
+BB-V0200192,,Default,simple,"Default Category/Casa Giardino,Default Category/Casa Giardino/Decorazione e Illuminazione,Default Category/Casa Giardino/Decorazione e Illuminazione/Centrotavola e Vasi",base,"Ciotola in Bambù TakeTokio Grigio","Arricchisci
la selezione dei tuoi utensili da cucina con la ciotola in bambù TakeTokio , una ciotola da cucina funzionale e dal design moderno è perfetta come insalatiera , portafrutta, ecc. Realizzata in pregiato legno di bambù. Dimensioni (diametro x altezza): 25 x 15 cm circa. Diametro della base: 9 cm circa.www.taketokio.com
Dimenzioni per Ciotola in Bambù TakeTokio:
Altezza: 25 Cm Larghezza: 25 Cm Profondita': 15 Cm Peso: 0.39 Kg Codice Prodotto (EAN): 8718158904577
","Arricchisci la selezione dei tuoi utensili da cucina con la ciotola in bambù TakeTokio, una ciotola da cucina funzionale e dal design moderno è perfetta come insalatiera, portafrutta, ecc. Maggiori Informazioni ",0.39,1,"Taxable Goods","Catalog, Search",19.8,,,,Ciotola-in-Bambù-TakeTokio-Grigio,"Ciotola in Bambù TakeTokio Grigio","Casa Giardino,Casa,Giardino,Decorazione e Illuminazione,Decorazione,Illuminazione,Centrotavola e Vasi,Centrotavola,Vasi,Colore Grigio,Grigio,","Arricchisci la selezione dei tuoi utensili da cucina con la ciotola in bambù TakeTokio, una ciotola da cucina funzionale e dal design moderno è perfetta come insalatiera, portafrutta, ecc",http://dropshipping.bigbuy.eu/imgs/V0200189_90747.jpg,,http://dropshipping.bigbuy.eu/imgs/V0200189_90747.jpg,,,,,,"-0001-11-30 00:00:00",,,,,,,,,,,,,,,,,"GTIN=8718158904577",26,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/V0200189_90746.jpg,http://dropshipping.bigbuy.eu/imgs/V0200189_90745.jpg,http://dropshipping.bigbuy.eu/imgs/V0200189_90744.jpg,http://dropshipping.bigbuy.eu/imgs/V0200189_90743.jpg,http://dropshipping.bigbuy.eu/imgs/V0200189_90742.jpg","GTIN=8718158904577",,,,,,,,,,
+BB-V0200191,,Default,simple,"Default Category/Casa Giardino,Default Category/Casa Giardino/Decorazione e Illuminazione,Default Category/Casa Giardino/Decorazione e Illuminazione/Centrotavola e Vasi",base,"Ciotola in Bambù TakeTokio Nero","Arricchisci
la selezione dei tuoi utensili da cucina con la ciotola in bambù TakeTokio , una ciotola da cucina funzionale e dal design moderno è perfetta come insalatiera , portafrutta, ecc. Realizzata in pregiato legno di bambù. Dimensioni (diametro x altezza): 25 x 15 cm circa. Diametro della base: 9 cm circa.www.taketokio.com
Dimenzioni per Ciotola in Bambù TakeTokio:
Altezza: 25 Cm Larghezza: 25 Cm Profondita': 15 Cm Peso: 0.39 Kg Codice Prodotto (EAN): 8718158904577
","Arricchisci la selezione dei tuoi utensili da cucina con la ciotola in bambù TakeTokio, una ciotola da cucina funzionale e dal design moderno è perfetta come insalatiera, portafrutta, ecc. Maggiori Informazioni ",0.39,1,"Taxable Goods","Catalog, Search",19.8,,,,Ciotola-in-Bambù-TakeTokio-Nero,"Ciotola in Bambù TakeTokio Nero","Casa Giardino,Casa,Giardino,Decorazione e Illuminazione,Decorazione,Illuminazione,Centrotavola e Vasi,Centrotavola,Vasi,Colore Nero,Nero,","Arricchisci la selezione dei tuoi utensili da cucina con la ciotola in bambù TakeTokio, una ciotola da cucina funzionale e dal design moderno è perfetta come insalatiera, portafrutta, ecc",http://dropshipping.bigbuy.eu/imgs/V0200189_90745.jpg,,http://dropshipping.bigbuy.eu/imgs/V0200189_90745.jpg,,,,,,"-0001-11-30 00:00:00",,,,,,,,,,,,,,,,,"GTIN=8718158904577",22,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/V0200189_90746.jpg,http://dropshipping.bigbuy.eu/imgs/V0200189_90747.jpg,http://dropshipping.bigbuy.eu/imgs/V0200189_90744.jpg,http://dropshipping.bigbuy.eu/imgs/V0200189_90743.jpg,http://dropshipping.bigbuy.eu/imgs/V0200189_90742.jpg","GTIN=8718158904577",,,,,,,,,,
+BB-V0200360,,Default,simple,"Default Category/Casa Giardino,Default Category/Casa Giardino/Arredamento,Default Category/Casa Giardino/Arredamento/Soluzioni per Organizzare",base,"Scatola porta Tè Flower Vintage Coconut Rosa","Gli
amanti della moda vintage non potranno resistere di fronte all'adorabile scatola porta tè Flower Vintage Coconut ! Una scatola vintage in legno ottima come decorazione e utilissima per sistemare le bustine di tè o di altri infusi. Dispone di un coperchio in cristallo e vari scompartimenti. Dimensioni: circa 23 x 7 x 23 cm.www.vintagecoconut.com
Dimenzioni per Scatola porta Tè Flower Vintage Coconut:
Altezza: 23 Cm Larghezza: 7.1 Cm Profondita': 23 Cm Peso: 0.795 Kg Codice Prodotto (EAN): 8711295889547
","Gli amanti della moda vintage non potranno resistere di fronte all'adorabile scatola porta tè Flower Vintage Coconut! Una scatola vintage in legno ottima come decorazione e utilissima per sistemare le bustine di tè o di altri infusi. Maggiori Informazioni ",0.795,1,"Taxable Goods","Catalog, Search",25.9,,,,Scatola-porta-Tè-Flower-Vintage-Coconut-Rosa,"Scatola porta Tè Flower Vintage Coconut Rosa","Casa Giardino,Casa,Giardino,Arredamento,Soluzioni per Organizzare,Soluzioni,Organizzare,Colore Rosa,Rosa,","Gli amanti della moda vintage non potranno resistere di fronte all'adorabile scatola porta tè Flower Vintage Coconut! Una scatola vintage in legno ottima come decorazione e utilissima per sistemare le bustine di tè o di altri infusi",http://dropshipping.bigbuy.eu/imgs/V0200328_92649.jpg,,http://dropshipping.bigbuy.eu/imgs/V0200328_92649.jpg,,,,,,"-0001-11-30 00:00:00",,,,,,,,,,,,,,,,,"GTIN=8711295889547",13,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/V0200328_92648.jpg,http://dropshipping.bigbuy.eu/imgs/V0200328_92647.jpg","GTIN=8711295889547",,,,,,,,,,
+BB-V0200361,,Default,simple,"Default Category/Casa Giardino,Default Category/Casa Giardino/Arredamento,Default Category/Casa Giardino/Arredamento/Soluzioni per Organizzare",base,"Scatola porta Tè Flower Vintage Coconut Azzurro","Gli
amanti della moda vintage non potranno resistere di fronte all'adorabile scatola porta tè Flower Vintage Coconut ! Una scatola vintage in legno ottima come decorazione e utilissima per sistemare le bustine di tè o di altri infusi. Dispone di un coperchio in cristallo e vari scompartimenti. Dimensioni: circa 23 x 7 x 23 cm.www.vintagecoconut.com
Dimenzioni per Scatola porta Tè Flower Vintage Coconut:
Altezza: 23 Cm Larghezza: 7.1 Cm Profondita': 23 Cm Peso: 0.795 Kg Codice Prodotto (EAN): 8711295889547
","Gli amanti della moda vintage non potranno resistere di fronte all'adorabile scatola porta tè Flower Vintage Coconut! Una scatola vintage in legno ottima come decorazione e utilissima per sistemare le bustine di tè o di altri infusi. Maggiori Informazioni ",0.795,1,"Taxable Goods","Catalog, Search",25.9,,,,Scatola-porta-Tè-Flower-Vintage-Coconut-Azzurro,"Scatola porta Tè Flower Vintage Coconut Azzurro","Casa Giardino,Casa,Giardino,Arredamento,Soluzioni per Organizzare,Soluzioni,Organizzare,Colore Azzurro,Azzurro,","Gli amanti della moda vintage non potranno resistere di fronte all'adorabile scatola porta tè Flower Vintage Coconut! Una scatola vintage in legno ottima come decorazione e utilissima per sistemare le bustine di tè o di altri infusi",http://dropshipping.bigbuy.eu/imgs/V0200328_92648.jpg,,http://dropshipping.bigbuy.eu/imgs/V0200328_92648.jpg,,,,,,"-0001-11-30 00:00:00",,,,,,,,,,,,,,,,,"GTIN=8711295889547",21,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/V0200328_92649.jpg,http://dropshipping.bigbuy.eu/imgs/V0200328_92647.jpg","GTIN=8711295889547",,,,,,,,,,
+BB-V0200353,,Default,simple,"Default Category/Casa Giardino,Default Category/Casa Giardino/Giardino e Terrazza,Default Category/Casa Giardino/Giardino e Terrazza/Barbecue",base,"Ventilatore a Pistola classico per Barbecue BBQ Classics","Utilizza
i migliori barbecue alimentando il fuoco con il ventilatore a pistola classico per babecue BBQ Classics ! Basterà solo fare una leggera pressione sul pulsante per far uscire l'aria.www.bbqclassics.com
Realizzato in plastica e metallo Dimensioni: 25 x 18 x 4 cm circa Dimenzioni per Ventilatore a Pistola classico per Barbecue BBQ Classics:
Altezza: 5.5 Cm Larghezza: 11 Cm Profondita': 22 Cm Peso: 0.167 Kg Codice Prodotto (EAN): 8718158032706
","Utilizza i migliori barbecue alimentando il fuoco con il ventilatore a pistola classico per babecue BBQ Classics! Basterà solo fare una leggera pressione sul pulsante per far uscire l'aria. Maggiori Informazioni ",0.167,1,"Taxable Goods","Catalog, Search",9.3,,,,Ventilatore-a-Pistola-classico-per-Barbecue-BBQ-Classics,"Ventilatore a Pistola classico per Barbecue BBQ Classics","Casa Giardino,Casa,Giardino,Giardino e Terrazza,Giardino,Terrazza,Barbecue,","Utilizza i migliori barbecue alimentando il fuoco con il ventilatore a pistola classico per babecue BBQ Classics! Basterà solo fare una leggera pressione sul pulsante per far uscire l'aria",http://dropshipping.bigbuy.eu/imgs/V0200353_92695.jpg,,http://dropshipping.bigbuy.eu/imgs/V0200353_92695.jpg,,,,,,"2016-09-13 09:56:07",,,,,,,,,,,,,,,,,"GTIN=8718158032706",60,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/V0200353_92696.jpg,http://dropshipping.bigbuy.eu/imgs/V0200353_92694.jpg","GTIN=8718158032706",,,,,,,,,,
+BB-V1600123,,Default,simple,"Default Category/Casa Giardino,Default Category/Casa Giardino/Arredamento,Default Category/Casa Giardino/Arredamento/Soluzioni per Organizzare",base,"Contenitore Portagiochi Frozen (32 x 23 cm)","Non
c'è nulla di meglio che tenere le camere dei più piccini in ordine in modo originale e divertente. Con il contenitore portagiochi Frozen (32 x 23 cm) sarà semplicissimo!Realizzato in polipropilene Dimensioni aprossimative: 32 x 15 x 23 cm Età consigliata: +3 anni
Dimenzioni per Contenitore Portagiochi Frozen (32 x 23 cm):
Altezza: 15 Cm Larghezza: 34 Cm Profondita': 23 Cm Peso: 0.331 Kg Codice Prodotto (EAN): 8412842766006
","Non c'è nulla di meglio che tenere le camere dei più piccini in ordine in modo originale e divertente. Maggiori Informazioni ",0.331,1,"Taxable Goods","Catalog, Search",21.9,,,,Contenitore-Portagiochi-Frozen-(32-x-23-cm),"Contenitore Portagiochi Frozen (32 x 23 cm)","Casa Giardino,Casa,Giardino,Arredamento,Soluzioni per Organizzare,Soluzioni,Organizzare,","Non c'è nulla di meglio che tenere le camere dei più piccini in ordine in modo originale e divertente",http://dropshipping.bigbuy.eu/imgs/V1600123_93002.jpg,,http://dropshipping.bigbuy.eu/imgs/V1600123_93002.jpg,,,,,,"2016-08-08 21:04:27",,,,,,,,,,,,,,,,,"GTIN=8412842766006",48,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/V1600123_93005.jpg,http://dropshipping.bigbuy.eu/imgs/V1600123_93004.jpg,http://dropshipping.bigbuy.eu/imgs/V1600123_93003.jpg","GTIN=8412842766006",,,,,,,,,,
+BB-V1600124,,Default,simple,"Default Category/Casa Giardino,Default Category/Casa Giardino/Arredamento,Default Category/Casa Giardino/Arredamento/Soluzioni per Organizzare",base,"Contenitore Portagiochi Spiderman (32 x 23 cm)","Desideri
sorprendere i più piccini con un regalo molto originale? Il contenitore portagiochi Spiderman (32 x 23 cm) decorerà e metterà in ordine le loro camerette.Realizzato in polipropilene Dimensioni approssimative: 32 x 15 x 23 cm Età consigliata: +3 anni Dimenzioni per Contenitore Portagiochi Spiderman (32 x 23 cm):
Altezza: 15 Cm Larghezza: 34 Cm Profondita': 23 Cm Peso: 0.331 Kg Codice Prodotto (EAN): 8412842766037
","Desideri sorprendere i più piccini con un regalo molto originale? Il contenitore portagiochi Spiderman (32 x 23 cm) decorerà e metterà in ordine le loro camerette. Maggiori Informazioni ",0.331,1,"Taxable Goods","Catalog, Search",21.9,,,,Contenitore-Portagiochi-Spiderman--(32-x-23-cm),"Contenitore Portagiochi Spiderman (32 x 23 cm)","Casa Giardino,Casa,Giardino,Arredamento,Soluzioni per Organizzare,Soluzioni,Organizzare,","Desideri sorprendere i più piccini con un regalo molto originale? Il contenitore portagiochi Spiderman (32 x 23 cm) decorerà e metterà in ordine le loro camerette",http://dropshipping.bigbuy.eu/imgs/V1600124_93006.jpg,,http://dropshipping.bigbuy.eu/imgs/V1600124_93006.jpg,,,,,,"2016-08-08 21:09:24",,,,,,,,,,,,,,,,,"GTIN=8412842766037",52,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/V1600124_93008.jpg,http://dropshipping.bigbuy.eu/imgs/V1600124_93007.jpg","GTIN=8412842766037",,,,,,,,,,
+BB-V1600125,,Default,simple,"Default Category/Casa Giardino,Default Category/Casa Giardino/Arredamento,Default Category/Casa Giardino/Arredamento/Soluzioni per Organizzare",base,"Contenitore Portagiochi Frozen (45 x 32 cm)","Insegna
ai tuoi bambini a tenere i giocattoli conservati ben in ordine con l'aiuto del contenitore portagiochi Frozen (45 x 32 cm) . Il portagiocattoli che tutte le bambine sognano!Realizzato in polipropilene Dimensioni: circa 45 x 22 x 32 cm Età consigliata: +3 anni Dimenzioni per Contenitore Portagiochi Frozen (45 x 32 cm):
Altezza: 22 Cm Larghezza: 37 Cm Profondita': 45 Cm Peso: 0.775 Kg Codice Prodotto (EAN): 8412842766129
","Insegna ai tuoi bambini a tenere i giocattoli conservati ben in ordine con l'aiuto del contenitore portagiochi Frozen (45 x 32 cm). Maggiori Informazioni ",0.775,1,"Taxable Goods","Catalog, Search",39.6,,,,Contenitore-Portagiochi-Frozen-(45-x-32-cm),"Contenitore Portagiochi Frozen (45 x 32 cm)","Casa Giardino,Casa,Giardino,Arredamento,Soluzioni per Organizzare,Soluzioni,Organizzare,","Insegna ai tuoi bambini a tenere i giocattoli conservati ben in ordine con l'aiuto del contenitore portagiochi Frozen (45 x 32 cm)",http://dropshipping.bigbuy.eu/imgs/V1600125_93010.jpg,,http://dropshipping.bigbuy.eu/imgs/V1600125_93010.jpg,,,,,,"2016-08-08 21:04:27",,,,,,,,,,,,,,,,,"GTIN=8412842766129",17,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/V1600125_93011.jpg,http://dropshipping.bigbuy.eu/imgs/V1600125_93009.jpg","GTIN=8412842766129",,,,,,,,,,
+BB-V1600126,,Default,simple,"Default Category/Casa Giardino,Default Category/Casa Giardino/Arredamento,Default Category/Casa Giardino/Arredamento/Soluzioni per Organizzare",base,"Contenitore Portagiochi Spiderman (45 x 32 cm)","I
piccoli di casa ora possono ordinare e riporre i loro giocattoli facilmente grazie al contenitore portagiochi Spiderman (45 x 32 cm) . Il contenitore portagiochi preferito dai bambini!Fabbricato in polipropilene Dimensioni: circa 45 x 22 x 32 cm Età raccomandata: +3 anni Dimenzioni per Contenitore Portagiochi Spiderman (45 x 32 cm):
Altezza: 22 Cm Larghezza: 37 Cm Profondita': 45 Cm Peso: 0.775 Kg Codice Prodotto (EAN): 8412842766150
","I piccoli di casa ora possono ordinare e riporre i loro giocattoli facilmente grazie al contenitore portagiochi Spiderman (45 x 32 cm). Maggiori Informazioni ",0.775,1,"Taxable Goods","Catalog, Search",39.6,,,,Contenitore-Portagiochi-Spiderman-(45-x-32-cm),"Contenitore Portagiochi Spiderman (45 x 32 cm)","Casa Giardino,Casa,Giardino,Arredamento,Soluzioni per Organizzare,Soluzioni,Organizzare,","I piccoli di casa ora possono ordinare e riporre i loro giocattoli facilmente grazie al contenitore portagiochi Spiderman (45 x 32 cm)",http://dropshipping.bigbuy.eu/imgs/V1600126_93012.jpg,,http://dropshipping.bigbuy.eu/imgs/V1600126_93012.jpg,,,,,,"2016-08-08 21:09:24",,,,,,,,,,,,,,,,,"GTIN=8412842766150",18,0,1,0,1,1,1,1,10000,1,1,,1,0,1,1,1,1,0,0,0,,,,,,,"http://dropshipping.bigbuy.eu/imgs/V1600126_93014.jpg,http://dropshipping.bigbuy.eu/imgs/V1600126_93013.jpg","GTIN=8412842766150",,,,,,,,,,
From 9b4b44f0fe094da2ccf20a90a29f561fab50a107 Mon Sep 17 00:00:00 2001
From: Yuliya Labudova
Date: Wed, 26 Jun 2019 16:11:53 +0300
Subject: [PATCH 029/937] MAGETWO-44170: Not pass functional test
\Magento\Catalog\Test\TestCase\Product\ProductTypeSwitchingOnUpdateTest
- Add a tag about migration tests.
---
.../Test/AdminProductTypeSwitchingOnEditingTest.xml | 4 ++--
.../Product/ProductTypeSwitchingOnUpdateTest.php | 1 -
.../Product/ProductTypeSwitchingOnUpdateTest.xml | 12 ++++++------
3 files changed, 8 insertions(+), 9 deletions(-)
diff --git a/app/code/Magento/Catalog/Test/Mftf/Test/AdminProductTypeSwitchingOnEditingTest.xml b/app/code/Magento/Catalog/Test/Mftf/Test/AdminProductTypeSwitchingOnEditingTest.xml
index 116fbc1b6b455..2154a89a5fa73 100644
--- a/app/code/Magento/Catalog/Test/Mftf/Test/AdminProductTypeSwitchingOnEditingTest.xml
+++ b/app/code/Magento/Catalog/Test/Mftf/Test/AdminProductTypeSwitchingOnEditingTest.xml
@@ -94,7 +94,7 @@
-
+
@@ -221,7 +221,7 @@
-
+
diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/ProductTypeSwitchingOnUpdateTest.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/ProductTypeSwitchingOnUpdateTest.php
index 2abd17fce5b45..90cd6bdb76328 100644
--- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/ProductTypeSwitchingOnUpdateTest.php
+++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/ProductTypeSwitchingOnUpdateTest.php
@@ -36,7 +36,6 @@
class ProductTypeSwitchingOnUpdateTest extends Injectable
{
/* tags */
- const TEST_TYPE = 'acceptance_test';
const MVP = 'yes';
/* end tags */
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 3d3e36754e92c..732dac98e0779 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,7 +11,7 @@
catalogProductSimple::default
configurableProduct::default
-
- test_type:acceptance_test
+ mftf_migrated:yes
@@ -35,7 +35,7 @@
- test_type:acceptance_test
+ mftf_migrated:yes
configurableProduct::default
catalogProductVirtual::required_fields
deleteVariations
@@ -50,7 +50,7 @@
- test_type:acceptance_test
+ mftf_migrated:yes
catalogProductVirtual::default
configurableProduct::not_virtual_for_type_switching
-
@@ -63,7 +63,7 @@
- test_type:acceptance_test
+ mftf_migrated:yes
catalogProductVirtual::default
downloadableProduct::default
-
@@ -75,7 +75,7 @@
- test_type:acceptance_test
+ mftf_migrated:yes
downloadableProduct::default
catalogProductSimple::default
-
@@ -103,7 +103,7 @@
- test_type:acceptance_test
+ mftf_migrated:yes
catalogProductSimple::default
downloadableProduct::default
-
From 827ac377c916d0eb77a387733a757a2b78315253 Mon Sep 17 00:00:00 2001
From: Stsiapan Korf
Date: Wed, 26 Jun 2019 13:26:07 +0000
Subject: [PATCH 030/937] MC-15507: Shipping address is dropped after zip code
in new billing address form is filled
- Set shipping address in checkout provider
---
.../Magento/Checkout/view/frontend/web/js/view/shipping.js | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/app/code/Magento/Checkout/view/frontend/web/js/view/shipping.js b/app/code/Magento/Checkout/view/frontend/web/js/view/shipping.js
index c811d3a1e8369..71cdf9bd83241 100644
--- a/app/code/Magento/Checkout/view/frontend/web/js/view/shipping.js
+++ b/app/code/Magento/Checkout/view/frontend/web/js/view/shipping.js
@@ -246,9 +246,14 @@ define([
* Set shipping information handler
*/
setShippingInformation: function () {
+ var checkoutProvider = registry.get('checkoutProvider');
if (this.validateShippingInformation()) {
quote.billingAddress(null);
checkoutDataResolver.resolveBillingAddress();
+ checkoutProvider.set(
+ 'shippingAddress',
+ $.extend(true, {}, checkoutProvider.get('shippingAddress'), quote.shippingAddress())
+ );
setShippingInformationAction().done(
function () {
stepNavigator.next();
From af956595235f7739eba3119c447b1ccce711aece Mon Sep 17 00:00:00 2001
From: Yuliya Labudova
Date: Thu, 27 Jun 2019 10:54:21 +0300
Subject: [PATCH 031/937] MAGETWO-44170: Not pass functional test
\Magento\Catalog\Test\TestCase\Product\ProductTypeSwitchingOnUpdateTest
- Fix a typo in the test.
---
.../Test/Mftf/Test/AdminProductTypeSwitchingOnEditingTest.xml | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/app/code/Magento/Catalog/Test/Mftf/Test/AdminProductTypeSwitchingOnEditingTest.xml b/app/code/Magento/Catalog/Test/Mftf/Test/AdminProductTypeSwitchingOnEditingTest.xml
index 2154a89a5fa73..22eaa9c8b34bb 100644
--- a/app/code/Magento/Catalog/Test/Mftf/Test/AdminProductTypeSwitchingOnEditingTest.xml
+++ b/app/code/Magento/Catalog/Test/Mftf/Test/AdminProductTypeSwitchingOnEditingTest.xml
@@ -385,7 +385,7 @@
-
+
From 26816700ad5fd7e9330b8f3dce118d672f7567c6 Mon Sep 17 00:00:00 2001
From: Yuliya Labudova
Date: Thu, 4 Jul 2019 12:11:38 +0300
Subject: [PATCH 032/937] MAGETWO-94565: Catalog product collection filters
produce errors and cause inconsistent behaviour
- Fix CR comments.
---
.../ResourceModel/Product/Collection.php | 24 +++++++------------
1 file changed, 8 insertions(+), 16 deletions(-)
diff --git a/app/code/Magento/Catalog/Model/ResourceModel/Product/Collection.php b/app/code/Magento/Catalog/Model/ResourceModel/Product/Collection.php
index 7127aa2cb3e77..b4673412d25b2 100644
--- a/app/code/Magento/Catalog/Model/ResourceModel/Product/Collection.php
+++ b/app/code/Magento/Catalog/Model/ResourceModel/Product/Collection.php
@@ -2068,7 +2068,7 @@ protected function _applyProductLimitations()
protected function _applyZeroStoreProductLimitations()
{
$filters = $this->_productLimitationFilters;
- $categories = $this->getChildrenCategories((int)$filters['category_id'], []);
+ $categories = $this->getChildrenCategories((int)$filters['category_id']);
$conditions = [
'cat_pro.product_id=e.entity_id',
@@ -2099,30 +2099,22 @@ protected function _applyZeroStoreProductLimitations()
* Get children categories.
*
* @param int $categoryId
- * @param array $categories
* @return array
*/
- private function getChildrenCategories(int $categoryId, array $categories): array
+ private function getChildrenCategories(int $categoryId): array
{
- $categories[] = $categoryId;
+ $categoryIds[] = $categoryId;
/** @var \Magento\Catalog\Model\ResourceModel\Category\Collection $categoryCollection */
$categoryCollection = $this->categoryCollectionFactory->create();
- $category = $categoryCollection
- ->addAttributeToSelect('is_anchor')
+ $categories = $categoryCollection
->addAttributeToFilter('is_anchor', 1)
- ->addIdFilter([$categoryId])
- ->getFirstItem();
- if ($category) {
+ ->addAttributeToFilter('path', ['like' => $categoryId . '/%'])->getItems();
+ foreach ($categories as $category) {
$categoryChildren = $category->getChildren();
- $categoryChildrenIds = explode(',', $categoryChildren);
- foreach ($categoryChildrenIds as $categoryChildrenId) {
- if ($categoryChildrenId) {
- $categories = $this->getChildrenCategories((int)$categoryChildrenId, $categories);
- }
- }
+ $categoryIds = array_merge($categoryIds, explode(',', $categoryChildren));
}
- return $categories;
+ return $categoryIds;
}
/**
From 6491b27f785b75a8e71cbd37b3e77886b5e12a5e Mon Sep 17 00:00:00 2001
From: Yuliya Labudova
Date: Fri, 5 Jul 2019 12:24:54 +0300
Subject: [PATCH 033/937] MAGETWO-44170: Not pass functional test
\Magento\Catalog\Test\TestCase\Product\ProductTypeSwitchingOnUpdateTest
- Change id for test cases.
---
.../Test/AdminProductTypeSwitchingOnEditingTest.xml | 12 ++++++------
1 file changed, 6 insertions(+), 6 deletions(-)
diff --git a/app/code/Magento/Catalog/Test/Mftf/Test/AdminProductTypeSwitchingOnEditingTest.xml b/app/code/Magento/Catalog/Test/Mftf/Test/AdminProductTypeSwitchingOnEditingTest.xml
index 22eaa9c8b34bb..b1af17fb25838 100644
--- a/app/code/Magento/Catalog/Test/Mftf/Test/AdminProductTypeSwitchingOnEditingTest.xml
+++ b/app/code/Magento/Catalog/Test/Mftf/Test/AdminProductTypeSwitchingOnEditingTest.xml
@@ -85,7 +85,7 @@
-
+
@@ -129,7 +129,7 @@
-
+
@@ -202,7 +202,7 @@
-
+
@@ -258,7 +258,7 @@
-
+
@@ -297,7 +297,7 @@
-
+
@@ -353,7 +353,7 @@
-
+
From 723bd8d4f3386c6e0372ebac27a62b2c546cd0b4 Mon Sep 17 00:00:00 2001
From: Nikita Chubukov
Date: Mon, 8 Jul 2019 13:06:06 +0300
Subject: [PATCH 034/937] MC-15256: Exported customer without modification can
not be imported
- Integration test
---
.../CustomerImportExport/Model/Import/CustomerTest.php | 5 +++++
.../Model/Import/_files/customers_to_import.csv | 4 ++--
2 files changed, 7 insertions(+), 2 deletions(-)
diff --git a/dev/tests/integration/testsuite/Magento/CustomerImportExport/Model/Import/CustomerTest.php b/dev/tests/integration/testsuite/Magento/CustomerImportExport/Model/Import/CustomerTest.php
index 05d9c5d3acb1e..54890f7db3a1d 100644
--- a/dev/tests/integration/testsuite/Magento/CustomerImportExport/Model/Import/CustomerTest.php
+++ b/dev/tests/integration/testsuite/Magento/CustomerImportExport/Model/Import/CustomerTest.php
@@ -133,6 +133,11 @@ public function testImportData()
$updatedCustomer->getCreatedAt(),
'Creation date must be changed'
);
+ $this->assertNotEquals(
+ $existingCustomer->getGender(),
+ $updatedCustomer->getGender(),
+ 'Gender must be changed'
+ );
}
/**
diff --git a/dev/tests/integration/testsuite/Magento/CustomerImportExport/Model/Import/_files/customers_to_import.csv b/dev/tests/integration/testsuite/Magento/CustomerImportExport/Model/Import/_files/customers_to_import.csv
index 30a283ce0502f..96c14c67607aa 100644
--- a/dev/tests/integration/testsuite/Magento/CustomerImportExport/Model/Import/_files/customers_to_import.csv
+++ b/dev/tests/integration/testsuite/Magento/CustomerImportExport/Model/Import/_files/customers_to_import.csv
@@ -1,7 +1,7 @@
email,_website,_store,confirmation,created_at,created_in,default_billing,default_shipping,disable_auto_group_change,dob,firstname,gender,group_id,lastname,middlename,password_hash,prefix,rp_token,rp_token_created_at,store_id,suffix,taxvat,website_id,password
-AnthonyANealy@magento.com,base,admin,,5/6/2012 15:53,Admin,1,1,0,5/6/2010,Anthony,Male,1,Nealy,A.,6a9c9bfb2ba88a6ad2a64e7402df44a763e0c48cd21d7af9e7e796cd4677ee28:RF,,,,0,,,1,
+AnthonyANealy@magento.com,base,admin,,5/6/2012 15:53,Admin,1,1,0,5/6/2010,Anthony,Female,1,Nealy,A.,6a9c9bfb2ba88a6ad2a64e7402df44a763e0c48cd21d7af9e7e796cd4677ee28:RF,,,,0,,,1,
LoriBBanks@magento.com,admin,admin,,5/6/2012 15:59,Admin,3,3,0,5/6/2010,Lori,Female,1,Banks,B.,7ad6dbdc83d3e9f598825dc58b84678c7351e4281f6bc2b277a32dcd88b9756b:pz,,,,0,,,0,
CharlesTAlston@teleworm.us,base,admin,,5/6/2012 16:13,Admin,4,4,0,,Jhon,Female,1,Doe,T.,145d12bfff8a6a279eb61e277e3d727c0ba95acc1131237f1594ddbb7687a564:l1,,,,0,,,2,
-customer@example.com,base,admin,,5/6/2012 16:15,Admin,4,4,0,,Firstname,Male,1,Lastname,T.,145d12bfff8a6a279eb61e277e3d727c0ba95acc1131237f1594ddbb7687a564:l1,,,,0,,,2,
+customer@example.com,base,admin,,5/6/2012 16:15,Admin,4,4,0,,Firstname,Female,1,Lastname,T.,145d12bfff8a6a279eb61e277e3d727c0ba95acc1131237f1594ddbb7687a564:l1,,,,0,,,2,
julie.worrell@example.com,base,admin,,5/6/2012 16:19,Admin,4,4,0,,Julie,Female,1,Worrell,T.,145d12bfff8a6a279eb61e277e3d727c0ba95acc1131237f1594ddbb7687a564:l1,,,,0,,,2,
david.lamar@example.com,base,admin,,5/6/2012 16:25,Admin,4,4,0,,David,,1,Lamar,T.,145d12bfff8a6a279eb61e277e3d727c0ba95acc1131237f1594ddbb7687a564:l1,,,,0,,,2,
From fc328d923d1e69d46501eef17a831954adcc01a5 Mon Sep 17 00:00:00 2001
From: Yuliya Labudova
Date: Mon, 8 Jul 2019 18:00:03 +0300
Subject: [PATCH 035/937] MAGETWO-94565: Catalog product collection filters
produce errors and cause inconsistent behaviour
- Fix CR comments.
---
.../Catalog/Model/ResourceModel/Product/Collection.php | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/app/code/Magento/Catalog/Model/ResourceModel/Product/Collection.php b/app/code/Magento/Catalog/Model/ResourceModel/Product/Collection.php
index b4673412d25b2..dffa49d97838c 100644
--- a/app/code/Magento/Catalog/Model/ResourceModel/Product/Collection.php
+++ b/app/code/Magento/Catalog/Model/ResourceModel/Product/Collection.php
@@ -2108,8 +2108,10 @@ private function getChildrenCategories(int $categoryId): array
/** @var \Magento\Catalog\Model\ResourceModel\Category\Collection $categoryCollection */
$categoryCollection = $this->categoryCollectionFactory->create();
$categories = $categoryCollection
- ->addAttributeToFilter('is_anchor', 1)
- ->addAttributeToFilter('path', ['like' => $categoryId . '/%'])->getItems();
+ ->addAttributeToFilter(
+ ['is_anchor', 'path'],
+ [1, ['like' => $categoryId . '/%']]
+ )->getItems();
foreach ($categories as $category) {
$categoryChildren = $category->getChildren();
$categoryIds = array_merge($categoryIds, explode(',', $categoryChildren));
From dc8c4d35aa0f55e6ef819a1fb7087372194a4353 Mon Sep 17 00:00:00 2001
From: Nikita Chubukov
Date: Thu, 11 Jul 2019 01:10:15 +0300
Subject: [PATCH 036/937] MC-15256: Exported customer without modification can
not be imported
- Fix integration test
---
.../Magento/CustomerImportExport/Model/Import/Customer.php | 4 ++--
.../Magento/Customer/_files/import_export/customer.php | 2 +-
.../CustomerImportExport/Model/Import/CustomerTest.php | 2 +-
3 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/app/code/Magento/CustomerImportExport/Model/Import/Customer.php b/app/code/Magento/CustomerImportExport/Model/Import/Customer.php
index 991d4f3558adc..33dc7e55228bf 100644
--- a/app/code/Magento/CustomerImportExport/Model/Import/Customer.php
+++ b/app/code/Magento/CustomerImportExport/Model/Import/Customer.php
@@ -600,14 +600,14 @@ protected function _validateRowForUpdate(array $rowData, $rowNumber)
$isFieldNotSetAndCustomerDoesNotExist =
!isset($rowData[$attributeCode]) && !$this->_getCustomerId($email, $website);
$isFieldSetAndTrimmedValueIsEmpty
- = isset($rowData[$attributeCode]) && '' === trim($rowData[$attributeCode]);
+ = isset($rowData[$attributeCode]) && '' === trim((string)$rowData[$attributeCode]);
if ($isFieldRequired && ($isFieldNotSetAndCustomerDoesNotExist || $isFieldSetAndTrimmedValueIsEmpty)) {
$this->addRowError(self::ERROR_VALUE_IS_REQUIRED, $rowNumber, $attributeCode);
continue;
}
- if (isset($rowData[$attributeCode]) && strlen($rowData[$attributeCode])) {
+ if (isset($rowData[$attributeCode]) && strlen((string)$rowData[$attributeCode])) {
if ($attributeParams['type'] == 'select' && empty($rowData[$attributeCode])) {
continue;
}
diff --git a/dev/tests/integration/testsuite/Magento/Customer/_files/import_export/customer.php b/dev/tests/integration/testsuite/Magento/Customer/_files/import_export/customer.php
index 215dd2a709418..3a39e62af0ccb 100644
--- a/dev/tests/integration/testsuite/Magento/Customer/_files/import_export/customer.php
+++ b/dev/tests/integration/testsuite/Magento/Customer/_files/import_export/customer.php
@@ -30,7 +30,7 @@
)->setLastname(
'Alston'
)->setGender(
- 2
+ '2'
);
$customer->isObjectNew(true);
diff --git a/dev/tests/integration/testsuite/Magento/CustomerImportExport/Model/Import/CustomerTest.php b/dev/tests/integration/testsuite/Magento/CustomerImportExport/Model/Import/CustomerTest.php
index 54890f7db3a1d..daab687408749 100644
--- a/dev/tests/integration/testsuite/Magento/CustomerImportExport/Model/Import/CustomerTest.php
+++ b/dev/tests/integration/testsuite/Magento/CustomerImportExport/Model/Import/CustomerTest.php
@@ -133,7 +133,7 @@ public function testImportData()
$updatedCustomer->getCreatedAt(),
'Creation date must be changed'
);
- $this->assertNotEquals(
+ $this->assertEquals(
$existingCustomer->getGender(),
$updatedCustomer->getGender(),
'Gender must be changed'
From 861ef75fbb90f5bb0b04b7f27833ac4c25a9c6df Mon Sep 17 00:00:00 2001
From: Ani Tumanyan
Date: Wed, 10 Jul 2019 16:13:14 +0400
Subject: [PATCH 037/937] MC-15507: shipping address is dropped after zip code
in new billing address form is filled
- Added automated test
---
...eckoutFillNewBillingAddressActionGroup.xml | 4 +
.../Checkout/Test/Mftf/Page/CheckoutPage.xml | 1 +
.../Mftf/Section/CheckoutPaymentSection.xml | 2 +-
.../Mftf/Section/CheckoutShippingSection.xml | 1 +
.../SelectShippingAddressPopupSection.xml | 16 ++
...AffectOnShippingAddressAfterUpdateTest.xml | 148 ++++++++++++++++++
.../Customer/Test/Mftf/Data/AddressData.xml | 15 ++
.../Customer/Test/Mftf/Data/CustomerData.xml | 14 ++
8 files changed, 200 insertions(+), 1 deletion(-)
create mode 100644 app/code/Magento/Checkout/Test/Mftf/Section/SelectShippingAddressPopupSection.xml
create mode 100644 app/code/Magento/Checkout/Test/Mftf/Test/BillingAddressFormAffectOnShippingAddressAfterUpdateTest.xml
diff --git a/app/code/Magento/Checkout/Test/Mftf/ActionGroup/GuestCheckoutFillNewBillingAddressActionGroup.xml b/app/code/Magento/Checkout/Test/Mftf/ActionGroup/GuestCheckoutFillNewBillingAddressActionGroup.xml
index 59e997eccecc0..6d92ca79000eb 100644
--- a/app/code/Magento/Checkout/Test/Mftf/ActionGroup/GuestCheckoutFillNewBillingAddressActionGroup.xml
+++ b/app/code/Magento/Checkout/Test/Mftf/ActionGroup/GuestCheckoutFillNewBillingAddressActionGroup.xml
@@ -24,6 +24,10 @@
+
+
+
+
diff --git a/app/code/Magento/Checkout/Test/Mftf/Page/CheckoutPage.xml b/app/code/Magento/Checkout/Test/Mftf/Page/CheckoutPage.xml
index d3fa045e4654f..d6173dfa17916 100644
--- a/app/code/Magento/Checkout/Test/Mftf/Page/CheckoutPage.xml
+++ b/app/code/Magento/Checkout/Test/Mftf/Page/CheckoutPage.xml
@@ -14,5 +14,6 @@
+
diff --git a/app/code/Magento/Checkout/Test/Mftf/Section/CheckoutPaymentSection.xml b/app/code/Magento/Checkout/Test/Mftf/Section/CheckoutPaymentSection.xml
index e1c2a3b1550f1..13bac9cefb681 100644
--- a/app/code/Magento/Checkout/Test/Mftf/Section/CheckoutPaymentSection.xml
+++ b/app/code/Magento/Checkout/Test/Mftf/Section/CheckoutPaymentSection.xml
@@ -46,7 +46,6 @@
-
@@ -59,5 +58,6 @@
+
diff --git a/app/code/Magento/Checkout/Test/Mftf/Section/CheckoutShippingSection.xml b/app/code/Magento/Checkout/Test/Mftf/Section/CheckoutShippingSection.xml
index f90ec0aad4624..bf1001ad6b286 100644
--- a/app/code/Magento/Checkout/Test/Mftf/Section/CheckoutShippingSection.xml
+++ b/app/code/Magento/Checkout/Test/Mftf/Section/CheckoutShippingSection.xml
@@ -41,5 +41,6 @@
+
diff --git a/app/code/Magento/Checkout/Test/Mftf/Section/SelectShippingAddressPopupSection.xml b/app/code/Magento/Checkout/Test/Mftf/Section/SelectShippingAddressPopupSection.xml
new file mode 100644
index 0000000000000..ff1431ab33ba5
--- /dev/null
+++ b/app/code/Magento/Checkout/Test/Mftf/Section/SelectShippingAddressPopupSection.xml
@@ -0,0 +1,16 @@
+
+
+
+
+
+
diff --git a/app/code/Magento/Checkout/Test/Mftf/Test/BillingAddressFormAffectOnShippingAddressAfterUpdateTest.xml b/app/code/Magento/Checkout/Test/Mftf/Test/BillingAddressFormAffectOnShippingAddressAfterUpdateTest.xml
new file mode 100644
index 0000000000000..9b2958a190be8
--- /dev/null
+++ b/app/code/Magento/Checkout/Test/Mftf/Test/BillingAddressFormAffectOnShippingAddressAfterUpdateTest.xml
@@ -0,0 +1,148 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/app/code/Magento/Customer/Test/Mftf/Data/AddressData.xml b/app/code/Magento/Customer/Test/Mftf/Data/AddressData.xml
index 88f86e456e5bf..1ea7b924ba105 100755
--- a/app/code/Magento/Customer/Test/Mftf/Data/AddressData.xml
+++ b/app/code/Magento/Customer/Test/Mftf/Data/AddressData.xml
@@ -51,6 +51,21 @@
Yes
RegionTX
+
+ John
+ Doe
+ Magento
+
+ - 7700 West Parmer Lane
+
+ Austin
+ Texas
+ US
+ United States
+ 78729
+ 512-345-6789
+ RegionTX
+
John
Doe
diff --git a/app/code/Magento/Customer/Test/Mftf/Data/CustomerData.xml b/app/code/Magento/Customer/Test/Mftf/Data/CustomerData.xml
index 55bc9b56c7917..d19d0bfa65186 100644
--- a/app/code/Magento/Customer/Test/Mftf/Data/CustomerData.xml
+++ b/app/code/Magento/Customer/Test/Mftf/Data/CustomerData.xml
@@ -47,6 +47,20 @@
General
US_Address_TX
+
+ 1
+ true
+ true
+ John.Doe@example.com
+ John
+ Doe
+ John Doe
+ pwdTest123!
+ 0
+ 0
+ General
+ US_Address_TX_Without_Default
+
true
true
From b0c53ba72e57134025bc55e1e6b7e099c6cfccbc Mon Sep 17 00:00:00 2001
From: Yuliya Labudova
Date: Thu, 18 Jul 2019 10:21:08 +0300
Subject: [PATCH 038/937] MC-15507: Shipping address is dropped after zip code
in new billing address form is filled
- Fix for checkout address.
---
...AffectOnShippingAddressAfterUpdateTest.xml | 148 ------------------
.../view/frontend/web/js/view/shipping.js | 15 +-
2 files changed, 10 insertions(+), 153 deletions(-)
delete mode 100644 app/code/Magento/Checkout/Test/Mftf/Test/BillingAddressFormAffectOnShippingAddressAfterUpdateTest.xml
diff --git a/app/code/Magento/Checkout/Test/Mftf/Test/BillingAddressFormAffectOnShippingAddressAfterUpdateTest.xml b/app/code/Magento/Checkout/Test/Mftf/Test/BillingAddressFormAffectOnShippingAddressAfterUpdateTest.xml
deleted file mode 100644
index 9b2958a190be8..0000000000000
--- a/app/code/Magento/Checkout/Test/Mftf/Test/BillingAddressFormAffectOnShippingAddressAfterUpdateTest.xml
+++ /dev/null
@@ -1,148 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/app/code/Magento/Checkout/view/frontend/web/js/view/shipping.js b/app/code/Magento/Checkout/view/frontend/web/js/view/shipping.js
index 71cdf9bd83241..d5098dbc6f734 100644
--- a/app/code/Magento/Checkout/view/frontend/web/js/view/shipping.js
+++ b/app/code/Magento/Checkout/view/frontend/web/js/view/shipping.js
@@ -246,14 +246,19 @@ define([
* Set shipping information handler
*/
setShippingInformation: function () {
- var checkoutProvider = registry.get('checkoutProvider');
if (this.validateShippingInformation()) {
quote.billingAddress(null);
checkoutDataResolver.resolveBillingAddress();
- checkoutProvider.set(
- 'shippingAddress',
- $.extend(true, {}, checkoutProvider.get('shippingAddress'), quote.shippingAddress())
- );
+ registry.async('checkoutProvider')(function (checkoutProvider) {
+ var shippingAddressData = checkoutData.getShippingAddressFromData();
+
+ if (shippingAddressData) {
+ checkoutProvider.set(
+ 'shippingAddress',
+ $.extend(true, {}, checkoutProvider.get('shippingAddress'), shippingAddressData)
+ );
+ }
+ });
setShippingInformationAction().done(
function () {
stepNavigator.next();
From 8488c07818215f92b073a6e6b31b38162caa7aaf Mon Sep 17 00:00:00 2001
From: Valentin Hirson
Date: Thu, 18 Jul 2019 12:23:22 +0200
Subject: [PATCH 039/937] #23766 - fix pattern validation on form submit
---
lib/web/mage/validation.js | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/lib/web/mage/validation.js b/lib/web/mage/validation.js
index a7a5ade2ae9f3..8c1b68be3ba6c 100644
--- a/lib/web/mage/validation.js
+++ b/lib/web/mage/validation.js
@@ -559,7 +559,7 @@
/* eslint-enable max-len */
'pattern': [
function (value, element, param) {
- return this.optional(element) || param.test(value);
+ return this.optional(element) || new RegExp(param).test(value);
},
$.mage.__('Invalid format.')
],
From 11f7f3954132512dd9d8fbc0a70e81e48de7a4ba Mon Sep 17 00:00:00 2001
From: Jamie Saunders
Date: Tue, 23 Jul 2019 08:15:31 +0100
Subject: [PATCH 040/937] Fixes #23824: User data serialised multiple times on
save when loaded via loadByUsername.
Unserialises the extra data when loading a user using the loadByUsername method of the User model.
---
app/code/Magento/User/Model/User.php | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/app/code/Magento/User/Model/User.php b/app/code/Magento/User/Model/User.php
index d8040b0bbaaac..674dabb7ff166 100644
--- a/app/code/Magento/User/Model/User.php
+++ b/app/code/Magento/User/Model/User.php
@@ -671,6 +671,10 @@ public function loadByUsername($username)
{
$data = $this->getResource()->loadByUsername($username);
if ($data !== false) {
+ if (is_string($data['extra'])) {
+ $data['extra'] = $this->serializer->unserialize($data['extra']);
+ }
+
$this->setData($data);
$this->setOrigData();
}
From 04739de66cf39fe6f1de50cf93dd05471ec03c7d Mon Sep 17 00:00:00 2001
From: Veronika Kurochkina
Date: Fri, 26 Jul 2019 17:14:04 +0300
Subject: [PATCH 041/937] MAGETWO-44170: Not pass function test
\Magento\Catalog\Test\TestCase\Product\ProductTypeSwitchingOnUpdateTest
- Added automated test script.
---
.../Test/Mftf/Test/AdminProductTypeSwitchingOnEditingTest.xml | 1 +
1 file changed, 1 insertion(+)
diff --git a/app/code/Magento/Catalog/Test/Mftf/Test/AdminProductTypeSwitchingOnEditingTest.xml b/app/code/Magento/Catalog/Test/Mftf/Test/AdminProductTypeSwitchingOnEditingTest.xml
index b1af17fb25838..cac5e209af9fd 100644
--- a/app/code/Magento/Catalog/Test/Mftf/Test/AdminProductTypeSwitchingOnEditingTest.xml
+++ b/app/code/Magento/Catalog/Test/Mftf/Test/AdminProductTypeSwitchingOnEditingTest.xml
@@ -395,6 +395,7 @@
+
From bf54e6f78a4eef5081c14cb0bd95c1967dad4f01 Mon Sep 17 00:00:00 2001
From: Oleksandr Gorkun
Date: Fri, 26 Jul 2019 13:58:37 -0500
Subject: [PATCH 042/937] MAGETWO-96975: Remove __sleep and __wakeup from code
---
app/code/Magento/Authorization/Model/Role.php | 10 +
.../Magento/Backend/Model/Auth/Session.php | 197 ++++++++++++-
.../Backend/Model/Auth/SessionAclHydrator.php | 36 +++
.../Model/Auth/SessionUserHydrator.php | 54 ++++
.../Spi/SessionAclHydratorInterface.php | 34 +++
.../Spi/SessionUserHydratorInterface.php | 34 +++
.../Test/Unit/Model/Auth/SessionTest.php | 273 ------------------
.../Model/Authorization/RoleLocatorTest.php | 39 ---
.../Test/Unit/Model/Locale/ManagerTest.php | 130 ---------
app/code/Magento/Backend/composer.json | 1 +
app/code/Magento/Backend/etc/di.xml | 4 +
.../Model/ResourceModel/Eav/Attribute.php | 10 +
.../Config/Model/Config/Backend/Encrypted.php | 10 +
.../Product/Type/Configurable/Attribute.php | 13 +-
.../Configurable/Attribute/Collection.php | 14 +-
app/code/Magento/Customer/Model/Attribute.php | 10 +
.../Magento/Eav/Model/Entity/Attribute.php | 14 +-
.../Entity/Attribute/AbstractAttribute.php | 10 +
.../Model/ResourceModel/Entity/Attribute.php | 10 +
.../System/Config/Fieldset/GroupTest.php | 110 -------
.../Condition/CanViewNotificationTest.php | 16 +-
app/code/Magento/Store/Model/Store.php | 10 +
app/code/Magento/User/Model/User.php | 14 +
.../AdminSessionUserContextTest.php | 89 ------
.../Magento/User/Test/Unit/Model/UserTest.php | 25 --
.../Backend/Model/Auth/SessionTest.php | 39 ++-
.../Backend/Model/Locale/ResolverTest.php | 15 +-
.../Rule/Design/SerializationAware.php | 34 +++
.../resources/rulesets/design.xml | 25 ++
.../Magento/Test/Php/_files/phpmd/ruleset.xml | 1 +
.../Magento/Framework/App/AreaList/Proxy.php | 15 +-
.../Magento/Framework/App/Response/Http.php | 17 +-
.../App/Route/ConfigInterface/Proxy.php | 12 +-
.../App/Test/Unit/Response/HttpTest.php | 39 ---
lib/internal/Magento/Framework/DB/Select.php | 16 +-
.../Framework/DB/Select/RendererProxy.php | 12 +-
.../Magento/Framework/Data/Collection.php | 10 +
.../Framework/Data/Collection/AbstractDb.php | 10 +
.../DataObject/Copy/Config/Data/Proxy.php | 12 +-
.../Framework/Interception/Interceptor.php | 10 +
.../Model/AbstractExtensibleModel.php | 10 +
.../Magento/Framework/Model/AbstractModel.php | 10 +
.../Model/ResourceModel/Db/AbstractDb.php | 22 +-
.../Db/Collection/AbstractCollection.php | 10 +
.../Framework/Mview/Config/Data/Proxy.php | 12 +-
.../Framework/Translate/Inline/Proxy.php | 12 +-
.../Magento/Framework/View/Layout/Proxy.php | 12 +-
47 files changed, 773 insertions(+), 749 deletions(-)
create mode 100644 app/code/Magento/Backend/Model/Auth/SessionAclHydrator.php
create mode 100644 app/code/Magento/Backend/Model/Auth/SessionUserHydrator.php
create mode 100644 app/code/Magento/Backend/Spi/SessionAclHydratorInterface.php
create mode 100644 app/code/Magento/Backend/Spi/SessionUserHydratorInterface.php
delete mode 100644 app/code/Magento/Backend/Test/Unit/Model/Auth/SessionTest.php
delete mode 100644 app/code/Magento/Backend/Test/Unit/Model/Authorization/RoleLocatorTest.php
delete mode 100644 app/code/Magento/Backend/Test/Unit/Model/Locale/ManagerTest.php
delete mode 100644 app/code/Magento/Paypal/Test/Unit/Block/Adminhtml/System/Config/Fieldset/GroupTest.php
delete mode 100644 app/code/Magento/User/Test/Unit/Model/Authorization/AdminSessionUserContextTest.php
create mode 100644 dev/tests/static/framework/Magento/CodeMessDetector/Rule/Design/SerializationAware.php
diff --git a/app/code/Magento/Authorization/Model/Role.php b/app/code/Magento/Authorization/Model/Role.php
index fc32fbcaa2e98..719059c6f67c4 100644
--- a/app/code/Magento/Authorization/Model/Role.php
+++ b/app/code/Magento/Authorization/Model/Role.php
@@ -52,18 +52,28 @@ public function __construct( //phpcs:ignore Generic.CodeAnalysis.UselessOverridi
/**
* @inheritDoc
+ *
+ * @SuppressWarnings(PHPMD.SerializationAware)
+ * @deprecated Do not use PHP serialization.
*/
public function __sleep()
{
+ trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
+
$properties = parent::__sleep();
return array_diff($properties, ['_resource', '_resourceCollection']);
}
/**
* @inheritDoc
+ *
+ * @SuppressWarnings(PHPMD.SerializationAware)
+ * @deprecated Do not use PHP serialization.
*/
public function __wakeup()
{
+ trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
+
parent::__wakeup();
$objectManager = \Magento\Framework\App\ObjectManager::getInstance();
$this->_resource = $objectManager->get(\Magento\Authorization\Model\ResourceModel\Role::class);
diff --git a/app/code/Magento/Backend/Model/Auth/Session.php b/app/code/Magento/Backend/Model/Auth/Session.php
index 809b78b7b98bc..d34323d4bec87 100644
--- a/app/code/Magento/Backend/Model/Auth/Session.php
+++ b/app/code/Magento/Backend/Model/Auth/Session.php
@@ -5,17 +5,20 @@
*/
namespace Magento\Backend\Model\Auth;
+use Magento\Framework\Acl;
+use Magento\Framework\AclFactory;
+use Magento\Framework\App\ObjectManager;
use Magento\Framework\Stdlib\Cookie\CookieMetadataFactory;
use Magento\Framework\Stdlib\CookieManagerInterface;
+use Magento\Backend\Spi\SessionUserHydratorInterface;
+use Magento\Backend\Spi\SessionAclHydratorInterface;
+use Magento\User\Model\User;
+use Magento\User\Model\UserFactory;
/**
* Backend Auth session model
*
* @api
- * @method \Magento\User\Model\User|null getUser()
- * @method \Magento\Backend\Model\Auth\Session setUser(\Magento\User\Model\User $value)
- * @method \Magento\Framework\Acl|null getAcl()
- * @method \Magento\Backend\Model\Auth\Session setAcl(\Magento\Framework\Acl $value)
* @method int getUpdatedAt()
* @method \Magento\Backend\Model\Auth\Session setUpdatedAt(int $value)
*
@@ -56,6 +59,36 @@ class Session extends \Magento\Framework\Session\SessionManager implements \Mage
*/
protected $_config;
+ /**
+ * @var SessionUserHydratorInterface
+ */
+ private $userHydrator;
+
+ /**
+ * @var SessionAclHydratorInterface
+ */
+ private $aclHydrator;
+
+ /**
+ * @var UserFactory
+ */
+ private $userFactory;
+
+ /**
+ * @var AclFactory
+ */
+ private $aclFactory;
+
+ /**
+ * @var User|null
+ */
+ private $user;
+
+ /**
+ * @var Acl|null
+ */
+ private $acl;
+
/**
* @param \Magento\Framework\App\Request\Http $request
* @param \Magento\Framework\Session\SidResolverInterface $sidResolver
@@ -70,6 +103,10 @@ class Session extends \Magento\Framework\Session\SessionManager implements \Mage
* @param \Magento\Backend\Model\UrlInterface $backendUrl
* @param \Magento\Backend\App\ConfigInterface $config
* @throws \Magento\Framework\Exception\SessionException
+ * @param SessionUserHydratorInterface|null $userHydrator
+ * @param SessionAclHydratorInterface|null $aclHydrator
+ * @param UserFactory|null $userFactory
+ * @param AclFactory|null $aclFactory
* @SuppressWarnings(PHPMD.ExcessiveParameterList)
*/
public function __construct(
@@ -84,11 +121,19 @@ public function __construct(
\Magento\Framework\App\State $appState,
\Magento\Framework\Acl\Builder $aclBuilder,
\Magento\Backend\Model\UrlInterface $backendUrl,
- \Magento\Backend\App\ConfigInterface $config
+ \Magento\Backend\App\ConfigInterface $config,
+ ?SessionUserHydratorInterface $userHydrator = null,
+ ?SessionAclHydratorInterface $aclHydrator = null,
+ ?UserFactory $userFactory = null,
+ ?AclFactory $aclFactory = null
) {
$this->_config = $config;
$this->_aclBuilder = $aclBuilder;
$this->_backendUrl = $backendUrl;
+ $this->userHydrator = $userHydrator ?? ObjectManager::getInstance()->get(SessionUserHydratorInterface::class);
+ $this->aclHydrator = $aclHydrator ?? ObjectManager::getInstance()->get(SessionAclHydratorInterface::class);
+ $this->userFactory = $userFactory ?? ObjectManager::getInstance()->get(UserFactory::class);
+ $this->aclFactory = $aclFactory ?? ObjectManager::getInstance()->get(AclFactory::class);
parent::__construct(
$request,
$sidResolver,
@@ -232,6 +277,16 @@ public function processLogin()
return $this;
}
+ /**
+ * @inheritDoc
+ */
+ public function destroy(array $options = null)
+ {
+ $this->user = null;
+ $this->acl = null;
+ parent::destroy($options);
+ }
+
/**
* Process of configuring of current auth storage when logout was performed
*
@@ -255,4 +310,136 @@ public function isValidForPath($path)
{
return true;
}
+
+ /**
+ * Logged-in user.
+ *
+ * @return User|null
+ */
+ public function getUser()
+ {
+ if (!$this->user) {
+ $userData = $this->getUserData();
+ if ($userData) {
+ /** @var User $user */
+ $user = $this->userFactory->create();
+ $this->userHydrator->hydrate($user, $userData);
+ $this->user = $user;
+ }
+ }
+
+ return $this->user;
+ }
+
+ /**
+ * Set logged-in user instance.
+ *
+ * @param User|null $user
+ * @return Session
+ */
+ public function setUser($user)
+ {
+ $this->setUserData(null);
+ if ($user) {
+ $this->setUserData($this->userHydrator->extract($user));
+ }
+ $this->user = $user;
+
+ return $this;
+ }
+
+ /**
+ * Is user logged in?
+ *
+ * @return bool
+ */
+ public function hasUser()
+ {
+ return $this->user || $this->hasUserData();
+ }
+
+ /**
+ * Remove logged-in user.
+ *
+ * @return Session
+ */
+ public function unsUser()
+ {
+ $this->user = null;
+ return $this->unsUserData();
+ }
+
+ /**
+ * Logged-in user's ACL data.
+ *
+ * @return Acl|null
+ */
+ public function getAcl()
+ {
+ if (!$this->acl) {
+ $aclData = $this->getUserAclData();
+ if ($aclData) {
+ /** @var Acl $acl */
+ $acl = $this->aclFactory->create();
+ $this->aclHydrator->hydrate($acl, $aclData);
+ $this->acl = $acl;
+ }
+ }
+
+ return $this->acl;
+ }
+
+ /**
+ * Set logged-in user's ACL data instance.
+ *
+ * @param Acl|null $acl
+ * @return Session
+ */
+ public function setAcl($acl)
+ {
+ $this->setUserAclData(null);
+ if ($acl) {
+ $this->setUserAclData($this->aclHydrator->extract($acl));
+ }
+ $this->acl = $acl;
+
+ return $this;
+ }
+
+ /**
+ * Whether ACL data is present.
+ *
+ * @return bool
+ */
+ public function hasAcl()
+ {
+ return $this->acl || $this->hasUserAclData();
+ }
+
+ /**
+ * Remove ACL data.
+ *
+ * @return Session
+ */
+ public function unsAcl()
+ {
+ $this->acl = null;
+ return $this->unsUserAclData();
+ }
+
+ /**
+ * @inheritDoc
+ */
+ public function writeClose()
+ {
+ //Updating data in session in case these objects has been changed.
+ if ($this->user) {
+ $this->setUser($this->user);
+ }
+ if ($this->acl) {
+ $this->setAcl($this->acl);
+ }
+
+ parent::writeClose();
+ }
}
diff --git a/app/code/Magento/Backend/Model/Auth/SessionAclHydrator.php b/app/code/Magento/Backend/Model/Auth/SessionAclHydrator.php
new file mode 100644
index 0000000000000..34e01be696672
--- /dev/null
+++ b/app/code/Magento/Backend/Model/Auth/SessionAclHydrator.php
@@ -0,0 +1,36 @@
+ $acl->_rules, 'resources' => $acl->_resources, 'roles' => $acl->_roleRegistry];
+ }
+
+ /**
+ * @inheritDoc
+ */
+ public function hydrate(Acl $target, array $data): void
+ {
+ $target->_rules = $data['rules'];
+ $target->_resources = $data['resources'];
+ $target->_roleRegistry = $data['roles'];
+ }
+}
diff --git a/app/code/Magento/Backend/Model/Auth/SessionUserHydrator.php b/app/code/Magento/Backend/Model/Auth/SessionUserHydrator.php
new file mode 100644
index 0000000000000..6dee8b7b302c8
--- /dev/null
+++ b/app/code/Magento/Backend/Model/Auth/SessionUserHydrator.php
@@ -0,0 +1,54 @@
+roleFactory = $roleFactory;
+ }
+
+ /**
+ * @inheritDoc
+ */
+ public function extract(User $user): array
+ {
+ return ['data' => $user->getData(), 'role_data' => $user->getRole()->getData()];
+ }
+
+ /**
+ * @inheritDoc
+ */
+ public function hydrate(User $target, array $data): void
+ {
+ $target->setData($data['data']);
+ /** @var Role $role */
+ $role = $this->roleFactory->create();
+ $role->setData($data['role_data']);
+ $target->setData('extracted_role', $role);
+ $target->getRole();
+ }
+}
diff --git a/app/code/Magento/Backend/Spi/SessionAclHydratorInterface.php b/app/code/Magento/Backend/Spi/SessionAclHydratorInterface.php
new file mode 100644
index 0000000000000..7227cc92fcc8e
--- /dev/null
+++ b/app/code/Magento/Backend/Spi/SessionAclHydratorInterface.php
@@ -0,0 +1,34 @@
+cookieMetadataFactory = $this->createPartialMock(
- \Magento\Framework\Stdlib\Cookie\CookieMetadataFactory::class,
- ['createPublicCookieMetadata']
- );
-
- $this->config = $this->createPartialMock(\Magento\Backend\App\Config::class, ['getValue']);
- $this->cookieManager = $this->createPartialMock(
- \Magento\Framework\Stdlib\Cookie\PhpCookieManager::class,
- ['getCookie', 'setPublicCookie']
- );
- $this->storage = $this->createPartialMock(
- \Magento\Framework\Session\Storage::class,
- ['getUser', 'getAcl', 'setAcl']
- );
- $this->sessionConfig = $this->createPartialMock(
- \Magento\Framework\Session\Config::class,
- ['getCookiePath', 'getCookieDomain', 'getCookieSecure', 'getCookieHttpOnly']
- );
- $this->aclBuilder = $this->getMockBuilder(\Magento\Framework\Acl\Builder::class)
- ->disableOriginalConstructor()
- ->getMock();
- $objectManager = new ObjectManager($this);
- $this->session = $objectManager->getObject(
- \Magento\Backend\Model\Auth\Session::class,
- [
- 'config' => $this->config,
- 'sessionConfig' => $this->sessionConfig,
- 'cookieManager' => $this->cookieManager,
- 'cookieMetadataFactory' => $this->cookieMetadataFactory,
- 'storage' => $this->storage,
- 'aclBuilder' => $this->aclBuilder
- ]
- );
- }
-
- protected function tearDown()
- {
- $this->config = null;
- $this->sessionConfig = null;
- $this->session = null;
- }
-
- /**
- * @dataProvider refreshAclDataProvider
- * @param $isUserPassedViaParams
- */
- public function testRefreshAcl($isUserPassedViaParams)
- {
- $aclMock = $this->getMockBuilder(\Magento\Framework\Acl::class)->disableOriginalConstructor()->getMock();
- $this->aclBuilder->expects($this->any())->method('getAcl')->willReturn($aclMock);
- $userMock = $this->getMockBuilder(\Magento\User\Model\User::class)
- ->setMethods(['getReloadAclFlag', 'setReloadAclFlag', 'unsetData', 'save'])
- ->disableOriginalConstructor()
- ->getMock();
- $userMock->expects($this->any())->method('getReloadAclFlag')->willReturn(true);
- $userMock->expects($this->once())->method('setReloadAclFlag')->with('0')->willReturnSelf();
- $userMock->expects($this->once())->method('save');
- $this->storage->expects($this->once())->method('setAcl')->with($aclMock);
- $this->storage->expects($this->any())->method('getAcl')->willReturn($aclMock);
- if ($isUserPassedViaParams) {
- $this->session->refreshAcl($userMock);
- } else {
- $this->storage->expects($this->once())->method('getUser')->willReturn($userMock);
- $this->session->refreshAcl();
- }
- $this->assertSame($aclMock, $this->session->getAcl());
- }
-
- /**
- * @return array
- */
- public function refreshAclDataProvider()
- {
- return [
- 'User set via params' => [true],
- 'User set to session object' => [false]
- ];
- }
-
- public function testIsLoggedInPositive()
- {
- $user = $this->createPartialMock(\Magento\User\Model\User::class, ['getId', '__wakeup']);
- $user->expects($this->once())
- ->method('getId')
- ->will($this->returnValue(1));
-
- $this->storage->expects($this->any())
- ->method('getUser')
- ->will($this->returnValue($user));
-
- $this->assertTrue($this->session->isLoggedIn());
- }
-
- public function testProlong()
- {
- $name = session_name();
- $cookie = 'cookie';
- $lifetime = 900;
- $path = '/';
- $domain = 'magento2';
- $secure = true;
- $httpOnly = true;
-
- $this->config->expects($this->once())
- ->method('getValue')
- ->with(\Magento\Backend\Model\Auth\Session::XML_PATH_SESSION_LIFETIME)
- ->willReturn($lifetime);
- $cookieMetadata = $this->createMock(\Magento\Framework\Stdlib\Cookie\PublicCookieMetadata::class);
- $cookieMetadata->expects($this->once())
- ->method('setDuration')
- ->with($lifetime)
- ->will($this->returnSelf());
- $cookieMetadata->expects($this->once())
- ->method('setPath')
- ->with($path)
- ->will($this->returnSelf());
- $cookieMetadata->expects($this->once())
- ->method('setDomain')
- ->with($domain)
- ->will($this->returnSelf());
- $cookieMetadata->expects($this->once())
- ->method('setSecure')
- ->with($secure)
- ->will($this->returnSelf());
- $cookieMetadata->expects($this->once())
- ->method('setHttpOnly')
- ->with($httpOnly)
- ->will($this->returnSelf());
-
- $this->cookieMetadataFactory->expects($this->once())
- ->method('createPublicCookieMetadata')
- ->will($this->returnValue($cookieMetadata));
-
- $this->cookieManager->expects($this->once())
- ->method('getCookie')
- ->with($name)
- ->will($this->returnValue($cookie));
- $this->cookieManager->expects($this->once())
- ->method('setPublicCookie')
- ->with($name, $cookie, $cookieMetadata);
-
- $this->sessionConfig->expects($this->once())
- ->method('getCookiePath')
- ->will($this->returnValue($path));
- $this->sessionConfig->expects($this->once())
- ->method('getCookieDomain')
- ->will($this->returnValue($domain));
- $this->sessionConfig->expects($this->once())
- ->method('getCookieSecure')
- ->will($this->returnValue($secure));
- $this->sessionConfig->expects($this->once())
- ->method('getCookieHttpOnly')
- ->will($this->returnValue($httpOnly));
-
- $this->session->prolong();
-
- $this->assertLessThanOrEqual(time(), $this->session->getUpdatedAt());
- }
-
- /**
- * @dataProvider isAllowedDataProvider
- * @param bool $isUserDefined
- * @param bool $isAclDefined
- * @param bool $isAllowed
- * @param true $expectedResult
- */
- public function testIsAllowed($isUserDefined, $isAclDefined, $isAllowed, $expectedResult)
- {
- $userAclRole = 'userAclRole';
- if ($isAclDefined) {
- $aclMock = $this->getMockBuilder(\Magento\Framework\Acl::class)->disableOriginalConstructor()->getMock();
- $this->storage->expects($this->any())->method('getAcl')->willReturn($aclMock);
- }
- if ($isUserDefined) {
- $userMock = $this->getMockBuilder(\Magento\User\Model\User::class)->disableOriginalConstructor()->getMock();
- $this->storage->expects($this->once())->method('getUser')->willReturn($userMock);
- }
- if ($isAclDefined && $isUserDefined) {
- $userMock->expects($this->any())->method('getAclRole')->willReturn($userAclRole);
- $aclMock->expects($this->once())->method('isAllowed')->with($userAclRole)->willReturn($isAllowed);
- }
-
- $this->assertEquals($expectedResult, $this->session->isAllowed('resource'));
- }
-
- /**
- * @return array
- */
- public function isAllowedDataProvider()
- {
- return [
- "Negative: User not defined" => [false, true, true, false],
- "Negative: Acl not defined" => [true, false, true, false],
- "Negative: Permission denied" => [true, true, false, false],
- "Positive: Permission granted" => [true, true, false, false],
- ];
- }
-
- /**
- * @dataProvider firstPageAfterLoginDataProvider
- * @param bool $isFirstPageAfterLogin
- */
- public function testFirstPageAfterLogin($isFirstPageAfterLogin)
- {
- $this->session->setIsFirstPageAfterLogin($isFirstPageAfterLogin);
- $this->assertEquals($isFirstPageAfterLogin, $this->session->isFirstPageAfterLogin());
- }
-
- /**
- * @return array
- */
- public function firstPageAfterLoginDataProvider()
- {
- return [
- 'First page after login' => [true],
- 'Not first page after login' => [false],
- ];
- }
-}
diff --git a/app/code/Magento/Backend/Test/Unit/Model/Authorization/RoleLocatorTest.php b/app/code/Magento/Backend/Test/Unit/Model/Authorization/RoleLocatorTest.php
deleted file mode 100644
index 77c428a6a116a..0000000000000
--- a/app/code/Magento/Backend/Test/Unit/Model/Authorization/RoleLocatorTest.php
+++ /dev/null
@@ -1,39 +0,0 @@
-_sessionMock = $this->createPartialMock(
- \Magento\Backend\Model\Auth\Session::class,
- ['getUser', 'getAclRole', 'hasUser']
- );
- $this->_model = new \Magento\Backend\Model\Authorization\RoleLocator($this->_sessionMock);
- }
-
- public function testGetAclRoleIdReturnsCurrentUserAclRoleId()
- {
- $this->_sessionMock->expects($this->once())->method('hasUser')->will($this->returnValue(true));
- $this->_sessionMock->expects($this->once())->method('getUser')->will($this->returnSelf());
- $this->_sessionMock->expects($this->once())->method('getAclRole')->will($this->returnValue('some_role'));
- $this->assertEquals('some_role', $this->_model->getAclRoleId());
- }
-}
diff --git a/app/code/Magento/Backend/Test/Unit/Model/Locale/ManagerTest.php b/app/code/Magento/Backend/Test/Unit/Model/Locale/ManagerTest.php
deleted file mode 100644
index ce2b65a2249ac..0000000000000
--- a/app/code/Magento/Backend/Test/Unit/Model/Locale/ManagerTest.php
+++ /dev/null
@@ -1,130 +0,0 @@
-_session = $this->createMock(\Magento\Backend\Model\Session::class);
-
- $this->_authSession = $this->createPartialMock(\Magento\Backend\Model\Auth\Session::class, ['getUser']);
-
- $this->_backendConfig = $this->getMockForAbstractClass(
- \Magento\Backend\App\ConfigInterface::class,
- [],
- '',
- false
- );
-
- $userMock = new \Magento\Framework\DataObject();
-
- $this->_authSession->expects($this->any())->method('getUser')->will($this->returnValue($userMock));
-
- $this->_translator = $this->getMockBuilder(\Magento\Framework\TranslateInterface::class)
- ->setMethods(['init', 'setLocale'])
- ->getMockForAbstractClass();
-
- $this->_translator->expects($this->any())->method('setLocale')->will($this->returnValue($this->_translator));
-
- $this->_translator->expects($this->any())->method('init')->will($this->returnValue(false));
-
- $this->_model = new \Magento\Backend\Model\Locale\Manager(
- $this->_session,
- $this->_authSession,
- $this->_translator,
- $this->_backendConfig
- );
- }
-
- /**
- * @return array
- */
- public function switchBackendInterfaceLocaleDataProvider()
- {
- return ['case1' => ['locale' => 'de_DE'], 'case2' => ['locale' => 'en_US']];
- }
-
- /**
- * @param string $locale
- * @dataProvider switchBackendInterfaceLocaleDataProvider
- * @covers \Magento\Backend\Model\Locale\Manager::switchBackendInterfaceLocale
- */
- public function testSwitchBackendInterfaceLocale($locale)
- {
- $this->_model->switchBackendInterfaceLocale($locale);
-
- $userInterfaceLocale = $this->_authSession->getUser()->getInterfaceLocale();
- $this->assertEquals($userInterfaceLocale, $locale);
-
- $sessionLocale = $this->_session->getSessionLocale();
- $this->assertEquals($sessionLocale, null);
- }
-
- /**
- * @covers \Magento\Backend\Model\Locale\Manager::getUserInterfaceLocale
- */
- public function testGetUserInterfaceLocaleDefault()
- {
- $locale = $this->_model->getUserInterfaceLocale();
-
- $this->assertEquals($locale, Resolver::DEFAULT_LOCALE);
- }
-
- /**
- * @covers \Magento\Backend\Model\Locale\Manager::getUserInterfaceLocale
- */
- public function testGetUserInterfaceLocale()
- {
- $this->_model->switchBackendInterfaceLocale('de_DE');
- $locale = $this->_model->getUserInterfaceLocale();
-
- $this->assertEquals($locale, 'de_DE');
- }
-
- /**
- * @covers \Magento\Backend\Model\Locale\Manager::getUserInterfaceLocale
- */
- public function testGetUserInterfaceGeneralLocale()
- {
- $this->_backendConfig->expects($this->any())
- ->method('getValue')
- ->with('general/locale/code')
- ->willReturn('test_locale');
- $locale = $this->_model->getUserInterfaceLocale();
- $this->assertEquals($locale, 'test_locale');
- }
-}
diff --git a/app/code/Magento/Backend/composer.json b/app/code/Magento/Backend/composer.json
index f9408768136bb..e54bd136b3494 100644
--- a/app/code/Magento/Backend/composer.json
+++ b/app/code/Magento/Backend/composer.json
@@ -22,6 +22,7 @@
"magento/module-store": "*",
"magento/module-translation": "*",
"magento/module-ui": "*",
+ "magento/module-authorization": "*",
"magento/module-user": "*"
},
"suggest": {
diff --git a/app/code/Magento/Backend/etc/di.xml b/app/code/Magento/Backend/etc/di.xml
index c526703da9975..41db85b9323a8 100644
--- a/app/code/Magento/Backend/etc/di.xml
+++ b/app/code/Magento/Backend/etc/di.xml
@@ -198,4 +198,8 @@
Magento\Backend\Block\AnchorRenderer
+
+
diff --git a/app/code/Magento/Catalog/Model/ResourceModel/Eav/Attribute.php b/app/code/Magento/Catalog/Model/ResourceModel/Eav/Attribute.php
index e7c98b218f5ad..e7c67463d8a5d 100644
--- a/app/code/Magento/Catalog/Model/ResourceModel/Eav/Attribute.php
+++ b/app/code/Magento/Catalog/Model/ResourceModel/Eav/Attribute.php
@@ -846,9 +846,14 @@ public function afterDelete()
/**
* @inheritdoc
* @since 100.0.9
+ *
+ * @SuppressWarnings(PHPMD.SerializationAware)
+ * @deprecated Do not use PHP serialization.
*/
public function __sleep()
{
+ trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
+
$this->unsetData('entity_type');
return array_diff(
parent::__sleep(),
@@ -859,9 +864,14 @@ public function __sleep()
/**
* @inheritdoc
* @since 100.0.9
+ *
+ * @SuppressWarnings(PHPMD.SerializationAware)
+ * @deprecated Do not use PHP serialization.
*/
public function __wakeup()
{
+ trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
+
parent::__wakeup();
$objectManager = \Magento\Framework\App\ObjectManager::getInstance();
$this->_indexerEavProcessor = $objectManager->get(\Magento\Catalog\Model\Indexer\Product\Flat\Processor::class);
diff --git a/app/code/Magento/Config/Model/Config/Backend/Encrypted.php b/app/code/Magento/Config/Model/Config/Backend/Encrypted.php
index 62d6531978d8a..0700d637d6144 100644
--- a/app/code/Magento/Config/Model/Config/Backend/Encrypted.php
+++ b/app/code/Magento/Config/Model/Config/Backend/Encrypted.php
@@ -48,9 +48,14 @@ public function __construct(
* Magic method called during class serialization
*
* @return string[]
+ *
+ * @SuppressWarnings(PHPMD.SerializationAware)
+ * @deprecated Do not use PHP serialization.
*/
public function __sleep()
{
+ trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
+
$properties = parent::__sleep();
return array_diff($properties, ['_encryptor']);
}
@@ -59,9 +64,14 @@ public function __sleep()
* Magic method called during class un-serialization
*
* @return void
+ *
+ * @SuppressWarnings(PHPMD.SerializationAware)
+ * @deprecated Do not use PHP serialization.
*/
public function __wakeup()
{
+ trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
+
parent::__wakeup();
$this->_encryptor = \Magento\Framework\App\ObjectManager::getInstance()->get(
\Magento\Framework\Encryption\EncryptorInterface::class
diff --git a/app/code/Magento/ConfigurableProduct/Model/Product/Type/Configurable/Attribute.php b/app/code/Magento/ConfigurableProduct/Model/Product/Type/Configurable/Attribute.php
index b013916cc221a..6dd3790191551 100644
--- a/app/code/Magento/ConfigurableProduct/Model/Product/Type/Configurable/Attribute.php
+++ b/app/code/Magento/ConfigurableProduct/Model/Product/Type/Configurable/Attribute.php
@@ -113,11 +113,12 @@ public function afterSave()
}
/**
- * Load configurable attribute by product and product's attribute
+ * Load configurable attribute by product and product's attribute.
*
* @param \Magento\Catalog\Model\Product $product
* @param \Magento\Catalog\Model\ResourceModel\Eav\Attribute $attribute
* @throws LocalizedException
+ * @return void
*/
public function loadByProductAndAttribute($product, $attribute)
{
@@ -263,9 +264,14 @@ public function setProductId($value)
/**
* @inheritdoc
+ *
+ * @SuppressWarnings(PHPMD.SerializationAware)
+ * @deprecated Do not use PHP serialization.
*/
public function __sleep()
{
+ trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
+
return array_diff(
parent::__sleep(),
['metadataPool']
@@ -274,9 +280,14 @@ public function __sleep()
/**
* @inheritdoc
+ *
+ * @SuppressWarnings(PHPMD.SerializationAware)
+ * @deprecated Do not use PHP serialization.
*/
public function __wakeup()
{
+ trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
+
parent::__wakeup();
$objectManager = \Magento\Framework\App\ObjectManager::getInstance();
$this->metadataPool = $objectManager->get(MetadataPool::class);
diff --git a/app/code/Magento/ConfigurableProduct/Model/ResourceModel/Product/Type/Configurable/Attribute/Collection.php b/app/code/Magento/ConfigurableProduct/Model/ResourceModel/Product/Type/Configurable/Attribute/Collection.php
index 8f2cc6ddb43ce..90b02cb112b5f 100644
--- a/app/code/Magento/ConfigurableProduct/Model/ResourceModel/Product/Type/Configurable/Attribute/Collection.php
+++ b/app/code/Magento/ConfigurableProduct/Model/ResourceModel/Product/Type/Configurable/Attribute/Collection.php
@@ -302,7 +302,9 @@ protected function _loadLabels()
}
/**
- * Load attribute options.
+ * Load related options' data.
+ *
+ * @return void
*/
protected function loadOptions()
{
@@ -355,9 +357,14 @@ protected function getIncludedOptions(array $usedProducts, AbstractAttribute $pr
/**
* @inheritdoc
* @since 100.0.6
+ *
+ * @SuppressWarnings(PHPMD.SerializationAware)
+ * @deprecated Do not use PHP serialization.
*/
public function __sleep()
{
+ trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
+
return array_diff(
parent::__sleep(),
[
@@ -374,9 +381,14 @@ public function __sleep()
/**
* @inheritdoc
* @since 100.0.6
+ *
+ * @SuppressWarnings(PHPMD.SerializationAware)
+ * @deprecated Do not use PHP serialization.
*/
public function __wakeup()
{
+ trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
+
parent::__wakeup();
$objectManager = ObjectManager::getInstance();
$this->_storeManager = $objectManager->get(\Magento\Store\Model\StoreManagerInterface::class);
diff --git a/app/code/Magento/Customer/Model/Attribute.php b/app/code/Magento/Customer/Model/Attribute.php
index 98a97872f15f4..ae714f993082e 100644
--- a/app/code/Magento/Customer/Model/Attribute.php
+++ b/app/code/Magento/Customer/Model/Attribute.php
@@ -202,9 +202,14 @@ public function canBeFilterableInGrid()
/**
* @inheritdoc
+ *
+ * @SuppressWarnings(PHPMD.SerializationAware)
+ * @deprecated Do not use PHP serialization.
*/
public function __sleep()
{
+ trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
+
$this->unsetData('entity_type');
return array_diff(
parent::__sleep(),
@@ -214,9 +219,14 @@ public function __sleep()
/**
* @inheritdoc
+ *
+ * @SuppressWarnings(PHPMD.SerializationAware)
+ * @deprecated Do not use PHP serialization.
*/
public function __wakeup()
{
+ trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
+
parent::__wakeup();
$objectManager = \Magento\Framework\App\ObjectManager::getInstance();
$this->indexerRegistry = $objectManager->get(\Magento\Framework\Indexer\IndexerRegistry::class);
diff --git a/app/code/Magento/Eav/Model/Entity/Attribute.php b/app/code/Magento/Eav/Model/Entity/Attribute.php
index bb2477d4df827..1ca942ef1679c 100644
--- a/app/code/Magento/Eav/Model/Entity/Attribute.php
+++ b/app/code/Magento/Eav/Model/Entity/Attribute.php
@@ -214,7 +214,7 @@ public function deleteEntity()
/**
* Load entity_attribute_id into $this by $this->attribute_set_id
*
- * @return $this
+ * Save additional data.
*/
public function loadEntityAttributeIdBySet()
{
@@ -311,7 +311,7 @@ public function beforeSave()
}
/**
- * Save additional data
+ * @inheritdoc
*
* @return $this
* @throws LocalizedException
@@ -489,9 +489,14 @@ public function getIdentities()
/**
* @inheritdoc
* @since 100.0.7
+ *
+ * @SuppressWarnings(PHPMD.SerializationAware)
+ * @deprecated Do not use PHP serialization.
*/
public function __sleep()
{
+ trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
+
$this->unsetData('attribute_set_info');
return array_diff(
parent::__sleep(),
@@ -502,9 +507,14 @@ public function __sleep()
/**
* @inheritdoc
* @since 100.0.7
+ *
+ * @SuppressWarnings(PHPMD.SerializationAware)
+ * @deprecated Do not use PHP serialization.
*/
public function __wakeup()
{
+ trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
+
parent::__wakeup();
$objectManager = ObjectManager::getInstance();
$this->_localeDate = $objectManager->get(\Magento\Framework\Stdlib\DateTime\TimezoneInterface::class);
diff --git a/app/code/Magento/Eav/Model/Entity/Attribute/AbstractAttribute.php b/app/code/Magento/Eav/Model/Entity/Attribute/AbstractAttribute.php
index 3857118ae67ca..b7b712c493669 100644
--- a/app/code/Magento/Eav/Model/Entity/Attribute/AbstractAttribute.php
+++ b/app/code/Magento/Eav/Model/Entity/Attribute/AbstractAttribute.php
@@ -1405,9 +1405,14 @@ public function setExtensionAttributes(\Magento\Eav\Api\Data\AttributeExtensionI
/**
* @inheritdoc
* @since 100.0.7
+ *
+ * @SuppressWarnings(PHPMD.SerializationAware)
+ * @deprecated Do not use PHP serialization.
*/
public function __sleep()
{
+ trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
+
return array_diff(
parent::__sleep(),
[
@@ -1430,9 +1435,14 @@ public function __sleep()
/**
* @inheritdoc
* @since 100.0.7
+ *
+ * @SuppressWarnings(PHPMD.SerializationAware)
+ * @deprecated Do not use PHP serialization.
*/
public function __wakeup()
{
+ trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
+
parent::__wakeup();
$objectManager = \Magento\Framework\App\ObjectManager::getInstance();
$this->_eavConfig = $objectManager->get(\Magento\Eav\Model\Config::class);
diff --git a/app/code/Magento/Eav/Model/ResourceModel/Entity/Attribute.php b/app/code/Magento/Eav/Model/ResourceModel/Entity/Attribute.php
index 0e7a46125d872..5e7226e7a36dd 100644
--- a/app/code/Magento/Eav/Model/ResourceModel/Entity/Attribute.php
+++ b/app/code/Magento/Eav/Model/ResourceModel/Entity/Attribute.php
@@ -725,9 +725,14 @@ public function getValidAttributeIds($attributeIds)
*
* @return array
* @since 100.0.7
+ *
+ * @SuppressWarnings(PHPMD.SerializationAware)
+ * @deprecated Do not use PHP serialization.
*/
public function __sleep()
{
+ trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
+
$properties = parent::__sleep();
$properties = array_diff($properties, ['_storeManager']);
return $properties;
@@ -738,9 +743,14 @@ public function __sleep()
*
* @return void
* @since 100.0.7
+ *
+ * @SuppressWarnings(PHPMD.SerializationAware)
+ * @deprecated Do not use PHP serialization.
*/
public function __wakeup()
{
+ trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
+
parent::__wakeup();
$this->_storeManager = \Magento\Framework\App\ObjectManager::getInstance()
->get(\Magento\Store\Model\StoreManagerInterface::class);
diff --git a/app/code/Magento/Paypal/Test/Unit/Block/Adminhtml/System/Config/Fieldset/GroupTest.php b/app/code/Magento/Paypal/Test/Unit/Block/Adminhtml/System/Config/Fieldset/GroupTest.php
deleted file mode 100644
index e4de60cafb8ad..0000000000000
--- a/app/code/Magento/Paypal/Test/Unit/Block/Adminhtml/System/Config/Fieldset/GroupTest.php
+++ /dev/null
@@ -1,110 +0,0 @@
-_group = $this->createMock(\Magento\Config\Model\Config\Structure\Element\Group::class);
- $this->_element = $this->getMockForAbstractClass(
- \Magento\Framework\Data\Form\Element\AbstractElement::class,
- [],
- '',
- false,
- true,
- true,
- ['getHtmlId', 'getElementHtml', 'getName', 'getElements', 'getId']
- );
- $this->_element->expects($this->any())
- ->method('getHtmlId')
- ->will($this->returnValue('html id'));
- $this->_element->expects($this->any())
- ->method('getElementHtml')
- ->will($this->returnValue('element html'));
- $this->_element->expects($this->any())
- ->method('getName')
- ->will($this->returnValue('name'));
- $this->_element->expects($this->any())
- ->method('getElements')
- ->will($this->returnValue([]));
- $this->_element->expects($this->any())
- ->method('getId')
- ->will($this->returnValue('id'));
- $this->_user = $this->createMock(\Magento\User\Model\User::class);
- $this->_authSession = $this->createMock(\Magento\Backend\Model\Auth\Session::class);
- $this->_authSession->expects($this->any())
- ->method('__call')
- ->with('getUser')
- ->will($this->returnValue($this->_user));
- $this->_model = $helper->getObject(
- \Magento\Paypal\Block\Adminhtml\System\Config\Fieldset\Group::class,
- ['authSession' => $this->_authSession]
- );
- $this->_model->setGroup($this->_group);
- }
-
- /**
- * @param mixed $expanded
- * @param int $expected
- * @dataProvider isCollapseStateDataProvider
- */
- public function testIsCollapseState($expanded, $expected)
- {
- $this->_user->setExtra(['configState' => []]);
- $this->_element->setGroup(isset($expanded) ? ['expanded' => $expanded] : []);
- $html = $this->_model->render($this->_element);
- $this->assertContains(
- ' ',
- $html
- );
- }
-
- /**
- * @return array
- */
- public function isCollapseStateDataProvider()
- {
- return [
- [null, 0],
- [false, 0],
- ['', 0],
- [1, 1],
- ['1', 1],
- ];
- }
-}
diff --git a/app/code/Magento/ReleaseNotification/Test/Unit/Model/Condition/CanViewNotificationTest.php b/app/code/Magento/ReleaseNotification/Test/Unit/Model/Condition/CanViewNotificationTest.php
index 813c5f28bf4d9..a7f619863af56 100644
--- a/app/code/Magento/ReleaseNotification/Test/Unit/Model/Condition/CanViewNotificationTest.php
+++ b/app/code/Magento/ReleaseNotification/Test/Unit/Model/Condition/CanViewNotificationTest.php
@@ -12,6 +12,7 @@
use Magento\Framework\TestFramework\Unit\Helper\ObjectManager;
use Magento\Backend\Model\Auth\Session;
use Magento\Framework\App\CacheInterface;
+use Magento\User\Model\User;
/**
* Class CanViewNotificationTest
@@ -36,6 +37,11 @@ class CanViewNotificationTest extends \PHPUnit\Framework\TestCase
/** @var $cacheStorageMock \PHPUnit_Framework_MockObject_MockObject|CacheInterface */
private $cacheStorageMock;
+ /**
+ * @var User|\PHPUnit_Framework_MockObject_MockObject
+ */
+ private $userMock;
+
public function setUp()
{
$this->cacheStorageMock = $this->getMockBuilder(CacheInterface::class)
@@ -44,7 +50,6 @@ public function setUp()
->getMock();
$this->sessionMock = $this->getMockBuilder(Session::class)
->disableOriginalConstructor()
- ->setMethods(['getUser', 'getId'])
->getMock();
$this->viewerLoggerMock = $this->getMockBuilder(Logger::class)
->disableOriginalConstructor()
@@ -52,6 +57,7 @@ public function setUp()
$this->productMetadataMock = $this->getMockBuilder(ProductMetadataInterface::class)
->disableOriginalConstructor()
->getMock();
+ $this->userMock = $this->createMock(User::class);
$objectManager = new ObjectManager($this);
$this->canViewNotification = $objectManager->getObject(
CanViewNotification::class,
@@ -68,8 +74,8 @@ public function testIsVisibleLoadDataFromCache()
{
$this->sessionMock->expects($this->once())
->method('getUser')
- ->willReturn($this->sessionMock);
- $this->sessionMock->expects($this->once())
+ ->willReturn($this->userMock);
+ $this->userMock->expects($this->once())
->method('getId')
->willReturn(1);
$this->cacheStorageMock->expects($this->once())
@@ -93,8 +99,8 @@ public function testIsVisible($expected, $version, $lastViewVersion)
->willReturn(false);
$this->sessionMock->expects($this->once())
->method('getUser')
- ->willReturn($this->sessionMock);
- $this->sessionMock->expects($this->once())
+ ->willReturn($this->userMock);
+ $this->userMock->expects($this->once())
->method('getId')
->willReturn(1);
$this->productMetadataMock->expects($this->once())
diff --git a/app/code/Magento/Store/Model/Store.php b/app/code/Magento/Store/Model/Store.php
index dab9c55c216d9..eaabdedb4b7fd 100644
--- a/app/code/Magento/Store/Model/Store.php
+++ b/app/code/Magento/Store/Model/Store.php
@@ -423,9 +423,14 @@ public function __construct(
/**
* @inheritdoc
+ *
+ * @SuppressWarnings(PHPMD.SerializationAware)
+ * @deprecated Do not use PHP serialization.
*/
public function __sleep()
{
+ trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
+
$properties = parent::__sleep();
$properties = array_diff($properties, ['_coreFileStorageDatabase', '_config']);
return $properties;
@@ -435,9 +440,14 @@ public function __sleep()
* Init not serializable fields
*
* @return void
+ *
+ * @SuppressWarnings(PHPMD.SerializationAware)
+ * @deprecated Do not use PHP serialization.
*/
public function __wakeup()
{
+ trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
+
parent::__wakeup();
$this->_coreFileStorageDatabase = ObjectManager::getInstance()
->get(\Magento\MediaStorage\Helper\File\Storage\Database::class);
diff --git a/app/code/Magento/User/Model/User.php b/app/code/Magento/User/Model/User.php
index dc0aa0cd38343..297f6d8814de2 100644
--- a/app/code/Magento/User/Model/User.php
+++ b/app/code/Magento/User/Model/User.php
@@ -212,9 +212,14 @@ protected function _construct()
* Removing dependencies and leaving only entity's properties.
*
* @return string[]
+ *
+ * @SuppressWarnings(PHPMD.SerializationAware)
+ * @deprecated Do not use PHP serialization.
*/
public function __sleep()
{
+ trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
+
$properties = parent::__sleep();
return array_diff(
$properties,
@@ -240,9 +245,14 @@ public function __sleep()
* Restoring required objects after serialization.
*
* @return void
+ *
+ * @SuppressWarnings(PHPMD.SerializationAware)
+ * @deprecated Do not use PHP serialization.
*/
public function __wakeup()
{
+ trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
+
parent::__wakeup();
$objectManager = \Magento\Framework\App\ObjectManager::getInstance();
$this->serializer = $objectManager->get(Json::class);
@@ -409,6 +419,10 @@ public function getRoles()
*/
public function getRole()
{
+ if ($this->getData('extracted_role')) {
+ $this->_role = $this->getData('extracted_role');
+ $this->unsetData('extracted_role');
+ }
if (null === $this->_role) {
$this->_role = $this->_roleFactory->create();
$roles = $this->getRoles();
diff --git a/app/code/Magento/User/Test/Unit/Model/Authorization/AdminSessionUserContextTest.php b/app/code/Magento/User/Test/Unit/Model/Authorization/AdminSessionUserContextTest.php
deleted file mode 100644
index 23681c4b8da26..0000000000000
--- a/app/code/Magento/User/Test/Unit/Model/Authorization/AdminSessionUserContextTest.php
+++ /dev/null
@@ -1,89 +0,0 @@
-objectManager = new \Magento\Framework\TestFramework\Unit\Helper\ObjectManager($this);
-
- $this->adminSession = $this->getMockBuilder(\Magento\Backend\Model\Auth\Session::class)
- ->disableOriginalConstructor()
- ->setMethods(['hasUser', 'getUser', 'getId'])
- ->getMock();
-
- $this->adminSessionUserContext = $this->objectManager->getObject(
- \Magento\User\Model\Authorization\AdminSessionUserContext::class,
- ['adminSession' => $this->adminSession]
- );
- }
-
- public function testGetUserIdExist()
- {
- $userId = 1;
-
- $this->setupUserId($userId);
-
- $this->assertEquals($userId, $this->adminSessionUserContext->getUserId());
- }
-
- public function testGetUserIdDoesNotExist()
- {
- $userId = null;
-
- $this->setupUserId($userId);
-
- $this->assertEquals($userId, $this->adminSessionUserContext->getUserId());
- }
-
- public function testGetUserType()
- {
- $this->assertEquals(UserContextInterface::USER_TYPE_ADMIN, $this->adminSessionUserContext->getUserType());
- }
-
- /**
- * @param int|null $userId
- * @return void
- */
- public function setupUserId($userId)
- {
- $this->adminSession->expects($this->once())
- ->method('hasUser')
- ->will($this->returnValue($userId));
-
- if ($userId) {
- $this->adminSession->expects($this->once())
- ->method('getUser')
- ->will($this->returnSelf());
-
- $this->adminSession->expects($this->once())
- ->method('getId')
- ->will($this->returnValue($userId));
- }
- }
-}
diff --git a/app/code/Magento/User/Test/Unit/Model/UserTest.php b/app/code/Magento/User/Test/Unit/Model/UserTest.php
index 670316c2500fc..ab06c8754b2f0 100644
--- a/app/code/Magento/User/Test/Unit/Model/UserTest.php
+++ b/app/code/Magento/User/Test/Unit/Model/UserTest.php
@@ -44,31 +44,6 @@ protected function setUp()
);
}
- /**
- * @return void
- */
- public function testSleep()
- {
- $excludedProperties = [
- '_eventManager',
- '_cacheManager',
- '_registry',
- '_appState',
- '_userData',
- '_config',
- '_validatorObject',
- '_roleFactory',
- '_encryptor',
- '_transportBuilder',
- '_storeManager',
- '_validatorBeforeSave'
- ];
- $actualResult = $this->model->__sleep();
- $this->assertNotEmpty($actualResult);
- $expectedResult = array_intersect($actualResult, $excludedProperties);
- $this->assertEmpty($expectedResult);
- }
-
/**
* @return void
*/
diff --git a/dev/tests/integration/testsuite/Magento/Backend/Model/Auth/SessionTest.php b/dev/tests/integration/testsuite/Magento/Backend/Model/Auth/SessionTest.php
index 5ca2bf1f73175..f1e7a10737604 100644
--- a/dev/tests/integration/testsuite/Magento/Backend/Model/Auth/SessionTest.php
+++ b/dev/tests/integration/testsuite/Magento/Backend/Model/Auth/SessionTest.php
@@ -3,8 +3,12 @@
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
+
namespace Magento\Backend\Model\Auth;
+use Magento\TestFramework\Bootstrap as TestHelper;
+use Magento\TestFramework\Helper\Bootstrap;
+
/**
* @magentoAppArea adminhtml
* @magentoAppIsolation enabled
@@ -18,10 +22,15 @@ class SessionTest extends \PHPUnit\Framework\TestCase
private $auth;
/**
- * @var \Magento\Backend\Model\Auth\Session
+ * @var Session
*/
private $authSession;
+ /**
+ * @var SessionFactory
+ */
+ private $authSessionFactory;
+
/**
* @var \Magento\Framework\ObjectManagerInterface
*/
@@ -30,11 +39,12 @@ class SessionTest extends \PHPUnit\Framework\TestCase
protected function setUp()
{
parent::setUp();
- $this->objectManager = \Magento\TestFramework\Helper\Bootstrap::getObjectManager();
+ $this->objectManager = Bootstrap::getObjectManager();
$this->objectManager->get(\Magento\Framework\Config\ScopeInterface::class)
->setCurrentScope(\Magento\Backend\App\Area\FrontNameResolver::AREA_CODE);
$this->auth = $this->objectManager->create(\Magento\Backend\Model\Auth::class);
- $this->authSession = $this->objectManager->create(\Magento\Backend\Model\Auth\Session::class);
+ $this->authSession = $this->objectManager->create(Session::class);
+ $this->authSessionFactory = $this->objectManager->get(SessionFactory::class);
$this->auth->setAuthStorage($this->authSession);
$this->auth->logout();
}
@@ -52,8 +62,8 @@ public function testIsLoggedIn($loggedIn)
{
if ($loggedIn) {
$this->auth->login(
- \Magento\TestFramework\Bootstrap::ADMIN_NAME,
- \Magento\TestFramework\Bootstrap::ADMIN_PASSWORD
+ TestHelper::ADMIN_NAME,
+ TestHelper::ADMIN_PASSWORD
);
}
$this->assertEquals($loggedIn, $this->authSession->isLoggedIn());
@@ -63,4 +73,23 @@ public function loginDataProvider()
{
return [[false], [true]];
}
+
+ /**
+ * Check that persisting user data is working.
+ */
+ public function testStorage()
+ {
+ $this->auth->login(TestHelper::ADMIN_NAME, TestHelper::ADMIN_PASSWORD);
+ $user = $this->authSession->getUser();
+ $acl = $this->authSession->getAcl();
+ /** @var Session $session */
+ $session = $this->authSessionFactory->create();
+ $persistedUser = $session->getUser();
+ $persistedAcl = $session->getAcl();
+
+ $this->assertEquals($user->getData(), $persistedUser->getData());
+ $this->assertEquals($user->getAclRole(), $persistedUser->getAclRole());
+ $this->assertEquals($acl->getRoles(), $persistedAcl->getRoles());
+ $this->assertEquals($acl->getResources(), $persistedAcl->getResources());
+ }
}
diff --git a/dev/tests/integration/testsuite/Magento/Backend/Model/Locale/ResolverTest.php b/dev/tests/integration/testsuite/Magento/Backend/Model/Locale/ResolverTest.php
index d1252be2c4b53..88662a65c7428 100644
--- a/dev/tests/integration/testsuite/Magento/Backend/Model/Locale/ResolverTest.php
+++ b/dev/tests/integration/testsuite/Magento/Backend/Model/Locale/ResolverTest.php
@@ -3,9 +3,12 @@
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
+
namespace Magento\Backend\Model\Locale;
use Magento\Framework\Locale\Resolver;
+use Magento\TestFramework\Helper\Bootstrap;
+use Magento\User\Model\User;
/**
* @magentoAppArea adminhtml
@@ -20,7 +23,7 @@ class ResolverTest extends \PHPUnit\Framework\TestCase
protected function setUp()
{
parent::setUp();
- $this->_model = \Magento\TestFramework\Helper\Bootstrap::getObjectManager()->create(
+ $this->_model = Bootstrap::getObjectManager()->create(
\Magento\Backend\Model\Locale\Resolver::class
);
}
@@ -38,12 +41,12 @@ public function testSetLocaleWithDefaultLocale()
*/
public function testSetLocaleWithBaseInterfaceLocale()
{
- $user = new \Magento\Framework\DataObject();
- $session = \Magento\TestFramework\Helper\Bootstrap::getObjectManager()->get(
+ $user = Bootstrap::getObjectManager()->create(User::class);
+ $session = Bootstrap::getObjectManager()->get(
\Magento\Backend\Model\Auth\Session::class
);
$session->setUser($user);
- \Magento\TestFramework\Helper\Bootstrap::getObjectManager()->get(
+ Bootstrap::getObjectManager()->get(
\Magento\Backend\Model\Auth\Session::class
)->getUser()->setInterfaceLocale(
'fr_FR'
@@ -56,7 +59,7 @@ public function testSetLocaleWithBaseInterfaceLocale()
*/
public function testSetLocaleWithSessionLocale()
{
- \Magento\TestFramework\Helper\Bootstrap::getObjectManager()->get(
+ Bootstrap::getObjectManager()->get(
\Magento\Backend\Model\Session::class
)->setSessionLocale(
'es_ES'
@@ -69,7 +72,7 @@ public function testSetLocaleWithSessionLocale()
*/
public function testSetLocaleWithRequestLocale()
{
- $request = \Magento\TestFramework\Helper\Bootstrap::getObjectManager()
+ $request = Bootstrap::getObjectManager()
->get(\Magento\Framework\App\RequestInterface::class);
$request->setPostValue(['locale' => 'de_DE']);
$this->_checkSetLocale('de_DE');
diff --git a/dev/tests/static/framework/Magento/CodeMessDetector/Rule/Design/SerializationAware.php b/dev/tests/static/framework/Magento/CodeMessDetector/Rule/Design/SerializationAware.php
new file mode 100644
index 0000000000000..e38fba8558bad
--- /dev/null
+++ b/dev/tests/static/framework/Magento/CodeMessDetector/Rule/Design/SerializationAware.php
@@ -0,0 +1,34 @@
+getName() === '__wakeup' || $method->getName() === '__sleep') {
+ $this->addViolation($method, [$method->getName(), $method->getParent()->getFullQualifiedName()]);
+ }
+ }
+}
diff --git a/dev/tests/static/framework/Magento/CodeMessDetector/resources/rulesets/design.xml b/dev/tests/static/framework/Magento/CodeMessDetector/resources/rulesets/design.xml
index 53f2fe4a0084e..5f2461812bab7 100644
--- a/dev/tests/static/framework/Magento/CodeMessDetector/resources/rulesets/design.xml
+++ b/dev/tests/static/framework/Magento/CodeMessDetector/resources/rulesets/design.xml
@@ -60,6 +60,31 @@ class OrderProcessor
$currentOrder = $this->session->get('current_order');
...
}
+}
+ ]]>
+
+
+
+
+
+
+ 2
+
+
+
diff --git a/dev/tests/static/testsuite/Magento/Test/Php/_files/phpmd/ruleset.xml b/dev/tests/static/testsuite/Magento/Test/Php/_files/phpmd/ruleset.xml
index 0e3b5fa3d341c..e65a9a089da9e 100644
--- a/dev/tests/static/testsuite/Magento/Test/Php/_files/phpmd/ruleset.xml
+++ b/dev/tests/static/testsuite/Magento/Test/Php/_files/phpmd/ruleset.xml
@@ -45,5 +45,6 @@
+
diff --git a/lib/internal/Magento/Framework/App/AreaList/Proxy.php b/lib/internal/Magento/Framework/App/AreaList/Proxy.php
index d080e4cabbd87..09115add57190 100644
--- a/lib/internal/Magento/Framework/App/AreaList/Proxy.php
+++ b/lib/internal/Magento/Framework/App/AreaList/Proxy.php
@@ -3,10 +3,11 @@
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
+
namespace Magento\Framework\App\AreaList;
/**
- * Application area list
+ * Proxy for area list.
*/
class Proxy extends \Magento\Framework\App\AreaList implements
\Magento\Framework\ObjectManager\NoninterceptableInterface
@@ -57,12 +58,17 @@ public function __construct(
}
/**
- * Sleep magic method.
+ * Remove links to other objects.
*
* @return array
+ *
+ * @SuppressWarnings(PHPMD.SerializationAware)
+ * @deprecated Do not use PHP serialization.
*/
public function __sleep()
{
+ trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
+
return ['_subject', '_isShared'];
}
@@ -70,9 +76,14 @@ public function __sleep()
* Retrieve ObjectManager from global scope
*
* @return void
+ *
+ * @SuppressWarnings(PHPMD.SerializationAware)
+ * @deprecated Do not use PHP serialization.
*/
public function __wakeup()
{
+ trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
+
$this->_objectManager = \Magento\Framework\App\ObjectManager::getInstance();
}
diff --git a/lib/internal/Magento/Framework/App/Response/Http.php b/lib/internal/Magento/Framework/App/Response/Http.php
index e6fff90837d9d..0c2523faa2ae1 100644
--- a/lib/internal/Magento/Framework/App/Response/Http.php
+++ b/lib/internal/Magento/Framework/App/Response/Http.php
@@ -1,10 +1,9 @@
cookieManager = $objectManager->create(\Magento\Framework\Stdlib\CookieManagerInterface::class);
$this->cookieMetadataFactory = $objectManager->get(
diff --git a/lib/internal/Magento/Framework/App/Route/ConfigInterface/Proxy.php b/lib/internal/Magento/Framework/App/Route/ConfigInterface/Proxy.php
index 09dda9727b937..5e79315238f7d 100644
--- a/lib/internal/Magento/Framework/App/Route/ConfigInterface/Proxy.php
+++ b/lib/internal/Magento/Framework/App/Route/ConfigInterface/Proxy.php
@@ -60,12 +60,17 @@ public function __construct(
}
/**
- * Sleep magic method.
+ * Remove links to other objects.
*
* @return array
+ *
+ * @SuppressWarnings(PHPMD.SerializationAware)
+ * @deprecated Do not use PHP serialization.
*/
public function __sleep()
{
+ trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
+
return ['_subject', '_isShared'];
}
@@ -73,9 +78,14 @@ public function __sleep()
* Retrieve ObjectManager from global scope
*
* @return void
+ *
+ * @SuppressWarnings(PHPMD.SerializationAware)
+ * @deprecated Do not use PHP serialization.
*/
public function __wakeup()
{
+ trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
+
$this->_objectManager = \Magento\Framework\App\ObjectManager::getInstance();
}
diff --git a/lib/internal/Magento/Framework/App/Test/Unit/Response/HttpTest.php b/lib/internal/Magento/Framework/App/Test/Unit/Response/HttpTest.php
index efb35b7321c3b..9be68b379900a 100644
--- a/lib/internal/Magento/Framework/App/Test/Unit/Response/HttpTest.php
+++ b/lib/internal/Magento/Framework/App/Test/Unit/Response/HttpTest.php
@@ -290,45 +290,6 @@ public function testRepresentJson()
$this->assertEquals('json_string', $this->model->getBody('default'));
}
- /**
- *
- * @expectedException \RuntimeException
- * @expectedExceptionMessage ObjectManager isn't initialized
- */
- public function testWakeUpWithException()
- {
- /* ensure that the test preconditions are met */
- $objectManagerClass = new \ReflectionClass(\Magento\Framework\App\ObjectManager::class);
- $instanceProperty = $objectManagerClass->getProperty('_instance');
- $instanceProperty->setAccessible(true);
- $instanceProperty->setValue(null);
-
- $this->model->__wakeup();
- $this->assertNull($this->cookieMetadataFactoryMock);
- $this->assertNull($this->cookieManagerMock);
- }
-
- /**
- * Test for the magic method __wakeup
- *
- * @covers \Magento\Framework\App\Response\Http::__wakeup
- */
- public function testWakeUpWith()
- {
- $objectManagerMock = $this->createMock(\Magento\Framework\App\ObjectManager::class);
- $objectManagerMock->expects($this->once())
- ->method('create')
- ->with(\Magento\Framework\Stdlib\CookieManagerInterface::class)
- ->will($this->returnValue($this->cookieManagerMock));
- $objectManagerMock->expects($this->at(1))
- ->method('get')
- ->with(\Magento\Framework\Stdlib\Cookie\CookieMetadataFactory::class)
- ->will($this->returnValue($this->cookieMetadataFactoryMock));
-
- \Magento\Framework\App\ObjectManager::setInstance($objectManagerMock);
- $this->model->__wakeup();
- }
-
public function testSetXFrameOptions()
{
$value = 'DENY';
diff --git a/lib/internal/Magento/Framework/DB/Select.php b/lib/internal/Magento/Framework/DB/Select.php
index 7399845215bb5..273d940babb91 100644
--- a/lib/internal/Magento/Framework/DB/Select.php
+++ b/lib/internal/Magento/Framework/DB/Select.php
@@ -400,7 +400,7 @@ public function useStraightJoin($flag = true)
/**
* Render STRAIGHT_JOIN clause
*
- * @param string $sql SQL query
+ * @param string $sql SQL query
* @return string
*/
protected function _renderStraightjoin($sql)
@@ -452,7 +452,7 @@ public function orderRand($field = null)
/**
* Render FOR UPDATE clause
*
- * @param string $sql SQL query
+ * @param string $sql SQL query
* @return string
*/
protected function _renderForupdate($sql)
@@ -509,13 +509,18 @@ public function assemble()
}
/**
- * Sleep magic method.
+ * Remove links to other objects.
*
* @return string[]
* @since 100.0.11
+ *
+ * @SuppressWarnings(PHPMD.SerializationAware)
+ * @deprecated Do not use PHP serialization.
*/
public function __sleep()
{
+ trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
+
$properties = array_keys(get_object_vars($this));
$properties = array_diff(
$properties,
@@ -532,9 +537,14 @@ public function __sleep()
*
* @return void
* @since 100.0.11
+ *
+ * @SuppressWarnings(PHPMD.SerializationAware)
+ * @deprecated Do not use PHP serialization.
*/
public function __wakeup()
{
+ trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
+
$objectManager = \Magento\Framework\App\ObjectManager::getInstance();
$this->_adapter = $objectManager->get(ResourceConnection::class)->getConnection();
$this->selectRenderer = $objectManager->get(\Magento\Framework\DB\Select\SelectRenderer::class);
diff --git a/lib/internal/Magento/Framework/DB/Select/RendererProxy.php b/lib/internal/Magento/Framework/DB/Select/RendererProxy.php
index b6d0803759842..e8030a6794a29 100644
--- a/lib/internal/Magento/Framework/DB/Select/RendererProxy.php
+++ b/lib/internal/Magento/Framework/DB/Select/RendererProxy.php
@@ -56,12 +56,17 @@ public function __construct(
}
/**
- * Sleep magic method.
+ * Remove links to other objects.
*
* @return array
+ *
+ * @SuppressWarnings(PHPMD.SerializationAware)
+ * @deprecated Do not use PHP serialization.
*/
public function __sleep()
{
+ trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
+
return ['_subject', '_isShared'];
}
@@ -69,9 +74,14 @@ public function __sleep()
* Retrieve ObjectManager from global scope
*
* @return void
+ *
+ * @SuppressWarnings(PHPMD.SerializationAware)
+ * @deprecated Do not use PHP serialization.
*/
public function __wakeup()
{
+ trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
+
$this->_objectManager = \Magento\Framework\App\ObjectManager::getInstance();
}
diff --git a/lib/internal/Magento/Framework/Data/Collection.php b/lib/internal/Magento/Framework/Data/Collection.php
index 128d3d8e9fd3d..2f3aaad98dfe5 100644
--- a/lib/internal/Magento/Framework/Data/Collection.php
+++ b/lib/internal/Magento/Framework/Data/Collection.php
@@ -889,9 +889,14 @@ public function hasFlag($flag)
*
* @return string[]
* @since 100.0.11
+ *
+ * @SuppressWarnings(PHPMD.SerializationAware)
+ * @deprecated Do not use PHP serialization.
*/
public function __sleep()
{
+ trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
+
$properties = array_keys(get_object_vars($this));
$properties = array_diff(
$properties,
@@ -907,9 +912,14 @@ public function __sleep()
*
* @return void
* @since 100.0.11
+ *
+ * @SuppressWarnings(PHPMD.SerializationAware)
+ * @deprecated Do not use PHP serialization.
*/
public function __wakeup()
{
+ trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
+
$objectManager = \Magento\Framework\App\ObjectManager::getInstance();
$this->_entityFactory = $objectManager->get(EntityFactoryInterface::class);
}
diff --git a/lib/internal/Magento/Framework/Data/Collection/AbstractDb.php b/lib/internal/Magento/Framework/Data/Collection/AbstractDb.php
index 8a22c9a1ce4fc..283d3684cf9fc 100644
--- a/lib/internal/Magento/Framework/Data/Collection/AbstractDb.php
+++ b/lib/internal/Magento/Framework/Data/Collection/AbstractDb.php
@@ -896,9 +896,14 @@ private function getMainTableAlias()
/**
* @inheritdoc
* @since 100.0.11
+ *
+ * @SuppressWarnings(PHPMD.SerializationAware)
+ * @deprecated Do not use PHP serialization.
*/
public function __sleep()
{
+ trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
+
return array_diff(
parent::__sleep(),
['_fetchStrategy', '_logger', '_conn', 'extensionAttributesJoinProcessor']
@@ -908,9 +913,14 @@ public function __sleep()
/**
* @inheritdoc
* @since 100.0.11
+ *
+ * @SuppressWarnings(PHPMD.SerializationAware)
+ * @deprecated Do not use PHP serialization.
*/
public function __wakeup()
{
+ trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
+
parent::__wakeup();
$objectManager = \Magento\Framework\App\ObjectManager::getInstance();
$this->_logger = $objectManager->get(Logger::class);
diff --git a/lib/internal/Magento/Framework/DataObject/Copy/Config/Data/Proxy.php b/lib/internal/Magento/Framework/DataObject/Copy/Config/Data/Proxy.php
index d8bb7a06e5b7d..6486643614d9e 100644
--- a/lib/internal/Magento/Framework/DataObject/Copy/Config/Data/Proxy.php
+++ b/lib/internal/Magento/Framework/DataObject/Copy/Config/Data/Proxy.php
@@ -57,12 +57,17 @@ public function __construct(
}
/**
- * Sleep magic method.
+ * Remove links to other objects.
*
* @return array
+ *
+ * @SuppressWarnings(PHPMD.SerializationAware)
+ * @deprecated Do not use PHP serialization.
*/
public function __sleep()
{
+ trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
+
return ['_subject', '_isShared'];
}
@@ -70,9 +75,14 @@ public function __sleep()
* Retrieve ObjectManager from global scope
*
* @return void
+ *
+ * @SuppressWarnings(PHPMD.SerializationAware)
+ * @deprecated Do not use PHP serialization.
*/
public function __wakeup()
{
+ trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
+
$this->_objectManager = \Magento\Framework\App\ObjectManager::getInstance();
}
diff --git a/lib/internal/Magento/Framework/Interception/Interceptor.php b/lib/internal/Magento/Framework/Interception/Interceptor.php
index 07600c5168181..df1b680234220 100644
--- a/lib/internal/Magento/Framework/Interception/Interceptor.php
+++ b/lib/internal/Magento/Framework/Interception/Interceptor.php
@@ -62,9 +62,14 @@ public function ___callParent($method, array $arguments)
* Calls parent class sleep if defined, otherwise provides own implementation
*
* @return array
+ *
+ * @SuppressWarnings(PHPMD.SerializationAware)
+ * @deprecated Do not use PHP serialization.
*/
public function __sleep()
{
+ trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
+
if (method_exists(get_parent_class($this), '__sleep')) {
$properties = parent::__sleep();
} else {
@@ -78,9 +83,14 @@ public function __sleep()
* Causes Interceptor to be initialized
*
* @return void
+ *
+ * @SuppressWarnings(PHPMD.SerializationAware)
+ * @deprecated Do not use PHP serialization.
*/
public function __wakeup()
{
+ trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
+
if (method_exists(get_parent_class($this), '__wakeup')) {
parent::__wakeup();
}
diff --git a/lib/internal/Magento/Framework/Model/AbstractExtensibleModel.php b/lib/internal/Magento/Framework/Model/AbstractExtensibleModel.php
index 949e002a14208..f80c05a959046 100644
--- a/lib/internal/Magento/Framework/Model/AbstractExtensibleModel.php
+++ b/lib/internal/Magento/Framework/Model/AbstractExtensibleModel.php
@@ -362,17 +362,27 @@ private function populateExtensionAttributes(array $extensionAttributesData = []
/**
* @inheritdoc
+ *
+ * @SuppressWarnings(PHPMD.SerializationAware)
+ * @deprecated Do not use PHP serialization.
*/
public function __sleep()
{
+ trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
+
return array_diff(parent::__sleep(), ['extensionAttributesFactory', 'customAttributeFactory']);
}
/**
* @inheritdoc
+ *
+ * @SuppressWarnings(PHPMD.SerializationAware)
+ * @deprecated Do not use PHP serialization.
*/
public function __wakeup()
{
+ trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
+
parent::__wakeup();
$objectManager = \Magento\Framework\App\ObjectManager::getInstance();
$this->extensionAttributesFactory = $objectManager->get(ExtensionAttributesFactory::class);
diff --git a/lib/internal/Magento/Framework/Model/AbstractModel.php b/lib/internal/Magento/Framework/Model/AbstractModel.php
index 8018c6176390f..91b1ff338250c 100644
--- a/lib/internal/Magento/Framework/Model/AbstractModel.php
+++ b/lib/internal/Magento/Framework/Model/AbstractModel.php
@@ -220,9 +220,14 @@ protected function _init($resourceModel)
* Remove unneeded properties from serialization
*
* @return string[]
+ *
+ * @SuppressWarnings(PHPMD.SerializationAware)
+ * @deprecated Do not use PHP serialization.
*/
public function __sleep()
{
+ trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
+
$properties = array_keys(get_object_vars($this));
$properties = array_diff(
$properties,
@@ -244,9 +249,14 @@ public function __sleep()
* Init not serializable fields
*
* @return void
+ *
+ * @SuppressWarnings(PHPMD.SerializationAware)
+ * @deprecated Do not use PHP serialization.
*/
public function __wakeup()
{
+ trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
+
$objectManager = \Magento\Framework\App\ObjectManager::getInstance();
$this->_registry = $objectManager->get(\Magento\Framework\Registry::class);
diff --git a/lib/internal/Magento/Framework/Model/ResourceModel/Db/AbstractDb.php b/lib/internal/Magento/Framework/Model/ResourceModel/Db/AbstractDb.php
index fc0edf931fa9c..cf37296a7574e 100644
--- a/lib/internal/Magento/Framework/Model/ResourceModel/Db/AbstractDb.php
+++ b/lib/internal/Magento/Framework/Model/ResourceModel/Db/AbstractDb.php
@@ -157,9 +157,14 @@ public function __construct(
* Provide variables to serialize
*
* @return array
+ *
+ * @SuppressWarnings(PHPMD.SerializationAware)
+ * @deprecated Do not use PHP serialization.
*/
public function __sleep()
{
+ trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
+
$properties = array_keys(get_object_vars($this));
$properties = array_diff($properties, ['_resources', '_connections']);
return $properties;
@@ -169,9 +174,14 @@ public function __sleep()
* Restore global dependencies
*
* @return void
+ *
+ * @SuppressWarnings(PHPMD.SerializationAware)
+ * @deprecated Do not use PHP serialization.
*/
public function __wakeup()
{
+ trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
+
$this->_resources = \Magento\Framework\App\ObjectManager::getInstance()
->get(\Magento\Framework\App\ResourceConnection::class);
}
@@ -220,9 +230,10 @@ protected function _setResource($connections, $tables = null)
}
/**
- * Set main entity table name and primary key field name
+ * Main table setter.
*
- * If field name is omitted {table_name}_id will be used
+ * Set main entity table name and primary key field name.
+ * If field name is omitted {table_name}_id will be used.
*
* @param string $mainTable
* @param string|null $idFieldName
@@ -255,7 +266,10 @@ public function getIdFieldName()
}
/**
- * Returns main table name - extracted from "module/table" style and validated by db adapter
+ * Main table getter.
+ *
+ * Returns main table name - extracted from "module/table" style and
+ * validated by db adapter.
*
* @throws LocalizedException
* @return string
@@ -544,7 +558,7 @@ protected function _prepareDataForSave(\Magento\Framework\Model\AbstractModel $o
}
/**
- * Check that model data fields that can be saved has really changed comparing with origData
+ * Check that model data fields that can be saved has really changed comparing with origData.
*
* @param \Magento\Framework\Model\AbstractModel $object
* @return bool
diff --git a/lib/internal/Magento/Framework/Model/ResourceModel/Db/Collection/AbstractCollection.php b/lib/internal/Magento/Framework/Model/ResourceModel/Db/Collection/AbstractCollection.php
index cba5f133f53c8..1f7c15fe4a5bd 100644
--- a/lib/internal/Magento/Framework/Model/ResourceModel/Db/Collection/AbstractCollection.php
+++ b/lib/internal/Magento/Framework/Model/ResourceModel/Db/Collection/AbstractCollection.php
@@ -607,9 +607,14 @@ public function save()
/**
* @inheritdoc
* @since 100.0.11
+ *
+ * @SuppressWarnings(PHPMD.SerializationAware)
+ * @deprecated Do not use PHP serialization.
*/
public function __sleep()
{
+ trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
+
return array_diff(
parent::__sleep(),
['_resource', '_eventManager']
@@ -619,9 +624,14 @@ public function __sleep()
/**
* @inheritdoc
* @since 100.0.11
+ *
+ * @SuppressWarnings(PHPMD.SerializationAware)
+ * @deprecated Do not use PHP serialization.
*/
public function __wakeup()
{
+ trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
+
parent::__wakeup();
$objectManager = \Magento\Framework\App\ObjectManager::getInstance();
$this->_eventManager = $objectManager->get(\Magento\Framework\Event\ManagerInterface::class);
diff --git a/lib/internal/Magento/Framework/Mview/Config/Data/Proxy.php b/lib/internal/Magento/Framework/Mview/Config/Data/Proxy.php
index 470ba16bdd40c..cc7d831dc5e61 100644
--- a/lib/internal/Magento/Framework/Mview/Config/Data/Proxy.php
+++ b/lib/internal/Magento/Framework/Mview/Config/Data/Proxy.php
@@ -55,12 +55,17 @@ public function __construct(
}
/**
- * Sleep magic method.
+ * Remove links to objects.
*
* @return array
+ *
+ * @SuppressWarnings(PHPMD.SerializationAware)
+ * @deprecated Do not use PHP serialization.
*/
public function __sleep()
{
+ trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
+
return ['subject', 'isShared'];
}
@@ -68,9 +73,14 @@ public function __sleep()
* Retrieve ObjectManager from global scope
*
* @return void
+ *
+ * @SuppressWarnings(PHPMD.SerializationAware)
+ * @deprecated Do not use PHP serialization.
*/
public function __wakeup()
{
+ trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
+
$this->objectManager = \Magento\Framework\App\ObjectManager::getInstance();
}
diff --git a/lib/internal/Magento/Framework/Translate/Inline/Proxy.php b/lib/internal/Magento/Framework/Translate/Inline/Proxy.php
index d2b0468bebde9..add5c0dee66ed 100644
--- a/lib/internal/Magento/Framework/Translate/Inline/Proxy.php
+++ b/lib/internal/Magento/Framework/Translate/Inline/Proxy.php
@@ -55,12 +55,17 @@ public function __construct(
}
/**
- * Sleep magic method.
+ * Remove links to other objects.
*
* @return array
+ *
+ * @SuppressWarnings(PHPMD.SerializationAware)
+ * @deprecated Do not use PHP serialization.
*/
public function __sleep()
{
+ trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
+
return ['subject', 'isShared'];
}
@@ -68,9 +73,14 @@ public function __sleep()
* Retrieve ObjectManager from global scope
*
* @return void
+ *
+ * @SuppressWarnings(PHPMD.SerializationAware)
+ * @deprecated Do not use PHP serialization.
*/
public function __wakeup()
{
+ trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
+
$this->objectManager = \Magento\Framework\App\ObjectManager::getInstance();
}
diff --git a/lib/internal/Magento/Framework/View/Layout/Proxy.php b/lib/internal/Magento/Framework/View/Layout/Proxy.php
index ec5ce761154ed..d4897bb5cd101 100644
--- a/lib/internal/Magento/Framework/View/Layout/Proxy.php
+++ b/lib/internal/Magento/Framework/View/Layout/Proxy.php
@@ -57,12 +57,17 @@ public function __construct(
}
/**
- * Sleep magic method.
+ * Remove links to objects.
*
* @return array
+ *
+ * @SuppressWarnings(PHPMD.SerializationAware)
+ * @deprecated Do not use PHP serialization.
*/
public function __sleep()
{
+ trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
+
return ['_subject', '_isShared'];
}
@@ -70,9 +75,14 @@ public function __sleep()
* Retrieve ObjectManager from global scope
*
* @return void
+ *
+ * @SuppressWarnings(PHPMD.SerializationAware)
+ * @deprecated Do not use PHP serialization.
*/
public function __wakeup()
{
+ trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
+
$this->_objectManager = \Magento\Framework\App\ObjectManager::getInstance();
}
From 660c9891c7bbfbbdaf64e76b205c73546a57b6e5 Mon Sep 17 00:00:00 2001
From: Vinai Kopp
Date: Sun, 21 Jul 2019 12:52:59 -0400
Subject: [PATCH 043/937] Fix loss of page_cache cache_dir setting from di.xml
Additionally fixed follow up issues:
* Clean category pages from the built in page cache when categories are moved
* Improve test isolation for GraphQl controller tests
* Add tests to check caching queries actually works
---
.../Observer/FlushCategoryPagesCache.php | 60 +++++
.../Magento/Catalog/etc/adminhtml/events.xml | 3 +
.../Framework/App/Cache/Frontend/PoolTest.php | 55 +++++
.../Controller/AbstractGraphqlCacheTest.php | 136 +++++++++---
.../CategoriesWithProductsCacheTest.php | 35 +--
.../Controller/Catalog/CategoryCacheTest.php | 22 +-
.../DeepNestedCategoriesAndProductsTest.php | 21 +-
.../Controller/Catalog/ProductsCacheTest.php | 81 +++++--
.../Controller/Cms/BlockCacheTest.php | 91 +++-----
.../Controller/Cms/CmsPageCacheTest.php | 175 ++++++---------
.../AllEntitiesUrlResolverCacheTest.php | 206 +++++++++---------
.../Framework/App/Cache/Frontend/Pool.php | 21 +-
.../App/Test/Unit/Cache/Frontend/PoolTest.php | 34 ++-
13 files changed, 537 insertions(+), 403 deletions(-)
create mode 100644 app/code/Magento/Catalog/Observer/FlushCategoryPagesCache.php
create mode 100644 dev/tests/integration/testsuite/Magento/Framework/App/Cache/Frontend/PoolTest.php
diff --git a/app/code/Magento/Catalog/Observer/FlushCategoryPagesCache.php b/app/code/Magento/Catalog/Observer/FlushCategoryPagesCache.php
new file mode 100644
index 0000000000000..751fa3fdfad84
--- /dev/null
+++ b/app/code/Magento/Catalog/Observer/FlushCategoryPagesCache.php
@@ -0,0 +1,60 @@
+cacheConfig = $cacheConfig;
+ $this->pageCache = $pageCache;
+ }
+
+ /**
+ * Clean the category page cache if built in cache page cache is used.
+ *
+ * The built in cache requires cleaning all pages that contain the top category navigation menu when a
+ * category is moved. This is because the built in cache does not support ESI blocks.
+ *
+ * @param Event $event
+ * @SuppressWarnings(PHPMD.UnusedFormalParameter)
+ */
+ public function execute(Event $event)
+ {
+ if ($this->cacheConfig->getType() == CacheConfig::BUILT_IN && $this->cacheConfig->isEnabled()) {
+ $this->pageCache->clean(\Zend_Cache::CLEANING_MODE_MATCHING_ANY_TAG, [Category::CACHE_TAG]);
+ }
+ }
+}
diff --git a/app/code/Magento/Catalog/etc/adminhtml/events.xml b/app/code/Magento/Catalog/etc/adminhtml/events.xml
index ad83f5898237a..ab1a8348d2904 100644
--- a/app/code/Magento/Catalog/etc/adminhtml/events.xml
+++ b/app/code/Magento/Catalog/etc/adminhtml/events.xml
@@ -12,4 +12,7 @@
+
+
+
diff --git a/dev/tests/integration/testsuite/Magento/Framework/App/Cache/Frontend/PoolTest.php b/dev/tests/integration/testsuite/Magento/Framework/App/Cache/Frontend/PoolTest.php
new file mode 100644
index 0000000000000..3324da008a84a
--- /dev/null
+++ b/dev/tests/integration/testsuite/Magento/Framework/App/Cache/Frontend/PoolTest.php
@@ -0,0 +1,55 @@
+get(ObjectManagerConfig::class);
+ $argumentConfig = $diConfig->getArguments(\Magento\Framework\App\Cache\Frontend\Pool::class);
+
+ $pageCacheDir = $argumentConfig['frontendSettings']['page_cache']['backend_options']['cache_dir'] ?? null;
+ $defaultCacheDir = $argumentConfig['frontendSettings']['default']['backend_options']['cache_dir'] ?? null;
+
+ $noPageCacheMessage = "No default page_cache directory set in di.xml: \n" . var_export($argumentConfig, true);
+ $this->assertNotEmpty($pageCacheDir, $noPageCacheMessage);
+
+ $sameCacheDirMessage = 'The page_cache and default cache storages share the same cache directory';
+ $this->assertNotSame($pageCacheDir, $defaultCacheDir, $sameCacheDirMessage);
+ }
+
+ /**
+ * @covers \Magento\Framework\App\Cache\Frontend\Pool::_getCacheSettings
+ * @depends testPageCacheNotSameAsDefaultCacheDirectory
+ */
+ public function testCleaningDefaultCachePreservesPageCache()
+ {
+ $testData = 'test data';
+ $testKey = 'test-key';
+
+ /** @var \Magento\Framework\App\Cache\Frontend\Pool $cacheFrontendPool */
+ $cacheFrontendPool = ObjectManager::getInstance()->get(\Magento\Framework\App\Cache\Frontend\Pool::class);
+
+ $pageCache = $cacheFrontendPool->get('page_cache');
+ $pageCache->save($testData, $testKey);
+
+ $defaultCache = $cacheFrontendPool->get('default');
+ $defaultCache->clean();
+
+ $this->assertSame($testData, $pageCache->load($testKey));
+ }
+}
diff --git a/dev/tests/integration/testsuite/Magento/GraphQlCache/Controller/AbstractGraphqlCacheTest.php b/dev/tests/integration/testsuite/Magento/GraphQlCache/Controller/AbstractGraphqlCacheTest.php
index f25144c308c68..862a924f65793 100644
--- a/dev/tests/integration/testsuite/Magento/GraphQlCache/Controller/AbstractGraphqlCacheTest.php
+++ b/dev/tests/integration/testsuite/Magento/GraphQlCache/Controller/AbstractGraphqlCacheTest.php
@@ -7,9 +7,15 @@
namespace Magento\GraphQlCache\Controller;
-use PHPUnit\Framework\TestCase;
-use Magento\TestFramework\ObjectManager;
+use Magento\Framework\App\Request\Http as HttpRequest;
+use Magento\Framework\App\Response\HttpInterface as HttpResponse;
+use Magento\Framework\Registry;
+use Magento\GraphQl\Controller\GraphQl as GraphQlController;
+use Magento\GraphQlCache\Model\CacheableQuery;
+use Magento\PageCache\Model\Cache\Type as PageCache;
use Magento\TestFramework\Helper\Bootstrap;
+use Magento\TestFramework\ObjectManager;
+use PHPUnit\Framework\TestCase;
/**
* Abstract test class for Graphql cache tests
@@ -21,40 +27,114 @@ abstract class AbstractGraphqlCacheTest extends TestCase
*/
protected $objectManager;
- /**
- * @inheritdoc
- */
protected function setUp(): void
{
$this->objectManager = Bootstrap::getObjectManager();
+ $this->enablePageCachePlugin();
+ $this->enableCachebleQueryTestProxy();
+ }
+
+ protected function tearDown(): void
+ {
+ $this->disableCacheableQueryTestProxy();
+ $this->disablePageCachePlugin();
+ $this->flushPageCache();
+ }
+
+ protected function enablePageCachePlugin(): void
+ {
+ /** @var $registry Registry */
+ $registry = $this->objectManager->get(Registry::class);
+ $registry->register('use_page_cache_plugin', true, true);
+ }
+
+ protected function disablePageCachePlugin(): void
+ {
+ /** @var $registry Registry */
+ $registry = $this->objectManager->get(Registry::class);
+ $registry->unregister('use_page_cache_plugin');
+ }
+
+ protected function flushPageCache(): void
+ {
+ /** @var PageCache $fullPageCache */
+ $fullPageCache = $this->objectManager->get(PageCache::class);
+ $fullPageCache->clean();
}
/**
- * Prepare a query and return a request to be used in the same test end to end
+ * Regarding the SuppressWarnings annotation below: the nested class below triggers a false rule match.
*
- * @param string $query
- * @return \Magento\Framework\App\Request\Http
+ * @SuppressWarnings(PHPMD.UnusedLocalVariable)
*/
- protected function prepareRequest(string $query) : \Magento\Framework\App\Request\Http
- {
- $cacheableQuery = $this->objectManager->get(\Magento\GraphQlCache\Model\CacheableQuery::class);
- $cacheableQueryReflection = new \ReflectionProperty(
- $cacheableQuery,
- 'cacheTags'
- );
- $cacheableQueryReflection->setAccessible(true);
- $cacheableQueryReflection->setValue($cacheableQuery, []);
-
- /** @var \Magento\Framework\UrlInterface $urlInterface */
- $urlInterface = $this->objectManager->create(\Magento\Framework\UrlInterface::class);
- //set unique URL
- $urlInterface->setQueryParam('query', $query);
-
- $request = $this->objectManager->get(\Magento\Framework\App\Request\Http::class);
- $request->setUri($urlInterface->getUrl('graphql'));
+ private function enableCachebleQueryTestProxy(): void
+ {
+ $cacheableQueryProxy = new class($this->objectManager) extends CacheableQuery {
+ /** @var CacheableQuery */
+ private $delegate;
+
+ public function __construct(ObjectManager $objectManager)
+ {
+ $this->reset($objectManager);
+ }
+
+ public function reset(ObjectManager $objectManager): void
+ {
+ $this->delegate = $objectManager->create(CacheableQuery::class);
+ }
+
+ public function getCacheTags(): array
+ {
+ return $this->delegate->getCacheTags();
+ }
+
+ public function addCacheTags(array $cacheTags): void
+ {
+ $this->delegate->addCacheTags($cacheTags);
+ }
+
+ public function isCacheable(): bool
+ {
+ return $this->delegate->isCacheable();
+ }
+
+ public function setCacheValidity(bool $cacheable): void
+ {
+ $this->delegate->setCacheValidity($cacheable);
+ }
+
+ public function shouldPopulateCacheHeadersWithTags(): bool
+ {
+ return $this->delegate->shouldPopulateCacheHeadersWithTags();
+ }
+ };
+ $this->objectManager->addSharedInstance($cacheableQueryProxy, CacheableQuery::class);
+ }
+
+ private function disableCacheableQueryTestProxy(): void
+ {
+ $this->resetQueryCacheTags();
+ $this->objectManager->removeSharedInstance(CacheableQuery::class);
+ }
+
+ protected function resetQueryCacheTags(): void
+ {
+ $this->objectManager->get(CacheableQuery::class)->reset($this->objectManager);
+ }
+
+ protected function dispatchGraphQlGETRequest(array $queryParams): HttpResponse
+ {
+ $this->resetQueryCacheTags();
+
+ /** @var HttpRequest $request */
+ $request = $this->objectManager->get(HttpRequest::class);
+ $request->setPathInfo('/graphql');
$request->setMethod('GET');
- //set the actual GET query
- $request->setQueryValue('query', $query);
- return $request;
+ $request->setParams($queryParams);
+
+ // required for \Magento\Framework\App\PageCache\Identifier to generate the correct cache key
+ $request->setUri(implode('?', [$request->getPathInfo(), http_build_query($queryParams)]));
+
+ return $this->objectManager->create(GraphQlController::class)->dispatch($request);
}
}
diff --git a/dev/tests/integration/testsuite/Magento/GraphQlCache/Controller/Catalog/CategoriesWithProductsCacheTest.php b/dev/tests/integration/testsuite/Magento/GraphQlCache/Controller/Catalog/CategoriesWithProductsCacheTest.php
index fd97399992c1c..287353bbd2b80 100644
--- a/dev/tests/integration/testsuite/Magento/GraphQlCache/Controller/Catalog/CategoriesWithProductsCacheTest.php
+++ b/dev/tests/integration/testsuite/Magento/GraphQlCache/Controller/Catalog/CategoriesWithProductsCacheTest.php
@@ -9,8 +9,6 @@
use Magento\Catalog\Api\Data\ProductInterface;
use Magento\Catalog\Api\ProductRepositoryInterface;
-use Magento\Framework\App\Request\Http;
-use Magento\GraphQl\Controller\GraphQl;
use Magento\GraphQlCache\Controller\AbstractGraphqlCacheTest;
/**
@@ -22,31 +20,12 @@
*/
class CategoriesWithProductsCacheTest extends AbstractGraphqlCacheTest
{
- /**
- * @var GraphQl
- */
- private $graphqlController;
-
- /**
- * @var Http
- */
- private $request;
-
- /**
- * @inheritdoc
- */
- protected function setUp(): void
- {
- parent::setUp();
- $this->graphqlController = $this->objectManager->get(\Magento\GraphQl\Controller\GraphQl::class);
- $this->request = $this->objectManager->create(Http::class);
- }
/**
* Test cache tags and debug header for category with products querying for products and category
*
* @magentoDataFixture Magento/Catalog/_files/category_product.php
*/
- public function testToCheckRequestCacheTagsForCategoryWithProducts(): void
+ public function testRequestCacheTagsForCategoryWithProducts(): void
{
/** @var ProductRepositoryInterface $productRepository */
$productRepository = $this->objectManager->get(ProductRepositoryInterface::class);
@@ -91,17 +70,7 @@ public function testToCheckRequestCacheTagsForCategoryWithProducts(): void
'operationName' => 'GetCategoryWithProducts'
];
- /** @var \Magento\Framework\UrlInterface $urlInterface */
- $urlInterface = $this->objectManager->create(\Magento\Framework\UrlInterface::class);
- //set unique URL
- $urlInterface->setQueryParam('query', $queryParams['query']);
- $urlInterface->setQueryParam('variables', $queryParams['variables']);
- $urlInterface->setQueryParam('operationName', $queryParams['operationName']);
- $this->request->setUri($urlInterface->getUrl('graphql'));
- $this->request->setPathInfo('/graphql');
- $this->request->setMethod('GET');
- $this->request->setParams($queryParams);
- $response = $this->graphqlController->dispatch($this->request);
+ $response = $this->dispatchGraphQlGETRequest($queryParams);
$this->assertEquals('MISS', $response->getHeader('X-Magento-Cache-Debug')->getFieldValue());
$expectedCacheTags = ['cat_c','cat_c_' . $categoryId,'cat_p','cat_p_' . $product->getId(),'FPC'];
$actualCacheTags = explode(',', $response->getHeader('X-Magento-Tags')->getFieldValue());
diff --git a/dev/tests/integration/testsuite/Magento/GraphQlCache/Controller/Catalog/CategoryCacheTest.php b/dev/tests/integration/testsuite/Magento/GraphQlCache/Controller/Catalog/CategoryCacheTest.php
index be920fb200ff3..90bdc4f75825a 100644
--- a/dev/tests/integration/testsuite/Magento/GraphQlCache/Controller/Catalog/CategoryCacheTest.php
+++ b/dev/tests/integration/testsuite/Magento/GraphQlCache/Controller/Catalog/CategoryCacheTest.php
@@ -7,8 +7,6 @@
namespace Magento\GraphQlCache\Controller\Catalog;
-use Magento\Framework\App\Request\Http;
-use Magento\GraphQl\Controller\GraphQl;
use Magento\GraphQlCache\Controller\AbstractGraphqlCacheTest;
/**
@@ -20,25 +18,12 @@
*/
class CategoryCacheTest extends AbstractGraphqlCacheTest
{
- /**
- * @var GraphQl
- */
- private $graphqlController;
-
- /**
- * @inheritdoc
- */
- protected function setUp(): void
- {
- parent::setUp();
- $this->graphqlController = $this->objectManager->get(\Magento\GraphQl\Controller\GraphQl::class);
- }
/**
* Test cache tags and debug header for category and querying only for category
*
* @magentoDataFixture Magento/Catalog/_files/category_product.php
*/
- public function testToCheckRequestCacheTagsForForCategory(): void
+ public function testRequestCacheTagsForCategory(): void
{
$categoryId ='333';
$query
@@ -53,11 +38,10 @@ public function testToCheckRequestCacheTagsForForCategory(): void
}
}
QUERY;
- $request = $this->prepareRequest($query);
- $response = $this->graphqlController->dispatch($request);
+ $response = $this->dispatchGraphQlGETRequest(['query' => $query]);
$this->assertEquals('MISS', $response->getHeader('X-Magento-Cache-Debug')->getFieldValue());
$actualCacheTags = explode(',', $response->getHeader('X-Magento-Tags')->getFieldValue());
- $expectedCacheTags = ['cat_c','cat_c_' . $categoryId,'FPC'];
+ $expectedCacheTags = ['cat_c','cat_c_' . $categoryId, 'FPC'];
$this->assertEquals($expectedCacheTags, $actualCacheTags);
}
}
diff --git a/dev/tests/integration/testsuite/Magento/GraphQlCache/Controller/Catalog/DeepNestedCategoriesAndProductsTest.php b/dev/tests/integration/testsuite/Magento/GraphQlCache/Controller/Catalog/DeepNestedCategoriesAndProductsTest.php
index 746b37a88770a..e2f16e06d8b94 100644
--- a/dev/tests/integration/testsuite/Magento/GraphQlCache/Controller/Catalog/DeepNestedCategoriesAndProductsTest.php
+++ b/dev/tests/integration/testsuite/Magento/GraphQlCache/Controller/Catalog/DeepNestedCategoriesAndProductsTest.php
@@ -9,7 +9,6 @@
use Magento\Catalog\Api\ProductRepositoryInterface;
use Magento\Catalog\Api\CategoryRepositoryInterface;
-use Magento\Framework\App\Request\Http;
use Magento\GraphQlCache\Controller\AbstractGraphqlCacheTest;
/**
@@ -20,24 +19,11 @@
*/
class DeepNestedCategoriesAndProductsTest extends AbstractGraphqlCacheTest
{
- /** @var \Magento\GraphQl\Controller\GraphQl */
- private $graphql;
-
- /**
- * @inheritdoc
- */
- protected function setUp(): void
- {
- parent::setUp();
- $this->graphql = $this->objectManager->get(\Magento\GraphQl\Controller\GraphQl::class);
- }
-
/**
* Test cache tags and debug header for deep nested queries involving category and products
*
* @magentoCache all enabled
* @magentoDataFixture Magento/Catalog/_files/product_in_multiple_categories.php
- *
*/
public function testDispatchForCacheHeadersOnDeepNestedQueries(): void
{
@@ -102,14 +88,13 @@ public function testDispatchForCacheHeadersOnDeepNestedQueries(): void
$uniqueCategoryIds = array_unique($resolvedCategoryIds);
$expectedCacheTags = ['cat_c', 'cat_p', 'FPC'];
foreach ($uniqueProductIds as $uniqueProductId) {
- $expectedCacheTags = array_merge($expectedCacheTags, ['cat_p_'.$uniqueProductId]);
+ $expectedCacheTags = array_merge($expectedCacheTags, ['cat_p_' . $uniqueProductId]);
}
foreach ($uniqueCategoryIds as $uniqueCategoryId) {
- $expectedCacheTags = array_merge($expectedCacheTags, ['cat_c_'.$uniqueCategoryId]);
+ $expectedCacheTags = array_merge($expectedCacheTags, ['cat_c_' . $uniqueCategoryId]);
}
- $request = $this->prepareRequest($query);
- $response = $this->graphql->dispatch($request);
+ $response = $this->dispatchGraphQlGETRequest(['query' => $query]);
$this->assertEquals('MISS', $response->getHeader('X-Magento-Cache-Debug')->getFieldValue());
$actualCacheTags = explode(',', $response->getHeader('X-Magento-Tags')->getFieldValue());
$this->assertEmpty(
diff --git a/dev/tests/integration/testsuite/Magento/GraphQlCache/Controller/Catalog/ProductsCacheTest.php b/dev/tests/integration/testsuite/Magento/GraphQlCache/Controller/Catalog/ProductsCacheTest.php
index 335067f8408df..038a8c7255815 100644
--- a/dev/tests/integration/testsuite/Magento/GraphQlCache/Controller/Catalog/ProductsCacheTest.php
+++ b/dev/tests/integration/testsuite/Magento/GraphQlCache/Controller/Catalog/ProductsCacheTest.php
@@ -8,7 +8,6 @@
namespace Magento\GraphQlCache\Controller\Catalog;
use Magento\Catalog\Api\ProductRepositoryInterface;
-use Magento\GraphQl\Controller\GraphQl;
use Magento\GraphQlCache\Controller\AbstractGraphqlCacheTest;
/**
@@ -20,26 +19,12 @@
*/
class ProductsCacheTest extends AbstractGraphqlCacheTest
{
- /**
- * @var GraphQl
- */
- private $graphqlController;
-
- /**
- * @inheritdoc
- */
- protected function setUp(): void
- {
- parent::setUp();
- $this->graphqlController = $this->objectManager->get(\Magento\GraphQl\Controller\GraphQl::class);
- }
-
/**
* Test request is dispatched and response is checked for debug headers and cache tags
*
* @magentoDataFixture Magento/Catalog/_files/product_simple_with_url_key.php
*/
- public function testToCheckRequestCacheTagsForProducts(): void
+ public function testRequestCacheTagsForProducts(): void
{
/** @var ProductRepositoryInterface $productRepository */
$productRepository = $this->objectManager->get(ProductRepositoryInterface::class);
@@ -63,8 +48,7 @@ public function testToCheckRequestCacheTagsForProducts(): void
}
QUERY;
- $request = $this->prepareRequest($query);
- $response = $this->graphqlController->dispatch($request);
+ $response = $this->dispatchGraphQlGETRequest(['query' => $query]);
$this->assertEquals('MISS', $response->getHeader('X-Magento-Cache-Debug')->getFieldValue());
$actualCacheTags = explode(',', $response->getHeader('X-Magento-Tags')->getFieldValue());
$expectedCacheTags = ['cat_p', 'cat_p_' . $product->getId(), 'FPC'];
@@ -74,7 +58,7 @@ public function testToCheckRequestCacheTagsForProducts(): void
/**
* Test request is checked for debug headers and no cache tags for not existing product
*/
- public function testToCheckRequestNoTagsForProducts(): void
+ public function testRequestNoTagsForNonExistingProducts(): void
{
$query
= <<prepareRequest($query);
- $response = $this->graphqlController->dispatch($request);
+ $response = $this->dispatchGraphQlGETRequest(['query' => $query]);
$this->assertEquals('MISS', $response->getHeader('X-Magento-Cache-Debug')->getFieldValue());
$actualCacheTags = explode(',', $response->getHeader('X-Magento-Tags')->getFieldValue());
$expectedCacheTags = ['FPC'];
$this->assertEquals($expectedCacheTags, $actualCacheTags);
}
+
+ /**
+ * @magentoDataFixture Magento/Catalog/_files/product_simple_with_url_key.php
+ */
+ public function testConsecutiveRequestsAreServedFromThePageCache(): void
+ {
+ $query
+ = <<dispatchGraphQlGETRequest(['query' => $query]);
+ $response2 = $this->dispatchGraphQlGETRequest(['query' => $query]);
+
+ $this->assertEquals('MISS', $response1->getHeader('X-Magento-Cache-Debug')->getFieldValue());
+ $this->assertEquals('HIT', $response2->getHeader('X-Magento-Cache-Debug')->getFieldValue());
+ }
+
+ /**
+ * @magentoDataFixture Magento/Catalog/_files/product_simple_with_url_key.php
+ */
+ public function testDifferentProductsRequestsUseDifferentPageCacheRecords(): void
+ {
+ $queryTemplate
+ = <<dispatchGraphQlGETRequest(['query' => sprintf($queryTemplate, 'simple1')]);
+ $responseProduct2 = $this->dispatchGraphQlGETRequest(['query' => sprintf($queryTemplate, 'simple2')]);
+
+ $this->assertEquals('MISS', $responseProduct1->getHeader('X-Magento-Cache-Debug')->getFieldValue());
+ $this->assertEquals('MISS', $responseProduct2->getHeader('X-Magento-Cache-Debug')->getFieldValue());
+ }
}
diff --git a/dev/tests/integration/testsuite/Magento/GraphQlCache/Controller/Cms/BlockCacheTest.php b/dev/tests/integration/testsuite/Magento/GraphQlCache/Controller/Cms/BlockCacheTest.php
index c9dca2a5a8372..bcc7c623eb18a 100644
--- a/dev/tests/integration/testsuite/Magento/GraphQlCache/Controller/Cms/BlockCacheTest.php
+++ b/dev/tests/integration/testsuite/Magento/GraphQlCache/Controller/Cms/BlockCacheTest.php
@@ -7,8 +7,9 @@
namespace Magento\GraphQlCache\Controller\Cms;
+use Magento\Cms\Api\Data\BlockInterface;
use Magento\Cms\Model\BlockRepository;
-use Magento\GraphQl\Controller\GraphQl;
+use Magento\Framework\App\Response\HttpInterface as HttpResponse;
use Magento\GraphQlCache\Controller\AbstractGraphqlCacheTest;
/**
@@ -20,23 +21,27 @@
*/
class BlockCacheTest extends AbstractGraphqlCacheTest
{
- /**
- * @var GraphQl
- */
- private $graphqlController;
+ private function assertPageCacheMissWithTagsForCmsBlock(HttpResponse $response, BlockInterface $block): void
+ {
+ $this->assertEquals('MISS', $response->getHeader('X-Magento-Cache-Debug')->getFieldValue());
+ $this->assertCmsBlockCacheTags($response, $block);
+ }
- /**
- * @inheritdoc
- */
- protected function setUp(): void
+ private function assertPageCacheHitWithTagsForCmsBlock(HttpResponse $response, BlockInterface $block): void
+ {
+ $this->assertEquals('HIT', $response->getHeader('X-Magento-Cache-Debug')->getFieldValue());
+ $this->assertCmsBlockCacheTags($response, $block);
+ }
+
+ private function assertCmsBlockCacheTags(HttpResponse $response, BlockInterface $block): void
{
- parent::setUp();
- $this->graphqlController = $this->objectManager->get(\Magento\GraphQl\Controller\GraphQl::class);
+ $expectedCacheTags = ['cms_b', 'cms_b_' . $block->getId(), 'cms_b_' . $block->getIdentifier(), 'FPC'];
+ $rawActualCacheTags = $response->getHeader('X-Magento-Tags')->getFieldValue();
+ $actualCacheTags = explode(',', $rawActualCacheTags);
+ $this->assertEquals($expectedCacheTags, $actualCacheTags);
}
/**
- * Test that the correct cache tags get added to request for cmsBlocks
- *
* @magentoDataFixture Magento/Cms/_files/block.php
* @magentoDataFixture Magento/Cms/_files/blocks.php
*/
@@ -46,9 +51,9 @@ public function testCmsBlocksRequestHasCorrectTags(): void
$blockRepository = $this->objectManager->get(BlockRepository::class);
$block1Identifier = 'fixture_block';
- $block1 = $blockRepository->getById($block1Identifier);
+ $block1 = $blockRepository->getById($block1Identifier);
$block2Identifier = 'enabled_block';
- $block2 = $blockRepository->getById($block2Identifier);
+ $block2 = $blockRepository->getById($block2Identifier);
$queryBlock1
= <<prepareRequest($queryBlock1);
- $response = $this->graphqlController->dispatch($request);
- $this->assertEquals('MISS', $response->getHeader('X-Magento-Cache-Debug')->getFieldValue());
- $expectedCacheTags = ['cms_b', 'cms_b_' . $block1->getId(), 'cms_b_' . $block1->getIdentifier(), 'FPC'];
- $rawActualCacheTags = $response->getHeader('X-Magento-Tags')->getFieldValue();
- $actualCacheTags = explode(',', $rawActualCacheTags);
- $this->assertEquals($expectedCacheTags, $actualCacheTags);
+ $response = $this->dispatchGraphQlGETRequest(['query' => $queryBlock1]);
+ $this->assertPageCacheMissWithTagsForCmsBlock($response, $block1);
- // check to see that the second entity gets a miss when called the first time
- $request = $this->prepareRequest($queryBlock2);
- $response = $this->graphqlController->dispatch($request);
- $this->assertEquals('MISS', $response->getHeader('X-Magento-Cache-Debug')->getFieldValue());
- $expectedCacheTags = ['cms_b', 'cms_b_' . $block2->getId(), 'cms_b_' . $block2->getIdentifier(), 'FPC'];
- $rawActualCacheTags = $response->getHeader('X-Magento-Tags')->getFieldValue();
- $actualCacheTags = explode(',', $rawActualCacheTags);
- $this->assertEquals($expectedCacheTags, $actualCacheTags);
+ // check to see that the second entity gets a MISS when called the first time
+ $response = $this->dispatchGraphQlGETRequest(['query' => $queryBlock2]);
+ $this->assertPageCacheMissWithTagsForCmsBlock($response, $block2);
// check to see that the first entity gets a HIT when called the second time
- $request = $this->prepareRequest($queryBlock1);
- $response = $this->graphqlController->dispatch($request);
- $this->assertEquals('HIT', $response->getHeader('X-Magento-Cache-Debug')->getFieldValue());
- $expectedCacheTags = ['cms_b', 'cms_b_' . $block1->getId(), 'cms_b_' . $block1->getIdentifier(), 'FPC'];
- $rawActualCacheTags = $response->getHeader('X-Magento-Tags')->getFieldValue();
- $actualCacheTags = explode(',', $rawActualCacheTags);
- $this->assertEquals($expectedCacheTags, $actualCacheTags);
+ $response = $this->dispatchGraphQlGETRequest(['query' => $queryBlock1]);
+ $this->assertPageCacheHitWithTagsForCmsBlock($response, $block1);
// check to see that the second entity gets a HIT when called the second time
- $request = $this->prepareRequest($queryBlock2);
- $response = $this->graphqlController->dispatch($request);
- $this->assertEquals('HIT', $response->getHeader('X-Magento-Cache-Debug')->getFieldValue());
- $expectedCacheTags = ['cms_b', 'cms_b_' . $block2->getId(), 'cms_b_' . $block2->getIdentifier(), 'FPC'];
- $rawActualCacheTags = $response->getHeader('X-Magento-Tags')->getFieldValue();
- $actualCacheTags = explode(',', $rawActualCacheTags);
- $this->assertEquals($expectedCacheTags, $actualCacheTags);
+ $response = $this->dispatchGraphQlGETRequest(['query' => $queryBlock2]);
+ $this->assertPageCacheHitWithTagsForCmsBlock($response, $block2);
$block1->setTitle('something else that causes invalidation');
$blockRepository->save($block1);
// check to see that the first entity gets a MISS and it was invalidated
- $request = $this->prepareRequest($queryBlock1);
- $response = $this->graphqlController->dispatch($request);
- $this->assertEquals('MISS', $response->getHeader('X-Magento-Cache-Debug')->getFieldValue());
- $expectedCacheTags = ['cms_b', 'cms_b_' . $block1->getId(), 'cms_b_' . $block1->getIdentifier(), 'FPC'];
- $rawActualCacheTags = $response->getHeader('X-Magento-Tags')->getFieldValue();
- $actualCacheTags = explode(',', $rawActualCacheTags);
- $this->assertEquals($expectedCacheTags, $actualCacheTags);
+ $response = $this->dispatchGraphQlGETRequest(['query' => $queryBlock1]);
+ $this->assertPageCacheMissWithTagsForCmsBlock($response, $block1);
// check to see that the first entity gets a HIT when called the second time
- $request = $this->prepareRequest($queryBlock1);
- $response = $this->graphqlController->dispatch($request);
- $this->assertEquals('HIT', $response->getHeader('X-Magento-Cache-Debug')->getFieldValue());
- $expectedCacheTags = ['cms_b', 'cms_b_' . $block1->getId(), 'cms_b_' . $block1->getIdentifier(), 'FPC'];
- $rawActualCacheTags = $response->getHeader('X-Magento-Tags')->getFieldValue();
- $actualCacheTags = explode(',', $rawActualCacheTags);
- $this->assertEquals($expectedCacheTags, $actualCacheTags);
+ $response = $this->dispatchGraphQlGETRequest(['query' => $queryBlock1]);
+ $this->assertPageCacheHitWithTagsForCmsBlock($response, $block1);
}
}
diff --git a/dev/tests/integration/testsuite/Magento/GraphQlCache/Controller/Cms/CmsPageCacheTest.php b/dev/tests/integration/testsuite/Magento/GraphQlCache/Controller/Cms/CmsPageCacheTest.php
index 0248f870a5f11..60d84947d87c8 100644
--- a/dev/tests/integration/testsuite/Magento/GraphQlCache/Controller/Cms/CmsPageCacheTest.php
+++ b/dev/tests/integration/testsuite/Magento/GraphQlCache/Controller/Cms/CmsPageCacheTest.php
@@ -7,13 +7,14 @@
namespace Magento\GraphQlCache\Controller\Cms;
+use Magento\Cms\Api\Data\PageInterface;
use Magento\Cms\Model\GetPageByIdentifier;
use Magento\Cms\Model\PageRepository;
-use Magento\GraphQl\Controller\GraphQl;
+use Magento\Framework\App\Response\HttpInterface as HttpResponse;
use Magento\GraphQlCache\Controller\AbstractGraphqlCacheTest;
/**
- * Test caching works for CMS page
+ * Test caching works for CMS pages
*
* @magentoAppArea graphql
* @magentoCache full_page enabled
@@ -22,123 +23,34 @@
*/
class CmsPageCacheTest extends AbstractGraphqlCacheTest
{
- /**
- * @var GraphQl
- */
- private $graphqlController;
-
- /**
- * @inheritdoc
- */
- protected function setUp(): void
- {
- parent::setUp();
- $this->graphqlController = $this->objectManager->get(\Magento\GraphQl\Controller\GraphQl::class);
- }
-
- /**
- * Test that the correct cache tags get added to request for cmsPage query
- *
- * @magentoDataFixture Magento/Cms/_files/pages.php
- */
- public function testToCheckCmsPageRequestCacheTags(): void
+ private function assertPageCacheMissWithTagsForCmsPage(string $pageId, string $name, HttpResponse $response): void
{
- $cmsPage100 = $this->objectManager->get(GetPageByIdentifier::class)->execute('page100', 0);
- $pageId100 = $cmsPage100->getId();
-
- $cmsPageBlank = $this->objectManager->get(GetPageByIdentifier::class)->execute('page_design_blank', 0);
- $pageIdBlank = $cmsPageBlank->getId();
-
- $queryCmsPage100 = $this->getQuery($pageId100);
- $queryCmsPageBlank = $this->getQuery($pageIdBlank);
-
- // check to see that the first entity gets a MISS when called the first time
- $request = $this->prepareRequest($queryCmsPage100);
- $response = $this->graphqlController->dispatch($request);
- $this->assertEquals(
- 'MISS',
- $response->getHeader('X-Magento-Cache-Debug')->getFieldValue(),
- "expected MISS on page page100 id {$queryCmsPage100}"
- );
- $requestedCacheTags = explode(',', $response->getHeader('X-Magento-Tags')->getFieldValue());
- $expectedCacheTags = ['cms_p', 'cms_p_' .$pageId100 , 'FPC'];
- $this->assertEquals($expectedCacheTags, $requestedCacheTags);
-
- // check to see that the second entity gets a miss when called the first time
- $request = $this->prepareRequest($queryCmsPageBlank);
- $response = $this->graphqlController->dispatch($request);
$this->assertEquals(
'MISS',
$response->getHeader('X-Magento-Cache-Debug')->getFieldValue(),
- "expected MISS on page pageBlank id {$pageIdBlank}"
- );
- $requestedCacheTags = explode(',', $response->getHeader('X-Magento-Tags')->getFieldValue());
- $expectedCacheTags = ['cms_p', 'cms_p_' .$pageIdBlank , 'FPC'];
- $this->assertEquals($expectedCacheTags, $requestedCacheTags);
-
- // check to see that the first entity gets a HIT when called the second time
- $request = $this->prepareRequest($queryCmsPage100);
- $response = $this->graphqlController->dispatch($request);
- $this->assertEquals(
- 'HIT',
- $response->getHeader('X-Magento-Cache-Debug')->getFieldValue(),
- "expected HIT on page page100 id {$queryCmsPage100}"
- );
- $requestedCacheTags = explode(',', $response->getHeader('X-Magento-Tags')->getFieldValue());
- $expectedCacheTags = ['cms_p', 'cms_p_' .$pageId100 , 'FPC'];
- $this->assertEquals($expectedCacheTags, $requestedCacheTags);
-
- // check to see that the second entity gets a HIT when called the second time
- $request = $this->prepareRequest($queryCmsPageBlank);
- $response = $this->graphqlController->dispatch($request);
- $this->assertEquals(
- 'HIT',
- $response->getHeader('X-Magento-Cache-Debug')->getFieldValue(),
- "expected HIT on page pageBlank id {$pageIdBlank}"
+ "expected MISS on page {$name} id {$pageId}"
);
- $requestedCacheTags = explode(',', $response->getHeader('X-Magento-Tags')->getFieldValue());
- $expectedCacheTags = ['cms_p', 'cms_p_' .$pageIdBlank , 'FPC'];
- $this->assertEquals($expectedCacheTags, $requestedCacheTags);
-
- /** @var PageRepository $pageRepository */
- $pageRepository = $this->objectManager->get(PageRepository::class);
-
- $page = $pageRepository->getById($pageId100);
- $page->setTitle('something else that causes invalidation');
- $pageRepository->save($page);
-
- // check to see that the first entity gets a MISS and it was invalidated
- $request = $this->prepareRequest($queryCmsPage100);
- $response = $this->graphqlController->dispatch($request);
- $this->assertEquals(
- 'MISS',
- $response->getHeader('X-Magento-Cache-Debug')->getFieldValue(),
- "expected MISS on page page100 id {$queryCmsPage100}"
- );
- $requestedCacheTags = explode(',', $response->getHeader('X-Magento-Tags')->getFieldValue());
- $expectedCacheTags = ['cms_p', 'cms_p_' .$pageId100 , 'FPC'];
- $this->assertEquals($expectedCacheTags, $requestedCacheTags);
+ $this->assertCmsPageCacheTags($pageId, $response);
+ }
- // check to see that the first entity gets a HIT when called the second time
- $request = $this->prepareRequest($queryCmsPage100);
- $response = $this->graphqlController->dispatch($request);
+ private function assertPageCacheHitWithTagsForCmsPage(string $pageId, string $name, HttpResponse $response): void
+ {
$this->assertEquals(
'HIT',
$response->getHeader('X-Magento-Cache-Debug')->getFieldValue(),
- "expected MISS on page page100 id {$queryCmsPage100}"
+ "expected HIT on page {$name} id {$pageId}"
);
+ $this->assertCmsPageCacheTags($pageId, $response);
+ }
+
+ private function assertCmsPageCacheTags(string $pageId, HttpResponse $response): void
+ {
$requestedCacheTags = explode(',', $response->getHeader('X-Magento-Tags')->getFieldValue());
- $expectedCacheTags = ['cms_p', 'cms_p_' .$pageId100 , 'FPC'];
+ $expectedCacheTags = ['cms_p', 'cms_p_' . $pageId, 'FPC'];
$this->assertEquals($expectedCacheTags, $requestedCacheTags);
}
- /**
- * Get cms query
- *
- * @param string $id
- * @return string
- */
- private function getQuery(string $id) : string
+ private function buildQuery(string $id): string
{
$queryCmsPage = <<objectManager->get(PageRepository::class);
+ $page = $pageRepository->getById($pageId100);
+ $page->setTitle($newTitle);
+ $pageRepository->save($page);
+ }
+
+ /**
+ * @magentoDataFixture Magento/Cms/_files/pages.php
+ */
+ public function testCmsPageRequestCacheTags(): void
+ {
+ /** @var PageInterface $cmsPage100 */
+ $cmsPage100 = $this->objectManager->get(GetPageByIdentifier::class)->execute('page100', 0);
+ $pageId100 = (string) $cmsPage100->getId();
+
+ /** @var PageInterface $cmsPageBlank */
+ $cmsPageBlank = $this->objectManager->get(GetPageByIdentifier::class)->execute('page_design_blank', 0);
+ $pageIdBlank = (string) $cmsPageBlank->getId();
+
+ $queryCmsPage100 = $this->buildQuery($pageId100);
+ $queryCmsPageBlank = $this->buildQuery($pageIdBlank);
+
+ // check to see that the first entity gets a MISS when called the first time
+ $response = $this->dispatchGraphQlGETRequest(['query' => $queryCmsPage100]);
+ $this->assertPageCacheMissWithTagsForCmsPage($pageId100, 'page100', $response);
+
+ // check to see that the second entity gets a MISS when called the first time
+ $response = $this->dispatchGraphQlGETRequest(['query' => $queryCmsPageBlank]);
+ $this->assertPageCacheMissWithTagsForCmsPage($pageIdBlank, 'pageBlank', $response);
+
+ // check to see that the first entity gets a HIT when called the second time
+ $response = $this->dispatchGraphQlGETRequest(['query' => $queryCmsPage100]);
+ $this->assertPageCacheHitWithTagsForCmsPage($pageId100, 'page100', $response);
+
+ // check to see that the second entity gets a HIT when called the second time
+ $response = $this->dispatchGraphQlGETRequest(['query' => $queryCmsPageBlank]);
+ $this->assertPageCacheHitWithTagsForCmsPage($pageIdBlank, 'pageBlank', $response);
+
+ // invalidate first entity
+ $this->updateCmsPageTitle($pageId100, 'something else that causes invalidation');
+
+ // check to see that the second entity gets a HIT to confirm only the first was invalidated
+ $response = $this->dispatchGraphQlGETRequest(['query' => $queryCmsPageBlank]);
+ $this->assertPageCacheHitWithTagsForCmsPage($pageIdBlank, 'pageBlank', $response);
+
+ // check to see that the first entity gets a MISS because it was invalidated
+ $response = $this->dispatchGraphQlGETRequest(['query' => $queryCmsPage100]);
+ $this->assertPageCacheMissWithTagsForCmsPage($pageId100, 'page100', $response);
+ }
}
diff --git a/dev/tests/integration/testsuite/Magento/GraphQlCache/Controller/UrlRewrite/AllEntitiesUrlResolverCacheTest.php b/dev/tests/integration/testsuite/Magento/GraphQlCache/Controller/UrlRewrite/AllEntitiesUrlResolverCacheTest.php
index 7accb1d7d0b26..81a4988b81935 100644
--- a/dev/tests/integration/testsuite/Magento/GraphQlCache/Controller/UrlRewrite/AllEntitiesUrlResolverCacheTest.php
+++ b/dev/tests/integration/testsuite/Magento/GraphQlCache/Controller/UrlRewrite/AllEntitiesUrlResolverCacheTest.php
@@ -9,7 +9,7 @@
use Magento\Catalog\Api\ProductRepositoryInterface;
use Magento\Catalog\Model\Product;
-use Magento\GraphQl\Controller\GraphQl;
+use Magento\Framework\App\Response\HttpInterface as HttpResponse;
use Magento\GraphQlCache\Controller\AbstractGraphqlCacheTest;
use Magento\UrlRewrite\Model\UrlFinderInterface;
use Magento\Cms\Api\Data\PageInterface;
@@ -24,155 +24,153 @@
*/
class AllEntitiesUrlResolverCacheTest extends AbstractGraphqlCacheTest
{
- /**
- * @var GraphQl
- */
- private $graphqlController;
+ private function assertCacheMISSWithTagsForCategory(string $categoryId, HttpResponse $response): void
+ {
+ $this->assertCacheMISS($response);
+ $this->assertCacheTags($categoryId, 'cat_c', $response);
+ }
- /**
- * @inheritdoc
- */
- protected function setUp(): void
+ private function assertCacheMISSWithTagsForProduct(string $productId, HttpResponse $response): void
+ {
+ $this->assertCacheMISS($response);
+ $this->assertCacheTags($productId, 'cat_p', $response);
+ }
+
+ private function assertCacheMISSWithTagsForCmsPage(string $pageId, HttpResponse $response): void
+ {
+ $this->assertCacheMISS($response);
+ $this->assertCacheTags($pageId, 'cms_p', $response);
+ }
+
+ private function assertCacheHITWithTagsForCategory(string $categoryId, HttpResponse $response): void
{
- parent::setUp();
- $this->graphqlController = $this->objectManager->get(GraphQl::class);
+ $this->assertCacheHIT($response);
+ $this->assertCacheTags($categoryId, 'cat_c', $response);
+ }
+
+ private function assertCacheHITWithTagsForProduct(string $productId, HttpResponse $response): void
+ {
+ $this->assertCacheHIT($response);
+ $this->assertCacheTags($productId, 'cat_p', $response);
+ }
+
+ private function assertCacheHITWithTagsForCmsPage(string $pageId, HttpResponse $response): void
+ {
+ $this->assertCacheHIT($response);
+ $this->assertCacheTags($pageId, 'cms_p', $response);
+ }
+
+ private function assertCacheMISS(HttpResponse $response): void
+ {
+ $this->assertEquals('MISS', $response->getHeader('X-Magento-Cache-Debug')->getFieldValue());
+ }
+
+ private function assertCacheHIT(HttpResponse $response): void
+ {
+ $this->assertEquals('HIT', $response->getHeader('X-Magento-Cache-Debug')->getFieldValue());
+ }
+
+ private function assertCacheTags(string $entityId, string $entityCacheTag, HttpResponse $response)
+ {
+ $expectedCacheTags = [$entityCacheTag, $entityCacheTag . '_' . $entityId, 'FPC'];
+ $rawActualCacheTags = $response->getHeader('X-Magento-Tags')->getFieldValue();
+ $actualCacheTags = explode(',', $rawActualCacheTags);
+ $this->assertEquals($expectedCacheTags, $actualCacheTags);
+ }
+
+ private function buildQuery(string $requestPath): string
+ {
+ $resolverQuery = <<objectManager->get(ProductRepositoryInterface::class);
/** @var Product $product */
$product = $productRepository->get($productSku, false, null, true);
- $storeId = $product->getStoreId();
+ $storeId = (string) $product->getStoreId();
/** @var UrlFinderInterface $urlFinder */
- $urlFinder = $this->objectManager->get(UrlFinderInterface::class);
- $actualUrls = $urlFinder->findOneByData(
+ $urlFinder = $this->objectManager->get(UrlFinderInterface::class);
+ $actualUrls = $urlFinder->findOneByData(
[
'request_path' => $categoryUrlKey,
'store_id' => $storeId
]
);
- $categoryId = $actualUrls->getEntityId();
- $categoryQuery = $this->getQuery($categoryUrlKey);
+ $categoryId = (string) $actualUrls->getEntityId();
+ $categoryQuery = $this->buildQuery($categoryUrlKey);
- $productQuery = $this->getQuery($productUrlKey);
+ $productQuery = $this->buildQuery($productUrlKey);
/** @var GetPageByIdentifierInterface $page */
$page = $this->objectManager->get(GetPageByIdentifierInterface::class);
/** @var PageInterface $cmsPage */
- $cmsPage = $page->execute('page100', 0);
- $cmsPageId = $cmsPage->getId();
+ $cmsPage = $page->execute('page100', 0);
+ $cmsPageId = (string) $cmsPage->getId();
$requestPath = $cmsPage->getIdentifier();
- $pageQuery = $this->getQuery($requestPath);
+ $pageQuery = $this->buildQuery($requestPath);
// query category for MISS
- $request = $this->prepareRequest($categoryQuery);
- $response = $this->graphqlController->dispatch($request);
- $this->assertEquals('MISS', $response->getHeader('X-Magento-Cache-Debug')->getFieldValue());
- $expectedCacheTags = ['cat_c','cat_c_' . $categoryId, 'FPC'];
- $rawActualCacheTags = $response->getHeader('X-Magento-Tags')->getFieldValue();
- $actualCacheTags = explode(',', $rawActualCacheTags);
- $this->assertEquals($expectedCacheTags, $actualCacheTags);
+ $response = $this->dispatchGraphQlGETRequest(['query' => $categoryQuery]);
+ $this->assertCacheMISSWithTagsForCategory($categoryId, $response);
// query product for MISS
- $request = $this->prepareRequest($productQuery);
- $response = $this->graphqlController->dispatch($request);
- $this->assertEquals('MISS', $response->getHeader('X-Magento-Cache-Debug')->getFieldValue());
- $expectedCacheTags = ['cat_p', 'cat_p_' . $product->getId(), 'FPC'];
- $rawActualCacheTags = $response->getHeader('X-Magento-Tags')->getFieldValue();
- $actualCacheTags = explode(',', $rawActualCacheTags);
- $this->assertEquals($expectedCacheTags, $actualCacheTags);
+ $response = $this->dispatchGraphQlGETRequest(['query' => $productQuery]);
+ $this->assertCacheMISSWithTagsForProduct((string) $product->getId(), $response);
// query page for MISS
- $request = $this->prepareRequest($pageQuery);
- $response = $this->graphqlController->dispatch($request);
- $this->assertEquals('MISS', $response->getHeader('X-Magento-Cache-Debug')->getFieldValue());
- $expectedCacheTags = ['cms_p','cms_p_' . $cmsPageId,'FPC'];
- $rawActualCacheTags = $response->getHeader('X-Magento-Tags')->getFieldValue();
- $actualCacheTags = explode(',', $rawActualCacheTags);
- $this->assertEquals($expectedCacheTags, $actualCacheTags);
+ $response = $this->dispatchGraphQlGETRequest(['query' => $pageQuery]);
+ $this->assertCacheMISSWithTagsForCmsPage($cmsPageId, $response);
// query category for HIT
- $request = $this->prepareRequest($categoryQuery);
- $response = $this->graphqlController->dispatch($request);
- $this->assertEquals('HIT', $response->getHeader('X-Magento-Cache-Debug')->getFieldValue());
- $expectedCacheTags = ['cat_c','cat_c_' . $categoryId, 'FPC'];
- $rawActualCacheTags = $response->getHeader('X-Magento-Tags')->getFieldValue();
- $actualCacheTags = explode(',', $rawActualCacheTags);
- $this->assertEquals($expectedCacheTags, $actualCacheTags);
+ $response = $this->dispatchGraphQlGETRequest(['query' => $categoryQuery]);
+ $this->assertCacheHITWithTagsForCategory($categoryId, $response);
// query product for HIT
- $request = $this->prepareRequest($productQuery);
- $response = $this->graphqlController->dispatch($request);
- $this->assertEquals('HIT', $response->getHeader('X-Magento-Cache-Debug')->getFieldValue());
- $expectedCacheTags = ['cat_p', 'cat_p_' . $product->getId(), 'FPC'];
- $rawActualCacheTags = $response->getHeader('X-Magento-Tags')->getFieldValue();
- $actualCacheTags = explode(',', $rawActualCacheTags);
- $this->assertEquals($expectedCacheTags, $actualCacheTags);
+ $response = $this->dispatchGraphQlGETRequest(['query' => $productQuery]);
+ $this->assertCacheHITWithTagsForProduct((string) $product->getId(), $response);
- // query product for HIT
- $request = $this->prepareRequest($pageQuery);
- $response = $this->graphqlController->dispatch($request);
- $this->assertEquals('HIT', $response->getHeader('X-Magento-Cache-Debug')->getFieldValue());
- $expectedCacheTags = ['cms_p','cms_p_' . $cmsPageId,'FPC'];
- $rawActualCacheTags = $response->getHeader('X-Magento-Tags')->getFieldValue();
- $actualCacheTags = explode(',', $rawActualCacheTags);
- $this->assertEquals($expectedCacheTags, $actualCacheTags);
+ // query page for HIT
+ $response = $this->dispatchGraphQlGETRequest(['query' => $pageQuery]);
+ $this->assertCacheHITWithTagsForCmsPage($cmsPageId, $response);
$product->setUrlKey('something-else-that-invalidates-the-cache');
$productRepository->save($product);
- $productQuery = $this->getQuery('something-else-that-invalidates-the-cache.html');
+ $productQuery = $this->buildQuery('something-else-that-invalidates-the-cache.html');
// query category for MISS
- $request = $this->prepareRequest($categoryQuery);
- $response = $this->graphqlController->dispatch($request);
- $this->assertEquals('MISS', $response->getHeader('X-Magento-Cache-Debug')->getFieldValue());
- $expectedCacheTags = ['cat_c','cat_c_' . $categoryId, 'FPC'];
- $rawActualCacheTags = $response->getHeader('X-Magento-Tags')->getFieldValue();
- $actualCacheTags = explode(',', $rawActualCacheTags);
- $this->assertEquals($expectedCacheTags, $actualCacheTags);
+ $response = $this->dispatchGraphQlGETRequest(['query' => $categoryQuery]);
+ $this->assertCacheMISSWithTagsForCategory($categoryId, $response);
- // query product for HIT
- $request = $this->prepareRequest($productQuery);
- $response = $this->graphqlController->dispatch($request);
- $this->assertEquals('MISS', $response->getHeader('X-Magento-Cache-Debug')->getFieldValue());
- $expectedCacheTags = ['cat_p', 'cat_p_' . $product->getId(), 'FPC'];
- $rawActualCacheTags = $response->getHeader('X-Magento-Tags')->getFieldValue();
- $actualCacheTags = explode(',', $rawActualCacheTags);
- $this->assertEquals($expectedCacheTags, $actualCacheTags);
- }
+ // query product for MISS
+ $response = $this->dispatchGraphQlGETRequest(['query' => $productQuery]);
+ $this->assertCacheMISSWithTagsForProduct((string) $product->getId(), $response);
- /**
- * Get urlResolver query
- *
- * @param string $id
- * @return string
- */
- private function getQuery(string $requestPath) : string
- {
- $resolverQuery = <<dispatchGraphQlGETRequest(['query' => $pageQuery]);
+ $this->assertCacheHITWithTagsForCmsPage($cmsPageId, $response);
}
}
diff --git a/lib/internal/Magento/Framework/App/Cache/Frontend/Pool.php b/lib/internal/Magento/Framework/App/Cache/Frontend/Pool.php
index 30cb4a67b9edd..a4c9fb4380651 100644
--- a/lib/internal/Magento/Framework/App/Cache/Frontend/Pool.php
+++ b/lib/internal/Magento/Framework/App/Cache/Frontend/Pool.php
@@ -3,6 +3,7 @@
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
+
namespace Magento\Framework\App\Cache\Frontend;
use Magento\Framework\App\Cache\Type\FrontendPool;
@@ -55,6 +56,7 @@ public function __construct(
/**
* Create instances of every cache frontend known to the system.
+ *
* Method is to be used for delayed initialization of the iterator.
*
* @return void
@@ -77,18 +79,21 @@ protected function _initialize()
protected function _getCacheSettings()
{
/*
- * Merging is intentionally implemented through array_merge() instead of array_replace_recursive()
- * to avoid "inheritance" of the default settings that become irrelevant as soon as cache storage type changes
+ * Merging is intentionally implemented through array_replace_recursive() instead of array_merge(), because even
+ * though some settings may become irrelevant when the cache storage type is changed, they don't do any harm
+ * and can be overwritten when needed.
+ * Also array_merge leads to unexpected behavior, for for example by dropping the
+ * default cache_dir setting from di.xml when a cache id_prefix is configured in app/etc/env.php.
*/
$cacheInfo = $this->deploymentConfig->getConfigData(FrontendPool::KEY_CACHE);
if (null !== $cacheInfo) {
- return array_merge($this->_frontendSettings, $cacheInfo[FrontendPool::KEY_FRONTEND_CACHE]);
+ return array_replace_recursive($this->_frontendSettings, $cacheInfo[FrontendPool::KEY_FRONTEND_CACHE]);
}
return $this->_frontendSettings;
}
/**
- * {@inheritdoc}
+ * @inheritdoc
*
* @return \Magento\Framework\Cache\FrontendInterface
*/
@@ -99,7 +104,7 @@ public function current()
}
/**
- * {@inheritdoc}
+ * @inheritdoc
*/
public function key()
{
@@ -108,7 +113,7 @@ public function key()
}
/**
- * {@inheritdoc}
+ * @inheritdoc
*/
public function next()
{
@@ -117,7 +122,7 @@ public function next()
}
/**
- * {@inheritdoc}
+ * @inheritdoc
*/
public function rewind()
{
@@ -126,7 +131,7 @@ public function rewind()
}
/**
- * {@inheritdoc}
+ * @inheritdoc
*/
public function valid()
{
diff --git a/lib/internal/Magento/Framework/App/Test/Unit/Cache/Frontend/PoolTest.php b/lib/internal/Magento/Framework/App/Test/Unit/Cache/Frontend/PoolTest.php
index bfa37311884ba..5ec3dd658737b 100644
--- a/lib/internal/Magento/Framework/App/Test/Unit/Cache/Frontend/PoolTest.php
+++ b/lib/internal/Magento/Framework/App/Test/Unit/Cache/Frontend/PoolTest.php
@@ -8,6 +8,9 @@
use Magento\Framework\App\Cache\Frontend\Pool;
use Magento\Framework\App\Cache\Type\FrontendPool;
+/**
+ * And another docblock to make the sniff shut up.
+ */
class PoolTest extends \PHPUnit\Framework\TestCase
{
/**
@@ -111,25 +114,38 @@ public function testInitializationParams(
public function initializationParamsDataProvider()
{
return [
- 'default frontend, default settings' => [
+ 'no deployment config, default settings' => [
['frontend' => []],
[Pool::DEFAULT_FRONTEND_ID => ['default_option' => 'default_value']],
['default_option' => 'default_value'],
],
- 'default frontend, overridden settings' => [
+ 'deployment config, default settings' => [
+ ['frontend' => [Pool::DEFAULT_FRONTEND_ID => ['configured_option' => 'configured_value']]],
+ [Pool::DEFAULT_FRONTEND_ID => ['default_option' => 'default_value']],
+ ['configured_option' => 'configured_value', 'default_option' => 'default_value'],
+ ],
+ 'deployment config, overridden settings' => [
['frontend' => [Pool::DEFAULT_FRONTEND_ID => ['configured_option' => 'configured_value']]],
- [Pool::DEFAULT_FRONTEND_ID => ['ignored_option' => 'ignored_value']],
+ [Pool::DEFAULT_FRONTEND_ID => ['configured_option' => 'default_value']],
['configured_option' => 'configured_value'],
],
- 'custom frontend, default settings' => [
- ['frontend' => []],
+ 'deployment config, default settings, overridden settings' => [
+ ['frontend' => [Pool::DEFAULT_FRONTEND_ID => ['configured_option' => 'configured_value']]],
+ [Pool::DEFAULT_FRONTEND_ID => [
+ 'configured_option' => 'default_value',
+ 'default_setting' => 'default_value'
+ ]],
+ ['configured_option' => 'configured_value', 'default_setting' => 'default_value'],
+ ],
+ 'custom deployent config, default settings' => [
+ ['frontend' => ['custom' => ['configured_option' => 'configured_value']]],
['custom' => ['default_option' => 'default_value']],
- ['default_option' => 'default_value'],
+ ['configured_option' => 'configured_value', 'default_option' => 'default_value'],
],
- 'custom frontend, overridden settings' => [
+ 'custom deployent config, default settings, overridden settings' => [
['frontend' => ['custom' => ['configured_option' => 'configured_value']]],
- ['custom' => ['ignored_option' => 'ignored_value']],
- ['configured_option' => 'configured_value'],
+ ['custom' => ['default_option' => 'default_value', 'configured_option' => 'default_value']],
+ ['configured_option' => 'configured_value', 'default_option' => 'default_value'],
]
];
}
From e436ae6e4956fb1c6546ccc91af05d61011ceb76 Mon Sep 17 00:00:00 2001
From: vital_pantsialeyeu
Date: Sat, 27 Jul 2019 05:10:52 +0300
Subject: [PATCH 044/937] MAGETWO-69825: [GITHUB #9891] Subcategory
"liquid-hand-soap" is not opened in category "soap"
- Added integration test
---
.../Controller/Adminhtml/CategoryTest.php | 62 ++++++++++++++++---
1 file changed, 53 insertions(+), 9 deletions(-)
diff --git a/dev/tests/integration/testsuite/Magento/Catalog/Controller/Adminhtml/CategoryTest.php b/dev/tests/integration/testsuite/Magento/Catalog/Controller/Adminhtml/CategoryTest.php
index 1001d58ee8a67..bfe02f2aa2e10 100644
--- a/dev/tests/integration/testsuite/Magento/Catalog/Controller/Adminhtml/CategoryTest.php
+++ b/dev/tests/integration/testsuite/Magento/Catalog/Controller/Adminhtml/CategoryTest.php
@@ -3,14 +3,20 @@
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
+declare(strict_types=1);
+
namespace Magento\Catalog\Controller\Adminhtml;
+use Magento\Backend\App\Area\FrontNameResolver;
+use Magento\Catalog\Model\ResourceModel\Product;
use Magento\Framework\App\Request\Http as HttpRequest;
-use Magento\TestFramework\Helper\Bootstrap;
+use Magento\Framework\Message\MessageInterface;
use Magento\Store\Model\Store;
-use Magento\Catalog\Model\ResourceModel\Product;
+use Magento\TestFramework\Helper\Bootstrap;
/**
+ * Test class for \Magento\Catalog\Controller\Adminhtml\Category.
+ *
* @magentoAppArea adminhtml
*/
class CategoryTest extends \Magento\TestFramework\TestCase\AbstractBackendController
@@ -36,6 +42,8 @@ protected function setUp()
}
/**
+ * Test save action.
+ *
* @magentoDataFixture Magento/Store/_files/core_fixturestore.php
* @magentoDbIsolation enabled
* @magentoConfigFixture current_store catalog/frontend/flat_catalog_product 1
@@ -48,7 +56,7 @@ protected function setUp()
public function testSaveAction($inputData, $defaultAttributes, $attributesSaved = [], $isSuccess = true)
{
/** @var $store \Magento\Store\Model\Store */
- $store = \Magento\TestFramework\Helper\Bootstrap::getObjectManager()->create(\Magento\Store\Model\Store::class);
+ $store = Bootstrap::getObjectManager()->create(\Magento\Store\Model\Store::class);
$store->load('fixturestore', 'code');
$storeId = $store->getId();
@@ -61,14 +69,12 @@ public function testSaveAction($inputData, $defaultAttributes, $attributesSaved
if ($isSuccess) {
$this->assertSessionMessages(
$this->equalTo(['You saved the category.']),
- \Magento\Framework\Message\MessageInterface::TYPE_SUCCESS
+ MessageInterface::TYPE_SUCCESS
);
}
/** @var $category \Magento\Catalog\Model\Category */
- $category = \Magento\TestFramework\Helper\Bootstrap::getObjectManager()->create(
- \Magento\Catalog\Model\Category::class
- );
+ $category = Bootstrap::getObjectManager()->create(\Magento\Catalog\Model\Category::class);
$category->setStoreId($storeId);
$category->load(2);
@@ -95,6 +101,8 @@ public function testSaveAction($inputData, $defaultAttributes, $attributesSaved
}
/**
+ * Test save action from product creation page.
+ *
* @param array $postData
* @dataProvider categoryCreatedFromProductCreationPageDataProvider
* @magentoDbIsolation enabled
@@ -377,11 +385,13 @@ public function testSaveActionCategoryWithDangerRequest()
$this->dispatch('backend/catalog/category/save');
$this->assertSessionMessages(
$this->equalTo(['The "Name" attribute value is empty. Set the attribute and try again.']),
- \Magento\Framework\Message\MessageInterface::TYPE_ERROR
+ MessageInterface::TYPE_ERROR
);
}
/**
+ * Test move action.
+ *
* @magentoDataFixture Magento/Catalog/_files/category_tree.php
* @dataProvider moveActionDataProvider
*
@@ -433,6 +443,8 @@ public function moveActionDataProvider()
}
/**
+ * Test save category with product position.
+ *
* @magentoDataFixture Magento/Catalog/_files/products_in_different_stores.php
* @magentoDbIsolation disabled
* @dataProvider saveActionWithDifferentWebsitesDataProvider
@@ -541,7 +553,7 @@ public function saveActionWithDifferentWebsitesDataProvider()
}
/**
- * Get items count from catalog_category_product
+ * Get items count from catalog_category_product.
*
* @return int
*/
@@ -555,4 +567,36 @@ private function getCategoryProductsCount(): int
$this->productResource->getConnection()->fetchAll($oldCategoryProducts)
);
}
+
+ /**
+ * Verify that the category cannot be saved if the category url matches the admin url.
+ *
+ * @magentoConfigFixture admin/url/use_custom_path 1
+ * @magentoConfigFixture admin/url/custom_path backend
+ */
+ public function testSaveWithCustomBackendNameAction()
+ {
+ $frontNameResolver = Bootstrap::getObjectManager()->create(FrontNameResolver::class);
+ $urlKey = $frontNameResolver->getFrontName();
+ $inputData = [
+ 'id' => '2',
+ 'url_key' => $urlKey,
+ 'use_config' => [
+ 'available_sort_by' => 1,
+ 'default_sort_by' => 1
+ ]
+ ];
+ $this->getRequest()->setMethod(HttpRequest::METHOD_POST);
+ $this->getRequest()->setPostValue($inputData);
+ $this->dispatch('backend/catalog/category/save');
+ $this->assertSessionMessages(
+ $this->equalTo(
+ [
+ 'URL key "backend" conflicts with reserved endpoint names: '
+ . 'admin, soap, rest, graphql, backend. Try another url key.'
+ ]
+ ),
+ MessageInterface::TYPE_ERROR
+ );
+ }
}
From 417565976b8ead7d58db8eb8eb1e539fd1f3f22c Mon Sep 17 00:00:00 2001
From: Oleksandr Gorkun
Date: Mon, 29 Jul 2019 14:07:27 -0500
Subject: [PATCH 045/937] MAGETWO-96975: Remove __sleep and __wakeup from code
---
app/code/Magento/Authorization/Model/Role.php | 2 ++
app/code/Magento/Catalog/Model/ResourceModel/Eav/Attribute.php | 2 ++
app/code/Magento/Config/Model/Config/Backend/Encrypted.php | 2 ++
.../Model/Product/Type/Configurable/Attribute.php | 2 ++
.../Product/Type/Configurable/Attribute/Collection.php | 2 ++
app/code/Magento/Customer/Model/Attribute.php | 2 ++
app/code/Magento/Eav/Model/Entity/Attribute.php | 2 ++
.../Magento/Eav/Model/Entity/Attribute/AbstractAttribute.php | 2 ++
app/code/Magento/Eav/Model/ResourceModel/Entity/Attribute.php | 2 ++
app/code/Magento/Store/Model/Store.php | 2 ++
app/code/Magento/User/Model/User.php | 2 ++
lib/internal/Magento/Framework/App/AreaList/Proxy.php | 2 ++
lib/internal/Magento/Framework/App/Response/Http.php | 2 ++
.../Magento/Framework/App/Route/ConfigInterface/Proxy.php | 2 ++
lib/internal/Magento/Framework/DB/Select.php | 2 ++
lib/internal/Magento/Framework/DB/Select/RendererProxy.php | 2 ++
lib/internal/Magento/Framework/Data/Collection.php | 2 ++
lib/internal/Magento/Framework/Data/Collection/AbstractDb.php | 2 ++
.../Magento/Framework/DataObject/Copy/Config/Data/Proxy.php | 2 ++
lib/internal/Magento/Framework/Interception/Interceptor.php | 2 ++
.../Magento/Framework/Model/AbstractExtensibleModel.php | 2 ++
lib/internal/Magento/Framework/Model/AbstractModel.php | 2 ++
.../Magento/Framework/Model/ResourceModel/Db/AbstractDb.php | 2 ++
.../Model/ResourceModel/Db/Collection/AbstractCollection.php | 2 ++
lib/internal/Magento/Framework/Mview/Config/Data/Proxy.php | 2 ++
lib/internal/Magento/Framework/Translate/Inline/Proxy.php | 2 ++
lib/internal/Magento/Framework/View/Layout/Proxy.php | 2 ++
27 files changed, 54 insertions(+)
diff --git a/app/code/Magento/Authorization/Model/Role.php b/app/code/Magento/Authorization/Model/Role.php
index 719059c6f67c4..40a1c7149a524 100644
--- a/app/code/Magento/Authorization/Model/Role.php
+++ b/app/code/Magento/Authorization/Model/Role.php
@@ -58,6 +58,7 @@ public function __construct( //phpcs:ignore Generic.CodeAnalysis.UselessOverridi
*/
public function __sleep()
{
+ // phpcs:ignore Magento2.Functions.DiscouragedFunction
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
$properties = parent::__sleep();
@@ -72,6 +73,7 @@ public function __sleep()
*/
public function __wakeup()
{
+ // phpcs:ignore Magento2.Functions.DiscouragedFunction
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
parent::__wakeup();
diff --git a/app/code/Magento/Catalog/Model/ResourceModel/Eav/Attribute.php b/app/code/Magento/Catalog/Model/ResourceModel/Eav/Attribute.php
index e7c67463d8a5d..ce7e5cd42f282 100644
--- a/app/code/Magento/Catalog/Model/ResourceModel/Eav/Attribute.php
+++ b/app/code/Magento/Catalog/Model/ResourceModel/Eav/Attribute.php
@@ -852,6 +852,7 @@ public function afterDelete()
*/
public function __sleep()
{
+ // phpcs:ignore Magento2.Functions.DiscouragedFunction
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
$this->unsetData('entity_type');
@@ -870,6 +871,7 @@ public function __sleep()
*/
public function __wakeup()
{
+ // phpcs:ignore Magento2.Functions.DiscouragedFunction
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
parent::__wakeup();
diff --git a/app/code/Magento/Config/Model/Config/Backend/Encrypted.php b/app/code/Magento/Config/Model/Config/Backend/Encrypted.php
index 0700d637d6144..fc4d0a54bb13d 100644
--- a/app/code/Magento/Config/Model/Config/Backend/Encrypted.php
+++ b/app/code/Magento/Config/Model/Config/Backend/Encrypted.php
@@ -54,6 +54,7 @@ public function __construct(
*/
public function __sleep()
{
+ // phpcs:ignore Magento2.Functions.DiscouragedFunction
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
$properties = parent::__sleep();
@@ -70,6 +71,7 @@ public function __sleep()
*/
public function __wakeup()
{
+ // phpcs:ignore Magento2.Functions.DiscouragedFunction
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
parent::__wakeup();
diff --git a/app/code/Magento/ConfigurableProduct/Model/Product/Type/Configurable/Attribute.php b/app/code/Magento/ConfigurableProduct/Model/Product/Type/Configurable/Attribute.php
index 6dd3790191551..0f34cb9f89474 100644
--- a/app/code/Magento/ConfigurableProduct/Model/Product/Type/Configurable/Attribute.php
+++ b/app/code/Magento/ConfigurableProduct/Model/Product/Type/Configurable/Attribute.php
@@ -270,6 +270,7 @@ public function setProductId($value)
*/
public function __sleep()
{
+ // phpcs:ignore Magento2.Functions.DiscouragedFunction
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
return array_diff(
@@ -286,6 +287,7 @@ public function __sleep()
*/
public function __wakeup()
{
+ // phpcs:ignore Magento2.Functions.DiscouragedFunction
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
parent::__wakeup();
diff --git a/app/code/Magento/ConfigurableProduct/Model/ResourceModel/Product/Type/Configurable/Attribute/Collection.php b/app/code/Magento/ConfigurableProduct/Model/ResourceModel/Product/Type/Configurable/Attribute/Collection.php
index 90b02cb112b5f..81dd0e42e3d3d 100644
--- a/app/code/Magento/ConfigurableProduct/Model/ResourceModel/Product/Type/Configurable/Attribute/Collection.php
+++ b/app/code/Magento/ConfigurableProduct/Model/ResourceModel/Product/Type/Configurable/Attribute/Collection.php
@@ -363,6 +363,7 @@ protected function getIncludedOptions(array $usedProducts, AbstractAttribute $pr
*/
public function __sleep()
{
+ // phpcs:ignore Magento2.Functions.DiscouragedFunction
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
return array_diff(
@@ -387,6 +388,7 @@ public function __sleep()
*/
public function __wakeup()
{
+ // phpcs:ignore Magento2.Functions.DiscouragedFunction
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
parent::__wakeup();
diff --git a/app/code/Magento/Customer/Model/Attribute.php b/app/code/Magento/Customer/Model/Attribute.php
index ae714f993082e..773b9643298a5 100644
--- a/app/code/Magento/Customer/Model/Attribute.php
+++ b/app/code/Magento/Customer/Model/Attribute.php
@@ -208,6 +208,7 @@ public function canBeFilterableInGrid()
*/
public function __sleep()
{
+ // phpcs:ignore Magento2.Functions.DiscouragedFunction
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
$this->unsetData('entity_type');
@@ -225,6 +226,7 @@ public function __sleep()
*/
public function __wakeup()
{
+ // phpcs:ignore Magento2.Functions.DiscouragedFunction
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
parent::__wakeup();
diff --git a/app/code/Magento/Eav/Model/Entity/Attribute.php b/app/code/Magento/Eav/Model/Entity/Attribute.php
index 1ca942ef1679c..b6522cdb2dda3 100644
--- a/app/code/Magento/Eav/Model/Entity/Attribute.php
+++ b/app/code/Magento/Eav/Model/Entity/Attribute.php
@@ -495,6 +495,7 @@ public function getIdentities()
*/
public function __sleep()
{
+ // phpcs:ignore Magento2.Functions.DiscouragedFunction
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
$this->unsetData('attribute_set_info');
@@ -513,6 +514,7 @@ public function __sleep()
*/
public function __wakeup()
{
+ // phpcs:ignore Magento2.Functions.DiscouragedFunction
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
parent::__wakeup();
diff --git a/app/code/Magento/Eav/Model/Entity/Attribute/AbstractAttribute.php b/app/code/Magento/Eav/Model/Entity/Attribute/AbstractAttribute.php
index b7b712c493669..f33ec1d5423e3 100644
--- a/app/code/Magento/Eav/Model/Entity/Attribute/AbstractAttribute.php
+++ b/app/code/Magento/Eav/Model/Entity/Attribute/AbstractAttribute.php
@@ -1411,6 +1411,7 @@ public function setExtensionAttributes(\Magento\Eav\Api\Data\AttributeExtensionI
*/
public function __sleep()
{
+ // phpcs:ignore Magento2.Functions.DiscouragedFunction
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
return array_diff(
@@ -1441,6 +1442,7 @@ public function __sleep()
*/
public function __wakeup()
{
+ // phpcs:ignore Magento2.Functions.DiscouragedFunction
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
parent::__wakeup();
diff --git a/app/code/Magento/Eav/Model/ResourceModel/Entity/Attribute.php b/app/code/Magento/Eav/Model/ResourceModel/Entity/Attribute.php
index 5e7226e7a36dd..e2d7ef7ff3581 100644
--- a/app/code/Magento/Eav/Model/ResourceModel/Entity/Attribute.php
+++ b/app/code/Magento/Eav/Model/ResourceModel/Entity/Attribute.php
@@ -731,6 +731,7 @@ public function getValidAttributeIds($attributeIds)
*/
public function __sleep()
{
+ // phpcs:ignore Magento2.Functions.DiscouragedFunction
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
$properties = parent::__sleep();
@@ -749,6 +750,7 @@ public function __sleep()
*/
public function __wakeup()
{
+ // phpcs:ignore Magento2.Functions.DiscouragedFunction
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
parent::__wakeup();
diff --git a/app/code/Magento/Store/Model/Store.php b/app/code/Magento/Store/Model/Store.php
index eaabdedb4b7fd..76e8a7019007e 100644
--- a/app/code/Magento/Store/Model/Store.php
+++ b/app/code/Magento/Store/Model/Store.php
@@ -429,6 +429,7 @@ public function __construct(
*/
public function __sleep()
{
+ // phpcs:ignore Magento2.Functions.DiscouragedFunction
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
$properties = parent::__sleep();
@@ -446,6 +447,7 @@ public function __sleep()
*/
public function __wakeup()
{
+ // phpcs:ignore Magento2.Functions.DiscouragedFunction
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
parent::__wakeup();
diff --git a/app/code/Magento/User/Model/User.php b/app/code/Magento/User/Model/User.php
index 297f6d8814de2..a81e7af1e983a 100644
--- a/app/code/Magento/User/Model/User.php
+++ b/app/code/Magento/User/Model/User.php
@@ -218,6 +218,7 @@ protected function _construct()
*/
public function __sleep()
{
+ // phpcs:ignore Magento2.Functions.DiscouragedFunction
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
$properties = parent::__sleep();
@@ -251,6 +252,7 @@ public function __sleep()
*/
public function __wakeup()
{
+ // phpcs:ignore Magento2.Functions.DiscouragedFunction
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
parent::__wakeup();
diff --git a/lib/internal/Magento/Framework/App/AreaList/Proxy.php b/lib/internal/Magento/Framework/App/AreaList/Proxy.php
index 09115add57190..7a571814371fe 100644
--- a/lib/internal/Magento/Framework/App/AreaList/Proxy.php
+++ b/lib/internal/Magento/Framework/App/AreaList/Proxy.php
@@ -67,6 +67,7 @@ public function __construct(
*/
public function __sleep()
{
+ // phpcs:ignore Magento2.Functions.DiscouragedFunction
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
return ['_subject', '_isShared'];
@@ -82,6 +83,7 @@ public function __sleep()
*/
public function __wakeup()
{
+ // phpcs:ignore Magento2.Functions.DiscouragedFunction
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
$this->_objectManager = \Magento\Framework\App\ObjectManager::getInstance();
diff --git a/lib/internal/Magento/Framework/App/Response/Http.php b/lib/internal/Magento/Framework/App/Response/Http.php
index 0c2523faa2ae1..db3da6beeaa51 100644
--- a/lib/internal/Magento/Framework/App/Response/Http.php
+++ b/lib/internal/Magento/Framework/App/Response/Http.php
@@ -191,6 +191,7 @@ public function representJson($content)
*/
public function __sleep()
{
+ // phpcs:ignore Magento2.Functions.DiscouragedFunction
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
return ['content', 'isRedirect', 'statusCode', 'context', 'headers'];
@@ -207,6 +208,7 @@ public function __sleep()
*/
public function __wakeup()
{
+ // phpcs:ignore Magento2.Functions.DiscouragedFunction
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
$objectManager = ObjectManager::getInstance();
diff --git a/lib/internal/Magento/Framework/App/Route/ConfigInterface/Proxy.php b/lib/internal/Magento/Framework/App/Route/ConfigInterface/Proxy.php
index 5e79315238f7d..4d2707d4a1c7e 100644
--- a/lib/internal/Magento/Framework/App/Route/ConfigInterface/Proxy.php
+++ b/lib/internal/Magento/Framework/App/Route/ConfigInterface/Proxy.php
@@ -69,6 +69,7 @@ public function __construct(
*/
public function __sleep()
{
+ // phpcs:ignore Magento2.Functions.DiscouragedFunction
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
return ['_subject', '_isShared'];
@@ -84,6 +85,7 @@ public function __sleep()
*/
public function __wakeup()
{
+ // phpcs:ignore Magento2.Functions.DiscouragedFunction
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
$this->_objectManager = \Magento\Framework\App\ObjectManager::getInstance();
diff --git a/lib/internal/Magento/Framework/DB/Select.php b/lib/internal/Magento/Framework/DB/Select.php
index 273d940babb91..c3da06a2ef924 100644
--- a/lib/internal/Magento/Framework/DB/Select.php
+++ b/lib/internal/Magento/Framework/DB/Select.php
@@ -519,6 +519,7 @@ public function assemble()
*/
public function __sleep()
{
+ // phpcs:ignore Magento2.Functions.DiscouragedFunction
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
$properties = array_keys(get_object_vars($this));
@@ -543,6 +544,7 @@ public function __sleep()
*/
public function __wakeup()
{
+ // phpcs:ignore Magento2.Functions.DiscouragedFunction
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
$objectManager = \Magento\Framework\App\ObjectManager::getInstance();
diff --git a/lib/internal/Magento/Framework/DB/Select/RendererProxy.php b/lib/internal/Magento/Framework/DB/Select/RendererProxy.php
index e8030a6794a29..629b600303ebb 100644
--- a/lib/internal/Magento/Framework/DB/Select/RendererProxy.php
+++ b/lib/internal/Magento/Framework/DB/Select/RendererProxy.php
@@ -65,6 +65,7 @@ public function __construct(
*/
public function __sleep()
{
+ // phpcs:ignore Magento2.Functions.DiscouragedFunction
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
return ['_subject', '_isShared'];
@@ -80,6 +81,7 @@ public function __sleep()
*/
public function __wakeup()
{
+ // phpcs:ignore Magento2.Functions.DiscouragedFunction
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
$this->_objectManager = \Magento\Framework\App\ObjectManager::getInstance();
diff --git a/lib/internal/Magento/Framework/Data/Collection.php b/lib/internal/Magento/Framework/Data/Collection.php
index 2f3aaad98dfe5..2f0404f35822d 100644
--- a/lib/internal/Magento/Framework/Data/Collection.php
+++ b/lib/internal/Magento/Framework/Data/Collection.php
@@ -895,6 +895,7 @@ public function hasFlag($flag)
*/
public function __sleep()
{
+ // phpcs:ignore Magento2.Functions.DiscouragedFunction
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
$properties = array_keys(get_object_vars($this));
@@ -918,6 +919,7 @@ public function __sleep()
*/
public function __wakeup()
{
+ // phpcs:ignore Magento2.Functions.DiscouragedFunction
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
$objectManager = \Magento\Framework\App\ObjectManager::getInstance();
diff --git a/lib/internal/Magento/Framework/Data/Collection/AbstractDb.php b/lib/internal/Magento/Framework/Data/Collection/AbstractDb.php
index 283d3684cf9fc..6ca28c738b3fe 100644
--- a/lib/internal/Magento/Framework/Data/Collection/AbstractDb.php
+++ b/lib/internal/Magento/Framework/Data/Collection/AbstractDb.php
@@ -902,6 +902,7 @@ private function getMainTableAlias()
*/
public function __sleep()
{
+ // phpcs:ignore Magento2.Functions.DiscouragedFunction
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
return array_diff(
@@ -919,6 +920,7 @@ public function __sleep()
*/
public function __wakeup()
{
+ // phpcs:ignore Magento2.Functions.DiscouragedFunction
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
parent::__wakeup();
diff --git a/lib/internal/Magento/Framework/DataObject/Copy/Config/Data/Proxy.php b/lib/internal/Magento/Framework/DataObject/Copy/Config/Data/Proxy.php
index 6486643614d9e..a6e84b483261e 100644
--- a/lib/internal/Magento/Framework/DataObject/Copy/Config/Data/Proxy.php
+++ b/lib/internal/Magento/Framework/DataObject/Copy/Config/Data/Proxy.php
@@ -66,6 +66,7 @@ public function __construct(
*/
public function __sleep()
{
+ // phpcs:ignore Magento2.Functions.DiscouragedFunction
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
return ['_subject', '_isShared'];
@@ -81,6 +82,7 @@ public function __sleep()
*/
public function __wakeup()
{
+ // phpcs:ignore Magento2.Functions.DiscouragedFunction
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
$this->_objectManager = \Magento\Framework\App\ObjectManager::getInstance();
diff --git a/lib/internal/Magento/Framework/Interception/Interceptor.php b/lib/internal/Magento/Framework/Interception/Interceptor.php
index df1b680234220..3b9543e8cbb7b 100644
--- a/lib/internal/Magento/Framework/Interception/Interceptor.php
+++ b/lib/internal/Magento/Framework/Interception/Interceptor.php
@@ -68,6 +68,7 @@ public function ___callParent($method, array $arguments)
*/
public function __sleep()
{
+ // phpcs:ignore Magento2.Functions.DiscouragedFunction
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
if (method_exists(get_parent_class($this), '__sleep')) {
@@ -89,6 +90,7 @@ public function __sleep()
*/
public function __wakeup()
{
+ // phpcs:ignore Magento2.Functions.DiscouragedFunction
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
if (method_exists(get_parent_class($this), '__wakeup')) {
diff --git a/lib/internal/Magento/Framework/Model/AbstractExtensibleModel.php b/lib/internal/Magento/Framework/Model/AbstractExtensibleModel.php
index f80c05a959046..8ae5a234911cd 100644
--- a/lib/internal/Magento/Framework/Model/AbstractExtensibleModel.php
+++ b/lib/internal/Magento/Framework/Model/AbstractExtensibleModel.php
@@ -368,6 +368,7 @@ private function populateExtensionAttributes(array $extensionAttributesData = []
*/
public function __sleep()
{
+ // phpcs:ignore Magento2.Functions.DiscouragedFunction
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
return array_diff(parent::__sleep(), ['extensionAttributesFactory', 'customAttributeFactory']);
@@ -381,6 +382,7 @@ public function __sleep()
*/
public function __wakeup()
{
+ // phpcs:ignore Magento2.Functions.DiscouragedFunction
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
parent::__wakeup();
diff --git a/lib/internal/Magento/Framework/Model/AbstractModel.php b/lib/internal/Magento/Framework/Model/AbstractModel.php
index 91b1ff338250c..7905ae280ff0c 100644
--- a/lib/internal/Magento/Framework/Model/AbstractModel.php
+++ b/lib/internal/Magento/Framework/Model/AbstractModel.php
@@ -226,6 +226,7 @@ protected function _init($resourceModel)
*/
public function __sleep()
{
+ // phpcs:ignore Magento2.Functions.DiscouragedFunction
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
$properties = array_keys(get_object_vars($this));
@@ -255,6 +256,7 @@ public function __sleep()
*/
public function __wakeup()
{
+ // phpcs:ignore Magento2.Functions.DiscouragedFunction
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
$objectManager = \Magento\Framework\App\ObjectManager::getInstance();
diff --git a/lib/internal/Magento/Framework/Model/ResourceModel/Db/AbstractDb.php b/lib/internal/Magento/Framework/Model/ResourceModel/Db/AbstractDb.php
index cf37296a7574e..8a0c78e4ff02b 100644
--- a/lib/internal/Magento/Framework/Model/ResourceModel/Db/AbstractDb.php
+++ b/lib/internal/Magento/Framework/Model/ResourceModel/Db/AbstractDb.php
@@ -163,6 +163,7 @@ public function __construct(
*/
public function __sleep()
{
+ // phpcs:ignore Magento2.Functions.DiscouragedFunction
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
$properties = array_keys(get_object_vars($this));
@@ -180,6 +181,7 @@ public function __sleep()
*/
public function __wakeup()
{
+ // phpcs:ignore Magento2.Functions.DiscouragedFunction
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
$this->_resources = \Magento\Framework\App\ObjectManager::getInstance()
diff --git a/lib/internal/Magento/Framework/Model/ResourceModel/Db/Collection/AbstractCollection.php b/lib/internal/Magento/Framework/Model/ResourceModel/Db/Collection/AbstractCollection.php
index 1f7c15fe4a5bd..4af5fd7a2a986 100644
--- a/lib/internal/Magento/Framework/Model/ResourceModel/Db/Collection/AbstractCollection.php
+++ b/lib/internal/Magento/Framework/Model/ResourceModel/Db/Collection/AbstractCollection.php
@@ -613,6 +613,7 @@ public function save()
*/
public function __sleep()
{
+ // phpcs:ignore Magento2.Functions.DiscouragedFunction
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
return array_diff(
@@ -630,6 +631,7 @@ public function __sleep()
*/
public function __wakeup()
{
+ // phpcs:ignore Magento2.Functions.DiscouragedFunction
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
parent::__wakeup();
diff --git a/lib/internal/Magento/Framework/Mview/Config/Data/Proxy.php b/lib/internal/Magento/Framework/Mview/Config/Data/Proxy.php
index cc7d831dc5e61..0de6c639812ad 100644
--- a/lib/internal/Magento/Framework/Mview/Config/Data/Proxy.php
+++ b/lib/internal/Magento/Framework/Mview/Config/Data/Proxy.php
@@ -64,6 +64,7 @@ public function __construct(
*/
public function __sleep()
{
+ // phpcs:ignore Magento2.Functions.DiscouragedFunction
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
return ['subject', 'isShared'];
@@ -79,6 +80,7 @@ public function __sleep()
*/
public function __wakeup()
{
+ // phpcs:ignore Magento2.Functions.DiscouragedFunction
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
$this->objectManager = \Magento\Framework\App\ObjectManager::getInstance();
diff --git a/lib/internal/Magento/Framework/Translate/Inline/Proxy.php b/lib/internal/Magento/Framework/Translate/Inline/Proxy.php
index add5c0dee66ed..0a9841adbfb08 100644
--- a/lib/internal/Magento/Framework/Translate/Inline/Proxy.php
+++ b/lib/internal/Magento/Framework/Translate/Inline/Proxy.php
@@ -64,6 +64,7 @@ public function __construct(
*/
public function __sleep()
{
+ // phpcs:ignore Magento2.Functions.DiscouragedFunction
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
return ['subject', 'isShared'];
@@ -79,6 +80,7 @@ public function __sleep()
*/
public function __wakeup()
{
+ // phpcs:ignore Magento2.Functions.DiscouragedFunction
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
$this->objectManager = \Magento\Framework\App\ObjectManager::getInstance();
diff --git a/lib/internal/Magento/Framework/View/Layout/Proxy.php b/lib/internal/Magento/Framework/View/Layout/Proxy.php
index d4897bb5cd101..a4550df566ff4 100644
--- a/lib/internal/Magento/Framework/View/Layout/Proxy.php
+++ b/lib/internal/Magento/Framework/View/Layout/Proxy.php
@@ -66,6 +66,7 @@ public function __construct(
*/
public function __sleep()
{
+ // phpcs:ignore Magento2.Functions.DiscouragedFunction
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
return ['_subject', '_isShared'];
@@ -81,6 +82,7 @@ public function __sleep()
*/
public function __wakeup()
{
+ // phpcs:ignore Magento2.Functions.DiscouragedFunction
trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
$this->_objectManager = \Magento\Framework\App\ObjectManager::getInstance();
From 264e7c6b7b4f045857c3a8364840034a115d9a85 Mon Sep 17 00:00:00 2001
From: Ani Tumanyan
Date: Tue, 30 Jul 2019 14:42:55 +0400
Subject: [PATCH 046/937] MC-15507: Shipping address is dropped after zip code
in new billing address form is filled
- Updated automated test script
---
.../Checkout/Test/Mftf/Section/CheckoutPaymentSection.xml | 2 +-
.../Checkout/Test/Mftf/Section/CheckoutShippingSection.xml | 2 +-
.../Test/Mftf/Section/SelectShippingAddressPopupSection.xml | 6 +++---
3 files changed, 5 insertions(+), 5 deletions(-)
diff --git a/app/code/Magento/Checkout/Test/Mftf/Section/CheckoutPaymentSection.xml b/app/code/Magento/Checkout/Test/Mftf/Section/CheckoutPaymentSection.xml
index e8119798bea46..0ebe78e44e7a3 100644
--- a/app/code/Magento/Checkout/Test/Mftf/Section/CheckoutPaymentSection.xml
+++ b/app/code/Magento/Checkout/Test/Mftf/Section/CheckoutPaymentSection.xml
@@ -60,6 +60,6 @@
-
+
diff --git a/app/code/Magento/Checkout/Test/Mftf/Section/CheckoutShippingSection.xml b/app/code/Magento/Checkout/Test/Mftf/Section/CheckoutShippingSection.xml
index 90df0c3475c41..6c2615083292e 100644
--- a/app/code/Magento/Checkout/Test/Mftf/Section/CheckoutShippingSection.xml
+++ b/app/code/Magento/Checkout/Test/Mftf/Section/CheckoutShippingSection.xml
@@ -44,6 +44,6 @@
-
+
diff --git a/app/code/Magento/Checkout/Test/Mftf/Section/SelectShippingAddressPopupSection.xml b/app/code/Magento/Checkout/Test/Mftf/Section/SelectShippingAddressPopupSection.xml
index ff1431ab33ba5..965ee4f4b10d8 100644
--- a/app/code/Magento/Checkout/Test/Mftf/Section/SelectShippingAddressPopupSection.xml
+++ b/app/code/Magento/Checkout/Test/Mftf/Section/SelectShippingAddressPopupSection.xml
@@ -9,8 +9,8 @@
From 48e7462eae84d7be2b50fda21935e8d5dea05826 Mon Sep 17 00:00:00 2001
From: natalia
Date: Fri, 2 Aug 2019 09:23:04 +0300
Subject: [PATCH 047/937] MC-18821: Increase test coverage for Catalog
functional area
- Integration test for MC-6328
---
.../Controller/Adminhtml/ProductTest.php | 63 +++++++++++++++----
1 file changed, 52 insertions(+), 11 deletions(-)
diff --git a/dev/tests/integration/testsuite/Magento/Catalog/Controller/Adminhtml/ProductTest.php b/dev/tests/integration/testsuite/Magento/Catalog/Controller/Adminhtml/ProductTest.php
index acec996d0c406..90b03510044d7 100644
--- a/dev/tests/integration/testsuite/Magento/Catalog/Controller/Adminhtml/ProductTest.php
+++ b/dev/tests/integration/testsuite/Magento/Catalog/Controller/Adminhtml/ProductTest.php
@@ -3,6 +3,8 @@
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
+declare(strict_types=1);
+
namespace Magento\Catalog\Controller\Adminhtml;
use Magento\Framework\App\Request\DataPersistorInterface;
@@ -10,8 +12,12 @@
use Magento\Framework\App\Request\Http as HttpRequest;
use Magento\Catalog\Api\ProductRepositoryInterface;
use Magento\Framework\Message\MessageInterface;
+use Magento\Catalog\Model\Product;
+use Magento\TestFramework\Helper\CacheCleaner;
/**
+ * Test class for Product adminhtml actions
+ *
* @magentoAppArea adminhtml
*/
class ProductTest extends \Magento\TestFramework\TestCase\AbstractBackendController
@@ -58,11 +64,10 @@ public function testSaveActionAndNew()
*/
public function testSaveActionAndDuplicate()
{
- $this->getRequest()->setPostValue(['back' => 'duplicate']);
$repository = $this->_objectManager->create(\Magento\Catalog\Model\ProductRepository::class);
+ /** @var Product $product */
$product = $repository->get('simple');
- $this->getRequest()->setMethod(HttpRequest::METHOD_POST);
- $this->dispatch('backend/catalog/product/save/id/' . $product->getEntityId());
+ $this->assertSaveAndDuplicateAction($product);
$this->assertRedirect($this->stringStartsWith('http://localhost/index.php/backend/catalog/product/edit/'));
$this->assertRedirect(
$this->logicalNot(
@@ -71,14 +76,30 @@ public function testSaveActionAndDuplicate()
)
)
);
- $this->assertSessionMessages(
- $this->contains('You saved the product.'),
- MessageInterface::TYPE_SUCCESS
- );
- $this->assertSessionMessages(
- $this->contains('You duplicated the product.'),
- MessageInterface::TYPE_SUCCESS
- );
+ }
+
+ /**
+ * Test saving and duplicate existing product after the script execution.
+ *
+ * @magentoDataFixture Magento/Catalog/_files/product_simple.php
+ */
+ public function testSaveActionAndDuplicateWithUrlPathAttribute()
+ {
+ $repository = $this->_objectManager->create(\Magento\Catalog\Model\ProductRepository::class);
+ /** @var Product $product */
+ $product = $repository->get('simple');
+
+ // set url_path attribute and check it
+ $product->setData('url_path', $product->getSku());
+ $repository->save($product);
+ $urlPathAttribute = $product->getCustomAttribute('url_path');
+ $this->assertEquals($urlPathAttribute->getValue(), $product->getSku());
+
+ // clean cache
+ CacheCleaner::cleanAll();
+
+ // dispatch Save&Duplicate action and check it
+ $this->assertSaveAndDuplicateAction($product);
}
/**
@@ -355,4 +376,24 @@ private function getProductData(array $tierPrice)
unset($product['entity_id']);
return $product;
}
+
+ /**
+ * Dispatch Save&Duplicate action and check it
+ *
+ * @param Product $product
+ */
+ private function assertSaveAndDuplicateAction(Product $product)
+ {
+ $this->getRequest()->setPostValue(['back' => 'duplicate']);
+ $this->getRequest()->setMethod(HttpRequest::METHOD_POST);
+ $this->dispatch('backend/catalog/product/save/id/' . $product->getEntityId());
+ $this->assertSessionMessages(
+ $this->contains('You saved the product.'),
+ MessageInterface::TYPE_SUCCESS
+ );
+ $this->assertSessionMessages(
+ $this->contains('You duplicated the product.'),
+ MessageInterface::TYPE_SUCCESS
+ );
+ }
}
From a1cedf1558e7b23583aa4968acdbcd4958f9355a Mon Sep 17 00:00:00 2001
From: vital_sery
Date: Fri, 2 Aug 2019 10:09:38 +0300
Subject: [PATCH 048/937] MC-18826: Increase test coverage for Cart & Checkout
and Order Processing functional areas
- Integration test for MC-11299
---
.../Sales/Model/Order/ShipmentTest.php | 38 +++++++++++++++++--
1 file changed, 35 insertions(+), 3 deletions(-)
diff --git a/dev/tests/integration/testsuite/Magento/Sales/Model/Order/ShipmentTest.php b/dev/tests/integration/testsuite/Magento/Sales/Model/Order/ShipmentTest.php
index 1d04a79ae3f84..9c0024480d164 100644
--- a/dev/tests/integration/testsuite/Magento/Sales/Model/Order/ShipmentTest.php
+++ b/dev/tests/integration/testsuite/Magento/Sales/Model/Order/ShipmentTest.php
@@ -117,9 +117,12 @@ public function testAddComment()
$saved = $this->shipmentRepository->save($shipment);
$comments = $saved->getComments();
- $actual = array_map(function (CommentInterface $comment) {
- return $comment->getComment();
- }, $comments);
+ $actual = array_map(
+ function (CommentInterface $comment) {
+ return $comment->getComment();
+ },
+ $comments
+ );
self::assertEquals(2, count($actual));
self::assertEquals([$message1, $message2], $actual);
}
@@ -144,4 +147,33 @@ private function getOrder(string $incrementId): OrderInterface
return array_pop($items);
}
+
+ /**
+ * Check that getTracksCollection() returns only order related tracks.
+ */
+ public function testGetTracksCollection()
+ {
+ $order = $this->getOrder('100000001');
+ $items = [];
+ foreach ($order->getItems() as $item) {
+ $items[$item->getId()] = $item->getQtyOrdered();
+ }
+ /** @var \Magento\Sales\Model\Order\Shipment $shipment */
+ $shipment = $this->objectManager->get(ShipmentFactory::class)
+ ->create($order, $items);
+
+ $tracks = $shipment->getTracksCollection();
+ self::assertTrue(empty($tracks->getItems()));
+
+ /** @var ShipmentTrackInterface $track */
+ $track = $this->objectManager->create(ShipmentTrackInterface::class);
+ $track->setNumber('Test Number')
+ ->setTitle('Test Title')
+ ->setCarrierCode('Test CODE');
+
+ $shipment->addTrack($track);
+ $this->shipmentRepository->save($shipment);
+ $saved = $shipment->getTracksCollection();
+ self::assertTrue(in_array($track->getId(), $saved->getColumnValues('id')));
+ }
}
From 42a5f9d6df6f7e323fbe7c47a8987ca8990319df Mon Sep 17 00:00:00 2001
From: natalia
Date: Fri, 2 Aug 2019 16:20:17 +0300
Subject: [PATCH 049/937] MC-18821: Increase test coverage for Catalog
functional area
- Integration test for MC-11232
---
.../Controller/Adminhtml/CategoryTest.php | 59 +++++++++++++++++++
1 file changed, 59 insertions(+)
diff --git a/dev/tests/integration/testsuite/Magento/Catalog/Controller/Adminhtml/CategoryTest.php b/dev/tests/integration/testsuite/Magento/Catalog/Controller/Adminhtml/CategoryTest.php
index 1001d58ee8a67..5e91d8b2092da 100644
--- a/dev/tests/integration/testsuite/Magento/Catalog/Controller/Adminhtml/CategoryTest.php
+++ b/dev/tests/integration/testsuite/Magento/Catalog/Controller/Adminhtml/CategoryTest.php
@@ -3,14 +3,21 @@
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
+
+declare(strict_types=1);
+
namespace Magento\Catalog\Controller\Adminhtml;
+use Magento\Catalog\Api\CategoryRepositoryInterface;
use Magento\Framework\App\Request\Http as HttpRequest;
+use Magento\Framework\Exception\NoSuchEntityException;
use Magento\TestFramework\Helper\Bootstrap;
use Magento\Store\Model\Store;
use Magento\Catalog\Model\ResourceModel\Product;
/**
+ * Test for category backend actions
+ *
* @magentoAppArea adminhtml
*/
class CategoryTest extends \Magento\TestFramework\TestCase\AbstractBackendController
@@ -36,6 +43,8 @@ protected function setUp()
}
/**
+ * Test save action
+ *
* @magentoDataFixture Magento/Store/_files/core_fixturestore.php
* @magentoDbIsolation enabled
* @magentoConfigFixture current_store catalog/frontend/flat_catalog_product 1
@@ -95,6 +104,44 @@ public function testSaveAction($inputData, $defaultAttributes, $attributesSaved
}
/**
+ * Check default value for category url path
+ *
+ * @magentoDbIsolation enabled
+ * @magentoDataFixture Magento/CatalogUrlRewrite/_files/categories.php
+ * @throws NoSuchEntityException
+ */
+ public function testDefaultValueForCategoryUrlPath()
+ {
+ $repository = $this->_objectManager->get(CategoryRepositoryInterface::class);
+ $categoryId = 3;
+ $category = $repository->get($categoryId);
+ $newUrlPath = 'test_url_path';
+ $defaultUrlPath = $category->getData('url_path');
+
+ // update url_path and check it
+ $category->setStoreId(1);
+ $category->setUrlKey($newUrlPath);
+ $category->setUrlPath($newUrlPath);
+ $repository->save($category);
+ $this->assertEquals($newUrlPath, $category->getUrlPath());
+
+ // set default url_path and check it
+ $this->getRequest()->setMethod(HttpRequest::METHOD_POST);
+ $postData = $category->getData();
+ $postData['use_default'] = [
+ 'available_sort_by' => 1,
+ 'default_sort_by' => 1,
+ 'url_key' => 1,
+ ];
+ $this->getRequest()->setPostValue($postData);
+ $this->dispatch('backend/catalog/category/save');
+ $category = $repository->get($categoryId);
+ $this->assertEquals($defaultUrlPath, $category->getData('url_path'));
+ }
+
+ /**
+ * Test save action from product form page
+ *
* @param array $postData
* @dataProvider categoryCreatedFromProductCreationPageDataProvider
* @magentoDbIsolation enabled
@@ -130,6 +177,8 @@ public function testSaveActionFromProductCreationPage($postData)
}
/**
+ * Get category post data
+ *
* @static
* @return array
*/
@@ -174,6 +223,8 @@ public function testSuggestCategoriesActionNoSuggestions()
}
/**
+ * Save action data provider
+ *
* @SuppressWarnings(PHPMD.ExcessiveMethodLength)
* @return array
*/
@@ -382,6 +433,8 @@ public function testSaveActionCategoryWithDangerRequest()
}
/**
+ * Test move Action
+ *
* @magentoDataFixture Magento/Catalog/_files/category_tree.php
* @dataProvider moveActionDataProvider
*
@@ -420,6 +473,8 @@ public function testMoveAction($parentId, $childId, $childUrlKey, $grandChildId,
}
/**
+ * Move action data provider
+ *
* @return array
*/
public function moveActionDataProvider()
@@ -433,6 +488,8 @@ public function moveActionDataProvider()
}
/**
+ * Test save action
+ *
* @magentoDataFixture Magento/Catalog/_files/products_in_different_stores.php
* @magentoDbIsolation disabled
* @dataProvider saveActionWithDifferentWebsitesDataProvider
@@ -460,6 +517,8 @@ public function testSaveCategoryWithProductPosition(array $postData)
}
/**
+ * Save action data provider
+ *
* @SuppressWarnings(PHPMD.ExcessiveMethodLength)
* @return array
*/
From 29051483b487beabda580f8a6e012e08402d48a9 Mon Sep 17 00:00:00 2001
From: natalia
Date: Mon, 5 Aug 2019 13:56:12 +0300
Subject: [PATCH 050/937] MC-18821: Increase test coverage for Catalog
functional area
- Integration test for MC-6308
---
.../Magento/Catalog/Model/ProductTest.php | 111 ++++++++++++++++--
1 file changed, 101 insertions(+), 10 deletions(-)
diff --git a/dev/tests/integration/testsuite/Magento/Catalog/Model/ProductTest.php b/dev/tests/integration/testsuite/Magento/Catalog/Model/ProductTest.php
index c34120404a950..d7da47ef78724 100644
--- a/dev/tests/integration/testsuite/Magento/Catalog/Model/ProductTest.php
+++ b/dev/tests/integration/testsuite/Magento/Catalog/Model/ProductTest.php
@@ -8,7 +8,12 @@
namespace Magento\Catalog\Model;
+use Magento\Catalog\Model\Product;
use Magento\Framework\App\Filesystem\DirectoryList;
+use Magento\Catalog\Api\ProductRepositoryInterface;
+use Magento\Catalog\Model\Product\Attribute\Source\Status;
+use Magento\Framework\ObjectManagerInterface;
+use Magento\TestFramework\Helper\Bootstrap;
/**
* Tests product model:
@@ -26,31 +31,32 @@
class ProductTest extends \PHPUnit\Framework\TestCase
{
/**
- * @var \Magento\Catalog\Api\ProductRepositoryInterface
+ * @var ProductRepositoryInterface
*/
protected $productRepository;
/**
- * @var \Magento\Catalog\Model\Product
+ * @var Product
*/
protected $_model;
+ /**
+ * @var ObjectManagerInterface
+ */
+ private $objectManager;
+
/**
* @inheritdoc
*/
protected function setUp()
{
- $this->productRepository = \Magento\TestFramework\Helper\Bootstrap::getObjectManager()
- ->create(\Magento\Catalog\Api\ProductRepositoryInterface::class);
-
- $this->_model = \Magento\TestFramework\Helper\Bootstrap::getObjectManager()->create(
- \Magento\Catalog\Model\Product::class
- );
+ $this->objectManager = Bootstrap::getObjectManager();
+ $this->productRepository = $this->objectManager->create(ProductRepositoryInterface::class);
+ $this->_model = $this->objectManager->create(Product::class);
}
/**
- * @throws \Magento\Framework\Exception\FileSystemException
- * @return void
+ * @inheritdoc
*/
public static function tearDownAfterClass()
{
@@ -74,6 +80,8 @@ public static function tearDownAfterClass()
}
/**
+ * Test can affect options
+ *
* @return void
*/
public function testCanAffectOptions()
@@ -84,6 +92,8 @@ public function testCanAffectOptions()
}
/**
+ * Test CRUD
+ *
* @magentoDbIsolation enabled
* @magentoAppIsolation enabled
* @magentoAppArea adminhtml
@@ -116,6 +126,8 @@ public function testCRUD()
}
/**
+ * Test clean cache
+ *
* @return void
*/
public function testCleanCache()
@@ -139,6 +151,8 @@ public function testCleanCache()
}
/**
+ * Test add image to media gallery
+ *
* @return void
*/
public function testAddImageToMediaGallery()
@@ -183,6 +197,8 @@ protected function _copyFileToBaseTmpMediaPath($sourceFile)
}
/**
+ * Test duplicate method
+ *
* @magentoAppIsolation enabled
* @magentoAppArea adminhtml
*/
@@ -213,6 +229,8 @@ public function testDuplicate()
}
/**
+ * Test duplicate sku generation
+ *
* @magentoAppArea adminhtml
*/
public function testDuplicateSkuGeneration()
@@ -244,6 +262,8 @@ protected function _undo($duplicate)
}
/**
+ * Test visibility api
+ *
* @covers \Magento\Catalog\Model\Product::getVisibleInCatalogStatuses
* @covers \Magento\Catalog\Model\Product::getVisibleStatuses
* @covers \Magento\Catalog\Model\Product::isVisibleInCatalog
@@ -286,6 +306,8 @@ public function testVisibilityApi()
}
/**
+ * Test isDuplicable and setIsDuplicable methods
+ *
* @covers \Magento\Catalog\Model\Product::isDuplicable
* @covers \Magento\Catalog\Model\Product::setIsDuplicable
*/
@@ -297,6 +319,8 @@ public function testIsDuplicable()
}
/**
+ * Test isSalable, isSaleable, isAvailable and isInStock methods
+ *
* @covers \Magento\Catalog\Model\Product::isSalable
* @covers \Magento\Catalog\Model\Product::isSaleable
* @covers \Magento\Catalog\Model\Product::isAvailable
@@ -314,6 +338,8 @@ public function testIsSalable()
}
/**
+ * Test isSalable method when Status is disabled
+ *
* @covers \Magento\Catalog\Model\Product::isSalable
* @covers \Magento\Catalog\Model\Product::isSaleable
* @covers \Magento\Catalog\Model\Product::isAvailable
@@ -331,6 +357,8 @@ public function testIsNotSalableWhenStatusDisabled()
}
/**
+ * Test isVirtual and getIsVirtual methods
+ *
* @covers \Magento\Catalog\Model\Product::isVirtual
* @covers \Magento\Catalog\Model\Product::getIsVirtual
*/
@@ -349,6 +377,8 @@ public function testIsVirtual()
}
/**
+ * Test toArray method
+ *
* @return void
*/
public function testToArray()
@@ -359,6 +389,8 @@ public function testToArray()
}
/**
+ * Test fromArray method
+ *
* @return void
*/
public function testFromArray()
@@ -368,6 +400,8 @@ public function testFromArray()
}
/**
+ * Test set original data backend
+ *
* @magentoAppArea adminhtml
*/
public function testSetOrigDataBackend()
@@ -378,6 +412,8 @@ public function testSetOrigDataBackend()
}
/**
+ * Test reset method
+ *
* @magentoAppArea frontend
*/
public function testReset()
@@ -418,6 +454,8 @@ protected function _assertEmpty($model)
}
/**
+ * Test is products has sku
+ *
* @magentoDataFixture Magento/Catalog/_files/multiple_products.php
*/
public function testIsProductsHasSku()
@@ -433,6 +471,8 @@ public function testIsProductsHasSku()
}
/**
+ * Test process by request
+ *
* @return void
*/
public function testProcessBuyRequest()
@@ -444,6 +484,8 @@ public function testProcessBuyRequest()
}
/**
+ * Test validate method
+ *
* @return void
*/
public function testValidate()
@@ -480,6 +522,8 @@ public function testValidate()
}
/**
+ * Test validate unique input attribute value
+ *
* @magentoDbIsolation enabled
* @magentoDataFixture Magento/Catalog/_files/products_with_unique_input_attribute.php
*/
@@ -523,6 +567,8 @@ public function testValidateUniqueInputAttributeValue()
}
/**
+ * Test validate unique input attribute value on the same product
+ *
* @magentoDbIsolation enabled
* @magentoDataFixture Magento/Catalog/_files/products_with_unique_input_attribute.php
*/
@@ -618,8 +664,53 @@ public function testSaveWithBackordersEnabled(int $qty, int $stockStatus, bool $
$this->assertEquals($expectedStockStatus, $stockItem->getIsInStock());
}
+ /**
+ * Checking enable/disable product when Catalog Flat Product is enabled
+ *
+ * @magentoAppArea frontend
+ * @magentoDbIsolation disabled
+ * @magentoConfigFixture current_store catalog/frontend/flat_catalog_product 1
+ * @magentoDataFixture Magento/Catalog/_files/product_simple.php
+ *
+ * @return void
+ * @throws \Magento\Framework\Exception\CouldNotSaveException
+ * @throws \Magento\Framework\Exception\InputException
+ * @throws \Magento\Framework\Exception\NoSuchEntityException
+ * @throws \Magento\Framework\Exception\StateException
+ */
+ public function testProductStatusWhenCatalogFlatProductIsEnabled()
+ {
+ // check if product flat table is enabled
+ $productFlatState = $this->objectManager->get(\Magento\Catalog\Model\Indexer\Product\Flat\State::class);
+ $this->assertTrue($productFlatState->isFlatEnabled());
+ // run reindex to create product flat table
+ $productFlatProcessor = $this->objectManager->get(\Magento\Catalog\Model\Indexer\Product\Flat\Processor::class);
+ $productFlatProcessor->reindexAll();
+ // get created simple product
+ $product = $this->productRepository->get('simple');
+ // get db connection and the product flat table name
+ $resource = $this->objectManager->get(\Magento\Framework\App\ResourceConnection::class);
+ /** @var \Magento\Framework\DB\Adapter\AdapterInterface $connection */
+ $connection = $resource->getConnection();
+ $productFlatTableName = $productFlatState->getFlatIndexerHelper()->getFlatTableName(1);
+ // generate sql query to find created simple product in the flat table
+ $sql = $connection->select()->from($productFlatTableName)->where('sku =?', $product->getSku());
+ // check if the product exists in the product flat table
+ $products = $connection->fetchAll($sql);
+ $this->assertEquals(Status::STATUS_ENABLED, $product->getStatus());
+ $this->assertNotEmpty($products);
+ // disable product
+ $product->setStatus(Status::STATUS_DISABLED);
+ $product = $this->productRepository->save($product);
+ // check if the product exists in the product flat table
+ $products = $connection->fetchAll($sql);
+ $this->assertEquals(Status::STATUS_DISABLED, $product->getStatus());
+ $this->assertEmpty($products);
+ }
+
/**
* DataProvider for the testSaveWithBackordersEnabled()
+ *
* @return array
*/
public function productWithBackordersDataProvider(): array
From f0856e8575bc0cc86543d14da2bd45d8e457fa25 Mon Sep 17 00:00:00 2001
From: David Verholen
Date: Tue, 6 Aug 2019 12:39:54 +0200
Subject: [PATCH 051/937] 24025 add caching for magento product version
fixes https://github.com/magento/magento2/issues/24025
---
.../Magento/Framework/App/ProductMetadata.php | 23 +++++++++++++++----
1 file changed, 19 insertions(+), 4 deletions(-)
diff --git a/lib/internal/Magento/Framework/App/ProductMetadata.php b/lib/internal/Magento/Framework/App/ProductMetadata.php
index c9fde94352a71..2829292555790 100644
--- a/lib/internal/Magento/Framework/App/ProductMetadata.php
+++ b/lib/internal/Magento/Framework/App/ProductMetadata.php
@@ -8,9 +8,9 @@
namespace Magento\Framework\App;
use Magento\Framework\Composer\ComposerFactory;
-use \Magento\Framework\Composer\ComposerJsonFinder;
-use \Magento\Framework\App\Filesystem\DirectoryList;
-use \Magento\Framework\Composer\ComposerInformation;
+use Magento\Framework\Composer\ComposerJsonFinder;
+use Magento\Framework\App\Filesystem\DirectoryList;
+use Magento\Framework\Composer\ComposerInformation;
/**
* Class ProductMetadata
@@ -28,6 +28,11 @@ class ProductMetadata implements ProductMetadataInterface
*/
const PRODUCT_NAME = 'Magento';
+ /**
+ * Magento Product Version Cache Key
+ */
+ const MAGENTO_PRODUCT_VERSION_CACHE_KEY = 'magento-product-version';
+
/**
* Product version
*
@@ -45,13 +50,19 @@ class ProductMetadata implements ProductMetadataInterface
* @var \Magento\Framework\Composer\ComposerInformation
*/
private $composerInformation;
+ /**
+ * @var CacheInterface
+ */
+ private $cache;
/**
* @param ComposerJsonFinder $composerJsonFinder
+ * @param CacheInterface|null $cache
*/
- public function __construct(ComposerJsonFinder $composerJsonFinder)
+ public function __construct(ComposerJsonFinder $composerJsonFinder, CacheInterface $cache = null)
{
$this->composerJsonFinder = $composerJsonFinder;
+ $this->cache = $cache ?: ObjectManager::getInstance()->get(CacheInterface::class);
}
/**
@@ -61,6 +72,9 @@ public function __construct(ComposerJsonFinder $composerJsonFinder)
*/
public function getVersion()
{
+ if ($cachedVersion = $this->cache->load(self::MAGENTO_PRODUCT_VERSION_CACHE_KEY)) {
+ $this->version = $cachedVersion;
+ }
if (!$this->version) {
if (!($this->version = $this->getSystemPackageVersion())) {
if ($this->getComposerInformation()->isMagentoRoot()) {
@@ -69,6 +83,7 @@ public function getVersion()
$this->version = 'UNKNOWN';
}
}
+ $this->cache->save($this->version, self::MAGENTO_PRODUCT_VERSION_CACHE_KEY);
}
return $this->version;
}
From 6cde8c528f93f8a1a1f32f60641a5c6baef9a57e Mon Sep 17 00:00:00 2001
From: Veronika Kurochkina
Date: Tue, 6 Aug 2019 15:42:33 +0300
Subject: [PATCH 052/937] MC-18821: Increase test coverage for Catalog
functional area
- Integration test for MC-11151
---
.../Adminhtml/Product/Set/SaveTest.php | 188 +++++++++++++++++-
.../_files/attribute_set_based_on_default.php | 22 ++
...ttribute_set_based_on_default_rollback.php | 21 ++
3 files changed, 220 insertions(+), 11 deletions(-)
create mode 100644 dev/tests/integration/testsuite/Magento/Catalog/_files/attribute_set_based_on_default.php
create mode 100644 dev/tests/integration/testsuite/Magento/Catalog/_files/attribute_set_based_on_default_rollback.php
diff --git a/dev/tests/integration/testsuite/Magento/Catalog/Controller/Adminhtml/Product/Set/SaveTest.php b/dev/tests/integration/testsuite/Magento/Catalog/Controller/Adminhtml/Product/Set/SaveTest.php
index 8ccd426424a29..a3f9c542809a3 100644
--- a/dev/tests/integration/testsuite/Magento/Catalog/Controller/Adminhtml/Product/Set/SaveTest.php
+++ b/dev/tests/integration/testsuite/Magento/Catalog/Controller/Adminhtml/Product/Set/SaveTest.php
@@ -3,6 +3,8 @@
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
+declare(strict_types=1);
+
namespace Magento\Catalog\Controller\Adminhtml\Product\Set;
use Magento\Eav\Api\AttributeSetRepositoryInterface;
@@ -10,9 +12,86 @@
use Magento\Framework\Api\SearchCriteriaBuilder;
use Magento\TestFramework\Helper\Bootstrap;
use Magento\Framework\App\Request\Http as HttpRequest;
+use Magento\Eav\Api\AttributeManagementInterface;
+use Magento\Catalog\Api\Data\ProductInterfaceFactory;
+use Magento\Framework\Api\DataObjectHelper;
+use Magento\Catalog\Api\ProductRepositoryInterface;
+use Magento\Catalog\Api\Data\ProductInterface;
+use Magento\Developer\Model\Logger\Handler\Syslog;
+use Magento\Framework\Logger\Monolog;
+use Magento\Catalog\Model\Product\Attribute\Repository;
+/**
+ * Test save attribute set
+ *
+ * @SuppressWarnings(PHPMD.CouplingBetweenObjects)
+ */
class SaveTest extends \Magento\TestFramework\TestCase\AbstractBackendController
{
+ /**
+ * @var string
+ */
+ private $systemLogPath = '';
+
+ /**
+ * @var Monolog
+ */
+ private $logger;
+
+ /**
+ * @var Syslog
+ */
+ private $syslogHandler;
+
+ /**
+ * @var AttributeManagementInterface
+ */
+ private $attributeManagement;
+
+ /**
+ * @var DataObjectHelper
+ */
+ private $dataObjectHelper;
+
+ /**
+ * @var ProductRepositoryInterface
+ */
+ private $productRepository;
+
+ /**
+ * @var Repository
+ */
+ private $attributeRepository;
+
+ /**
+ * @inheritDoc
+ */
+ public function setUp()
+ {
+ parent::setUp();
+ $this->logger = $this->_objectManager->get(Monolog::class);
+ $this->syslogHandler = $this->_objectManager->create(
+ Syslog::class,
+ [
+ 'filePath' => Bootstrap::getInstance()->getAppTempDir(),
+ ]
+ );
+ $this->attributeManagement = $this->_objectManager->get(AttributeManagementInterface::class);
+ $this->productRepository = $this->_objectManager->get(ProductRepositoryInterface::class);
+ $this->attributeRepository = $this->_objectManager->get(Repository::class);
+ $this->dataObjectHelper = $this->_objectManager->get(DataObjectHelper::class);
+ }
+
+ /**
+ * @inheritdoc
+ * @throws \Magento\Framework\Exception\FileSystemException
+ */
+ public function tearDown()
+ {
+ $this->attributeRepository->get('country_of_manufacture')->setIsUserDefined(false);
+ parent::tearDown();
+ }
+
/**
* @magentoDataFixture Magento/Catalog/_files/attribute_set_with_renamed_group.php
*/
@@ -22,17 +101,22 @@ public function testAlreadyExistsExceptionProcessingWhenGroupCodeIsDuplicated()
$this->assertNotEmpty($attributeSet, 'Attribute set with name "attribute_set_test" is missed');
$this->getRequest()->setMethod(HttpRequest::METHOD_POST);
- $this->getRequest()->setPostValue('data', json_encode([
- 'attribute_set_name' => 'attribute_set_test',
- 'groups' => [
- ['ynode-418', 'attribute-group-name', 1],
- ],
- 'attributes' => [
- ['9999', 'ynode-418', 1, null]
- ],
- 'not_attributes' => [],
- 'removeGroups' => [],
- ]));
+ $this->getRequest()->setPostValue(
+ 'data',
+ json_encode(
+ [
+ 'attribute_set_name' => 'attribute_set_test',
+ 'groups' => [
+ ['ynode-418', 'attribute-group-name', 1],
+ ],
+ 'attributes' => [
+ ['9999', 'ynode-418', 1, null]
+ ],
+ 'not_attributes' => [],
+ 'removeGroups' => [],
+ ]
+ )
+ );
$this->dispatch('backend/catalog/product_set/save/id/' . $attributeSet->getAttributeSetId());
$jsonResponse = json_decode($this->getResponse()->getBody());
@@ -63,4 +147,86 @@ protected function getAttributeSetByName($attributeSetName)
$items = $result->getItems();
return $result->getTotalCount() ? array_pop($items) : null;
}
+
+ /**
+ * Test behavior when attribute set was changed to a new set
+ * with deleted attribute from the previous set
+ *
+ * @magentoDataFixture Magento/Catalog/_files/product_simple.php
+ * @magentoDataFixture Magento/Catalog/_files/attribute_set_based_on_default.php
+ * @magentoDbIsolation disabled
+ */
+ public function testRemoveAttributeFromAttributeSet()
+ {
+ $message = 'Attempt to load value of nonexistent EAV attribute';
+ $this->removeSyslog();
+ $attributeSet = $this->getAttributeSetByName('new_attribute_set');
+ $product = $this->productRepository->get('simple');
+ $this->attributeRepository->get('country_of_manufacture')->setIsUserDefined(true);
+ $this->attributeManagement->unassign($attributeSet->getId(), 'country_of_manufacture');
+ $productData = [
+ 'country_of_manufacture' => 'Angola'
+ ];
+ $this->dataObjectHelper->populateWithArray($product, $productData, ProductInterface::class);
+ $this->productRepository->save($product);
+ $product->setAttributeSetId($attributeSet->getId());
+ $product = $this->productRepository->save($product);
+ $this->dispatch('backend/catalog/product/edit/id/' . $product->getEntityId());
+ $this->assertNotContains($message, $this->getSyslogContent());
+ }
+
+ /**
+ * Retrieve system.log file path
+ *
+ * @return string
+ */
+ private function getSyslogPath()
+ {
+ if (!$this->systemLogPath) {
+ foreach ($this->logger->getHandlers() as $handler) {
+ if ($handler instanceof \Magento\Framework\Logger\Handler\System) {
+ $this->systemLogPath = $handler->getUrl();
+ }
+ }
+ }
+
+ return $this->systemLogPath;
+ }
+
+ /**
+ * Remove system.log file
+ *
+ * @return void
+ */
+ private function removeSyslog()
+ {
+ $this->detachLogger();
+ if (file_exists($this->getSyslogPath())) {
+ unlink($this->getSyslogPath());
+ }
+ }
+
+ /**
+ * Detach system log handler.
+ *
+ * @return void
+ */
+ private function detachLogger()
+ {
+ $this->syslogHandler->close();
+ }
+
+ /**
+ * Retrieve content of system.log file
+ *
+ * @return bool|string
+ */
+ private function getSyslogContent()
+ {
+ if (!file_exists($this->getSyslogPath())) {
+ return '';
+ }
+
+ return file_get_contents($this->getSyslogPath());
+ }
}
diff --git a/dev/tests/integration/testsuite/Magento/Catalog/_files/attribute_set_based_on_default.php b/dev/tests/integration/testsuite/Magento/Catalog/_files/attribute_set_based_on_default.php
new file mode 100644
index 0000000000000..d48578aa73465
--- /dev/null
+++ b/dev/tests/integration/testsuite/Magento/Catalog/_files/attribute_set_based_on_default.php
@@ -0,0 +1,22 @@
+create(\Magento\Eav\Model\Entity\Attribute\Set::class);
+$entityType = $objectManager->create(\Magento\Eav\Model\Entity\Type::class)->loadByCode('catalog_product');
+$defaultSetId = $objectManager->create(\Magento\Catalog\Model\Product::class)->getDefaultAttributeSetid();
+$data = [
+ 'attribute_set_name' => 'new_attribute_set',
+ 'entity_type_id' => $entityType->getId(),
+ 'sort_order' => 300,
+];
+
+$attributeSet->setData($data);
+$attributeSet->validate();
+$attributeSet->save();
+$attributeSet->initFromSkeleton($defaultSetId);
+$attributeSet->save();
diff --git a/dev/tests/integration/testsuite/Magento/Catalog/_files/attribute_set_based_on_default_rollback.php b/dev/tests/integration/testsuite/Magento/Catalog/_files/attribute_set_based_on_default_rollback.php
new file mode 100644
index 0000000000000..981aed5d0ca28
--- /dev/null
+++ b/dev/tests/integration/testsuite/Magento/Catalog/_files/attribute_set_based_on_default_rollback.php
@@ -0,0 +1,21 @@
+create(\Magento\Eav\Model\Entity\Type::class)->loadByCode('catalog_product');
+
+$attributeSetCollection = $objectManager->create(
+ \Magento\Eav\Model\ResourceModel\Entity\Attribute\Set\Collection::class
+);
+$attributeSetCollection->addFilter('attribute_set_name', 'new_attribute_set');
+$attributeSetCollection->addFilter('entity_type_id', $entityType->getId());
+$attributeSetCollection->setOrder('attribute_set_id');
+$attributeSetCollection->setPageSize(1);
+$attributeSetCollection->load();
+
+$attributeSet = $attributeSetCollection->fetchItem();
+$attributeSet->delete();
From bd5b7c584de95da97200be47d6f63fd9eda372f7 Mon Sep 17 00:00:00 2001
From: Stsiapan Korf
Date: Wed, 7 Aug 2019 12:58:54 +0000
Subject: [PATCH 053/937] MAGETWO-98748: Incorrect behavior in the category
menu on the Storefront
- Add cache key info about active category
---
.../Magento/Catalog/Plugin/Block/Topmenu.php | 17 +++++++++++++++++
1 file changed, 17 insertions(+)
diff --git a/app/code/Magento/Catalog/Plugin/Block/Topmenu.php b/app/code/Magento/Catalog/Plugin/Block/Topmenu.php
index 44f9193ab4012..d788525356fab 100644
--- a/app/code/Magento/Catalog/Plugin/Block/Topmenu.php
+++ b/app/code/Magento/Catalog/Plugin/Block/Topmenu.php
@@ -193,4 +193,21 @@ protected function getCategoryTree($storeId, $rootId)
return $collection;
}
+
+ /**
+ * Add active
+ *
+ * @param \Magento\Theme\Block\Html\Topmenu $subject
+ * @param string[] $result
+ * @return string[]
+ */
+ public function afterGetCacheKeyInfo(\Magento\Theme\Block\Html\Topmenu $subject, array $result)
+ {
+ $activeCategory = $this->getCurrentCategory();
+ if ($activeCategory) {
+ $result[] = Category::CACHE_TAG . '_' . $activeCategory->getId();
+ }
+
+ return $result;
+ }
}
From ed1fb0358045fd988c59a00e68099cf3632e5865 Mon Sep 17 00:00:00 2001
From: David Verholen
Date: Wed, 7 Aug 2019 15:30:34 +0200
Subject: [PATCH 054/937] 24025 add caching for magento product version
fixes https://github.com/magento/magento2/issues/24025
---
lib/internal/Magento/Framework/App/ProductMetadata.php | 1 +
1 file changed, 1 insertion(+)
diff --git a/lib/internal/Magento/Framework/App/ProductMetadata.php b/lib/internal/Magento/Framework/App/ProductMetadata.php
index 2829292555790..d5da7aeba3054 100644
--- a/lib/internal/Magento/Framework/App/ProductMetadata.php
+++ b/lib/internal/Magento/Framework/App/ProductMetadata.php
@@ -14,6 +14,7 @@
/**
* Class ProductMetadata
+ *
* @package Magento\Framework\App
*/
class ProductMetadata implements ProductMetadataInterface
From bda4eb198e5bb0c392c3d6cbe8fb20d14b197f29 Mon Sep 17 00:00:00 2001
From: Dzmitry Tabusheu
Date: Wed, 7 Aug 2019 16:43:36 +0300
Subject: [PATCH 055/937] MC-18823: Increase test coverage for Framework and
Performance functional areas
- Integration test for MC-6399
---
.../Magento/Catalog/Model/Product/UrlTest.php | 48 +++++++++++++++++++
1 file changed, 48 insertions(+)
diff --git a/dev/tests/integration/testsuite/Magento/Catalog/Model/Product/UrlTest.php b/dev/tests/integration/testsuite/Magento/Catalog/Model/Product/UrlTest.php
index 4cf059d4bf692..afe052d9d853e 100644
--- a/dev/tests/integration/testsuite/Magento/Catalog/Model/Product/UrlTest.php
+++ b/dev/tests/integration/testsuite/Magento/Catalog/Model/Product/UrlTest.php
@@ -5,11 +5,15 @@
*/
namespace Magento\Catalog\Model\Product;
+use Magento\UrlRewrite\Service\V1\Data\UrlRewrite;
+use Magento\CatalogUrlRewrite\Model\ProductUrlRewriteGenerator;
+
/**
* Test class for \Magento\Catalog\Model\Product\Url.
*
* @magentoDataFixture Magento/Catalog/_files/url_rewrites.php
* @magentoAppArea frontend
+ * @SuppressWarnings(PHPMD.CouplingBetweenObjects)
*/
class UrlTest extends \PHPUnit\Framework\TestCase
{
@@ -132,4 +136,48 @@ public function testGetUrl()
$product->setId(100);
$this->assertContains('catalog/product/view/id/100/', $this->_model->getUrl($product));
}
+
+ /**
+ * Check that rearranging product url rewrites do not influence on whether to use category in product links
+ *
+ * @magentoConfigFixture current_store catalog/seo/product_use_categories 0
+ */
+ public function testGetProductUrlWithRearrangedUrlRewrites()
+ {
+ $productRepository = \Magento\TestFramework\Helper\Bootstrap::getObjectManager()->create(
+ \Magento\Catalog\Model\ProductRepository::class
+ );
+ $categoryRepository = \Magento\TestFramework\Helper\Bootstrap::getObjectManager()->create(
+ \Magento\Catalog\Model\CategoryRepository::class
+ );
+ $registry = \Magento\TestFramework\Helper\Bootstrap::getObjectManager()->get(
+ \Magento\Framework\Registry::class
+ );
+ $urlFinder = \Magento\TestFramework\Helper\Bootstrap::getObjectManager()->create(
+ \Magento\UrlRewrite\Model\UrlFinderInterface::class
+ );
+ $urlPersist = \Magento\TestFramework\Helper\Bootstrap::getObjectManager()->create(
+ \Magento\UrlRewrite\Model\UrlPersistInterface::class
+ );
+
+ $product = $productRepository->get('simple');
+ $category = $categoryRepository->get($product->getCategoryIds()[0]);
+ $registry->register('current_category', $category);
+ $this->assertNotContains($category->getUrlPath(), $this->_model->getProductUrl($product));
+
+ $rewrites = $urlFinder->findAllByData(
+ [
+ UrlRewrite::ENTITY_ID => $product->getId(),
+ UrlRewrite::ENTITY_TYPE => ProductUrlRewriteGenerator::ENTITY_TYPE
+ ]
+ );
+ $this->assertGreaterThan(1, count($rewrites));
+ foreach ($rewrites as $rewrite) {
+ if ($rewrite->getRequestPath() === 'simple-product.html') {
+ $rewrite->setUrlRewriteId($rewrite->getUrlRewriteId() + 1000);
+ }
+ }
+ $urlPersist->replace($rewrites);
+ $this->assertNotContains($category->getUrlPath(), $this->_model->getProductUrl($product));
+ }
}
From 98a84f75ce696647391a688001006d975bb98263 Mon Sep 17 00:00:00 2001
From: Oleksandr Gorkun
Date: Wed, 7 Aug 2019 11:33:46 -0500
Subject: [PATCH 056/937] MAGETWO-96975: Remove __sleep and __wakeup from code
---
app/code/Magento/Authorization/Model/Role.php | 6 ----
.../Magento/Backend/Model/Auth/Session.php | 10 ++++--
.../Model/ResourceModel/Eav/Attribute.php | 6 ----
.../Config/Model/Config/Backend/Encrypted.php | 6 ----
.../Product/Type/Configurable/Attribute.php | 6 ----
.../Configurable/Attribute/Collection.php | 6 ----
app/code/Magento/Customer/Model/Attribute.php | 6 ----
.../Magento/Eav/Model/Entity/Attribute.php | 6 ----
.../Entity/Attribute/AbstractAttribute.php | 6 ----
.../Model/ResourceModel/Entity/Attribute.php | 6 ----
app/code/Magento/Store/Model/Store.php | 6 ----
app/code/Magento/User/Model/User.php | 6 ----
.../Backend/Model/Auth/SessionTest.php | 32 +++++++++++++++++++
.../Magento/Framework/App/AreaList/Proxy.php | 6 ----
.../Magento/Framework/App/Response/Http.php | 6 ----
.../App/Route/ConfigInterface/Proxy.php | 6 ----
lib/internal/Magento/Framework/DB/Select.php | 6 ----
.../Framework/DB/Select/RendererProxy.php | 6 ----
.../Magento/Framework/Data/Collection.php | 6 ----
.../Framework/Data/Collection/AbstractDb.php | 6 ----
.../DataObject/Copy/Config/Data/Proxy.php | 6 ----
.../Framework/Interception/Interceptor.php | 6 ----
.../Model/AbstractExtensibleModel.php | 6 ----
.../Magento/Framework/Model/AbstractModel.php | 6 ----
.../Model/ResourceModel/Db/AbstractDb.php | 6 ----
.../Db/Collection/AbstractCollection.php | 6 ----
.../Framework/Mview/Config/Data/Proxy.php | 6 ----
.../Framework/Translate/Inline/Proxy.php | 6 ----
.../Magento/Framework/View/Layout/Proxy.php | 6 ----
29 files changed, 40 insertions(+), 164 deletions(-)
diff --git a/app/code/Magento/Authorization/Model/Role.php b/app/code/Magento/Authorization/Model/Role.php
index 40a1c7149a524..042e95806ae18 100644
--- a/app/code/Magento/Authorization/Model/Role.php
+++ b/app/code/Magento/Authorization/Model/Role.php
@@ -58,9 +58,6 @@ public function __construct( //phpcs:ignore Generic.CodeAnalysis.UselessOverridi
*/
public function __sleep()
{
- // phpcs:ignore Magento2.Functions.DiscouragedFunction
- trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
-
$properties = parent::__sleep();
return array_diff($properties, ['_resource', '_resourceCollection']);
}
@@ -73,9 +70,6 @@ public function __sleep()
*/
public function __wakeup()
{
- // phpcs:ignore Magento2.Functions.DiscouragedFunction
- trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
-
parent::__wakeup();
$objectManager = \Magento\Framework\App\ObjectManager::getInstance();
$this->_resource = $objectManager->get(\Magento\Authorization\Model\ResourceModel\Role::class);
diff --git a/app/code/Magento/Backend/Model/Auth/Session.php b/app/code/Magento/Backend/Model/Auth/Session.php
index d34323d4bec87..6d2f8f6a21d4a 100644
--- a/app/code/Magento/Backend/Model/Auth/Session.php
+++ b/app/code/Magento/Backend/Model/Auth/Session.php
@@ -325,6 +325,8 @@ public function getUser()
$user = $this->userFactory->create();
$this->userHydrator->hydrate($user, $userData);
$this->user = $user;
+ } elseif ($user = parent::getUser()) {
+ $this->setUser($user);
}
}
@@ -355,7 +357,7 @@ public function setUser($user)
*/
public function hasUser()
{
- return $this->user || $this->hasUserData();
+ return (bool)$this->getUser();
}
/**
@@ -366,6 +368,7 @@ public function hasUser()
public function unsUser()
{
$this->user = null;
+ parent::unsUser();
return $this->unsUserData();
}
@@ -383,6 +386,8 @@ public function getAcl()
$acl = $this->aclFactory->create();
$this->aclHydrator->hydrate($acl, $aclData);
$this->acl = $acl;
+ } elseif ($acl = parent::getAcl()) {
+ $this->setAcl($acl);
}
}
@@ -413,7 +418,7 @@ public function setAcl($acl)
*/
public function hasAcl()
{
- return $this->acl || $this->hasUserAclData();
+ return (bool)$this->getAcl();
}
/**
@@ -424,6 +429,7 @@ public function hasAcl()
public function unsAcl()
{
$this->acl = null;
+ parent::unsAcl();
return $this->unsUserAclData();
}
diff --git a/app/code/Magento/Catalog/Model/ResourceModel/Eav/Attribute.php b/app/code/Magento/Catalog/Model/ResourceModel/Eav/Attribute.php
index ce7e5cd42f282..a1eaa956e8351 100644
--- a/app/code/Magento/Catalog/Model/ResourceModel/Eav/Attribute.php
+++ b/app/code/Magento/Catalog/Model/ResourceModel/Eav/Attribute.php
@@ -852,9 +852,6 @@ public function afterDelete()
*/
public function __sleep()
{
- // phpcs:ignore Magento2.Functions.DiscouragedFunction
- trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
-
$this->unsetData('entity_type');
return array_diff(
parent::__sleep(),
@@ -871,9 +868,6 @@ public function __sleep()
*/
public function __wakeup()
{
- // phpcs:ignore Magento2.Functions.DiscouragedFunction
- trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
-
parent::__wakeup();
$objectManager = \Magento\Framework\App\ObjectManager::getInstance();
$this->_indexerEavProcessor = $objectManager->get(\Magento\Catalog\Model\Indexer\Product\Flat\Processor::class);
diff --git a/app/code/Magento/Config/Model/Config/Backend/Encrypted.php b/app/code/Magento/Config/Model/Config/Backend/Encrypted.php
index fc4d0a54bb13d..80ce061a0a17e 100644
--- a/app/code/Magento/Config/Model/Config/Backend/Encrypted.php
+++ b/app/code/Magento/Config/Model/Config/Backend/Encrypted.php
@@ -54,9 +54,6 @@ public function __construct(
*/
public function __sleep()
{
- // phpcs:ignore Magento2.Functions.DiscouragedFunction
- trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
-
$properties = parent::__sleep();
return array_diff($properties, ['_encryptor']);
}
@@ -71,9 +68,6 @@ public function __sleep()
*/
public function __wakeup()
{
- // phpcs:ignore Magento2.Functions.DiscouragedFunction
- trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
-
parent::__wakeup();
$this->_encryptor = \Magento\Framework\App\ObjectManager::getInstance()->get(
\Magento\Framework\Encryption\EncryptorInterface::class
diff --git a/app/code/Magento/ConfigurableProduct/Model/Product/Type/Configurable/Attribute.php b/app/code/Magento/ConfigurableProduct/Model/Product/Type/Configurable/Attribute.php
index 0f34cb9f89474..01549ffcd2755 100644
--- a/app/code/Magento/ConfigurableProduct/Model/Product/Type/Configurable/Attribute.php
+++ b/app/code/Magento/ConfigurableProduct/Model/Product/Type/Configurable/Attribute.php
@@ -270,9 +270,6 @@ public function setProductId($value)
*/
public function __sleep()
{
- // phpcs:ignore Magento2.Functions.DiscouragedFunction
- trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
-
return array_diff(
parent::__sleep(),
['metadataPool']
@@ -287,9 +284,6 @@ public function __sleep()
*/
public function __wakeup()
{
- // phpcs:ignore Magento2.Functions.DiscouragedFunction
- trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
-
parent::__wakeup();
$objectManager = \Magento\Framework\App\ObjectManager::getInstance();
$this->metadataPool = $objectManager->get(MetadataPool::class);
diff --git a/app/code/Magento/ConfigurableProduct/Model/ResourceModel/Product/Type/Configurable/Attribute/Collection.php b/app/code/Magento/ConfigurableProduct/Model/ResourceModel/Product/Type/Configurable/Attribute/Collection.php
index 81dd0e42e3d3d..3aa90c7b3ce57 100644
--- a/app/code/Magento/ConfigurableProduct/Model/ResourceModel/Product/Type/Configurable/Attribute/Collection.php
+++ b/app/code/Magento/ConfigurableProduct/Model/ResourceModel/Product/Type/Configurable/Attribute/Collection.php
@@ -363,9 +363,6 @@ protected function getIncludedOptions(array $usedProducts, AbstractAttribute $pr
*/
public function __sleep()
{
- // phpcs:ignore Magento2.Functions.DiscouragedFunction
- trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
-
return array_diff(
parent::__sleep(),
[
@@ -388,9 +385,6 @@ public function __sleep()
*/
public function __wakeup()
{
- // phpcs:ignore Magento2.Functions.DiscouragedFunction
- trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
-
parent::__wakeup();
$objectManager = ObjectManager::getInstance();
$this->_storeManager = $objectManager->get(\Magento\Store\Model\StoreManagerInterface::class);
diff --git a/app/code/Magento/Customer/Model/Attribute.php b/app/code/Magento/Customer/Model/Attribute.php
index 773b9643298a5..d05bf14fbc97d 100644
--- a/app/code/Magento/Customer/Model/Attribute.php
+++ b/app/code/Magento/Customer/Model/Attribute.php
@@ -208,9 +208,6 @@ public function canBeFilterableInGrid()
*/
public function __sleep()
{
- // phpcs:ignore Magento2.Functions.DiscouragedFunction
- trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
-
$this->unsetData('entity_type');
return array_diff(
parent::__sleep(),
@@ -226,9 +223,6 @@ public function __sleep()
*/
public function __wakeup()
{
- // phpcs:ignore Magento2.Functions.DiscouragedFunction
- trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
-
parent::__wakeup();
$objectManager = \Magento\Framework\App\ObjectManager::getInstance();
$this->indexerRegistry = $objectManager->get(\Magento\Framework\Indexer\IndexerRegistry::class);
diff --git a/app/code/Magento/Eav/Model/Entity/Attribute.php b/app/code/Magento/Eav/Model/Entity/Attribute.php
index b6522cdb2dda3..f20921db769d4 100644
--- a/app/code/Magento/Eav/Model/Entity/Attribute.php
+++ b/app/code/Magento/Eav/Model/Entity/Attribute.php
@@ -495,9 +495,6 @@ public function getIdentities()
*/
public function __sleep()
{
- // phpcs:ignore Magento2.Functions.DiscouragedFunction
- trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
-
$this->unsetData('attribute_set_info');
return array_diff(
parent::__sleep(),
@@ -514,9 +511,6 @@ public function __sleep()
*/
public function __wakeup()
{
- // phpcs:ignore Magento2.Functions.DiscouragedFunction
- trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
-
parent::__wakeup();
$objectManager = ObjectManager::getInstance();
$this->_localeDate = $objectManager->get(\Magento\Framework\Stdlib\DateTime\TimezoneInterface::class);
diff --git a/app/code/Magento/Eav/Model/Entity/Attribute/AbstractAttribute.php b/app/code/Magento/Eav/Model/Entity/Attribute/AbstractAttribute.php
index f33ec1d5423e3..16fe495de18db 100644
--- a/app/code/Magento/Eav/Model/Entity/Attribute/AbstractAttribute.php
+++ b/app/code/Magento/Eav/Model/Entity/Attribute/AbstractAttribute.php
@@ -1411,9 +1411,6 @@ public function setExtensionAttributes(\Magento\Eav\Api\Data\AttributeExtensionI
*/
public function __sleep()
{
- // phpcs:ignore Magento2.Functions.DiscouragedFunction
- trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
-
return array_diff(
parent::__sleep(),
[
@@ -1442,9 +1439,6 @@ public function __sleep()
*/
public function __wakeup()
{
- // phpcs:ignore Magento2.Functions.DiscouragedFunction
- trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
-
parent::__wakeup();
$objectManager = \Magento\Framework\App\ObjectManager::getInstance();
$this->_eavConfig = $objectManager->get(\Magento\Eav\Model\Config::class);
diff --git a/app/code/Magento/Eav/Model/ResourceModel/Entity/Attribute.php b/app/code/Magento/Eav/Model/ResourceModel/Entity/Attribute.php
index e2d7ef7ff3581..a40acab5eb67a 100644
--- a/app/code/Magento/Eav/Model/ResourceModel/Entity/Attribute.php
+++ b/app/code/Magento/Eav/Model/ResourceModel/Entity/Attribute.php
@@ -731,9 +731,6 @@ public function getValidAttributeIds($attributeIds)
*/
public function __sleep()
{
- // phpcs:ignore Magento2.Functions.DiscouragedFunction
- trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
-
$properties = parent::__sleep();
$properties = array_diff($properties, ['_storeManager']);
return $properties;
@@ -750,9 +747,6 @@ public function __sleep()
*/
public function __wakeup()
{
- // phpcs:ignore Magento2.Functions.DiscouragedFunction
- trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
-
parent::__wakeup();
$this->_storeManager = \Magento\Framework\App\ObjectManager::getInstance()
->get(\Magento\Store\Model\StoreManagerInterface::class);
diff --git a/app/code/Magento/Store/Model/Store.php b/app/code/Magento/Store/Model/Store.php
index 76e8a7019007e..e8e2ddebd3f41 100644
--- a/app/code/Magento/Store/Model/Store.php
+++ b/app/code/Magento/Store/Model/Store.php
@@ -429,9 +429,6 @@ public function __construct(
*/
public function __sleep()
{
- // phpcs:ignore Magento2.Functions.DiscouragedFunction
- trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
-
$properties = parent::__sleep();
$properties = array_diff($properties, ['_coreFileStorageDatabase', '_config']);
return $properties;
@@ -447,9 +444,6 @@ public function __sleep()
*/
public function __wakeup()
{
- // phpcs:ignore Magento2.Functions.DiscouragedFunction
- trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
-
parent::__wakeup();
$this->_coreFileStorageDatabase = ObjectManager::getInstance()
->get(\Magento\MediaStorage\Helper\File\Storage\Database::class);
diff --git a/app/code/Magento/User/Model/User.php b/app/code/Magento/User/Model/User.php
index a81e7af1e983a..029c867d2d1dd 100644
--- a/app/code/Magento/User/Model/User.php
+++ b/app/code/Magento/User/Model/User.php
@@ -218,9 +218,6 @@ protected function _construct()
*/
public function __sleep()
{
- // phpcs:ignore Magento2.Functions.DiscouragedFunction
- trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
-
$properties = parent::__sleep();
return array_diff(
$properties,
@@ -252,9 +249,6 @@ public function __sleep()
*/
public function __wakeup()
{
- // phpcs:ignore Magento2.Functions.DiscouragedFunction
- trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
-
parent::__wakeup();
$objectManager = \Magento\Framework\App\ObjectManager::getInstance();
$this->serializer = $objectManager->get(Json::class);
diff --git a/dev/tests/integration/testsuite/Magento/Backend/Model/Auth/SessionTest.php b/dev/tests/integration/testsuite/Magento/Backend/Model/Auth/SessionTest.php
index f1e7a10737604..5ef518fd2152f 100644
--- a/dev/tests/integration/testsuite/Magento/Backend/Model/Auth/SessionTest.php
+++ b/dev/tests/integration/testsuite/Magento/Backend/Model/Auth/SessionTest.php
@@ -92,4 +92,36 @@ public function testStorage()
$this->assertEquals($acl->getRoles(), $persistedAcl->getRoles());
$this->assertEquals($acl->getResources(), $persistedAcl->getResources());
}
+
+ /**
+ * Check that session manager can work with user storage in the old way.
+ */
+ public function testInnerStorage(): void
+ {
+ /** @var \Magento\Framework\Session\StorageInterface $innerStorage */
+ $innerStorage = Bootstrap::getObjectManager()->get(\Magento\Framework\Session\StorageInterface::class);
+ $this->authSession = $this->authSessionFactory->create(['storage' => $innerStorage]);
+ $this->auth->login(TestHelper::ADMIN_NAME, TestHelper::ADMIN_PASSWORD);
+ $user = $this->auth->getAuthStorage()->getUser();
+ $acl = $this->auth->getAuthStorage()->getAcl();
+ $this->assertNotEmpty($user);
+ $this->assertNotEmpty($acl);
+ $this->auth->logout();
+ $this->assertEmpty($this->auth->getAuthStorage()->getUser());
+ $this->assertEmpty($this->auth->getAuthStorage()->getAcl());
+ $this->authSession->setUser($user);
+ $this->authSession->setAcl($acl);
+ $this->assertTrue($user === $this->authSession->getUser());
+ $this->assertTrue($acl === $this->authSession->getAcl());
+ $this->authSession->destroy();
+ $innerStorage->setUser($user);
+ $innerStorage->setAcl($acl);
+ $this->assertTrue($user === $this->authSession->getUser());
+ $this->assertTrue($acl === $this->authSession->getAcl());
+ /** @var Session $newSession */
+ $newSession = $this->authSessionFactory->create(['storage' => $innerStorage]);
+ $this->assertTrue($newSession->hasUser());
+ $this->assertTrue($newSession->hasAcl());
+ $this->assertEquals($user->getId(), $newSession->getUser()->getId());
+ }
}
diff --git a/lib/internal/Magento/Framework/App/AreaList/Proxy.php b/lib/internal/Magento/Framework/App/AreaList/Proxy.php
index 7a571814371fe..105ddd3727906 100644
--- a/lib/internal/Magento/Framework/App/AreaList/Proxy.php
+++ b/lib/internal/Magento/Framework/App/AreaList/Proxy.php
@@ -67,9 +67,6 @@ public function __construct(
*/
public function __sleep()
{
- // phpcs:ignore Magento2.Functions.DiscouragedFunction
- trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
-
return ['_subject', '_isShared'];
}
@@ -83,9 +80,6 @@ public function __sleep()
*/
public function __wakeup()
{
- // phpcs:ignore Magento2.Functions.DiscouragedFunction
- trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
-
$this->_objectManager = \Magento\Framework\App\ObjectManager::getInstance();
}
diff --git a/lib/internal/Magento/Framework/App/Response/Http.php b/lib/internal/Magento/Framework/App/Response/Http.php
index db3da6beeaa51..279ae9d9649f6 100644
--- a/lib/internal/Magento/Framework/App/Response/Http.php
+++ b/lib/internal/Magento/Framework/App/Response/Http.php
@@ -191,9 +191,6 @@ public function representJson($content)
*/
public function __sleep()
{
- // phpcs:ignore Magento2.Functions.DiscouragedFunction
- trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
-
return ['content', 'isRedirect', 'statusCode', 'context', 'headers'];
}
@@ -208,9 +205,6 @@ public function __sleep()
*/
public function __wakeup()
{
- // phpcs:ignore Magento2.Functions.DiscouragedFunction
- trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
-
$objectManager = ObjectManager::getInstance();
$this->cookieManager = $objectManager->create(\Magento\Framework\Stdlib\CookieManagerInterface::class);
$this->cookieMetadataFactory = $objectManager->get(
diff --git a/lib/internal/Magento/Framework/App/Route/ConfigInterface/Proxy.php b/lib/internal/Magento/Framework/App/Route/ConfigInterface/Proxy.php
index 4d2707d4a1c7e..863a6d7d836d4 100644
--- a/lib/internal/Magento/Framework/App/Route/ConfigInterface/Proxy.php
+++ b/lib/internal/Magento/Framework/App/Route/ConfigInterface/Proxy.php
@@ -69,9 +69,6 @@ public function __construct(
*/
public function __sleep()
{
- // phpcs:ignore Magento2.Functions.DiscouragedFunction
- trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
-
return ['_subject', '_isShared'];
}
@@ -85,9 +82,6 @@ public function __sleep()
*/
public function __wakeup()
{
- // phpcs:ignore Magento2.Functions.DiscouragedFunction
- trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
-
$this->_objectManager = \Magento\Framework\App\ObjectManager::getInstance();
}
diff --git a/lib/internal/Magento/Framework/DB/Select.php b/lib/internal/Magento/Framework/DB/Select.php
index c3da06a2ef924..b98aa9a1a8aa1 100644
--- a/lib/internal/Magento/Framework/DB/Select.php
+++ b/lib/internal/Magento/Framework/DB/Select.php
@@ -519,9 +519,6 @@ public function assemble()
*/
public function __sleep()
{
- // phpcs:ignore Magento2.Functions.DiscouragedFunction
- trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
-
$properties = array_keys(get_object_vars($this));
$properties = array_diff(
$properties,
@@ -544,9 +541,6 @@ public function __sleep()
*/
public function __wakeup()
{
- // phpcs:ignore Magento2.Functions.DiscouragedFunction
- trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
-
$objectManager = \Magento\Framework\App\ObjectManager::getInstance();
$this->_adapter = $objectManager->get(ResourceConnection::class)->getConnection();
$this->selectRenderer = $objectManager->get(\Magento\Framework\DB\Select\SelectRenderer::class);
diff --git a/lib/internal/Magento/Framework/DB/Select/RendererProxy.php b/lib/internal/Magento/Framework/DB/Select/RendererProxy.php
index 629b600303ebb..f3029a7ac2bd0 100644
--- a/lib/internal/Magento/Framework/DB/Select/RendererProxy.php
+++ b/lib/internal/Magento/Framework/DB/Select/RendererProxy.php
@@ -65,9 +65,6 @@ public function __construct(
*/
public function __sleep()
{
- // phpcs:ignore Magento2.Functions.DiscouragedFunction
- trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
-
return ['_subject', '_isShared'];
}
@@ -81,9 +78,6 @@ public function __sleep()
*/
public function __wakeup()
{
- // phpcs:ignore Magento2.Functions.DiscouragedFunction
- trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
-
$this->_objectManager = \Magento\Framework\App\ObjectManager::getInstance();
}
diff --git a/lib/internal/Magento/Framework/Data/Collection.php b/lib/internal/Magento/Framework/Data/Collection.php
index 2f0404f35822d..bcc6de4b22e0d 100644
--- a/lib/internal/Magento/Framework/Data/Collection.php
+++ b/lib/internal/Magento/Framework/Data/Collection.php
@@ -895,9 +895,6 @@ public function hasFlag($flag)
*/
public function __sleep()
{
- // phpcs:ignore Magento2.Functions.DiscouragedFunction
- trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
-
$properties = array_keys(get_object_vars($this));
$properties = array_diff(
$properties,
@@ -919,9 +916,6 @@ public function __sleep()
*/
public function __wakeup()
{
- // phpcs:ignore Magento2.Functions.DiscouragedFunction
- trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
-
$objectManager = \Magento\Framework\App\ObjectManager::getInstance();
$this->_entityFactory = $objectManager->get(EntityFactoryInterface::class);
}
diff --git a/lib/internal/Magento/Framework/Data/Collection/AbstractDb.php b/lib/internal/Magento/Framework/Data/Collection/AbstractDb.php
index 6ca28c738b3fe..dc4b71caf5bee 100644
--- a/lib/internal/Magento/Framework/Data/Collection/AbstractDb.php
+++ b/lib/internal/Magento/Framework/Data/Collection/AbstractDb.php
@@ -902,9 +902,6 @@ private function getMainTableAlias()
*/
public function __sleep()
{
- // phpcs:ignore Magento2.Functions.DiscouragedFunction
- trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
-
return array_diff(
parent::__sleep(),
['_fetchStrategy', '_logger', '_conn', 'extensionAttributesJoinProcessor']
@@ -920,9 +917,6 @@ public function __sleep()
*/
public function __wakeup()
{
- // phpcs:ignore Magento2.Functions.DiscouragedFunction
- trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
-
parent::__wakeup();
$objectManager = \Magento\Framework\App\ObjectManager::getInstance();
$this->_logger = $objectManager->get(Logger::class);
diff --git a/lib/internal/Magento/Framework/DataObject/Copy/Config/Data/Proxy.php b/lib/internal/Magento/Framework/DataObject/Copy/Config/Data/Proxy.php
index a6e84b483261e..42d58daec2c93 100644
--- a/lib/internal/Magento/Framework/DataObject/Copy/Config/Data/Proxy.php
+++ b/lib/internal/Magento/Framework/DataObject/Copy/Config/Data/Proxy.php
@@ -66,9 +66,6 @@ public function __construct(
*/
public function __sleep()
{
- // phpcs:ignore Magento2.Functions.DiscouragedFunction
- trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
-
return ['_subject', '_isShared'];
}
@@ -82,9 +79,6 @@ public function __sleep()
*/
public function __wakeup()
{
- // phpcs:ignore Magento2.Functions.DiscouragedFunction
- trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
-
$this->_objectManager = \Magento\Framework\App\ObjectManager::getInstance();
}
diff --git a/lib/internal/Magento/Framework/Interception/Interceptor.php b/lib/internal/Magento/Framework/Interception/Interceptor.php
index 3b9543e8cbb7b..ccc311c5b3426 100644
--- a/lib/internal/Magento/Framework/Interception/Interceptor.php
+++ b/lib/internal/Magento/Framework/Interception/Interceptor.php
@@ -68,9 +68,6 @@ public function ___callParent($method, array $arguments)
*/
public function __sleep()
{
- // phpcs:ignore Magento2.Functions.DiscouragedFunction
- trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
-
if (method_exists(get_parent_class($this), '__sleep')) {
$properties = parent::__sleep();
} else {
@@ -90,9 +87,6 @@ public function __sleep()
*/
public function __wakeup()
{
- // phpcs:ignore Magento2.Functions.DiscouragedFunction
- trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
-
if (method_exists(get_parent_class($this), '__wakeup')) {
parent::__wakeup();
}
diff --git a/lib/internal/Magento/Framework/Model/AbstractExtensibleModel.php b/lib/internal/Magento/Framework/Model/AbstractExtensibleModel.php
index 8ae5a234911cd..69410b7757e44 100644
--- a/lib/internal/Magento/Framework/Model/AbstractExtensibleModel.php
+++ b/lib/internal/Magento/Framework/Model/AbstractExtensibleModel.php
@@ -368,9 +368,6 @@ private function populateExtensionAttributes(array $extensionAttributesData = []
*/
public function __sleep()
{
- // phpcs:ignore Magento2.Functions.DiscouragedFunction
- trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
-
return array_diff(parent::__sleep(), ['extensionAttributesFactory', 'customAttributeFactory']);
}
@@ -382,9 +379,6 @@ public function __sleep()
*/
public function __wakeup()
{
- // phpcs:ignore Magento2.Functions.DiscouragedFunction
- trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
-
parent::__wakeup();
$objectManager = \Magento\Framework\App\ObjectManager::getInstance();
$this->extensionAttributesFactory = $objectManager->get(ExtensionAttributesFactory::class);
diff --git a/lib/internal/Magento/Framework/Model/AbstractModel.php b/lib/internal/Magento/Framework/Model/AbstractModel.php
index 7905ae280ff0c..534c25fce8d42 100644
--- a/lib/internal/Magento/Framework/Model/AbstractModel.php
+++ b/lib/internal/Magento/Framework/Model/AbstractModel.php
@@ -226,9 +226,6 @@ protected function _init($resourceModel)
*/
public function __sleep()
{
- // phpcs:ignore Magento2.Functions.DiscouragedFunction
- trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
-
$properties = array_keys(get_object_vars($this));
$properties = array_diff(
$properties,
@@ -256,9 +253,6 @@ public function __sleep()
*/
public function __wakeup()
{
- // phpcs:ignore Magento2.Functions.DiscouragedFunction
- trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
-
$objectManager = \Magento\Framework\App\ObjectManager::getInstance();
$this->_registry = $objectManager->get(\Magento\Framework\Registry::class);
diff --git a/lib/internal/Magento/Framework/Model/ResourceModel/Db/AbstractDb.php b/lib/internal/Magento/Framework/Model/ResourceModel/Db/AbstractDb.php
index 8a0c78e4ff02b..f2b3eca7243b7 100644
--- a/lib/internal/Magento/Framework/Model/ResourceModel/Db/AbstractDb.php
+++ b/lib/internal/Magento/Framework/Model/ResourceModel/Db/AbstractDb.php
@@ -163,9 +163,6 @@ public function __construct(
*/
public function __sleep()
{
- // phpcs:ignore Magento2.Functions.DiscouragedFunction
- trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
-
$properties = array_keys(get_object_vars($this));
$properties = array_diff($properties, ['_resources', '_connections']);
return $properties;
@@ -181,9 +178,6 @@ public function __sleep()
*/
public function __wakeup()
{
- // phpcs:ignore Magento2.Functions.DiscouragedFunction
- trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
-
$this->_resources = \Magento\Framework\App\ObjectManager::getInstance()
->get(\Magento\Framework\App\ResourceConnection::class);
}
diff --git a/lib/internal/Magento/Framework/Model/ResourceModel/Db/Collection/AbstractCollection.php b/lib/internal/Magento/Framework/Model/ResourceModel/Db/Collection/AbstractCollection.php
index 4af5fd7a2a986..1186326ab6525 100644
--- a/lib/internal/Magento/Framework/Model/ResourceModel/Db/Collection/AbstractCollection.php
+++ b/lib/internal/Magento/Framework/Model/ResourceModel/Db/Collection/AbstractCollection.php
@@ -613,9 +613,6 @@ public function save()
*/
public function __sleep()
{
- // phpcs:ignore Magento2.Functions.DiscouragedFunction
- trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
-
return array_diff(
parent::__sleep(),
['_resource', '_eventManager']
@@ -631,9 +628,6 @@ public function __sleep()
*/
public function __wakeup()
{
- // phpcs:ignore Magento2.Functions.DiscouragedFunction
- trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
-
parent::__wakeup();
$objectManager = \Magento\Framework\App\ObjectManager::getInstance();
$this->_eventManager = $objectManager->get(\Magento\Framework\Event\ManagerInterface::class);
diff --git a/lib/internal/Magento/Framework/Mview/Config/Data/Proxy.php b/lib/internal/Magento/Framework/Mview/Config/Data/Proxy.php
index 0de6c639812ad..cfa79f3e7ee60 100644
--- a/lib/internal/Magento/Framework/Mview/Config/Data/Proxy.php
+++ b/lib/internal/Magento/Framework/Mview/Config/Data/Proxy.php
@@ -64,9 +64,6 @@ public function __construct(
*/
public function __sleep()
{
- // phpcs:ignore Magento2.Functions.DiscouragedFunction
- trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
-
return ['subject', 'isShared'];
}
@@ -80,9 +77,6 @@ public function __sleep()
*/
public function __wakeup()
{
- // phpcs:ignore Magento2.Functions.DiscouragedFunction
- trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
-
$this->objectManager = \Magento\Framework\App\ObjectManager::getInstance();
}
diff --git a/lib/internal/Magento/Framework/Translate/Inline/Proxy.php b/lib/internal/Magento/Framework/Translate/Inline/Proxy.php
index 0a9841adbfb08..62b3352e11b1a 100644
--- a/lib/internal/Magento/Framework/Translate/Inline/Proxy.php
+++ b/lib/internal/Magento/Framework/Translate/Inline/Proxy.php
@@ -64,9 +64,6 @@ public function __construct(
*/
public function __sleep()
{
- // phpcs:ignore Magento2.Functions.DiscouragedFunction
- trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
-
return ['subject', 'isShared'];
}
@@ -80,9 +77,6 @@ public function __sleep()
*/
public function __wakeup()
{
- // phpcs:ignore Magento2.Functions.DiscouragedFunction
- trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
-
$this->objectManager = \Magento\Framework\App\ObjectManager::getInstance();
}
diff --git a/lib/internal/Magento/Framework/View/Layout/Proxy.php b/lib/internal/Magento/Framework/View/Layout/Proxy.php
index a4550df566ff4..2ee50f8d14bc3 100644
--- a/lib/internal/Magento/Framework/View/Layout/Proxy.php
+++ b/lib/internal/Magento/Framework/View/Layout/Proxy.php
@@ -66,9 +66,6 @@ public function __construct(
*/
public function __sleep()
{
- // phpcs:ignore Magento2.Functions.DiscouragedFunction
- trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
-
return ['_subject', '_isShared'];
}
@@ -82,9 +79,6 @@ public function __sleep()
*/
public function __wakeup()
{
- // phpcs:ignore Magento2.Functions.DiscouragedFunction
- trigger_error('Using PHP serialization is deprecated', E_USER_DEPRECATED);
-
$this->_objectManager = \Magento\Framework\App\ObjectManager::getInstance();
}
From 83369f7c2c6c1818c2231589014117ecbb89dfa1 Mon Sep 17 00:00:00 2001
From: Soumya Unnikrishnan
Date: Wed, 7 Aug 2019 14:18:41 -0500
Subject: [PATCH 057/937] MQE-1686: Paypal integration test leveraging Adobe
Vault - PayPalSmartButtonInCheckoutPage
---
.../VerifyCheckoutSuccessActionGroup.xml | 17 ++
.../OpenCartOnPayPalActionGroup.xml | 20 +++
...xpressCheckoutConfigurationActionGroup.xml | 21 +--
.../PayPalExpressCheckoutConfigSection.xml | 2 +-
.../Test/CheckCreditButtonConfiguration.xml | 79 +++++++++
...efaultValueOfPayPalCustomizeButtonTest.xml | 44 +++++
.../Test/PayPalSmartButtonInCheckoutPage.xml | 158 ++++--------------
7 files changed, 201 insertions(+), 140 deletions(-)
create mode 100644 app/code/Magento/Checkout/Test/Mftf/ActionGroup/VerifyCheckoutSuccessActionGroup.xml
create mode 100644 app/code/Magento/Paypal/Test/Mftf/ActionGroup/OpenCartOnPayPalActionGroup.xml
create mode 100644 app/code/Magento/Paypal/Test/Mftf/Test/CheckCreditButtonConfiguration.xml
create mode 100644 app/code/Magento/Paypal/Test/Mftf/Test/CheckDefaultValueOfPayPalCustomizeButtonTest.xml
diff --git a/app/code/Magento/Checkout/Test/Mftf/ActionGroup/VerifyCheckoutSuccessActionGroup.xml b/app/code/Magento/Checkout/Test/Mftf/ActionGroup/VerifyCheckoutSuccessActionGroup.xml
new file mode 100644
index 0000000000000..c633bb078b06c
--- /dev/null
+++ b/app/code/Magento/Checkout/Test/Mftf/ActionGroup/VerifyCheckoutSuccessActionGroup.xml
@@ -0,0 +1,17 @@
+
+
+
+
+
+
+
+
+
+
+
diff --git a/app/code/Magento/Paypal/Test/Mftf/ActionGroup/OpenCartOnPayPalActionGroup.xml b/app/code/Magento/Paypal/Test/Mftf/ActionGroup/OpenCartOnPayPalActionGroup.xml
new file mode 100644
index 0000000000000..38cde73b5b7bc
--- /dev/null
+++ b/app/code/Magento/Paypal/Test/Mftf/ActionGroup/OpenCartOnPayPalActionGroup.xml
@@ -0,0 +1,20 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/app/code/Magento/Paypal/Test/Mftf/ActionGroup/PayPalExpressCheckoutConfigurationActionGroup.xml b/app/code/Magento/Paypal/Test/Mftf/ActionGroup/PayPalExpressCheckoutConfigurationActionGroup.xml
index bae517ffe2f3e..c5c9aff86d375 100644
--- a/app/code/Magento/Paypal/Test/Mftf/ActionGroup/PayPalExpressCheckoutConfigurationActionGroup.xml
+++ b/app/code/Magento/Paypal/Test/Mftf/ActionGroup/PayPalExpressCheckoutConfigurationActionGroup.xml
@@ -16,39 +16,40 @@
-
+
-
-
-
+
+
+
-
+
+
+
+
-
-
-
-
+
+
-
+
diff --git a/app/code/Magento/Paypal/Test/Mftf/Section/PayPalExpressCheckoutConfigSection.xml b/app/code/Magento/Paypal/Test/Mftf/Section/PayPalExpressCheckoutConfigSection.xml
index 85f94cd8691a5..0be7a7873825c 100644
--- a/app/code/Magento/Paypal/Test/Mftf/Section/PayPalExpressCheckoutConfigSection.xml
+++ b/app/code/Magento/Paypal/Test/Mftf/Section/PayPalExpressCheckoutConfigSection.xml
@@ -54,7 +54,7 @@
-
+
diff --git a/app/code/Magento/Paypal/Test/Mftf/Test/CheckCreditButtonConfiguration.xml b/app/code/Magento/Paypal/Test/Mftf/Test/CheckCreditButtonConfiguration.xml
new file mode 100644
index 0000000000000..a0f13e8ae6617
--- /dev/null
+++ b/app/code/Magento/Paypal/Test/Mftf/Test/CheckCreditButtonConfiguration.xml
@@ -0,0 +1,79 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/app/code/Magento/Paypal/Test/Mftf/Test/CheckDefaultValueOfPayPalCustomizeButtonTest.xml b/app/code/Magento/Paypal/Test/Mftf/Test/CheckDefaultValueOfPayPalCustomizeButtonTest.xml
new file mode 100644
index 0000000000000..0a90295c5528a
--- /dev/null
+++ b/app/code/Magento/Paypal/Test/Mftf/Test/CheckDefaultValueOfPayPalCustomizeButtonTest.xml
@@ -0,0 +1,44 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/app/code/Magento/Paypal/Test/Mftf/Test/PayPalSmartButtonInCheckoutPage.xml b/app/code/Magento/Paypal/Test/Mftf/Test/PayPalSmartButtonInCheckoutPage.xml
index 079b46dc1b0cb..426838596fad9 100644
--- a/app/code/Magento/Paypal/Test/Mftf/Test/PayPalSmartButtonInCheckoutPage.xml
+++ b/app/code/Magento/Paypal/Test/Mftf/Test/PayPalSmartButtonInCheckoutPage.xml
@@ -8,107 +8,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -122,49 +21,50 @@
-
-
-
+
+
+
+
+
+
+
+
-
-
-
-
-
-
+
+
+
-
+
+
-
-
-
+
+
+
+
+
+
-
-
+
+
-
+
+
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
\ No newline at end of file
From 2f279661a6fe2f9a2de9e63a50b63e88d9622b74 Mon Sep 17 00:00:00 2001
From: Soumya Unnikrishnan
Date: Wed, 7 Aug 2019 15:11:36 -0500
Subject: [PATCH 058/937] MQE-1686: Paypal integration test leveraging Adobe
Vault - PayPalSmartButtonInCheckoutPage
fixed formatting issues
---
.../PayPalExpressCheckoutConfigurationActionGroup.xml | 1 +
.../Paypal/Test/Mftf/Test/PayPalSmartButtonInCheckoutPage.xml | 3 +--
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/app/code/Magento/Paypal/Test/Mftf/ActionGroup/PayPalExpressCheckoutConfigurationActionGroup.xml b/app/code/Magento/Paypal/Test/Mftf/ActionGroup/PayPalExpressCheckoutConfigurationActionGroup.xml
index af0969615be59..4de7337cf2cce 100644
--- a/app/code/Magento/Paypal/Test/Mftf/ActionGroup/PayPalExpressCheckoutConfigurationActionGroup.xml
+++ b/app/code/Magento/Paypal/Test/Mftf/ActionGroup/PayPalExpressCheckoutConfigurationActionGroup.xml
@@ -5,6 +5,7 @@
* See COPYING.txt for license details.
*/
-->
+
diff --git a/app/code/Magento/Paypal/Test/Mftf/Test/PayPalSmartButtonInCheckoutPage.xml b/app/code/Magento/Paypal/Test/Mftf/Test/PayPalSmartButtonInCheckoutPage.xml
index ba68e394087dc..85e1ce347d501 100644
--- a/app/code/Magento/Paypal/Test/Mftf/Test/PayPalSmartButtonInCheckoutPage.xml
+++ b/app/code/Magento/Paypal/Test/Mftf/Test/PayPalSmartButtonInCheckoutPage.xml
@@ -52,7 +52,6 @@
-
@@ -73,4 +72,4 @@
-
\ No newline at end of file
+
From 673cec3bf2b2d1da2c37dfdf0de1e36e198c6bfc Mon Sep 17 00:00:00 2001
From: Lusine Papyan
Date: Thu, 8 Aug 2019 12:22:03 +0400
Subject: [PATCH 059/937] MC-18821: Increase test coverage for Account
functional area
- Automation test for MC-11531
---
.../StorefrontCategorySidebarSection.xml | 2 +
.../AdminConfigurableProductActionGroup.xml | 4 +
.../AddSwatchToProductActionGroup.xml | 8 ++
.../Section/AdminNewAttributePanelSection.xml | 1 +
...tImageColorWhenFilterByColorFilterTest.xml | 93 +++++++++++++++++++
5 files changed, 108 insertions(+)
create mode 100644 app/code/Magento/Swatches/Test/Mftf/Test/StorefrontImageColorWhenFilterByColorFilterTest.xml
diff --git a/app/code/Magento/Catalog/Test/Mftf/Section/StorefrontCategorySidebarSection.xml b/app/code/Magento/Catalog/Test/Mftf/Section/StorefrontCategorySidebarSection.xml
index 1b7bbd58eea9f..2c73941a92b42 100644
--- a/app/code/Magento/Catalog/Test/Mftf/Section/StorefrontCategorySidebarSection.xml
+++ b/app/code/Magento/Catalog/Test/Mftf/Section/StorefrontCategorySidebarSection.xml
@@ -12,6 +12,8 @@
+
+
diff --git a/app/code/Magento/ConfigurableProduct/Test/Mftf/ActionGroup/AdminConfigurableProductActionGroup.xml b/app/code/Magento/ConfigurableProduct/Test/Mftf/ActionGroup/AdminConfigurableProductActionGroup.xml
index a0a3a551c3d93..1561fa5e2702d 100644
--- a/app/code/Magento/ConfigurableProduct/Test/Mftf/ActionGroup/AdminConfigurableProductActionGroup.xml
+++ b/app/code/Magento/ConfigurableProduct/Test/Mftf/ActionGroup/AdminConfigurableProductActionGroup.xml
@@ -220,6 +220,10 @@
+
+
+
+
diff --git a/app/code/Magento/Swatches/Test/Mftf/ActionGroup/AddSwatchToProductActionGroup.xml b/app/code/Magento/Swatches/Test/Mftf/ActionGroup/AddSwatchToProductActionGroup.xml
index cd8470fe47fde..1cb3e630ae083 100644
--- a/app/code/Magento/Swatches/Test/Mftf/ActionGroup/AddSwatchToProductActionGroup.xml
+++ b/app/code/Magento/Swatches/Test/Mftf/ActionGroup/AddSwatchToProductActionGroup.xml
@@ -84,4 +84,12 @@
+
+
+
+
+
+
+
+
diff --git a/app/code/Magento/Swatches/Test/Mftf/Section/AdminNewAttributePanelSection.xml b/app/code/Magento/Swatches/Test/Mftf/Section/AdminNewAttributePanelSection.xml
index 0c2dea5f41235..5149fa3a1e518 100644
--- a/app/code/Magento/Swatches/Test/Mftf/Section/AdminNewAttributePanelSection.xml
+++ b/app/code/Magento/Swatches/Test/Mftf/Section/AdminNewAttributePanelSection.xml
@@ -9,6 +9,7 @@
+
diff --git a/app/code/Magento/Swatches/Test/Mftf/Test/StorefrontImageColorWhenFilterByColorFilterTest.xml b/app/code/Magento/Swatches/Test/Mftf/Test/StorefrontImageColorWhenFilterByColorFilterTest.xml
new file mode 100644
index 0000000000000..428915ab8ae6a
--- /dev/null
+++ b/app/code/Magento/Swatches/Test/Mftf/Test/StorefrontImageColorWhenFilterByColorFilterTest.xml
@@ -0,0 +1,93 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
From 753b922262b307aefdfc54abb4fa9f69261141e6 Mon Sep 17 00:00:00 2001
From: natalia
Date: Thu, 8 Aug 2019 17:23:21 +0300
Subject: [PATCH 060/937] MC-18821: Increase test coverage for Catalog
functional area
- Jasmine test for MC-6354
---
.../frontend/web/js/swatch-renderer.test.js | 76 +++++++++++++++++++
1 file changed, 76 insertions(+)
create mode 100644 dev/tests/js/jasmine/tests/app/code/Magento/Swatches/view/frontend/web/js/swatch-renderer.test.js
diff --git a/dev/tests/js/jasmine/tests/app/code/Magento/Swatches/view/frontend/web/js/swatch-renderer.test.js b/dev/tests/js/jasmine/tests/app/code/Magento/Swatches/view/frontend/web/js/swatch-renderer.test.js
new file mode 100644
index 0000000000000..b3172beec770a
--- /dev/null
+++ b/dev/tests/js/jasmine/tests/app/code/Magento/Swatches/view/frontend/web/js/swatch-renderer.test.js
@@ -0,0 +1,76 @@
+/**
+ * Copyright © Magento, Inc. All rights reserved.
+ * See COPYING.txt for license details.
+ */
+
+define([
+ 'jquery',
+ 'Magento_Swatches/js/swatch-renderer'
+], function ($, SwatchRenderer) {
+ 'use strict';
+
+ describe('Testing SwatchRenderer Widget', function () {
+ var widget,
+ attribute,
+ optionId = 2,
+ swathImageHeight = '60',
+ swathImageWidth = '70',
+ swathThumbImageHeight = '40',
+ swathThumbImageWidth = '50';
+
+ beforeEach(function () {
+ widget = new SwatchRenderer();
+ attribute = {
+ id: 1,
+ options: [{id: optionId}]
+ };
+ widget.options = {
+ classes: {optionClass: "swatch-option"},
+ jsonSwatchConfig: {1: {2: {type: 2}}},
+ jsonSwatchImageSizeConfig: {
+ swatchImage: {
+ width: swathImageWidth,
+ height: swathImageHeight
+ },
+ swatchThumb: {
+ width: swathThumbImageWidth,
+ height: swathThumbImageHeight
+ }
+ }
+ };
+ });
+
+ describe('"_RenderSwatchOptions" method', function () {
+ var html,
+ optionConfig;
+
+ beforeEach(function () {
+ optionConfig = widget.options.jsonSwatchConfig[attribute.id];
+ html = $(widget._RenderSwatchOptions(attribute, 'option-label-control-id-1'))[0];
+ });
+
+ it('check first conditional statement', function () {
+ expect(widget.options.jsonSwatchConfig.hasOwnProperty(attribute.id)).toEqual(true);
+ });
+
+ it('check second conditional statement', function () {
+ expect(optionConfig.hasOwnProperty(optionId)).toEqual(true);
+ });
+
+ it('check swatch thumbnail image height attribute', function () {
+ expect(html.hasAttribute('thumb-height')).toBe(true);
+ expect(html.getAttribute('thumb-height')).toEqual(swathThumbImageHeight);
+ });
+
+ it('check swatch thumbnail image width attribute', function () {
+ expect(html.hasAttribute('thumb-width')).toBe(true);
+ expect(html.getAttribute('thumb-width')).toEqual(swathThumbImageWidth);
+ });
+
+ it('check swatch image styles', function () {
+ expect(html.style.height).toEqual(swathImageHeight + 'px');
+ expect(html.style.width).toEqual(swathImageWidth + 'px');
+ });
+ });
+ });
+});
From fa4957fea80bdd3b675d5c0816fc33ece100cba9 Mon Sep 17 00:00:00 2001
From: Evgeny Petrov
Date: Tue, 6 Aug 2019 18:21:46 +0300
Subject: [PATCH 061/937] MC-18826: Increase test coverage for Cart & Checkout
and Order Processing functional areas
- Unit tests for MC-6387
---
.../Test/Unit/Model/DirectpostTest.php | 590 ++++++++++--------
1 file changed, 340 insertions(+), 250 deletions(-)
diff --git a/app/code/Magento/Authorizenet/Test/Unit/Model/DirectpostTest.php b/app/code/Magento/Authorizenet/Test/Unit/Model/DirectpostTest.php
index 95c67f67852da..50cf7e86e8fce 100644
--- a/app/code/Magento/Authorizenet/Test/Unit/Model/DirectpostTest.php
+++ b/app/code/Magento/Authorizenet/Test/Unit/Model/DirectpostTest.php
@@ -3,8 +3,18 @@
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
+
namespace Magento\Authorizenet\Test\Unit\Model;
+use Magento\Authorizenet\Helper\Backend\Data;
+use Magento\Authorizenet\Helper\Data as HelperData;
+use Magento\Authorizenet\Model\Directpost\Response;
+use Magento\Authorizenet\Model\Directpost\Response\Factory as ResponseFactory;
+use Magento\Framework\App\Config\ScopeConfigInterface;
+use Magento\Framework\HTTP\ZendClient;
+use Magento\Framework\HTTP\ZendClientFactory;
+use Magento\Payment\Model\InfoInterface;
+use Magento\Payment\Model\Method\ConfigInterface;
use Magento\Sales\Api\PaymentFailuresInterface;
use Magento\Framework\Simplexml\Element;
use Magento\Framework\TestFramework\Unit\Helper\ObjectManager as ObjectManagerHelper;
@@ -13,118 +23,118 @@
use Magento\Authorizenet\Model\Request;
use Magento\Authorizenet\Model\Directpost\Request\Factory;
use Magento\Sales\Model\Order;
+use Magento\Sales\Model\Order\Payment;
+use Magento\Sales\Model\Order\Payment\Transaction;
use Magento\Sales\Model\Order\Payment\Transaction\Repository as TransactionRepository;
+use PHPUnit\Framework\MockObject_MockBuilder;
+use PHPUnit\Framework\TestCase;
+use PHPUnit_Framework_MockObject_MockObject;
+use ReflectionClass;
/**
* Class DirectpostTest
* @SuppressWarnings(PHPMD.CouplingBetweenObjects)
*/
-class DirectpostTest extends \PHPUnit\Framework\TestCase
+class DirectpostTest extends TestCase
{
const TOTAL_AMOUNT = 100.02;
const INVOICE_NUM = '00000001';
const TRANSACTION_ID = '41a23x34fd124';
/**
- * @var \Magento\Authorizenet\Model\Directpost
+ * @var Directpost
*/
protected $directpost;
/**
- * @var \Magento\Framework\App\Config\ScopeConfigInterface|\PHPUnit_Framework_MockObject_MockObject
+ * @var ScopeConfigInterface|PHPUnit_Framework_MockObject_MockObject
*/
protected $scopeConfigMock;
/**
- * @var \Magento\Payment\Model\InfoInterface|\PHPUnit_Framework_MockObject_MockObject
+ * @var InfoInterface|PHPUnit_Framework_MockObject_MockObject
*/
protected $paymentMock;
/**
- * @var \Magento\Authorizenet\Helper\Data|\PHPUnit_Framework_MockObject_MockObject
+ * @var HelperData|PHPUnit_Framework_MockObject_MockObject
*/
protected $dataHelperMock;
/**
- * @var \Magento\Authorizenet\Model\Directpost\Response\Factory|\PHPUnit_Framework_MockObject_MockObject
+ * @var ResponseFactory|PHPUnit_Framework_MockObject_MockObject
*/
protected $responseFactoryMock;
/**
- * @var TransactionRepository|\PHPUnit_Framework_MockObject_MockObject
+ * @var TransactionRepository|PHPUnit_Framework_MockObject_MockObject
*/
protected $transactionRepositoryMock;
/**
- * @var \Magento\Authorizenet\Model\Directpost\Response|\PHPUnit_Framework_MockObject_MockObject
+ * @var Response|PHPUnit_Framework_MockObject_MockObject
*/
protected $responseMock;
/**
- * @var TransactionService|\PHPUnit_Framework_MockObject_MockObject
+ * @var TransactionService|PHPUnit_Framework_MockObject_MockObject
*/
protected $transactionServiceMock;
/**
- * @var \Magento\Framework\HTTP\ZendClient|\PHPUnit_Framework_MockObject_MockObject
+ * @var ZendClient|PHPUnit_Framework_MockObject_MockObject
*/
protected $httpClientMock;
/**
- * @var \Magento\Authorizenet\Model\Directpost\Request\Factory|\PHPUnit_Framework_MockObject_MockObject
+ * @var Factory|PHPUnit_Framework_MockObject_MockObject
*/
protected $requestFactory;
/**
- * @var PaymentFailuresInterface|\PHPUnit_Framework_MockObject_MockObject
+ * @var PaymentFailuresInterface|PHPUnit_Framework_MockObject_MockObject
*/
private $paymentFailures;
+ /**
+ * @var ZendClientFactory|PHPUnit_Framework_MockObject_MockObject
+ */
+ private $httpClientFactoryMock;
+
/**
* @inheritdoc
*/
protected function setUp()
{
- $this->scopeConfigMock = $this->getMockBuilder(\Magento\Framework\App\Config\ScopeConfigInterface::class)
- ->getMock();
- $this->paymentMock = $this->getMockBuilder(\Magento\Sales\Model\Order\Payment::class)
- ->disableOriginalConstructor()
- ->setMethods([
- 'getOrder', 'getId', 'setAdditionalInformation', 'getAdditionalInformation',
- 'setIsTransactionDenied', 'setIsTransactionClosed', 'decrypt', 'getCcLast4',
- 'getParentTransactionId', 'getPoNumber'
- ])
- ->getMock();
- $this->dataHelperMock = $this->getMockBuilder(\Magento\Authorizenet\Helper\Data::class)
- ->disableOriginalConstructor()
- ->getMock();
-
+ $this->initPaymentMock();
$this->initResponseFactoryMock();
+ $this->initHttpClientMock();
- $this->transactionRepositoryMock = $this->getMockBuilder(
- \Magento\Sales\Model\Order\Payment\Transaction\Repository::class
- )
+ $this->scopeConfigMock = $this->getMockBuilder(ScopeConfigInterface::class)->getMock();
+ $this->dataHelperMock = $this->getMockBuilder(HelperData::class)->disableOriginalConstructor()->getMock();
+ $this->transactionRepositoryMock = $this->getMockBuilder(TransactionRepository::class)
->disableOriginalConstructor()
->setMethods(['getByTransactionId'])
->getMock();
-
- $this->transactionServiceMock = $this->getMockBuilder(\Magento\Authorizenet\Model\TransactionService::class)
+ $this->transactionServiceMock = $this->getMockBuilder(TransactionService::class)
->disableOriginalConstructor()
->setMethods(['getTransactionDetails'])
->getMock();
-
- $this->paymentFailures = $this->getMockBuilder(
- PaymentFailuresInterface::class
- )
+ $this->paymentFailures = $this->getMockBuilder(PaymentFailuresInterface::class)
->disableOriginalConstructor()
->getMock();
-
- $this->requestFactory = $this->getRequestFactoryMock();
- $httpClientFactoryMock = $this->getHttpClientFactoryMock();
+ $this->requestFactory = $this->getMockBuilder(Factory::class)
+ ->disableOriginalConstructor()
+ ->setMethods(['create'])
+ ->getMock();
+ $this->httpClientFactoryMock = $this->getMockBuilder(ZendClientFactory::class)
+ ->disableOriginalConstructor()
+ ->setMethods(['create'])
+ ->getMock();
$helper = new ObjectManagerHelper($this);
$this->directpost = $helper->getObject(
- \Magento\Authorizenet\Model\Directpost::class,
+ Directpost::class,
[
'scopeConfig' => $this->scopeConfigMock,
'dataHelper' => $this->dataHelperMock,
@@ -132,18 +142,97 @@ protected function setUp()
'responseFactory' => $this->responseFactoryMock,
'transactionRepository' => $this->transactionRepositoryMock,
'transactionService' => $this->transactionServiceMock,
- 'httpClientFactory' => $httpClientFactoryMock,
+ 'httpClientFactory' => $this->httpClientFactoryMock,
'paymentFailures' => $this->paymentFailures,
]
);
}
+ /**
+ * Create mock for response factory
+ *
+ * @return void
+ */
+ private function initResponseFactoryMock()
+ {
+ $this->responseFactoryMock = $this->getMockBuilder(ResponseFactory::class)
+ ->disableOriginalConstructor()
+ ->getMock();
+ $this->responseMock = $this->getMockBuilder(Response::class)
+ ->setMethods(
+ [
+ 'isValidHash',
+ 'getXTransId',
+ 'getXResponseCode',
+ 'getXResponseReasonCode',
+ 'getXResponseReasonText',
+ 'getXAmount',
+ 'setXResponseCode',
+ 'setXResponseReasonCode',
+ 'setXAvsCode',
+ 'setXResponseReasonText',
+ 'setXTransId',
+ 'setXInvoiceNum',
+ 'setXAmount',
+ 'setXMethod',
+ 'setXType',
+ 'setData',
+ 'getData',
+ 'setXAccountNumber',
+ '__wakeup'
+ ]
+ )
+ ->disableOriginalConstructor()
+ ->getMock();
+
+ $this->responseFactoryMock->expects($this->any())->method('create')->willReturn($this->responseMock);
+ }
+
+ /**
+ * Create mock for payment
+ *
+ * @return void
+ */
+ private function initPaymentMock()
+ {
+ $this->paymentMock = $this->getMockBuilder(Payment::class)
+ ->disableOriginalConstructor()
+ ->setMethods(
+ [
+ 'getOrder',
+ 'setAmount',
+ 'setAnetTransType',
+ 'setXTransId',
+ 'getId',
+ 'setAdditionalInformation',
+ 'getAdditionalInformation',
+ 'setIsTransactionDenied',
+ 'setIsTransactionClosed',
+ 'decrypt',
+ 'getCcLast4',
+ 'getParentTransactionId',
+ 'getPoNumber'
+ ]
+ )
+ ->getMock();
+ }
+
+ /**
+ * Create a mock for http client
+ *
+ * @return void
+ */
+ private function initHttpClientMock()
+ {
+ $this->httpClientMock = $this->getMockBuilder(ZendClient::class)
+ ->disableOriginalConstructor()
+ ->setMethods(['request', 'getBody', '__wakeup'])
+ ->getMock();
+ }
+
public function testGetConfigInterface()
{
- $this->assertInstanceOf(
- \Magento\Payment\Model\Method\ConfigInterface::class,
- $this->directpost->getConfigInterface()
- );
+ $this->assertInstanceOf(ConfigInterface::class, $this->directpost->getConfigInterface());
}
public function testGetConfigValue()
@@ -162,7 +251,7 @@ public function testSetDataHelper()
$storeId = 'store-id';
$expectedResult = 'relay-url';
- $helperDataMock = $this->getMockBuilder(\Magento\Authorizenet\Helper\Backend\Data::class)
+ $helperDataMock = $this->getMockBuilder(Data::class)
->disableOriginalConstructor()
->getMock();
@@ -179,7 +268,7 @@ public function testAuthorize()
{
$paymentAction = 'some_action';
- $this->scopeConfigMock->expects($this->any())
+ $this->scopeConfigMock->expects($this->once())
->method('getValue')
->with('payment/authorizenet_directpost/payment_action', 'store', null)
->willReturn($paymentAction);
@@ -190,11 +279,141 @@ public function testAuthorize()
$this->directpost->authorize($this->paymentMock, 10);
}
+ /**
+ * @dataProvider dataProviderCaptureWithInvalidAmount
+ * @expectedExceptionMessage Invalid amount for capture.
+ * @expectedException \Magento\Framework\Exception\LocalizedException
+ *
+ * @param int $invalidAmount
+ */
+ public function testCaptureWithInvalidAmount($invalidAmount)
+ {
+ $this->directpost->capture($this->paymentMock, $invalidAmount);
+ }
+
+ /**
+ * @return array
+ */
+ public function dataProviderCaptureWithInvalidAmount()
+ {
+ return [
+ [0],
+ [0.000],
+ [-1.000],
+ [-1],
+ [null],
+ ];
+ }
+
+ /**
+ * @@expectedException \Magento\Framework\Exception\LocalizedException
+ */
+ public function testCaptureHasParentTransactionId()
+ {
+ $amount = 10;
+
+ $this->paymentMock->expects($this->once())->method('setAmount')->with($amount);
+ $this->paymentMock->expects($this->exactly(2))->method('getParentTransactionId')->willReturn(1);
+ $this->paymentMock->expects($this->once())->method('setAnetTransType')->willReturn('PRIOR_AUTH_CAPTURE');
+
+ $this->paymentMock->expects($this->once())->method('getId')->willReturn(1);
+ $orderMock = $this->getOrderMock();
+ $orderMock->expects($this->once())->method('getId')->willReturn(1);
+ $this->paymentMock->expects($this->once())->method('getOrder')->willReturn($orderMock);
+
+ $transactionMock = $this->getMockBuilder(Transaction::class)->disableOriginalConstructor()->getMock();
+ $this->transactionRepositoryMock->expects($this->once())
+ ->method('getByTransactionId')
+ ->with(1, 1, 1)
+ ->willReturn($transactionMock);
+
+ $this->paymentMock->expects($this->once())->method('setXTransId');
+ $this->responseMock->expects($this->once())->method('getData')->willReturn([1]);
+
+ $this->directpost->capture($this->paymentMock, 10);
+ }
+
+ /**
+ * @@expectedException \Magento\Framework\Exception\LocalizedException
+ */
+ public function testCaptureWithoutParentTransactionId()
+ {
+ $amount = 10;
+
+ $this->paymentMock->expects($this->once())->method('setAmount')->with($amount);
+ $this->paymentMock->expects($this->once())->method('getParentTransactionId')->willReturn(null);
+ $this->responseMock->expects($this->once())->method('getData')->willReturn([1]);
+
+ $this->directpost->capture($this->paymentMock, 10);
+ }
+
+ public function testCaptureWithoutParentTransactionIdWithoutData()
+ {
+ $amount = 10;
+
+ $this->paymentMock->expects($this->once())->method('setAmount')->with($amount);
+ $this->paymentMock->expects($this->exactly(2))->method('getParentTransactionId')->willReturn(null);
+ $this->responseMock->expects($this->once())->method('getData')->willReturn([]);
+
+ $this->paymentMock->expects($this->once())
+ ->method('setIsTransactionClosed')
+ ->with(0)
+ ->willReturnSelf();
+
+ $this->httpClientFactoryMock->expects($this->once())->method('create')->willReturn($this->httpClientMock);
+ $this->httpClientMock->expects($this->once())->method('request')->willReturnSelf();
+
+ $this->buildRequestTest();
+ $this->postRequestTest();
+
+ $this->directpost->capture($this->paymentMock, 10);
+ }
+
+ private function buildRequestTest()
+ {
+ $orderMock = $this->getOrderMock();
+ $orderMock->expects($this->once())->method('getStoreId')->willReturn(1);
+ $orderMock->expects($this->exactly(2))->method('getIncrementId')->willReturn(self::INVOICE_NUM);
+ $this->paymentMock->expects($this->once())->method('getOrder')->willReturn($orderMock);
+
+ $this->addRequestMockToRequestFactoryMock();
+ }
+
+ private function postRequestTest()
+ {
+ $this->httpClientFactoryMock->expects($this->once())->method('create')->willReturn($this->httpClientMock);
+ $this->httpClientMock->expects($this->once())->method('request')->willReturnSelf();
+ $this->responseMock->expects($this->once())->method('setXResponseCode')->willReturnSelf();
+ $this->responseMock->expects($this->once())->method('setXResponseReasonCode')->willReturnSelf();
+ $this->responseMock->expects($this->once())->method('setXResponseReasonText')->willReturnSelf();
+ $this->responseMock->expects($this->once())->method('setXAvsCode')->willReturnSelf();
+ $this->responseMock->expects($this->once())->method('setXTransId')->willReturnSelf();
+ $this->responseMock->expects($this->once())->method('setXInvoiceNum')->willReturnSelf();
+ $this->responseMock->expects($this->once())->method('setXAmount')->willReturnSelf();
+ $this->responseMock->expects($this->once())->method('setXMethod')->willReturnSelf();
+ $this->responseMock->expects($this->once())->method('setXType')->willReturnSelf();
+ $this->responseMock->expects($this->once())->method('setData')->willReturnSelf();
+
+ $response = $this->getRefundResponseBody(
+ Directpost::RESPONSE_CODE_APPROVED,
+ Directpost::RESPONSE_REASON_CODE_APPROVED,
+ 'Successful'
+ );
+ $this->httpClientMock->expects($this->once())->method('getBody')->willReturn($response);
+ $this->responseMock->expects($this->once())
+ ->method('getXResponseCode')
+ ->willReturn(Directpost::RESPONSE_CODE_APPROVED);
+ $this->responseMock->expects($this->once())
+ ->method('getXResponseReasonCode')
+ ->willReturn(Directpost::RESPONSE_REASON_CODE_APPROVED);
+ $this->dataHelperMock->expects($this->never())->method('wrapGatewayError');
+ }
+
public function testGetCgiUrl()
{
$url = 'cgi/url';
- $this->scopeConfigMock->expects($this->any())
+ $this->scopeConfigMock->expects($this->once())
->method('getValue')
->with('payment/authorizenet_directpost/cgi_url', 'store', null)
->willReturn($url);
@@ -204,7 +423,7 @@ public function testGetCgiUrl()
public function testGetCgiUrlWithEmptyConfigValue()
{
- $this->scopeConfigMock->expects($this->any())
+ $this->scopeConfigMock->expects($this->once())
->method('getValue')
->with('payment/authorizenet_directpost/cgi_url', 'store', null)
->willReturn(null);
@@ -218,7 +437,7 @@ public function testGetRelayUrl()
$url = 'relay/url';
$this->directpost->setData('store', $storeId);
- $this->dataHelperMock->expects($this->any())
+ $this->dataHelperMock->expects($this->exactly(2))
->method('getRelayUrl')
->with($storeId)
->willReturn($url);
@@ -268,7 +487,7 @@ public function testValidateResponseFailure()
*/
protected function prepareTestValidateResponse($transMd5, $login, $isValidHash)
{
- $this->scopeConfigMock->expects($this->any())
+ $this->scopeConfigMock->expects($this->exactly(2))
->method('getValue')
->willReturnMap(
[
@@ -276,7 +495,7 @@ protected function prepareTestValidateResponse($transMd5, $login, $isValidHash)
['payment/authorizenet_directpost/login', 'store', null, $login]
]
);
- $this->responseMock->expects($this->any())
+ $this->responseMock->expects($this->exactly(1))
->method('isValidHash')
->with($transMd5, $login)
->willReturn($isValidHash);
@@ -328,6 +547,23 @@ public function checkResponseCodeSuccessDataProvider()
];
}
+ /**
+ * Checks response failures behaviour.
+ *
+ * @param int $responseCode
+ * @param int $failuresHandlerCalls
+ * @return void
+ *
+ * @expectedException \Magento\Framework\Exception\LocalizedException
+ */
+ public function testCheckResponseCodeFailureDefault(): void
+ {
+ $responseCode = 999999;
+ $this->responseMock->expects($this->once())->method('getXResponseCode')->willReturn($responseCode);
+
+ $this->directpost->checkResponseCode();
+ }
+
/**
* Checks response failures behaviour.
*
@@ -338,34 +574,24 @@ public function checkResponseCodeSuccessDataProvider()
* @expectedException \Magento\Framework\Exception\LocalizedException
* @dataProvider checkResponseCodeFailureDataProvider
*/
- public function testCheckResponseCodeFailure(int $responseCode, int $failuresHandlerCalls): void
+ public function testCheckResponseCodeFailureDeclinedOrError(int $responseCode, int $failuresHandlerCalls): void
{
$reasonText = 'reason text';
$this->responseMock->expects($this->once())
->method('getXResponseCode')
->willReturn($responseCode);
- $this->responseMock->expects($this->any())
- ->method('getXResponseReasonText')
- ->willReturn($reasonText);
- $this->dataHelperMock->expects($this->any())
+ $this->responseMock->expects($this->once())->method('getXResponseReasonText')->willReturn($reasonText);
+ $this->dataHelperMock->expects($this->once())
->method('wrapGatewayError')
->with($reasonText)
->willReturn(__('Gateway error: %1', $reasonText));
- $orderMock = $this->getMockBuilder(Order::class)
- ->disableOriginalConstructor()
- ->getMock();
-
- $orderMock->expects($this->exactly($failuresHandlerCalls))
- ->method('getQuoteId')
- ->willReturn(1);
-
- $this->paymentFailures->expects($this->exactly($failuresHandlerCalls))
- ->method('handle')
- ->with(1);
+ $this->paymentFailures->expects($this->exactly($failuresHandlerCalls))->method('handle')->with(1);
+ $orderMock = $this->getOrderMock($failuresHandlerCalls);
- $reflection = new \ReflectionClass($this->directpost);
+ $orderMock->expects($this->exactly($failuresHandlerCalls))->method('getQuoteId')->willReturn(1);
+ $reflection = new ReflectionClass($this->directpost);
$order = $reflection->getProperty('order');
$order->setAccessible(true);
$order->setValue($this->directpost, $orderMock);
@@ -381,7 +607,6 @@ public function checkResponseCodeFailureDataProvider(): array
return [
['responseCode' => Directpost::RESPONSE_CODE_DECLINED, 1],
['responseCode' => Directpost::RESPONSE_CODE_ERROR, 1],
- ['responseCode' => 999999, 0],
];
}
@@ -417,7 +642,7 @@ public function testCanCapture($isGatewayActionsLocked, $canCapture)
{
$this->directpost->setData('info_instance', $this->paymentMock);
- $this->paymentMock->expects($this->any())
+ $this->paymentMock->expects($this->once())
->method('getAdditionalInformation')
->with(Directpost::GATEWAY_ACTIONS_LOCKED_STATE_KEY)
->willReturn($isGatewayActionsLocked);
@@ -452,30 +677,16 @@ public function testFetchVoidedTransactionInfo($transactionId, $resultStatus, $r
$paymentId = 36;
$orderId = 36;
- $this->paymentMock->expects(static::once())
- ->method('getId')
- ->willReturn($paymentId);
-
- $orderMock = $this->getMockBuilder(\Magento\Sales\Model\Order::class)
- ->disableOriginalConstructor()
- ->setMethods(['getId', '__wakeup'])
- ->getMock();
- $orderMock->expects(static::once())
- ->method('getId')
- ->willReturn($orderId);
+ $this->paymentMock->expects($this->once())->method('getId')->willReturn($paymentId);
- $this->paymentMock->expects(static::once())
- ->method('getOrder')
- ->willReturn($orderMock);
-
- $transactionMock = $this->getMockBuilder(\Magento\Sales\Model\Order\Payment\Transaction::class)
- ->disableOriginalConstructor()
- ->getMock();
- $this->transactionRepositoryMock->expects(static::once())
+ $orderMock = $this->getOrderMock();
+ $orderMock->expects($this->once())->method('getId')->willReturn($orderId);
+ $this->paymentMock->expects($this->once())->method('getOrder')->willReturn($orderMock);
+ $transactionMock = $this->getMockBuilder(Transaction::class)->disableOriginalConstructor()->getMock();
+ $this->transactionRepositoryMock->expects($this->once())
->method('getByTransactionId')
->with($transactionId, $paymentId, $orderId)
->willReturn($transactionMock);
-
$document = $this->getTransactionXmlDocument(
$transactionId,
TransactionService::PAYMENT_UPDATE_STATUS_CODE_SUCCESS,
@@ -483,20 +694,15 @@ public function testFetchVoidedTransactionInfo($transactionId, $resultStatus, $r
$responseStatus,
$responseCode
);
- $this->transactionServiceMock->expects(static::once())
+ $this->transactionServiceMock->expects($this->once())
->method('getTransactionDetails')
->with($this->directpost, $transactionId)
->willReturn($document);
// transaction should be closed
- $this->paymentMock->expects(static::once())
- ->method('setIsTransactionDenied')
- ->with(true);
- $this->paymentMock->expects(static::once())
- ->method('setIsTransactionClosed')
- ->with(true);
- $transactionMock->expects(static::once())
- ->method('close');
+ $this->paymentMock->expects($this->once())->method('setIsTransactionDenied')->with(true);
+ $this->paymentMock->expects($this->once())->method('setIsTransactionClosed')->with(true);
+ $transactionMock->expects($this->once())->method('close');
$this->directpost->fetchTransactionInfo($this->paymentMock, $transactionId);
}
@@ -509,60 +715,41 @@ public function testSuccessRefund()
{
$card = 1111;
- $this->paymentMock->expects(static::exactly(2))
- ->method('getCcLast4')
- ->willReturn($card);
- $this->paymentMock->expects(static::once())
- ->method('decrypt')
- ->willReturn($card);
- $this->paymentMock->expects(static::exactly(3))
+ $this->paymentMock->expects($this->exactly(1))->method('getCcLast4')->willReturn($card);
+ $this->paymentMock->expects($this->once())->method('decrypt')->willReturn($card);
+ $this->paymentMock->expects($this->exactly(3))
->method('getParentTransactionId')
->willReturn(self::TRANSACTION_ID . '-capture');
- $this->paymentMock->expects(static::once())
- ->method('getPoNumber')
- ->willReturn(self::INVOICE_NUM);
- $this->paymentMock->expects(static::once())
+ $this->paymentMock->expects($this->once())->method('getPoNumber')->willReturn(self::INVOICE_NUM);
+ $this->paymentMock->expects($this->once())
->method('setIsTransactionClosed')
->with(true)
->willReturnSelf();
+ $this->addRequestMockToRequestFactoryMock();
+
$orderMock = $this->getOrderMock();
- $this->paymentMock->expects(static::exactly(2))
- ->method('getOrder')
- ->willReturn($orderMock);
+ $orderMock->expects($this->once())->method('getId')->willReturn(1);
+ $orderMock->expects($this->exactly(2))->method('getIncrementId')->willReturn(self::INVOICE_NUM);
+ $orderMock->expects($this->once())->method('getStoreId')->willReturn(1);
+
+ $this->paymentMock->expects($this->exactly(2))->method('getOrder')->willReturn($orderMock);
- $transactionMock = $this->getMockBuilder(Order\Payment\Transaction::class)
+ $transactionMock = $this->getMockBuilder(Transaction::class)
->disableOriginalConstructor()
->setMethods(['getAdditionalInformation'])
->getMock();
- $transactionMock->expects(static::once())
+ $transactionMock->expects($this->once())
->method('getAdditionalInformation')
->with(Directpost::REAL_TRANSACTION_ID_KEY)
->willReturn(self::TRANSACTION_ID);
- $this->transactionRepositoryMock->expects(static::once())
+ $this->transactionRepositoryMock->expects($this->once())
->method('getByTransactionId')
->willReturn($transactionMock);
- $response = $this->getRefundResponseBody(
- Directpost::RESPONSE_CODE_APPROVED,
- Directpost::RESPONSE_REASON_CODE_APPROVED,
- 'Successful'
- );
- $this->httpClientMock->expects(static::once())
- ->method('getBody')
- ->willReturn($response);
-
- $this->responseMock->expects(static::once())
- ->method('getXResponseCode')
- ->willReturn(Directpost::RESPONSE_CODE_APPROVED);
- $this->responseMock->expects(static::once())
- ->method('getXResponseReasonCode')
- ->willReturn(Directpost::RESPONSE_REASON_CODE_APPROVED);
-
- $this->dataHelperMock->expects(static::never())
- ->method('wrapGatewayError');
+ $this->postRequestTest();
$this->directpost->refund($this->paymentMock, self::TOTAL_AMOUNT);
}
@@ -583,65 +770,6 @@ public function dataProviderTransaction()
];
}
- /**
- * Create mock for response factory
- * @return void
- */
- private function initResponseFactoryMock()
- {
- $this->responseFactoryMock = $this->getMockBuilder(
- \Magento\Authorizenet\Model\Directpost\Response\Factory::class
- )->disableOriginalConstructor()->getMock();
- $this->responseMock = $this->getMockBuilder(\Magento\Authorizenet\Model\Directpost\Response::class)
- ->setMethods(
- [
- 'isValidHash',
- 'getXTransId', 'getXResponseCode', 'getXResponseReasonCode', 'getXResponseReasonText', 'getXAmount',
- 'setXResponseCode', 'setXResponseReasonCode', 'setXAvsCode', 'setXResponseReasonText',
- 'setXTransId', 'setXInvoiceNum', 'setXAmount', 'setXMethod', 'setXType', 'setData',
- 'setXAccountNumber',
- '__wakeup'
- ]
- )
- ->disableOriginalConstructor()
- ->getMock();
-
- $this->responseMock->expects(static::any())
- ->method('setXResponseCode')
- ->willReturnSelf();
- $this->responseMock->expects(static::any())
- ->method('setXResponseReasonCode')
- ->willReturnSelf();
- $this->responseMock->expects(static::any())
- ->method('setXResponseReasonText')
- ->willReturnSelf();
- $this->responseMock->expects(static::any())
- ->method('setXAvsCode')
- ->willReturnSelf();
- $this->responseMock->expects(static::any())
- ->method('setXTransId')
- ->willReturnSelf();
- $this->responseMock->expects(static::any())
- ->method('setXInvoiceNum')
- ->willReturnSelf();
- $this->responseMock->expects(static::any())
- ->method('setXAmount')
- ->willReturnSelf();
- $this->responseMock->expects(static::any())
- ->method('setXMethod')
- ->willReturnSelf();
- $this->responseMock->expects(static::any())
- ->method('setXType')
- ->willReturnSelf();
- $this->responseMock->expects(static::any())
- ->method('setData')
- ->willReturnSelf();
-
- $this->responseFactoryMock->expects($this->any())
- ->method('create')
- ->willReturn($this->responseMock);
- }
-
/**
* Get transaction data
* @param $transactionId
@@ -694,80 +822,40 @@ private function getTransactionXmlDocument(
/**
* Get mock for authorize.net request factory
- * @return \PHPUnit\Framework\MockObject_MockBuilder
*/
- private function getRequestFactoryMock()
+ private function addRequestMockToRequestFactoryMock()
{
- $requestFactory = $this->getMockBuilder(Factory::class)
- ->disableOriginalConstructor()
- ->setMethods(['create'])
- ->getMock();
$request = $this->getMockBuilder(Request::class)
->disableOriginalConstructor()
->setMethods(['__wakeup'])
->getMock();
- $requestFactory->expects(static::any())
+ $this->requestFactory->expects($this->once())
->method('create')
->willReturn($request);
- return $requestFactory;
}
/**
* Get mock for order
- * @return \PHPUnit_Framework_MockObject_MockObject
+ * @return PHPUnit_Framework_MockObject_MockObject
*/
private function getOrderMock()
{
- $orderMock = $this->getMockBuilder(Order::class)
- ->disableOriginalConstructor()
- ->setMethods([
- 'getId', 'getIncrementId', 'getStoreId', 'getBillingAddress', 'getShippingAddress',
- 'getBaseCurrencyCode', 'getBaseTaxAmount', '__wakeup'
- ])
- ->getMock();
-
- $orderMock->expects(static::once())
- ->method('getId')
- ->willReturn(1);
-
- $orderMock->expects(static::exactly(2))
- ->method('getIncrementId')
- ->willReturn(self::INVOICE_NUM);
-
- $orderMock->expects(static::once())
- ->method('getStoreId')
- ->willReturn(1);
-
- $orderMock->expects(static::once())
- ->method('getBaseCurrencyCode')
- ->willReturn('USD');
- return $orderMock;
- }
-
- /**
- * Create and return mock for http client factory
- * @return \PHPUnit_Framework_MockObject_MockObject
- */
- private function getHttpClientFactoryMock()
- {
- $this->httpClientMock = $this->getMockBuilder(\Magento\Framework\HTTP\ZendClient::class)
+ return $this->getMockBuilder(Order::class)
->disableOriginalConstructor()
- ->setMethods(['request', 'getBody', '__wakeup'])
- ->getMock();
-
- $this->httpClientMock->expects(static::any())
- ->method('request')
- ->willReturnSelf();
-
- $httpClientFactoryMock = $this->getMockBuilder(\Magento\Framework\HTTP\ZendClientFactory::class)
- ->disableOriginalConstructor()
- ->setMethods(['create'])
+ ->setMethods(
+ [
+ 'getId',
+ 'getQuoteId',
+ 'getIncrementId',
+ 'getStoreId',
+ 'getBillingAddress',
+ 'getShippingAddress',
+ 'getBaseCurrencyCode',
+ 'getBaseTaxAmount',
+ '__wakeup'
+ ]
+ )
->getMock();
-
- $httpClientFactoryMock->expects(static::any())
- ->method('create')
- ->willReturn($this->httpClientMock);
- return $httpClientFactoryMock;
}
/**
@@ -788,7 +876,9 @@ private function getRefundResponseBody($code, $reasonCode, $reasonText)
$result[9] = self::TOTAL_AMOUNT; // XAmount
$result[10] = Directpost::REQUEST_METHOD_CC; // XMethod
$result[11] = Directpost::REQUEST_TYPE_CREDIT; // XType
+ // @codingStandardsIgnoreStart
$result[37] = md5(self::TRANSACTION_ID); // x_MD5_Hash
+ // @codingStandardsIgnoreEnd
$result[50] = '48329483921'; // setXAccountNumber
return implode(Directpost::RESPONSE_DELIM_CHAR, $result);
}
From 2e2d9dbd3be307a4f21330d1c4ba488039f3f274 Mon Sep 17 00:00:00 2001
From: Lusine Papyan
Date: Fri, 9 Aug 2019 16:02:12 +0400
Subject: [PATCH 062/937] MC-18823: Increase test coverage for Framework and
Performance functional areas
- Automation test for MC-11701
---
.../AdminForgotPasswordFormSection.xml | 2 +
...gRefreshCaptchaImageProductionModeTest.xml | 63 +++++++++++++++++++
.../Test/Mftf/Data/DeveloperJsConfigs.xml | 22 +++++++
.../Metadata/developer_js_config-meta.xml | 23 +++++++
4 files changed, 110 insertions(+)
create mode 100644 app/code/Magento/Captcha/Test/Mftf/Test/AdminCheckingRefreshCaptchaImageProductionModeTest.xml
create mode 100644 app/code/Magento/Developer/Test/Mftf/Data/DeveloperJsConfigs.xml
create mode 100644 app/code/Magento/Developer/Test/Mftf/Metadata/developer_js_config-meta.xml
diff --git a/app/code/Magento/Backend/Test/Mftf/Section/AdminForgotPasswordFormSection.xml b/app/code/Magento/Backend/Test/Mftf/Section/AdminForgotPasswordFormSection.xml
index efaca22123354..fae3b768d445b 100644
--- a/app/code/Magento/Backend/Test/Mftf/Section/AdminForgotPasswordFormSection.xml
+++ b/app/code/Magento/Backend/Test/Mftf/Section/AdminForgotPasswordFormSection.xml
@@ -11,5 +11,7 @@
diff --git a/app/code/Magento/Captcha/Test/Mftf/Test/AdminCheckingRefreshCaptchaImageProductionModeTest.xml b/app/code/Magento/Captcha/Test/Mftf/Test/AdminCheckingRefreshCaptchaImageProductionModeTest.xml
new file mode 100644
index 0000000000000..08bc3dbd02413
--- /dev/null
+++ b/app/code/Magento/Captcha/Test/Mftf/Test/AdminCheckingRefreshCaptchaImageProductionModeTest.xml
@@ -0,0 +1,63 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/app/code/Magento/Developer/Test/Mftf/Data/DeveloperJsConfigs.xml b/app/code/Magento/Developer/Test/Mftf/Data/DeveloperJsConfigs.xml
new file mode 100644
index 0000000000000..e490ef62bbed6
--- /dev/null
+++ b/app/code/Magento/Developer/Test/Mftf/Data/DeveloperJsConfigs.xml
@@ -0,0 +1,22 @@
+
+
+
+
+ DefaultJSBundling
+
+
+ 1
+
+
+ DefaultJSBundling
+
+
+ 1
+
+
diff --git a/app/code/Magento/Developer/Test/Mftf/Metadata/developer_js_config-meta.xml b/app/code/Magento/Developer/Test/Mftf/Metadata/developer_js_config-meta.xml
new file mode 100644
index 0000000000000..b56c88a22dd13
--- /dev/null
+++ b/app/code/Magento/Developer/Test/Mftf/Metadata/developer_js_config-meta.xml
@@ -0,0 +1,23 @@
+
+
+
+
+
+
+
+
+ string
+
+
+ string
+
+
+
+
+
+
From 8cc4f7663af090ff76a8fe4fd104c0a8576bf593 Mon Sep 17 00:00:00 2001
From: Soumya Unnikrishnan
Date: Fri, 9 Aug 2019 13:12:07 -0500
Subject: [PATCH 063/937] MQE-1686: Paypal integration test leveraging Adobe
Vault - PayPalSmartButtonInCheckoutPage
fixed review comments
---
.../VerifyCheckoutSuccessActionGroup.xml | 2 +-
.../PayOrderOnPayPalCheckoutActionGroup.xml | 7 +++++--
...lExpressCheckoutConfigurationActionGroup.xml | 17 ++++++++++-------
.../Test/PayPalSmartButtonInCheckoutPage.xml | 4 +++-
.../CreateOrderToPrintPageActionGroup.xml | 2 +-
5 files changed, 20 insertions(+), 12 deletions(-)
diff --git a/app/code/Magento/Checkout/Test/Mftf/ActionGroup/VerifyCheckoutSuccessActionGroup.xml b/app/code/Magento/Checkout/Test/Mftf/ActionGroup/VerifyCheckoutSuccessActionGroup.xml
index 2cbe97e163223..5048bcf37b320 100644
--- a/app/code/Magento/Checkout/Test/Mftf/ActionGroup/VerifyCheckoutSuccessActionGroup.xml
+++ b/app/code/Magento/Checkout/Test/Mftf/ActionGroup/VerifyCheckoutSuccessActionGroup.xml
@@ -10,7 +10,7 @@
xsi:noNamespaceSchemaLocation="urn:magento:mftf:Test/etc/actionGroupSchema.xsd">
- Goes to the checkout one page success page and verifies if theorder is placed successfully.
+ Verifies if the order is placed successfully on the 'one page checkout' page.
diff --git a/app/code/Magento/Paypal/Test/Mftf/ActionGroup/PayOrderOnPayPalCheckoutActionGroup.xml b/app/code/Magento/Paypal/Test/Mftf/ActionGroup/PayOrderOnPayPalCheckoutActionGroup.xml
index 02d6743e085e2..13409b16b56b1 100644
--- a/app/code/Magento/Paypal/Test/Mftf/ActionGroup/PayOrderOnPayPalCheckoutActionGroup.xml
+++ b/app/code/Magento/Paypal/Test/Mftf/ActionGroup/PayOrderOnPayPalCheckoutActionGroup.xml
@@ -10,10 +10,13 @@
xsi:noNamespaceSchemaLocation="urn:magento:mftf:Test/etc/actionGroupSchema.xsd">
- Goes to PayPal payment checkout page, confirms product name and clicks 'Pay Now'.
+ Verifies product name on Paypal cart and clicks 'Pay Now' on PayPal payment checkout page.
+
+
+
-
+
diff --git a/app/code/Magento/Paypal/Test/Mftf/ActionGroup/PayPalExpressCheckoutConfigurationActionGroup.xml b/app/code/Magento/Paypal/Test/Mftf/ActionGroup/PayPalExpressCheckoutConfigurationActionGroup.xml
index 4de7337cf2cce..1ed519a8a3db2 100644
--- a/app/code/Magento/Paypal/Test/Mftf/ActionGroup/PayPalExpressCheckoutConfigurationActionGroup.xml
+++ b/app/code/Magento/Paypal/Test/Mftf/ActionGroup/PayPalExpressCheckoutConfigurationActionGroup.xml
@@ -21,14 +21,14 @@
-
+
-
-
-
+
+
+
-
+
@@ -39,7 +39,10 @@
+
+
+
@@ -57,8 +60,8 @@
-
-
+
+
diff --git a/app/code/Magento/Paypal/Test/Mftf/Test/PayPalSmartButtonInCheckoutPage.xml b/app/code/Magento/Paypal/Test/Mftf/Test/PayPalSmartButtonInCheckoutPage.xml
index 85e1ce347d501..dcf00e49a5b99 100644
--- a/app/code/Magento/Paypal/Test/Mftf/Test/PayPalSmartButtonInCheckoutPage.xml
+++ b/app/code/Magento/Paypal/Test/Mftf/Test/PayPalSmartButtonInCheckoutPage.xml
@@ -67,7 +67,9 @@
-
+
+
+
diff --git a/app/code/Magento/Sales/Test/Mftf/ActionGroup/CreateOrderToPrintPageActionGroup.xml b/app/code/Magento/Sales/Test/Mftf/ActionGroup/CreateOrderToPrintPageActionGroup.xml
index aaeb9ffb30bd9..7388eaa96f215 100644
--- a/app/code/Magento/Sales/Test/Mftf/ActionGroup/CreateOrderToPrintPageActionGroup.xml
+++ b/app/code/Magento/Sales/Test/Mftf/ActionGroup/CreateOrderToPrintPageActionGroup.xml
@@ -15,7 +15,7 @@
-
+
From b92cd06916cb62447fe11501a7dbafb7b866566d Mon Sep 17 00:00:00 2001
From: Nikita Chubukov
Date: Tue, 13 Aug 2019 21:52:06 +0300
Subject: [PATCH 064/937] MC-15256: Exported customer without modification can
not be imported
- Fix CR comments
---
app/code/Magento/CustomerImportExport/Model/Import/Customer.php | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/app/code/Magento/CustomerImportExport/Model/Import/Customer.php b/app/code/Magento/CustomerImportExport/Model/Import/Customer.php
index 33dc7e55228bf..914b4fd2a3ca9 100644
--- a/app/code/Magento/CustomerImportExport/Model/Import/Customer.php
+++ b/app/code/Magento/CustomerImportExport/Model/Import/Customer.php
@@ -608,7 +608,7 @@ protected function _validateRowForUpdate(array $rowData, $rowNumber)
}
if (isset($rowData[$attributeCode]) && strlen((string)$rowData[$attributeCode])) {
- if ($attributeParams['type'] == 'select' && empty($rowData[$attributeCode])) {
+ if ($attributeParams['type'] == 'select') {
continue;
}
From c09d8c0ae032fe6c0fe324dd81d0ee08f5aa63a0 Mon Sep 17 00:00:00 2001
From: Veronika Kurochkina
Date: Wed, 14 Aug 2019 16:08:07 +0300
Subject: [PATCH 065/937] MAGETWO-44170: Not pass function test
\Magento\Catalog\Test\TestCase\Product\ProductTypeSwitchingOnUpdateTest
- Fix mftf
---
.../Mftf/ActionGroup/AdminCategoryActionGroup.xml | 12 ++++++++++--
1 file changed, 10 insertions(+), 2 deletions(-)
diff --git a/app/code/Magento/Catalog/Test/Mftf/ActionGroup/AdminCategoryActionGroup.xml b/app/code/Magento/Catalog/Test/Mftf/ActionGroup/AdminCategoryActionGroup.xml
index 90d732c9654e1..af919e5562729 100644
--- a/app/code/Magento/Catalog/Test/Mftf/ActionGroup/AdminCategoryActionGroup.xml
+++ b/app/code/Magento/Catalog/Test/Mftf/ActionGroup/AdminCategoryActionGroup.xml
@@ -75,7 +75,11 @@
-
+
+
+ /magento-logo(_[0-9]+)*?\.png$/
+ grabCategoryFileName
+
@@ -96,7 +100,11 @@
-
+
+
+ /magento-logo(_[0-9]+)*?\.png$/
+ grabCategoryFileName
+
From 380e14f9bd108a99ca26328ba345adb241585a1a Mon Sep 17 00:00:00 2001
From: Soumya Unnikrishnan
Date: Wed, 14 Aug 2019 12:11:54 -0500
Subject: [PATCH 066/937] MQE-1686: Paypal integration test leveraging Adobe
Vault - PayPalSmartButtonInCheckoutPage
replaced Paypal UI configurations with and
---
.../Paypal/Test/Mftf/Data/PaypalData.xml | 30 +++++++++++++++++++
.../Test/PayPalSmartButtonInCheckoutPage.xml | 29 ++++++++++--------
2 files changed, 47 insertions(+), 12 deletions(-)
diff --git a/app/code/Magento/Paypal/Test/Mftf/Data/PaypalData.xml b/app/code/Magento/Paypal/Test/Mftf/Data/PaypalData.xml
index ae34476e9ac0b..b8994f0e4bc04 100644
--- a/app/code/Magento/Paypal/Test/Mftf/Data/PaypalData.xml
+++ b/app/code/Magento/Paypal/Test/Mftf/Data/PaypalData.xml
@@ -99,4 +99,34 @@
someApiSignature
someMerchantId
+
+ BusinessAccount
+ ApiUsername
+ ApiPassword
+ ApiSignature
+ ApiAuthentication
+ SandboxFlag
+ UseProxy
+
+
+ {{_CREDS.magento/paypal_express_checkout_us_business_account}}
+
+
+ {{_CREDS.magento/paypal_express_checkout_us_api_username}}
+
+
+ {{_CREDS.magento/paypal_express_checkout_us_api_password}}
+
+
+ {{_CREDS.magento/paypal_express_checkout_us_api_signature}}
+
+
+ 0
+
+
+ 1
+
+
+ 0
+
diff --git a/app/code/Magento/Paypal/Test/Mftf/Test/PayPalSmartButtonInCheckoutPage.xml b/app/code/Magento/Paypal/Test/Mftf/Test/PayPalSmartButtonInCheckoutPage.xml
index dcf00e49a5b99..5fd81d4089005 100644
--- a/app/code/Magento/Paypal/Test/Mftf/Test/PayPalSmartButtonInCheckoutPage.xml
+++ b/app/code/Magento/Paypal/Test/Mftf/Test/PayPalSmartButtonInCheckoutPage.xml
@@ -31,30 +31,35 @@
+
+
+
+
+
+
+
-
+
+
+
+
+
+
+
+
-
-
-
-
+
+
-
-
-
-
-
-
-
From 73ba36616fbd3244b75ef07129aeb967c299765f Mon Sep 17 00:00:00 2001
From: Vitalii Zabaznov
Date: Thu, 15 Aug 2019 14:05:34 -0500
Subject: [PATCH 067/937] MC-18719: private cookie version increments each post
request
---
.../Checkout/etc/frontend/sections.xml | 1 +
.../view/frontend/web/js/customer-data.js | 27 +++----------------
2 files changed, 4 insertions(+), 24 deletions(-)
diff --git a/app/code/Magento/Checkout/etc/frontend/sections.xml b/app/code/Magento/Checkout/etc/frontend/sections.xml
index 90c2878f501cf..2427890c06694 100644
--- a/app/code/Magento/Checkout/etc/frontend/sections.xml
+++ b/app/code/Magento/Checkout/etc/frontend/sections.xml
@@ -9,6 +9,7 @@
xsi:noNamespaceSchemaLocation="urn:magento:module:Magento_Customer:etc/sections.xsd">
+
diff --git a/app/code/Magento/Customer/view/frontend/web/js/customer-data.js b/app/code/Magento/Customer/view/frontend/web/js/customer-data.js
index 41cf05df2b1d5..9df8d75e43172 100644
--- a/app/code/Magento/Customer/view/frontend/web/js/customer-data.js
+++ b/app/code/Magento/Customer/view/frontend/web/js/customer-data.js
@@ -198,30 +198,9 @@ define([
* Customer data initialization
*/
init: function () {
- var privateContentVersion = 'private_content_version',
- privateContent = $.cookieStorage.get(privateContentVersion),
- localPrivateContent = $.localStorage.get(privateContentVersion),
- needVersion = 'need_version',
- expiredSectionNames = this.getExpiredSectionNames();
-
- if (privateContent &&
- !$.cookieStorage.isSet(privateContentVersion) &&
- !$.localStorage.isSet(privateContentVersion)
- ) {
- $.cookieStorage.set(privateContentVersion, needVersion);
- $.localStorage.set(privateContentVersion, needVersion);
- this.reload([], false);
- } else if (localPrivateContent !== privateContent) {
- if (!$.cookieStorage.isSet(privateContentVersion)) {
- privateContent = needVersion;
- $.cookieStorage.set(privateContentVersion, privateContent);
- }
- $.localStorage.set(privateContentVersion, privateContent);
- _.each(dataProvider.getFromStorage(storage.keys()), function (sectionData, sectionName) {
- buffer.notify(sectionName, sectionData);
- });
- this.reload([], false);
- } else if (expiredSectionNames.length > 0) {
+ var expiredSectionNames = this.getExpiredSectionNames();
+
+ if (expiredSectionNames.length > 0) {
_.each(dataProvider.getFromStorage(storage.keys()), function (sectionData, sectionName) {
buffer.notify(sectionName, sectionData);
});
From 905804a24c934a166afe2e6fdb3434714dd35fd7 Mon Sep 17 00:00:00 2001
From: Mila Lesechko
Date: Thu, 15 Aug 2019 22:40:41 -0500
Subject: [PATCH 068/937] Convert AdvancedSearchEntityTest to MFTF
---
.../Test/Mftf/Data/CustomAttributeData.xml | 8 ++++
.../Catalog/Test/Mftf/Data/ProductData.xml | 27 +++++++++++
...frontFillFormAdvancedSearchActionGroup.xml | 29 ++++++++++++
...frontAdvancedSearchByAllParametersTest.xml | 30 ++++++++++++
...refrontAdvancedSearchByDescriptionTest.xml | 28 +++++++++++
...cedSearchByNameSkuDescriptionPriceTest.xml | 30 ++++++++++++
.../StorefrontAdvancedSearchByNameTest.xml | 28 +++++++++++
...refrontAdvancedSearchByPartialNameTest.xml | 25 ++++++++++
...cedSearchByPartialShortDescriptionTest.xml | 25 ++++++++++
...edSearchByPartialSkuAndDescriptionTest.xml | 26 ++++++++++
...orefrontAdvancedSearchByPartialSkuTest.xml | 25 ++++++++++
...dvancedSearchByPriceFromAndPriceToTest.xml | 26 ++++++++++
.../StorefrontAdvancedSearchByPriceToTest.xml | 33 +++++++++++++
...ntAdvancedSearchByShortDescriptionTest.xml | 29 ++++++++++++
.../StorefrontAdvancedSearchBySkuTest.xml | 25 ++++++++++
...tAdvancedSearchEntitySimpleProductTest.xml | 47 +++++++++++++++++++
...dvancedSearchNegativeProductSearchTest.xml | 29 ++++++++++++
...tAdvancedSearchWithoutEnteringDataTest.xml | 33 +++++++++++++
.../TestCase/AdvancedSearchEntityTest.xml | 16 ++++++-
19 files changed, 518 insertions(+), 1 deletion(-)
create mode 100644 app/code/Magento/CatalogSearch/Test/Mftf/ActionGroup/StorefrontFillFormAdvancedSearchActionGroup.xml
create mode 100644 app/code/Magento/CatalogSearch/Test/Mftf/Test/StorefrontAdvancedSearchByAllParametersTest.xml
create mode 100644 app/code/Magento/CatalogSearch/Test/Mftf/Test/StorefrontAdvancedSearchByDescriptionTest.xml
create mode 100644 app/code/Magento/CatalogSearch/Test/Mftf/Test/StorefrontAdvancedSearchByNameSkuDescriptionPriceTest.xml
create mode 100644 app/code/Magento/CatalogSearch/Test/Mftf/Test/StorefrontAdvancedSearchByNameTest.xml
create mode 100644 app/code/Magento/CatalogSearch/Test/Mftf/Test/StorefrontAdvancedSearchByPartialNameTest.xml
create mode 100644 app/code/Magento/CatalogSearch/Test/Mftf/Test/StorefrontAdvancedSearchByPartialShortDescriptionTest.xml
create mode 100644 app/code/Magento/CatalogSearch/Test/Mftf/Test/StorefrontAdvancedSearchByPartialSkuAndDescriptionTest.xml
create mode 100644 app/code/Magento/CatalogSearch/Test/Mftf/Test/StorefrontAdvancedSearchByPartialSkuTest.xml
create mode 100644 app/code/Magento/CatalogSearch/Test/Mftf/Test/StorefrontAdvancedSearchByPriceFromAndPriceToTest.xml
create mode 100644 app/code/Magento/CatalogSearch/Test/Mftf/Test/StorefrontAdvancedSearchByPriceToTest.xml
create mode 100644 app/code/Magento/CatalogSearch/Test/Mftf/Test/StorefrontAdvancedSearchByShortDescriptionTest.xml
create mode 100644 app/code/Magento/CatalogSearch/Test/Mftf/Test/StorefrontAdvancedSearchBySkuTest.xml
create mode 100644 app/code/Magento/CatalogSearch/Test/Mftf/Test/StorefrontAdvancedSearchEntitySimpleProductTest.xml
create mode 100644 app/code/Magento/CatalogSearch/Test/Mftf/Test/StorefrontAdvancedSearchNegativeProductSearchTest.xml
create mode 100644 app/code/Magento/CatalogSearch/Test/Mftf/Test/StorefrontAdvancedSearchWithoutEnteringDataTest.xml
diff --git a/app/code/Magento/Catalog/Test/Mftf/Data/CustomAttributeData.xml b/app/code/Magento/Catalog/Test/Mftf/Data/CustomAttributeData.xml
index 1684bd0c8a2c3..95e256c856fbe 100644
--- a/app/code/Magento/Catalog/Test/Mftf/Data/CustomAttributeData.xml
+++ b/app/code/Magento/Catalog/Test/Mftf/Data/CustomAttributeData.xml
@@ -51,4 +51,12 @@
short_description
Short Fixedtest 555
+
+ short_description
+ <p>abc_short</p>
+
+
+ description
+ <p>dfj_full</p>
+
diff --git a/app/code/Magento/Catalog/Test/Mftf/Data/ProductData.xml b/app/code/Magento/Catalog/Test/Mftf/Data/ProductData.xml
index 517ab253b8238..70d58be4b0df8 100644
--- a/app/code/Magento/Catalog/Test/Mftf/Data/ProductData.xml
+++ b/app/code/Magento/Catalog/Test/Mftf/Data/ProductData.xml
@@ -1210,4 +1210,31 @@
EavStock1
CustomAttributeProductAttribute
+
+ abc_dfj_
+ abc_dfj
+ 50.00
+ simple
+ 4
+ 4
+ 1
+ 100
+ 1
+ EavStockItem
+ ProductDescriptionAdvancedSearchABC
+ ProductShortDescriptionAdvancedSearch
+
+
+ adc_123_
+ adc_123
+ 100.00
+ simple
+ 4
+ 4
+ 1
+ 100
+ 1
+ EavStockItem
+ ProductDescriptionAdvancedSearchADC123
+
diff --git a/app/code/Magento/CatalogSearch/Test/Mftf/ActionGroup/StorefrontFillFormAdvancedSearchActionGroup.xml b/app/code/Magento/CatalogSearch/Test/Mftf/ActionGroup/StorefrontFillFormAdvancedSearchActionGroup.xml
new file mode 100644
index 0000000000000..1afdb6e5e46fa
--- /dev/null
+++ b/app/code/Magento/CatalogSearch/Test/Mftf/ActionGroup/StorefrontFillFormAdvancedSearchActionGroup.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/app/code/Magento/CatalogSearch/Test/Mftf/Test/StorefrontAdvancedSearchByAllParametersTest.xml b/app/code/Magento/CatalogSearch/Test/Mftf/Test/StorefrontAdvancedSearchByAllParametersTest.xml
new file mode 100644
index 0000000000000..0ebcf59dae2b3
--- /dev/null
+++ b/app/code/Magento/CatalogSearch/Test/Mftf/Test/StorefrontAdvancedSearchByAllParametersTest.xml
@@ -0,0 +1,30 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/app/code/Magento/CatalogSearch/Test/Mftf/Test/StorefrontAdvancedSearchByDescriptionTest.xml b/app/code/Magento/CatalogSearch/Test/Mftf/Test/StorefrontAdvancedSearchByDescriptionTest.xml
new file mode 100644
index 0000000000000..5693721e6ed65
--- /dev/null
+++ b/app/code/Magento/CatalogSearch/Test/Mftf/Test/StorefrontAdvancedSearchByDescriptionTest.xml
@@ -0,0 +1,28 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/app/code/Magento/CatalogSearch/Test/Mftf/Test/StorefrontAdvancedSearchByNameSkuDescriptionPriceTest.xml b/app/code/Magento/CatalogSearch/Test/Mftf/Test/StorefrontAdvancedSearchByNameSkuDescriptionPriceTest.xml
new file mode 100644
index 0000000000000..71b6ca064e0c8
--- /dev/null
+++ b/app/code/Magento/CatalogSearch/Test/Mftf/Test/StorefrontAdvancedSearchByNameSkuDescriptionPriceTest.xml
@@ -0,0 +1,30 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/app/code/Magento/CatalogSearch/Test/Mftf/Test/StorefrontAdvancedSearchByNameTest.xml b/app/code/Magento/CatalogSearch/Test/Mftf/Test/StorefrontAdvancedSearchByNameTest.xml
new file mode 100644
index 0000000000000..e6020a65cb62d
--- /dev/null
+++ b/app/code/Magento/CatalogSearch/Test/Mftf/Test/StorefrontAdvancedSearchByNameTest.xml
@@ -0,0 +1,28 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/app/code/Magento/CatalogSearch/Test/Mftf/Test/StorefrontAdvancedSearchByPartialNameTest.xml b/app/code/Magento/CatalogSearch/Test/Mftf/Test/StorefrontAdvancedSearchByPartialNameTest.xml
new file mode 100644
index 0000000000000..bf2b2f7bbbee9
--- /dev/null
+++ b/app/code/Magento/CatalogSearch/Test/Mftf/Test/StorefrontAdvancedSearchByPartialNameTest.xml
@@ -0,0 +1,25 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/app/code/Magento/CatalogSearch/Test/Mftf/Test/StorefrontAdvancedSearchByPartialShortDescriptionTest.xml b/app/code/Magento/CatalogSearch/Test/Mftf/Test/StorefrontAdvancedSearchByPartialShortDescriptionTest.xml
new file mode 100644
index 0000000000000..2afb4b5a341c1
--- /dev/null
+++ b/app/code/Magento/CatalogSearch/Test/Mftf/Test/StorefrontAdvancedSearchByPartialShortDescriptionTest.xml
@@ -0,0 +1,25 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/app/code/Magento/CatalogSearch/Test/Mftf/Test/StorefrontAdvancedSearchByPartialSkuAndDescriptionTest.xml b/app/code/Magento/CatalogSearch/Test/Mftf/Test/StorefrontAdvancedSearchByPartialSkuAndDescriptionTest.xml
new file mode 100644
index 0000000000000..b2b4ef9cc4782
--- /dev/null
+++ b/app/code/Magento/CatalogSearch/Test/Mftf/Test/StorefrontAdvancedSearchByPartialSkuAndDescriptionTest.xml
@@ -0,0 +1,26 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/app/code/Magento/CatalogSearch/Test/Mftf/Test/StorefrontAdvancedSearchByPartialSkuTest.xml b/app/code/Magento/CatalogSearch/Test/Mftf/Test/StorefrontAdvancedSearchByPartialSkuTest.xml
new file mode 100644
index 0000000000000..45cec0a899361
--- /dev/null
+++ b/app/code/Magento/CatalogSearch/Test/Mftf/Test/StorefrontAdvancedSearchByPartialSkuTest.xml
@@ -0,0 +1,25 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/app/code/Magento/CatalogSearch/Test/Mftf/Test/StorefrontAdvancedSearchByPriceFromAndPriceToTest.xml b/app/code/Magento/CatalogSearch/Test/Mftf/Test/StorefrontAdvancedSearchByPriceFromAndPriceToTest.xml
new file mode 100644
index 0000000000000..6b85cdf61c84c
--- /dev/null
+++ b/app/code/Magento/CatalogSearch/Test/Mftf/Test/StorefrontAdvancedSearchByPriceFromAndPriceToTest.xml
@@ -0,0 +1,26 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/app/code/Magento/CatalogSearch/Test/Mftf/Test/StorefrontAdvancedSearchByPriceToTest.xml b/app/code/Magento/CatalogSearch/Test/Mftf/Test/StorefrontAdvancedSearchByPriceToTest.xml
new file mode 100644
index 0000000000000..755bb92c897ea
--- /dev/null
+++ b/app/code/Magento/CatalogSearch/Test/Mftf/Test/StorefrontAdvancedSearchByPriceToTest.xml
@@ -0,0 +1,33 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/app/code/Magento/CatalogSearch/Test/Mftf/Test/StorefrontAdvancedSearchByShortDescriptionTest.xml b/app/code/Magento/CatalogSearch/Test/Mftf/Test/StorefrontAdvancedSearchByShortDescriptionTest.xml
new file mode 100644
index 0000000000000..c4622d02a5152
--- /dev/null
+++ b/app/code/Magento/CatalogSearch/Test/Mftf/Test/StorefrontAdvancedSearchByShortDescriptionTest.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/app/code/Magento/CatalogSearch/Test/Mftf/Test/StorefrontAdvancedSearchBySkuTest.xml b/app/code/Magento/CatalogSearch/Test/Mftf/Test/StorefrontAdvancedSearchBySkuTest.xml
new file mode 100644
index 0000000000000..ca5e237099681
--- /dev/null
+++ b/app/code/Magento/CatalogSearch/Test/Mftf/Test/StorefrontAdvancedSearchBySkuTest.xml
@@ -0,0 +1,25 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/app/code/Magento/CatalogSearch/Test/Mftf/Test/StorefrontAdvancedSearchEntitySimpleProductTest.xml b/app/code/Magento/CatalogSearch/Test/Mftf/Test/StorefrontAdvancedSearchEntitySimpleProductTest.xml
new file mode 100644
index 0000000000000..16bc36f907a61
--- /dev/null
+++ b/app/code/Magento/CatalogSearch/Test/Mftf/Test/StorefrontAdvancedSearchEntitySimpleProductTest.xml
@@ -0,0 +1,47 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/app/code/Magento/CatalogSearch/Test/Mftf/Test/StorefrontAdvancedSearchNegativeProductSearchTest.xml b/app/code/Magento/CatalogSearch/Test/Mftf/Test/StorefrontAdvancedSearchNegativeProductSearchTest.xml
new file mode 100644
index 0000000000000..b4f2314295a00
--- /dev/null
+++ b/app/code/Magento/CatalogSearch/Test/Mftf/Test/StorefrontAdvancedSearchNegativeProductSearchTest.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/app/code/Magento/CatalogSearch/Test/Mftf/Test/StorefrontAdvancedSearchWithoutEnteringDataTest.xml b/app/code/Magento/CatalogSearch/Test/Mftf/Test/StorefrontAdvancedSearchWithoutEnteringDataTest.xml
new file mode 100644
index 0000000000000..8a29ab718bd25
--- /dev/null
+++ b/app/code/Magento/CatalogSearch/Test/Mftf/Test/StorefrontAdvancedSearchWithoutEnteringDataTest.xml
@@ -0,0 +1,33 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/TestCase/AdvancedSearchEntityTest.xml b/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/TestCase/AdvancedSearchEntityTest.xml
index 4744fa7756c4e..9a26386c82cb8 100644
--- a/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/TestCase/AdvancedSearchEntityTest.xml
+++ b/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/TestCase/AdvancedSearchEntityTest.xml
@@ -8,7 +8,7 @@
- test_type:acceptance_test, test_type:extended_acceptance_test
+ test_type:acceptance_test, test_type:extended_acceptance_test, mftf_migrated:yes
Yes
-
abc_dfj
@@ -16,6 +16,7 @@
+ mftf_migrated:yes
Search product in advanced search by name
-
Yes
@@ -23,6 +24,7 @@
+ mftf_migrated:yes
Search product in advanced search by partial name
Yes
-
@@ -30,6 +32,7 @@
+ mftf_migrated:yes
Search product in advanced search by sku
Yes
-
@@ -37,6 +40,7 @@
+ mftf_migrated:yes
Search product in advanced search by partial sku
Yes
-
@@ -44,6 +48,7 @@
+ mftf_migrated:yes
Search product in advanced search by partial sku and description
Yes
-
@@ -52,6 +57,7 @@
+ mftf_migrated:yes
Search product in advanced search by description
-
Yes
@@ -59,6 +65,7 @@
+ mftf_migrated:yes
Search product in advanced search by short description
-
-
@@ -66,6 +73,7 @@
+ mftf_migrated:yes
Search product in advanced search by partial short description
Yes
-
@@ -73,6 +81,7 @@
+ mftf_migrated:yes
Search product in advanced search by price to
Yes
Yes
@@ -80,6 +89,7 @@
+ mftf_migrated:yes
Search product in advanced search by price from and price to
Yes
-
@@ -88,6 +98,7 @@
+ mftf_migrated:yes
Search product in advanced search by name, sku, description, short description, price from and price to
Yes
-
@@ -100,6 +111,7 @@
+ mftf_migrated:yes
Search product in advanced search by name, sku, description, short description, price from and price to
Yes
-
@@ -112,11 +124,13 @@
+ mftf_migrated:yes
Negative product search
Negative_product_search
+ mftf_migrated:yes
MAGETWO-18537: "Enter a search term and try again." error message is missed in Advanced Search
From 85902fb5a0825e5981e4d967db51d3bc7725165c Mon Sep 17 00:00:00 2001
From: Lusine Papyan
Date: Fri, 16 Aug 2019 10:26:24 +0400
Subject: [PATCH 069/937] MAGETWO-98748: Incorrect behavior in the category
menu on the Storefront
- Added automated test script
---
.../AdminCategorySidebarTreeSection.xml | 2 +
...goryHighlightedAndProductDisplayedTest.xml | 73 +++++++++++++++++++
2 files changed, 75 insertions(+)
create mode 100644 app/code/Magento/Catalog/Test/Mftf/Test/StorefrontCategoryHighlightedAndProductDisplayedTest.xml
diff --git a/app/code/Magento/Catalog/Test/Mftf/Section/AdminCategorySidebarTreeSection.xml b/app/code/Magento/Catalog/Test/Mftf/Section/AdminCategorySidebarTreeSection.xml
index fba28b3feaff1..bc552721e6ab8 100644
--- a/app/code/Magento/Catalog/Test/Mftf/Section/AdminCategorySidebarTreeSection.xml
+++ b/app/code/Magento/Catalog/Test/Mftf/Section/AdminCategorySidebarTreeSection.xml
@@ -11,6 +11,8 @@
+
+
diff --git a/app/code/Magento/Catalog/Test/Mftf/Test/StorefrontCategoryHighlightedAndProductDisplayedTest.xml b/app/code/Magento/Catalog/Test/Mftf/Test/StorefrontCategoryHighlightedAndProductDisplayedTest.xml
new file mode 100644
index 0000000000000..7d09cb419f312
--- /dev/null
+++ b/app/code/Magento/Catalog/Test/Mftf/Test/StorefrontCategoryHighlightedAndProductDisplayedTest.xml
@@ -0,0 +1,73 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
From 34d6d5599178d5939baf9d11bb4780b145f46e84 Mon Sep 17 00:00:00 2001
From: Vinai Kopp
Date: Fri, 16 Aug 2019 09:08:41 -0500
Subject: [PATCH 070/937] Fix config backend model PDF file name extension
---
.../Config/Model/Config/Backend/File/Pdf.php | 21 +++++++++++++++++++
.../Config/Model/Config/Backend/Image/Pdf.php | 10 +++------
2 files changed, 24 insertions(+), 7 deletions(-)
create mode 100644 app/code/Magento/Config/Model/Config/Backend/File/Pdf.php
diff --git a/app/code/Magento/Config/Model/Config/Backend/File/Pdf.php b/app/code/Magento/Config/Model/Config/Backend/File/Pdf.php
new file mode 100644
index 0000000000000..f4acd6ed21dbb
--- /dev/null
+++ b/app/code/Magento/Config/Model/Config/Backend/File/Pdf.php
@@ -0,0 +1,21 @@
+
- */
namespace Magento\Config\Model\Config\Backend\Image;
/**
* @api
- * @since 100.0.2
+ * @deprecated The wrong file type extensions are returned.
+ * @see \Magento\Config\Model\Config\Backend\File\Pdf
*/
class Pdf extends \Magento\Config\Model\Config\Backend\Image
{
@@ -22,6 +18,6 @@ class Pdf extends \Magento\Config\Model\Config\Backend\Image
*/
protected function _getAllowedExtensions()
{
- return ['tif', 'tiff', 'png', 'jpg', 'jpe', 'jpeg'];
+ return ['tif', 'tiff', 'png', 'jpg', 'jpe', 'jpeg', 'pdf'];
}
}
From 9c4cf858267136c719b960009dcd5319d54add21 Mon Sep 17 00:00:00 2001
From: Mark Berube
Date: Fri, 16 Aug 2019 12:14:47 -0500
Subject: [PATCH 071/937] MC-5696: Fixing flaky QueueManagementTest
---
.../MysqlMq/Model/QueueManagementTest.php | 84 ++++++++++++++-----
1 file changed, 61 insertions(+), 23 deletions(-)
diff --git a/dev/tests/integration/testsuite/Magento/MysqlMq/Model/QueueManagementTest.php b/dev/tests/integration/testsuite/Magento/MysqlMq/Model/QueueManagementTest.php
index 56dd77d3da17c..abb8205ba8867 100644
--- a/dev/tests/integration/testsuite/Magento/MysqlMq/Model/QueueManagementTest.php
+++ b/dev/tests/integration/testsuite/Magento/MysqlMq/Model/QueueManagementTest.php
@@ -23,27 +23,26 @@ class QueueManagementTest extends \PHPUnit\Framework\TestCase
protected function setUp()
{
$this->objectManager = \Magento\TestFramework\Helper\Bootstrap::getObjectManager();
- $this->queueManagement = $this->objectManager->create(\Magento\MysqlMq\Model\QueueManagement::class);
+ $this->queueManagement = $this->objectManager->create(QueueManagement::class);
}
/**
* @magentoDataFixture Magento/MysqlMq/_files/queues.php
*/
- public function testAllFlows()
+ public function testMessageReading()
{
- $this->queueManagement->addMessageToQueues('topic1', 'messageBody1', ['queue1', 'queue2']);
- $this->queueManagement->addMessageToQueues('topic2', 'messageBody2', ['queue2', 'queue3']);
- $this->queueManagement->addMessageToQueues('topic3', 'messageBody3', ['queue1', 'queue3']);
- $this->queueManagement->addMessageToQueues('topic4', 'messageBody4', ['queue1', 'queue2', 'queue3']);
+ $this->queueManagement->addMessageToQueues('topic1', 'messageBody1', ['queue1']);
+ $this->queueManagement->addMessageToQueues('topic2', 'messageBody2', ['queue1']);
+ $this->queueManagement->addMessageToQueues('topic3', 'messageBody3', ['queue1']);
$maxMessagesNumber = 2;
- $messages = $this->queueManagement->readMessages('queue3', $maxMessagesNumber);
+ $messages = $this->queueManagement->readMessages('queue1', $maxMessagesNumber);
$this->assertCount($maxMessagesNumber, $messages);
$firstMessage = array_shift($messages);
- $this->assertEquals('topic2', $firstMessage[QueueManagement::MESSAGE_TOPIC]);
- $this->assertEquals('messageBody2', $firstMessage[QueueManagement::MESSAGE_BODY]);
- $this->assertEquals('queue3', $firstMessage[QueueManagement::MESSAGE_QUEUE_NAME]);
+ $this->assertEquals('topic1', $firstMessage[QueueManagement::MESSAGE_TOPIC]);
+ $this->assertEquals('messageBody1', $firstMessage[QueueManagement::MESSAGE_BODY]);
+ $this->assertEquals('queue1', $firstMessage[QueueManagement::MESSAGE_QUEUE_NAME]);
$this->assertEquals(
QueueManagement::MESSAGE_STATUS_IN_PROGRESS,
$firstMessage[QueueManagement::MESSAGE_STATUS]
@@ -55,9 +54,9 @@ public function testAllFlows()
$this->assertCount(12, date_parse($firstMessage[QueueManagement::MESSAGE_UPDATED_AT]));
$secondMessage = array_shift($messages);
- $this->assertEquals('topic3', $secondMessage[QueueManagement::MESSAGE_TOPIC]);
- $this->assertEquals('messageBody3', $secondMessage[QueueManagement::MESSAGE_BODY]);
- $this->assertEquals('queue3', $secondMessage[QueueManagement::MESSAGE_QUEUE_NAME]);
+ $this->assertEquals('topic2', $secondMessage[QueueManagement::MESSAGE_TOPIC]);
+ $this->assertEquals('messageBody2', $secondMessage[QueueManagement::MESSAGE_BODY]);
+ $this->assertEquals('queue1', $secondMessage[QueueManagement::MESSAGE_QUEUE_NAME]);
$this->assertEquals(
QueueManagement::MESSAGE_STATUS_IN_PROGRESS,
$secondMessage[QueueManagement::MESSAGE_STATUS]
@@ -67,35 +66,74 @@ public function testAllFlows()
$this->assertTrue(is_numeric($secondMessage[QueueManagement::MESSAGE_QUEUE_RELATION_ID]));
$this->assertEquals(0, $secondMessage[QueueManagement::MESSAGE_NUMBER_OF_TRIALS]);
$this->assertCount(12, date_parse($secondMessage[QueueManagement::MESSAGE_UPDATED_AT]));
+ }
+
+ /**
+ * @magentoDataFixture Magento/MysqlMq/_files/queues.php
+ */
+ public function testChangingMessageStatus()
+ {
+ $this->queueManagement->addMessageToQueues('topic1', 'messageBody1', ['queue1']);
+ $this->queueManagement->addMessageToQueues('topic2', 'messageBody2', ['queue1']);
+ $this->queueManagement->addMessageToQueues('topic3', 'messageBody3', ['queue1']);
+ $this->queueManagement->addMessageToQueues('topic4', 'messageBody4', ['queue1']);
+
+ $maxMessagesNumber = 4;
+ $messages = $this->queueManagement->readMessages('queue1', $maxMessagesNumber);
+ $this->assertCount($maxMessagesNumber, $messages);
+
+ $firstMessage = array_shift($messages);
+ $secondMessage = array_shift($messages);
+ $thirdMessage = array_shift($messages);
+ $fourthMessage = array_shift($messages);
+
+ $this->queueManagement->changeStatus(
+ [
+ $firstMessage[QueueManagement::MESSAGE_QUEUE_RELATION_ID]
+ ],
+ QueueManagement::MESSAGE_STATUS_ERROR
+ );
- /** Mark one message as complete or failed and make sure it is not displayed in the list of read messages */
$this->queueManagement->changeStatus(
[
$secondMessage[QueueManagement::MESSAGE_QUEUE_RELATION_ID]
],
QueueManagement::MESSAGE_STATUS_COMPLETE
);
- $messages = $this->queueManagement->readMessages('queue3', $maxMessagesNumber);
- $this->assertCount(1, $messages);
$this->queueManagement->changeStatus(
[
- $firstMessage[QueueManagement::MESSAGE_QUEUE_RELATION_ID]
+ $thirdMessage[QueueManagement::MESSAGE_QUEUE_RELATION_ID]
],
- QueueManagement::MESSAGE_STATUS_ERROR
+ QueueManagement::MESSAGE_STATUS_NEW
+ );
+
+ $this->queueManagement->changeStatus(
+ [
+ $fourthMessage[QueueManagement::MESSAGE_QUEUE_RELATION_ID]
+ ],
+ QueueManagement::MESSAGE_STATUS_RETRY_REQUIRED
);
- $messages = $this->queueManagement->readMessages('queue3', $maxMessagesNumber);
- $this->assertCount(0, $messages);
- /** Ensure that message for retry is still accessible when reading messages from the queue */
- $messages = $this->queueManagement->readMessages('queue2', 1);
+ $messages = $this->queueManagement->readMessages('queue1');
+ $this->assertCount(2, $messages);
+ }
+
+ /**
+ * @magentoDataFixture Magento/MysqlMq/_files/queues.php
+ */
+ public function testMessageRetry()
+ {
+ $this->queueManagement->addMessageToQueues('topic1', 'messageBody1', ['queue1']);
+
+ $messages = $this->queueManagement->readMessages('queue1', 1);
$message = array_shift($messages);
$messageRelationId = $message[QueueManagement::MESSAGE_QUEUE_RELATION_ID];
for ($i = 0; $i < 2; $i++) {
$this->assertEquals($i, $message[QueueManagement::MESSAGE_NUMBER_OF_TRIALS]);
$this->queueManagement->pushToQueueForRetry($message[QueueManagement::MESSAGE_QUEUE_RELATION_ID]);
- $messages = $this->queueManagement->readMessages('queue2', 1);
+ $messages = $this->queueManagement->readMessages('queue1', 1);
$message = array_shift($messages);
$this->assertEquals($messageRelationId, $message[QueueManagement::MESSAGE_QUEUE_RELATION_ID]);
}
From 572f40f211edc9ba47241d75d912d251a618e793 Mon Sep 17 00:00:00 2001
From: Mark Berube
Date: Fri, 16 Aug 2019 16:22:16 -0500
Subject: [PATCH 072/937] MC-5696: Fixing flaky QueueManagementTest - Adding a
test scenario for adding to multiple queues
---
.../MysqlMq/Model/QueueManagementTest.php | 55 +++++++++++++++++++
1 file changed, 55 insertions(+)
diff --git a/dev/tests/integration/testsuite/Magento/MysqlMq/Model/QueueManagementTest.php b/dev/tests/integration/testsuite/Magento/MysqlMq/Model/QueueManagementTest.php
index abb8205ba8867..790e68ee3a720 100644
--- a/dev/tests/integration/testsuite/Magento/MysqlMq/Model/QueueManagementTest.php
+++ b/dev/tests/integration/testsuite/Magento/MysqlMq/Model/QueueManagementTest.php
@@ -3,6 +3,7 @@
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
+declare(strict_types=1);
namespace Magento\MysqlMq\Model;
/**
@@ -68,6 +69,60 @@ public function testMessageReading()
$this->assertCount(12, date_parse($secondMessage[QueueManagement::MESSAGE_UPDATED_AT]));
}
+ /**
+ * @magentoDataFixture Magento/MysqlMq/_files/queues.php
+ */
+ public function testMessageReadingMultipleQueues()
+ {
+ $this->queueManagement->addMessageToQueues('topic1', 'messageBody1', ['queue1']);
+ $this->queueManagement->addMessageToQueues('topic2', 'messageBody2', ['queue1', 'queue2']);
+ $this->queueManagement->addMessageToQueues('topic3', 'messageBody3', ['queue2']);
+
+ $maxMessagesNumber = 2;
+ $messages = $this->queueManagement->readMessages('queue1', $maxMessagesNumber);
+ $this->assertCount($maxMessagesNumber, $messages);
+
+ $message = array_shift($messages);
+ $this->assertEquals('topic1', $message[QueueManagement::MESSAGE_TOPIC]);
+ $this->assertEquals('messageBody1', $message[QueueManagement::MESSAGE_BODY]);
+ $this->assertEquals('queue1', $message[QueueManagement::MESSAGE_QUEUE_NAME]);
+ $this->assertEquals(
+ QueueManagement::MESSAGE_STATUS_IN_PROGRESS,
+ $message[QueueManagement::MESSAGE_STATUS]
+ );
+
+ $message= array_shift($messages);
+ $this->assertEquals('topic2', $message[QueueManagement::MESSAGE_TOPIC]);
+ $this->assertEquals('messageBody2', $message[QueueManagement::MESSAGE_BODY]);
+ $this->assertEquals('queue1', $message[QueueManagement::MESSAGE_QUEUE_NAME]);
+ $this->assertEquals(
+ QueueManagement::MESSAGE_STATUS_IN_PROGRESS,
+ $message[QueueManagement::MESSAGE_STATUS]
+ );
+
+ $maxMessagesNumber = 2;
+ $messages = $this->queueManagement->readMessages('queue2', $maxMessagesNumber);
+ $this->assertCount($maxMessagesNumber, $messages);
+
+ $message= array_shift($messages);
+ $this->assertEquals('topic2', $message[QueueManagement::MESSAGE_TOPIC]);
+ $this->assertEquals('messageBody2', $message[QueueManagement::MESSAGE_BODY]);
+ $this->assertEquals('queue2', $message[QueueManagement::MESSAGE_QUEUE_NAME]);
+ $this->assertEquals(
+ QueueManagement::MESSAGE_STATUS_IN_PROGRESS,
+ $message[QueueManagement::MESSAGE_STATUS]
+ );
+
+ $message = array_shift($messages);
+ $this->assertEquals('topic3', $message[QueueManagement::MESSAGE_TOPIC]);
+ $this->assertEquals('messageBody3', $message[QueueManagement::MESSAGE_BODY]);
+ $this->assertEquals('queue2', $message[QueueManagement::MESSAGE_QUEUE_NAME]);
+ $this->assertEquals(
+ QueueManagement::MESSAGE_STATUS_IN_PROGRESS,
+ $message[QueueManagement::MESSAGE_STATUS]
+ );
+ }
+
/**
* @magentoDataFixture Magento/MysqlMq/_files/queues.php
*/
From 5164240b200d05ed496cd8011f5ab7d2907e4fc6 Mon Sep 17 00:00:00 2001
From: Nikita Chubukov
Date: Sat, 17 Aug 2019 21:31:39 +0300
Subject: [PATCH 073/937] MC-15256: Exported customer without modification can
not be imported
- Fix static test
---
app/code/Magento/CustomerImportExport/Model/Import/Customer.php | 2 ++
1 file changed, 2 insertions(+)
diff --git a/app/code/Magento/CustomerImportExport/Model/Import/Customer.php b/app/code/Magento/CustomerImportExport/Model/Import/Customer.php
index 914b4fd2a3ca9..563bd2cd7f2b9 100644
--- a/app/code/Magento/CustomerImportExport/Model/Import/Customer.php
+++ b/app/code/Magento/CustomerImportExport/Model/Import/Customer.php
@@ -521,8 +521,10 @@ protected function _importData()
);
} elseif ($this->getBehavior($rowData) == \Magento\ImportExport\Model\Import::BEHAVIOR_ADD_UPDATE) {
$processedData = $this->_prepareDataForUpdate($rowData);
+ // phpcs:disable Magento2.Performance.ForeachArrayMerge
$entitiesToCreate = array_merge($entitiesToCreate, $processedData[self::ENTITIES_TO_CREATE_KEY]);
$entitiesToUpdate = array_merge($entitiesToUpdate, $processedData[self::ENTITIES_TO_UPDATE_KEY]);
+ // phpcs:enable
foreach ($processedData[self::ATTRIBUTES_TO_SAVE_KEY] as $tableName => $customerAttributes) {
if (!isset($attributesToSave[$tableName])) {
$attributesToSave[$tableName] = [];
From 986bc309fdb9f9eee85af46439e619946dcc324b Mon Sep 17 00:00:00 2001
From: Mila Lesechko <26227105+MilaLesechko@users.noreply.github.com>
Date: Mon, 19 Aug 2019 11:30:35 -0500
Subject: [PATCH 074/937] Convert AdvancedSearchEntityTest to MFTF
---
.../Magento/Catalog/Test/Mftf/Data/CustomAttributeData.xml | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/app/code/Magento/Catalog/Test/Mftf/Data/CustomAttributeData.xml b/app/code/Magento/Catalog/Test/Mftf/Data/CustomAttributeData.xml
index 95e256c856fbe..e87ee83c3c18a 100644
--- a/app/code/Magento/Catalog/Test/Mftf/Data/CustomAttributeData.xml
+++ b/app/code/Magento/Catalog/Test/Mftf/Data/CustomAttributeData.xml
@@ -51,6 +51,10 @@
short_description
Short Fixedtest 555
+
+ description
+ <p>adc_Full</p>
+
short_description
<p>abc_short</p>
From 3d55863b67754d553e10c1d5311405f5c9d4b4c1 Mon Sep 17 00:00:00 2001
From: Veronika Kurochkina
Date: Tue, 20 Aug 2019 13:31:48 +0300
Subject: [PATCH 075/937] MAGETWO-44170: Not pass function test
\Magento\Catalog\Test\TestCase\Product\ProductTypeSwitchingOnUpdateTest
- Fix modularity issue
---
...AdminProductTypeSwitchingOnEditingTest.xml | 280 ------------------
...AdminProductTypeSwitchingOnEditingTest.xml | 243 +++++++++++++++
2 files changed, 243 insertions(+), 280 deletions(-)
create mode 100644 app/code/Magento/ConfigurableProduct/Test/Mftf/Test/AdminProductTypeSwitchingOnEditingTest.xml
diff --git a/app/code/Magento/Catalog/Test/Mftf/Test/AdminProductTypeSwitchingOnEditingTest.xml b/app/code/Magento/Catalog/Test/Mftf/Test/AdminProductTypeSwitchingOnEditingTest.xml
index cac5e209af9fd..45f404478809a 100644
--- a/app/code/Magento/Catalog/Test/Mftf/Test/AdminProductTypeSwitchingOnEditingTest.xml
+++ b/app/code/Magento/Catalog/Test/Mftf/Test/AdminProductTypeSwitchingOnEditingTest.xml
@@ -8,195 +8,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -241,12 +52,6 @@
-
-
-
-
-
-
@@ -281,12 +86,6 @@
-
-
-
-
-
-
@@ -336,89 +135,10 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/app/code/Magento/ConfigurableProduct/Test/Mftf/Test/AdminProductTypeSwitchingOnEditingTest.xml b/app/code/Magento/ConfigurableProduct/Test/Mftf/Test/AdminProductTypeSwitchingOnEditingTest.xml
new file mode 100644
index 0000000000000..071ee8d18920f
--- /dev/null
+++ b/app/code/Magento/ConfigurableProduct/Test/Mftf/Test/AdminProductTypeSwitchingOnEditingTest.xml
@@ -0,0 +1,243 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
From 0cfebd6660dbcb89abba40aeb3e03706d80f97bb Mon Sep 17 00:00:00 2001
From: Lusine Papyan
Date: Tue, 20 Aug 2019 14:53:48 +0400
Subject: [PATCH 076/937] MAGETWO-69825: [GITHUB #9891] Subcategory
"liquid-hand-soap" is not opened in category "soap"
- Updated automated test script
---
.../Test/Mftf/ActionGroup/AdminCategoryActionGroup.xml | 2 +-
.../AdminCategoryWithRestrictedUrlKeyNotCreatedTest.xml | 9 +++++----
2 files changed, 6 insertions(+), 5 deletions(-)
diff --git a/app/code/Magento/Catalog/Test/Mftf/ActionGroup/AdminCategoryActionGroup.xml b/app/code/Magento/Catalog/Test/Mftf/ActionGroup/AdminCategoryActionGroup.xml
index a944aa72e5ccd..c108068b00648 100644
--- a/app/code/Magento/Catalog/Test/Mftf/ActionGroup/AdminCategoryActionGroup.xml
+++ b/app/code/Magento/Catalog/Test/Mftf/ActionGroup/AdminCategoryActionGroup.xml
@@ -139,7 +139,7 @@
-
+
diff --git a/app/code/Magento/CatalogUrlRewrite/Test/Mftf/Test/AdminCategoryWithRestrictedUrlKeyNotCreatedTest.xml b/app/code/Magento/CatalogUrlRewrite/Test/Mftf/Test/AdminCategoryWithRestrictedUrlKeyNotCreatedTest.xml
index 58997aa7a5182..3663035ca47af 100644
--- a/app/code/Magento/CatalogUrlRewrite/Test/Mftf/Test/AdminCategoryWithRestrictedUrlKeyNotCreatedTest.xml
+++ b/app/code/Magento/CatalogUrlRewrite/Test/Mftf/Test/AdminCategoryWithRestrictedUrlKeyNotCreatedTest.xml
@@ -10,6 +10,7 @@
+
@@ -23,16 +24,16 @@
-
+
-
+
-
+
-
+
From 0b8838ccfc4d5d7b86f8646969ec38fddbed2904 Mon Sep 17 00:00:00 2001
From: Mila Lesechko <26227105+MilaLesechko@users.noreply.github.com>
Date: Tue, 20 Aug 2019 10:21:53 -0500
Subject: [PATCH 077/937] Convert AdvancedSearchEntityTest to MFTF
---
.../Magento/Catalog/Test/Mftf/Data/CustomAttributeData.xml | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/app/code/Magento/Catalog/Test/Mftf/Data/CustomAttributeData.xml b/app/code/Magento/Catalog/Test/Mftf/Data/CustomAttributeData.xml
index e87ee83c3c18a..3fbe9f86eab96 100644
--- a/app/code/Magento/Catalog/Test/Mftf/Data/CustomAttributeData.xml
+++ b/app/code/Magento/Catalog/Test/Mftf/Data/CustomAttributeData.xml
@@ -63,4 +63,8 @@
description
<p>dfj_full</p>
+
+ short_description
+ <p>dfj_short</p>
+
From 4f93f813049504bb89bd9be8826fc9a3358cf2a4 Mon Sep 17 00:00:00 2001
From: Mila Lesechko <26227105+MilaLesechko@users.noreply.github.com>
Date: Tue, 20 Aug 2019 10:22:00 -0500
Subject: [PATCH 078/937] Convert AdvancedSearchEntityTest to MFTF
---
app/code/Magento/Catalog/Test/Mftf/Data/ProductData.xml | 1 +
1 file changed, 1 insertion(+)
diff --git a/app/code/Magento/Catalog/Test/Mftf/Data/ProductData.xml b/app/code/Magento/Catalog/Test/Mftf/Data/ProductData.xml
index 70d58be4b0df8..378e41e933fe7 100644
--- a/app/code/Magento/Catalog/Test/Mftf/Data/ProductData.xml
+++ b/app/code/Magento/Catalog/Test/Mftf/Data/ProductData.xml
@@ -1236,5 +1236,6 @@
1
EavStockItem
ProductDescriptionAdvancedSearchADC123
+ ProductShortDescriptionAdvancedSearchADC123
From 491790e2fec093d8b26c2a52d0aa987b8d1fee61 Mon Sep 17 00:00:00 2001
From: Mila Lesechko <26227105+MilaLesechko@users.noreply.github.com>
Date: Tue, 20 Aug 2019 10:22:05 -0500
Subject: [PATCH 079/937] Convert AdvancedSearchEntityTest to MFTF
---
.../StorefrontAdvancedSearchByPartialShortDescriptionTest.xml | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/app/code/Magento/CatalogSearch/Test/Mftf/Test/StorefrontAdvancedSearchByPartialShortDescriptionTest.xml b/app/code/Magento/CatalogSearch/Test/Mftf/Test/StorefrontAdvancedSearchByPartialShortDescriptionTest.xml
index 2afb4b5a341c1..0edc3f31216bb 100644
--- a/app/code/Magento/CatalogSearch/Test/Mftf/Test/StorefrontAdvancedSearchByPartialShortDescriptionTest.xml
+++ b/app/code/Magento/CatalogSearch/Test/Mftf/Test/StorefrontAdvancedSearchByPartialShortDescriptionTest.xml
@@ -19,7 +19,7 @@
-
+
From a19c9018e5a4b172f8beadb78cc8888c15bbbc62 Mon Sep 17 00:00:00 2001
From: natalia
Date: Wed, 14 Aug 2019 11:25:28 +0300
Subject: [PATCH 080/937] MC-18825: Increase test coverage for Promotion and
Loyalty functional area
- Integration test for MC-6347
---
...simple_out_of_stock_without_categories.php | 52 +++++++++
...t_of_stock_without_categories_rollback.php | 8 ++
.../_files/customer_for_second_store.php | 17 +++
.../customer_for_second_store_rollback.php | 8 ++
.../ProductAlert/Model/ObserverTest.php | 110 ++++++++++++++----
.../ProductAlert/_files/i18n/pt_BR.csv | 1 +
.../_files/product_alert_with_store.php | 29 +++++
7 files changed, 201 insertions(+), 24 deletions(-)
create mode 100644 dev/tests/integration/testsuite/Magento/Catalog/_files/product_simple_out_of_stock_without_categories.php
create mode 100644 dev/tests/integration/testsuite/Magento/Catalog/_files/product_simple_out_of_stock_without_categories_rollback.php
create mode 100644 dev/tests/integration/testsuite/Magento/Customer/_files/customer_for_second_store.php
create mode 100644 dev/tests/integration/testsuite/Magento/Customer/_files/customer_for_second_store_rollback.php
create mode 100644 dev/tests/integration/testsuite/Magento/ProductAlert/_files/i18n/pt_BR.csv
create mode 100644 dev/tests/integration/testsuite/Magento/ProductAlert/_files/product_alert_with_store.php
diff --git a/dev/tests/integration/testsuite/Magento/Catalog/_files/product_simple_out_of_stock_without_categories.php b/dev/tests/integration/testsuite/Magento/Catalog/_files/product_simple_out_of_stock_without_categories.php
new file mode 100644
index 0000000000000..4bd534b4165b4
--- /dev/null
+++ b/dev/tests/integration/testsuite/Magento/Catalog/_files/product_simple_out_of_stock_without_categories.php
@@ -0,0 +1,52 @@
+reinitialize();
+
+/** @var ObjectManager $objectManager */
+$objectManager = Bootstrap::getObjectManager();
+
+/** @var $product Product */
+$product = $objectManager->create(Product::class);
+$product->isObjectNew(true);
+$product->setTypeId(Type::TYPE_SIMPLE)
+ ->setId(1)
+ ->setAttributeSetId(4)
+ ->setWebsiteIds([1])
+ ->setName('Simple Product')
+ ->setSku('simple')
+ ->setPrice(10)
+ ->setWeight(1)
+ ->setShortDescription("Short description")
+ ->setTaxClassId(0)
+ ->setDescription('Description with html tag ')
+ ->setMetaTitle('meta title')
+ ->setMetaKeyword('meta keyword')
+ ->setMetaDescription('meta description')
+ ->setVisibility(Visibility::VISIBILITY_BOTH)
+ ->setStatus(Status::STATUS_ENABLED)
+ ->setStockData(
+ [
+ 'use_config_manage_stock' => 1,
+ 'qty' => 0,
+ 'is_qty_decimal' => 0,
+ 'is_in_stock' => 0,
+ ]
+ )->setCanSaveCustomOptions(true)
+ ->setHasOptions(true);
+
+/** @var ProductRepositoryInterface $productRepository */
+$productRepository = $objectManager->create(ProductRepositoryInterface::class);
+$productRepository->save($product);
diff --git a/dev/tests/integration/testsuite/Magento/Catalog/_files/product_simple_out_of_stock_without_categories_rollback.php b/dev/tests/integration/testsuite/Magento/Catalog/_files/product_simple_out_of_stock_without_categories_rollback.php
new file mode 100644
index 0000000000000..4c858f322f8a7
--- /dev/null
+++ b/dev/tests/integration/testsuite/Magento/Catalog/_files/product_simple_out_of_stock_without_categories_rollback.php
@@ -0,0 +1,8 @@
+create(CustomerRepositoryInterface::class);
+$customer = $repository->get('customer@example.com');
+$customer->setStoreId(2);
+$repository->save($customer);
diff --git a/dev/tests/integration/testsuite/Magento/Customer/_files/customer_for_second_store_rollback.php b/dev/tests/integration/testsuite/Magento/Customer/_files/customer_for_second_store_rollback.php
new file mode 100644
index 0000000000000..61cce9dbcc8d8
--- /dev/null
+++ b/dev/tests/integration/testsuite/Magento/Customer/_files/customer_for_second_store_rollback.php
@@ -0,0 +1,8 @@
+_objectManager = \Magento\TestFramework\Helper\Bootstrap::getObjectManager();
- $this->_customerSession = $this->_objectManager->get(
- \Magento\Customer\Model\Session::class
- );
- $service = \Magento\TestFramework\Helper\Bootstrap::getObjectManager()->create(
- \Magento\Customer\Api\AccountManagementInterface::class
- );
+ Bootstrap::getInstance()->loadArea(Area::AREA_FRONTEND);
+ $this->_objectManager = Bootstrap::getObjectManager();
+ $this->observer = $this->_objectManager->get(Observer::class);
+ $this->transportBuilder = $this->_objectManager->get(TransportBuilderMock::class);
+ $service = $this->_objectManager->create(AccountManagementInterface::class);
$customer = $service->authenticate('customer@example.com', 'password');
- $this->_customerSession->setCustomerDataAsLoggedIn($customer);
- $this->_customerViewHelper = $this->_objectManager->create(\Magento\Customer\Helper\View::class);
+ $customerSession = $this->_objectManager->get(Session::class);
+ $customerSession->setCustomerDataAsLoggedIn($customer);
}
/**
- * @magentoConfigFixture current_store catalog/productalert/allow_price 1
+ * Test process() method
*
+ * @magentoConfigFixture current_store catalog/productalert/allow_price 1 *
* @magentoDataFixture Magento/ProductAlert/_files/product_alert.php
*/
public function testProcess()
{
- \Magento\TestFramework\Helper\Bootstrap::getInstance()->loadArea(\Magento\Framework\App\Area::AREA_FRONTEND);
- $observer = $this->_objectManager->get(\Magento\ProductAlert\Model\Observer::class);
- $observer->process();
-
- /** @var \Magento\TestFramework\Mail\Template\TransportBuilderMock $transportBuilder */
- $transportBuilder = $this->_objectManager->get(
- \Magento\TestFramework\Mail\Template\TransportBuilderMock::class
- );
+ $this->observer->process();
$this->assertContains(
'John Smith,',
- $transportBuilder->getSentMessage()->getRawMessage()
+ $this->transportBuilder->getSentMessage()->getRawMessage()
);
}
+
+ /**
+ * Check translations for product alerts
+ *
+ * @magentoDbIsolation enabled
+ * @magentoAppArea frontend
+ * @magentoConfigFixture current_store catalog/productalert/allow_price 1
+ * @magentoDataFixture Magento/Store/_files/second_store.php
+ * @magentoConfigFixture fixture_second_store_store general/locale/code pt_BR
+ * @magentoDataFixture Magento/ProductAlert/_files/product_alert_with_store.php
+ */
+ public function testProcessPortuguese()
+ {
+ // get second store
+ $storeRepository = $this->_objectManager->create(StoreRepository::class);
+ $secondStore = $storeRepository->get('fixture_second_store');
+
+ // check if Portuguese language is specified for the second store
+ CacheCleaner::cleanAll();
+ $storeResolver = $this->_objectManager->get(Resolver::class);
+ $storeResolver->emulate($secondStore->getId());
+ $this->assertEquals('pt_BR', $storeResolver->getLocale());
+
+ // set translation data and check it
+ $modulesReader = $this->createPartialMock(Reader::class, ['getModuleDir']);
+ $modulesReader->expects($this->any())
+ ->method('getModuleDir')
+ ->willReturn(dirname(__DIR__) . '/_files/i18n');
+ /** @var Translate $translator */
+ $translator = $this->_objectManager->create(Translate::class, ['modulesReader' => $modulesReader]);
+ $translation = [
+ 'Price change alert! We wanted you to know that prices have changed for these products:' =>
+ 'Alerta de mudanca de preco! Queriamos que voce soubesse que os precos mudaram para esses produtos:'
+ ];
+ $translator->loadData();
+ $this->assertEquals($translation, $translator->getData());
+ $this->_objectManager->addSharedInstance($translator, Translate::class);
+ $this->_objectManager->removeSharedInstance(PhraseRendererTranslate::class);
+ Phrase::setRenderer($this->_objectManager->create(RendererInterface::class));
+
+ // dispatch process() method and check sent message
+ $this->observer->process();
+ $message = $this->transportBuilder->getSentMessage()->getRawMessage();
+ $expectedText = array_shift($translation);
+ $this->assertContains('/frontend/Magento/luma/pt_BR/', $message);
+ $this->assertContains(substr($expectedText, 0, 50), $message);
+ }
}
diff --git a/dev/tests/integration/testsuite/Magento/ProductAlert/_files/i18n/pt_BR.csv b/dev/tests/integration/testsuite/Magento/ProductAlert/_files/i18n/pt_BR.csv
new file mode 100644
index 0000000000000..0c8218a78923a
--- /dev/null
+++ b/dev/tests/integration/testsuite/Magento/ProductAlert/_files/i18n/pt_BR.csv
@@ -0,0 +1 @@
+"Price change alert! We wanted you to know that prices have changed for these products:","Alerta de mudanca de preco! Queriamos que voce soubesse que os precos mudaram para esses produtos:",Magento_ProductAlert
diff --git a/dev/tests/integration/testsuite/Magento/ProductAlert/_files/product_alert_with_store.php b/dev/tests/integration/testsuite/Magento/ProductAlert/_files/product_alert_with_store.php
new file mode 100644
index 0000000000000..38f00d49f1d47
--- /dev/null
+++ b/dev/tests/integration/testsuite/Magento/ProductAlert/_files/product_alert_with_store.php
@@ -0,0 +1,29 @@
+create(Price::class);
+$price->setCustomerId($customer->getId())
+ ->setProductId($product->getId())
+ ->setPrice($product->getPrice()+1)
+ ->setWebsiteId(1)
+ ->setStoreId(2);
+$price->save();
+
+$stock = $objectManager->create(Stock::class);
+$stock->setCustomerId($customer->getId())
+ ->setProductId($product->getId())
+ ->setWebsiteId(1)
+ ->setStoreId(2);
+$stock->save();
From 8145725564ebe7b0d6030985e1e821bafeec1f15 Mon Sep 17 00:00:00 2001
From: Stepan Furman
Date: Wed, 21 Aug 2019 14:00:55 +0300
Subject: [PATCH 081/937] MC-13951: Declarative upgrade leads to the
re-creation of constraints
---
.../Patch/Schema/ChangeTmpTablesEngine.php | 68 ----------------
app/code/Magento/Bundle/etc/db_schema.xml | 6 +-
.../Patch/Schema/ChangeTmpTablesEngine.php | 74 -----------------
app/code/Magento/Catalog/etc/db_schema.xml | 38 ++++-----
.../Patch/Schema/ChangeTmpTablesEngine.php | 61 --------------
.../CatalogInventory/etc/db_schema.xml | 6 +-
.../Patch/Schema/ChangeTmpTablesEngine.php | 61 --------------
.../Magento/Downloadable/etc/db_schema.xml | 2 +-
.../Patch/Schema/AddProductIdConstraint.php | 79 -------------------
app/code/Magento/Wishlist/etc/db_schema.xml | 4 +
10 files changed, 30 insertions(+), 369 deletions(-)
delete mode 100644 app/code/Magento/Bundle/Setup/Patch/Schema/ChangeTmpTablesEngine.php
delete mode 100644 app/code/Magento/Catalog/Setup/Patch/Schema/ChangeTmpTablesEngine.php
delete mode 100644 app/code/Magento/CatalogInventory/Setup/Patch/Schema/ChangeTmpTablesEngine.php
delete mode 100644 app/code/Magento/Downloadable/Setup/Patch/Schema/ChangeTmpTablesEngine.php
delete mode 100644 app/code/Magento/Wishlist/Setup/Patch/Schema/AddProductIdConstraint.php
diff --git a/app/code/Magento/Bundle/Setup/Patch/Schema/ChangeTmpTablesEngine.php b/app/code/Magento/Bundle/Setup/Patch/Schema/ChangeTmpTablesEngine.php
deleted file mode 100644
index c6a67cc5a110c..0000000000000
--- a/app/code/Magento/Bundle/Setup/Patch/Schema/ChangeTmpTablesEngine.php
+++ /dev/null
@@ -1,68 +0,0 @@
-schemaSetup = $schemaSetup;
- }
-
- /**
- * @inheritdoc
- */
- public function apply()
- {
- $this->schemaSetup->startSetup();
-
- $tables = [
- 'catalog_product_index_price_bundle_tmp',
- 'catalog_product_index_price_bundle_sel_tmp',
- 'catalog_product_index_price_bundle_opt_tmp',
- ];
- foreach ($tables as $table) {
- $tableName = $this->schemaSetup->getTable($table);
- if ($this->schemaSetup->getConnection()->isTableExists($tableName)) {
- $this->schemaSetup->getConnection()->changeTableEngine($tableName, 'InnoDB');
- }
- }
-
- $this->schemaSetup->endSetup();
- }
-
- /**
- * @inheritdoc
- */
- public static function getDependencies()
- {
- return [];
- }
-
- /**
- * @inheritdoc
- */
- public function getAliases()
- {
- return [];
- }
-}
diff --git a/app/code/Magento/Bundle/etc/db_schema.xml b/app/code/Magento/Bundle/etc/db_schema.xml
index 97e86e5c17359..ade8fbf7cf1ce 100644
--- a/app/code/Magento/Bundle/etc/db_schema.xml
+++ b/app/code/Magento/Bundle/etc/db_schema.xml
@@ -203,7 +203,7 @@
-
-
-
diff --git a/app/code/Magento/Catalog/Setup/Patch/Schema/ChangeTmpTablesEngine.php b/app/code/Magento/Catalog/Setup/Patch/Schema/ChangeTmpTablesEngine.php
deleted file mode 100644
index c39247f9b30df..0000000000000
--- a/app/code/Magento/Catalog/Setup/Patch/Schema/ChangeTmpTablesEngine.php
+++ /dev/null
@@ -1,74 +0,0 @@
-schemaSetup = $schemaSetup;
- }
-
- /**
- * @inheritdoc
- */
- public function apply()
- {
- $this->schemaSetup->startSetup();
-
- $tables = [
- 'catalog_product_index_price_cfg_opt_agr_tmp',
- 'catalog_product_index_price_cfg_opt_tmp',
- 'catalog_product_index_price_final_tmp',
- 'catalog_product_index_price_opt_tmp',
- 'catalog_product_index_price_opt_agr_tmp',
- 'catalog_product_index_eav_tmp',
- 'catalog_product_index_eav_decimal_tmp',
- 'catalog_product_index_price_tmp',
- 'catalog_category_product_index_tmp',
- ];
- foreach ($tables as $table) {
- $tableName = $this->schemaSetup->getTable($table);
- if ($this->schemaSetup->getConnection()->isTableExists($tableName)) {
- $this->schemaSetup->getConnection()->changeTableEngine($tableName, 'InnoDB');
- }
- }
-
- $this->schemaSetup->endSetup();
- }
-
- /**
- * @inheritdoc
- */
- public static function getDependencies()
- {
- return [];
- }
-
- /**
- * @inheritdoc
- */
- public function getAliases()
- {
- return [];
- }
-}
diff --git a/app/code/Magento/Catalog/etc/db_schema.xml b/app/code/Magento/Catalog/etc/db_schema.xml
index 6fef4ca6e9128..b5e02b1daaa01 100644
--- a/app/code/Magento/Catalog/etc/db_schema.xml
+++ b/app/code/Magento/Catalog/etc/db_schema.xml
@@ -1238,7 +1238,7 @@
-
-
-
-
-
-
@@ -1489,13 +1489,13 @@
-
+
-
+
-
+
@@ -1528,7 +1528,7 @@
-
@@ -1547,13 +1547,13 @@
-
+
-
+
-
+
@@ -1592,7 +1592,7 @@
-
@@ -1617,17 +1617,17 @@
-
+
-
+
-
+
-
@@ -1646,7 +1646,7 @@
-
+
diff --git a/app/code/Magento/CatalogInventory/Setup/Patch/Schema/ChangeTmpTablesEngine.php b/app/code/Magento/CatalogInventory/Setup/Patch/Schema/ChangeTmpTablesEngine.php
deleted file mode 100644
index 7f43cd279d4e3..0000000000000
--- a/app/code/Magento/CatalogInventory/Setup/Patch/Schema/ChangeTmpTablesEngine.php
+++ /dev/null
@@ -1,61 +0,0 @@
-schemaSetup = $schemaSetup;
- }
-
- /**
- * @inheritdoc
- */
- public function apply()
- {
- $this->schemaSetup->startSetup();
-
- $tableName = $this->schemaSetup->getTable('cataloginventory_stock_status_tmp');
- if ($this->schemaSetup->getConnection()->isTableExists($tableName)) {
- $this->schemaSetup->getConnection()->changeTableEngine($tableName, 'InnoDB');
- }
-
- $this->schemaSetup->endSetup();
- }
-
- /**
- * @inheritdoc
- */
- public static function getDependencies()
- {
- return [];
- }
-
- /**
- * @inheritdoc
- */
- public function getAliases()
- {
- return [];
- }
-}
diff --git a/app/code/Magento/CatalogInventory/etc/db_schema.xml b/app/code/Magento/CatalogInventory/etc/db_schema.xml
index 5ac7fedc5aa18..67a200eb37125 100644
--- a/app/code/Magento/CatalogInventory/etc/db_schema.xml
+++ b/app/code/Magento/CatalogInventory/etc/db_schema.xml
@@ -142,7 +142,7 @@
-
@@ -159,10 +159,10 @@
-
+
-
+
diff --git a/app/code/Magento/Downloadable/Setup/Patch/Schema/ChangeTmpTablesEngine.php b/app/code/Magento/Downloadable/Setup/Patch/Schema/ChangeTmpTablesEngine.php
deleted file mode 100644
index caf2f7745a3dd..0000000000000
--- a/app/code/Magento/Downloadable/Setup/Patch/Schema/ChangeTmpTablesEngine.php
+++ /dev/null
@@ -1,61 +0,0 @@
-schemaSetup = $schemaSetup;
- }
-
- /**
- * @inheritdoc
- */
- public function apply()
- {
- $this->schemaSetup->startSetup();
-
- $tableName = $this->schemaSetup->getTable('catalog_product_index_price_downlod_tmp');
- if ($this->schemaSetup->getConnection()->isTableExists($tableName)) {
- $this->schemaSetup->getConnection()->changeTableEngine($tableName, 'InnoDB');
- }
-
- $this->schemaSetup->endSetup();
- }
-
- /**
- * @inheritdoc
- */
- public static function getDependencies()
- {
- return [];
- }
-
- /**
- * @inheritdoc
- */
- public function getAliases()
- {
- return [];
- }
-}
diff --git a/app/code/Magento/Downloadable/etc/db_schema.xml b/app/code/Magento/Downloadable/etc/db_schema.xml
index ccbefa4fb3992..ee7b3c5683ea1 100644
--- a/app/code/Magento/Downloadable/etc/db_schema.xml
+++ b/app/code/Magento/Downloadable/etc/db_schema.xml
@@ -233,7 +233,7 @@
-
diff --git a/app/code/Magento/Wishlist/Setup/Patch/Schema/AddProductIdConstraint.php b/app/code/Magento/Wishlist/Setup/Patch/Schema/AddProductIdConstraint.php
deleted file mode 100644
index 5c65fce10ccd2..0000000000000
--- a/app/code/Magento/Wishlist/Setup/Patch/Schema/AddProductIdConstraint.php
+++ /dev/null
@@ -1,79 +0,0 @@
-schemaSetup = $schemaSetup;
- }
-
- /**
- * Run code inside patch.
- *
- * @return void
- */
- public function apply()
- {
- $this->schemaSetup->startSetup();
-
- $this->schemaSetup->getConnection()->addForeignKey(
- $this->schemaSetup->getConnection()->getForeignKeyName(
- $this->schemaSetup->getTable('wishlist_item_option'),
- 'product_id',
- $this->schemaSetup->getTable('catalog_product_entity'),
- 'entity_id'
- ),
- $this->schemaSetup->getTable('wishlist_item_option'),
- 'product_id',
- $this->schemaSetup->getTable('catalog_product_entity'),
- 'entity_id',
- AdapterInterface::FK_ACTION_CASCADE,
- true
- );
-
- $this->schemaSetup->endSetup();
- }
-
- /**
- * Get array of patches that have to be executed prior to this.
- *
- * @return string[]
- */
- public static function getDependencies()
- {
- return [];
- }
-
- /**
- * Get aliases (previous names) for the patch.
- *
- * @return string[]
- */
- public function getAliases()
- {
- return [];
- }
-}
diff --git a/app/code/Magento/Wishlist/etc/db_schema.xml b/app/code/Magento/Wishlist/etc/db_schema.xml
index 8a02f411ad0db..a1c50c240a9fb 100644
--- a/app/code/Magento/Wishlist/etc/db_schema.xml
+++ b/app/code/Magento/Wishlist/etc/db_schema.xml
@@ -77,5 +77,9 @@
+
From 246f2c9fc940408dd97904dd3c5385f8aad9939d Mon Sep 17 00:00:00 2001
From: Lusine Papyan
Date: Wed, 21 Aug 2019 16:59:20 +0400
Subject: [PATCH 082/937] MAGETWO-69825: [GITHUB #9891] Subcategory
"liquid-hand-soap" is not opened in category "soap"
- Updated automated test script
---
.../Test/AdminCategoryWithRestrictedUrlKeyNotCreatedTest.xml | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/app/code/Magento/CatalogUrlRewrite/Test/Mftf/Test/AdminCategoryWithRestrictedUrlKeyNotCreatedTest.xml b/app/code/Magento/CatalogUrlRewrite/Test/Mftf/Test/AdminCategoryWithRestrictedUrlKeyNotCreatedTest.xml
index 3663035ca47af..1e71d8e152651 100644
--- a/app/code/Magento/CatalogUrlRewrite/Test/Mftf/Test/AdminCategoryWithRestrictedUrlKeyNotCreatedTest.xml
+++ b/app/code/Magento/CatalogUrlRewrite/Test/Mftf/Test/AdminCategoryWithRestrictedUrlKeyNotCreatedTest.xml
@@ -10,7 +10,7 @@
-
+
From 86151cec2b662b91d000fdba886c05096569f84a Mon Sep 17 00:00:00 2001
From: Volodymyr Vygovskyi
Date: Wed, 21 Aug 2019 16:57:05 +0300
Subject: [PATCH 083/937] #813: [Test coverage] Update item qty for
configurable product
---
.../UpdateConfigurableCartItemsTest.php | 151 ++++++++++++++++++
1 file changed, 151 insertions(+)
create mode 100644 dev/tests/api-functional/testsuite/Magento/GraphQl/ConfigurableProduct/UpdateConfigurableCartItemsTest.php
diff --git a/dev/tests/api-functional/testsuite/Magento/GraphQl/ConfigurableProduct/UpdateConfigurableCartItemsTest.php b/dev/tests/api-functional/testsuite/Magento/GraphQl/ConfigurableProduct/UpdateConfigurableCartItemsTest.php
new file mode 100644
index 0000000000000..26ec331dcbce1
--- /dev/null
+++ b/dev/tests/api-functional/testsuite/Magento/GraphQl/ConfigurableProduct/UpdateConfigurableCartItemsTest.php
@@ -0,0 +1,151 @@
+getMaskedQuoteId($reservedOrderId);
+ $productSku = 'simple_10';
+ $newQuantity = 123;
+ $quoteItem = $this->getQuoteItemBySku($productSku, $reservedOrderId);
+
+ $query = $this->getQuery($maskedQuoteId, (int)$quoteItem->getId(), $newQuantity);
+ $response = $this->graphQlMutation($query);
+
+ self::assertArrayHasKey('updateCartItems', $response);
+ self::assertArrayHasKey('quantity', $response['updateCartItems']['cart']['items']['0']);
+ self::assertEquals($newQuantity, $response['updateCartItems']['cart']['items']['0']['quantity']);
+ }
+
+ /**
+ * @inheritdoc
+ */
+ protected function setUp()
+ {
+ $objectManager = Bootstrap::getObjectManager();
+ $this->getMaskedQuoteIdByReservedOrderId = $objectManager->get(GetMaskedQuoteIdByReservedOrderId::class);
+ $this->quoteFactory = $objectManager->get(QuoteFactory::class);
+ $this->quoteResource = $objectManager->get(QuoteResource::class);
+ $this->productRepository = $objectManager->get(ProductRepositoryInterface::class);
+ $this->quoteIdMaskFactory = Bootstrap::getObjectManager()->get(QuoteIdMaskFactory::class);
+ }
+
+ /**
+ * @param string $maskedQuoteId
+ * @param int $quoteItemId
+ * @param int $newQuantity
+ * @return string
+ */
+ private function getQuery(string $maskedQuoteId, int $quoteItemId, int $newQuantity): string
+ {
+ return <<quoteFactory->create();
+ $this->quoteResource->load($quote, $reservedOrderId, 'reserved_order_id');
+ $item = false;
+ foreach ($quote->getAllItems() as $quoteItem) {
+ if ($quoteItem->getSku() == $sku && $quoteItem->getProductType() == Configurable::TYPE_CODE &&
+ !$quoteItem->getParentItemId()) {
+ $item = $quoteItem;
+ break;
+ }
+ }
+
+ return $item;
+ }
+
+ /**
+ * @param $reservedOrderId
+ * @return string
+ * @throws NoSuchEntityException
+ */
+ private function getMaskedQuoteId(string $reservedOrderId): string
+ {
+ $quote = $this->quoteFactory->create();
+ $this->quoteResource->load($quote, $reservedOrderId, 'reserved_order_id');
+ $quoteIdMask = $this->quoteIdMaskFactory->create();
+ $quoteIdMask->setQuoteId($quote->getId())
+ ->save();
+
+ return $this->getMaskedQuoteIdByReservedOrderId->execute($reservedOrderId);
+ }
+}
From e5708b0fa06f12b4a4ff0080d286dd1651e7b7cb Mon Sep 17 00:00:00 2001
From: Volodymyr Vygovskyi
Date: Wed, 21 Aug 2019 17:10:18 +0300
Subject: [PATCH 084/937] #813: removed redundant dependency
---
.../UpdateConfigurableCartItemsTest.php | 7 -------
1 file changed, 7 deletions(-)
diff --git a/dev/tests/api-functional/testsuite/Magento/GraphQl/ConfigurableProduct/UpdateConfigurableCartItemsTest.php b/dev/tests/api-functional/testsuite/Magento/GraphQl/ConfigurableProduct/UpdateConfigurableCartItemsTest.php
index 26ec331dcbce1..b13a75fa8c4e7 100644
--- a/dev/tests/api-functional/testsuite/Magento/GraphQl/ConfigurableProduct/UpdateConfigurableCartItemsTest.php
+++ b/dev/tests/api-functional/testsuite/Magento/GraphQl/ConfigurableProduct/UpdateConfigurableCartItemsTest.php
@@ -8,7 +8,6 @@
namespace Magento\GraphQl\ConfigurableProduct;
-use Magento\Catalog\Api\ProductRepositoryInterface;
use Magento\ConfigurableProduct\Model\Product\Type\Configurable;
use Magento\Framework\Exception\NoSuchEntityException as NoSuchEntityException;
use Magento\GraphQl\Quote\GetMaskedQuoteIdByReservedOrderId;
@@ -34,11 +33,6 @@ class UpdateConfigurableCartItemsTest extends GraphQlAbstract
*/
private $getMaskedQuoteIdByReservedOrderId;
- /**
- * @var ProductRepositoryInterface
- */
- private $productRepository;
-
/**
* @var QuoteFactory
*/
@@ -77,7 +71,6 @@ protected function setUp()
$this->getMaskedQuoteIdByReservedOrderId = $objectManager->get(GetMaskedQuoteIdByReservedOrderId::class);
$this->quoteFactory = $objectManager->get(QuoteFactory::class);
$this->quoteResource = $objectManager->get(QuoteResource::class);
- $this->productRepository = $objectManager->get(ProductRepositoryInterface::class);
$this->quoteIdMaskFactory = Bootstrap::getObjectManager()->get(QuoteIdMaskFactory::class);
}
From 5d16cb1a5897adf439209c3c9cde1254cf3be20b Mon Sep 17 00:00:00 2001
From: Lusine Papyan
Date: Thu, 22 Aug 2019 10:02:20 +0400
Subject: [PATCH 085/937] MAGETWO-98748: Incorrect behavior in the category
menu on the Storefront
- Updated automated test script
---
.../StorefrontCategoryHighlightedAndProductDisplayedTest.xml | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/app/code/Magento/Catalog/Test/Mftf/Test/StorefrontCategoryHighlightedAndProductDisplayedTest.xml b/app/code/Magento/Catalog/Test/Mftf/Test/StorefrontCategoryHighlightedAndProductDisplayedTest.xml
index 7d09cb419f312..c036712398bf9 100644
--- a/app/code/Magento/Catalog/Test/Mftf/Test/StorefrontCategoryHighlightedAndProductDisplayedTest.xml
+++ b/app/code/Magento/Catalog/Test/Mftf/Test/StorefrontCategoryHighlightedAndProductDisplayedTest.xml
@@ -8,7 +8,7 @@
-
+
From 8628a3a1acf0f34ada315b2e80b11f0c6d17ad62 Mon Sep 17 00:00:00 2001
From: Pavel Bystritsky
Date: Thu, 22 Aug 2019 14:46:22 +0300
Subject: [PATCH 086/937] magento/magento2#24153: Static tests fix.
---
app/code/Magento/Config/Model/Config/Backend/File/Pdf.php | 6 ++++--
app/code/Magento/Config/Model/Config/Backend/Image/Pdf.php | 4 +++-
2 files changed, 7 insertions(+), 3 deletions(-)
diff --git a/app/code/Magento/Config/Model/Config/Backend/File/Pdf.php b/app/code/Magento/Config/Model/Config/Backend/File/Pdf.php
index f4acd6ed21dbb..9e3a5ec507a4b 100644
--- a/app/code/Magento/Config/Model/Config/Backend/File/Pdf.php
+++ b/app/code/Magento/Config/Model/Config/Backend/File/Pdf.php
@@ -4,15 +4,17 @@
* See COPYING.txt for license details.
*/
-namespace Magento\Config\Model\Config\Backend\Image;
+namespace Magento\Config\Model\Config\Backend\File;
/**
+ * System config PDF field backend model.
+ *
* @api
*/
class Pdf extends \Magento\Config\Model\Config\Backend\File
{
/**
- * @return string[]
+ * @inheritdoc
*/
protected function _getAllowedExtensions()
{
diff --git a/app/code/Magento/Config/Model/Config/Backend/Image/Pdf.php b/app/code/Magento/Config/Model/Config/Backend/Image/Pdf.php
index 6e1ff24a65ce3..bde392547a7f9 100644
--- a/app/code/Magento/Config/Model/Config/Backend/Image/Pdf.php
+++ b/app/code/Magento/Config/Model/Config/Backend/Image/Pdf.php
@@ -7,6 +7,8 @@
namespace Magento\Config\Model\Config\Backend\Image;
/**
+ * System config PDF field backend model.
+ *
* @api
* @deprecated The wrong file type extensions are returned.
* @see \Magento\Config\Model\Config\Backend\File\Pdf
@@ -14,7 +16,7 @@
class Pdf extends \Magento\Config\Model\Config\Backend\Image
{
/**
- * @return string[]
+ * @inheritdoc
*/
protected function _getAllowedExtensions()
{
From 81c566a0f0d396e0382fea0877526e7702defb02 Mon Sep 17 00:00:00 2001
From: Lusine Papyan
Date: Thu, 22 Aug 2019 17:53:18 +0400
Subject: [PATCH 087/937] MC-18823: Increase test coverage for Framework and
Performance functional areas
- Automation test for MC-11701
---
...gRefreshCaptchaImageProductionModeTest.xml | 16 ++++---------
.../Test/Mftf/Data/DeveloperJsConfigs.xml | 22 ------------------
.../Metadata/developer_js_config-meta.xml | 23 -------------------
3 files changed, 5 insertions(+), 56 deletions(-)
delete mode 100644 app/code/Magento/Developer/Test/Mftf/Data/DeveloperJsConfigs.xml
delete mode 100644 app/code/Magento/Developer/Test/Mftf/Metadata/developer_js_config-meta.xml
diff --git a/app/code/Magento/Captcha/Test/Mftf/Test/AdminCheckingRefreshCaptchaImageProductionModeTest.xml b/app/code/Magento/Captcha/Test/Mftf/Test/AdminCheckingRefreshCaptchaImageProductionModeTest.xml
index 08bc3dbd02413..e2c4e929741b9 100644
--- a/app/code/Magento/Captcha/Test/Mftf/Test/AdminCheckingRefreshCaptchaImageProductionModeTest.xml
+++ b/app/code/Magento/Captcha/Test/Mftf/Test/AdminCheckingRefreshCaptchaImageProductionModeTest.xml
@@ -20,9 +20,6 @@
-
-
-
@@ -32,13 +29,13 @@
-
+
-
-
-
-
+
+
+
+
@@ -49,9 +46,6 @@
-
-
-
diff --git a/app/code/Magento/Developer/Test/Mftf/Data/DeveloperJsConfigs.xml b/app/code/Magento/Developer/Test/Mftf/Data/DeveloperJsConfigs.xml
deleted file mode 100644
index e490ef62bbed6..0000000000000
--- a/app/code/Magento/Developer/Test/Mftf/Data/DeveloperJsConfigs.xml
+++ /dev/null
@@ -1,22 +0,0 @@
-
-
-
-
- DefaultJSBundling
-
-
- 1
-
-
- DefaultJSBundling
-
-
- 1
-
-
diff --git a/app/code/Magento/Developer/Test/Mftf/Metadata/developer_js_config-meta.xml b/app/code/Magento/Developer/Test/Mftf/Metadata/developer_js_config-meta.xml
deleted file mode 100644
index b56c88a22dd13..0000000000000
--- a/app/code/Magento/Developer/Test/Mftf/Metadata/developer_js_config-meta.xml
+++ /dev/null
@@ -1,23 +0,0 @@
-
-
-
-
-
-
-
-
- string
-
-
- string
-
-
-
-
-
-
From 6e66e2a2f9aac92be2f1e80ff5a6ed5ae7277120 Mon Sep 17 00:00:00 2001
From: Soumya Unnikrishnan
Date: Fri, 23 Aug 2019 15:26:19 -0500
Subject: [PATCH 088/937] MQE-1686: Paypal integration test leveraging Adobe
Vault - PayPalSmartButtonInCheckoutPage fixed as per review comments
---
...tStorefrontCheckoutSuccessActionGroup.xml} | 2 +-
...ntPayOrderOnPayPalCheckoutActionGroup.xml} | 2 +-
.../Test/Mftf/Data/PaypalConfigData.xml | 52 +++++++++++++++++++
.../Paypal/Test/Mftf/Data/PaypalData.xml | 17 +++---
.../Magento/Paypal/Test/Mftf/Suite/suite.xml | 6 +--
...faultValueOfPayPalCustomizeButtonTest.xml} | 8 +--
...ontCheckCreditButtonConfigurationTest.xml} | 8 +--
...ntPaypalSmartButtonInCheckoutPageTest.xml} | 30 +++++------
8 files changed, 90 insertions(+), 35 deletions(-)
rename app/code/Magento/Checkout/Test/Mftf/ActionGroup/{VerifyCheckoutSuccessActionGroup.xml => AssertStorefrontCheckoutSuccessActionGroup.xml} (92%)
rename app/code/Magento/Paypal/Test/Mftf/ActionGroup/{PayOrderOnPayPalCheckoutActionGroup.xml => StorefrontPayOrderOnPayPalCheckoutActionGroup.xml} (93%)
create mode 100644 app/code/Magento/Paypal/Test/Mftf/Data/PaypalConfigData.xml
rename app/code/Magento/Paypal/Test/Mftf/Test/{CheckDefaultValueOfPayPalCustomizeButtonTest.xml => AdminCheckDefaultValueOfPayPalCustomizeButtonTest.xml} (89%)
rename app/code/Magento/Paypal/Test/Mftf/Test/{CheckCreditButtonConfiguration.xml => StorefrontCheckCreditButtonConfigurationTest.xml} (97%)
rename app/code/Magento/Paypal/Test/Mftf/Test/{PayPalSmartButtonInCheckoutPage.xml => StorefrontPaypalSmartButtonInCheckoutPageTest.xml} (57%)
diff --git a/app/code/Magento/Checkout/Test/Mftf/ActionGroup/VerifyCheckoutSuccessActionGroup.xml b/app/code/Magento/Checkout/Test/Mftf/ActionGroup/AssertStorefrontCheckoutSuccessActionGroup.xml
similarity index 92%
rename from app/code/Magento/Checkout/Test/Mftf/ActionGroup/VerifyCheckoutSuccessActionGroup.xml
rename to app/code/Magento/Checkout/Test/Mftf/ActionGroup/AssertStorefrontCheckoutSuccessActionGroup.xml
index 5048bcf37b320..9ff7e5a96fae7 100644
--- a/app/code/Magento/Checkout/Test/Mftf/ActionGroup/VerifyCheckoutSuccessActionGroup.xml
+++ b/app/code/Magento/Checkout/Test/Mftf/ActionGroup/AssertStorefrontCheckoutSuccessActionGroup.xml
@@ -8,7 +8,7 @@
-
+
Verifies if the order is placed successfully on the 'one page checkout' page.
diff --git a/app/code/Magento/Paypal/Test/Mftf/ActionGroup/PayOrderOnPayPalCheckoutActionGroup.xml b/app/code/Magento/Paypal/Test/Mftf/ActionGroup/StorefrontPayOrderOnPayPalCheckoutActionGroup.xml
similarity index 93%
rename from app/code/Magento/Paypal/Test/Mftf/ActionGroup/PayOrderOnPayPalCheckoutActionGroup.xml
rename to app/code/Magento/Paypal/Test/Mftf/ActionGroup/StorefrontPayOrderOnPayPalCheckoutActionGroup.xml
index 13409b16b56b1..392014d876e46 100644
--- a/app/code/Magento/Paypal/Test/Mftf/ActionGroup/PayOrderOnPayPalCheckoutActionGroup.xml
+++ b/app/code/Magento/Paypal/Test/Mftf/ActionGroup/StorefrontPayOrderOnPayPalCheckoutActionGroup.xml
@@ -8,7 +8,7 @@
-
+
Verifies product name on Paypal cart and clicks 'Pay Now' on PayPal payment checkout page.
diff --git a/app/code/Magento/Paypal/Test/Mftf/Data/PaypalConfigData.xml b/app/code/Magento/Paypal/Test/Mftf/Data/PaypalConfigData.xml
new file mode 100644
index 0000000000000..0744207494108
--- /dev/null
+++ b/app/code/Magento/Paypal/Test/Mftf/Data/PaypalConfigData.xml
@@ -0,0 +1,52 @@
+
+
+
+
+
+ payment/paypal_express/active
+ 1
+ Yes
+ 1
+
+
+ payment/paypal_express/active
+ 1
+ No
+ 0
+
+
+ payment/paypal_express/merchant_id
+ 1
+ ''
+
+
+ payment/paypal_express/skip_order_review_step
+ 1
+ Yes
+ 1
+
+
+ payment/paypal_express/skip_order_review_step
+ 1
+ No
+ 0
+
+
+ payment/paypal_express/in_context
+ 1
+ Yes
+ 1
+
+
+ payment/paypal_express/active
+ 1
+ No
+ 0
+
+
diff --git a/app/code/Magento/Paypal/Test/Mftf/Data/PaypalData.xml b/app/code/Magento/Paypal/Test/Mftf/Data/PaypalData.xml
index b8994f0e4bc04..ba56243fdb391 100644
--- a/app/code/Magento/Paypal/Test/Mftf/Data/PaypalData.xml
+++ b/app/code/Magento/Paypal/Test/Mftf/Data/PaypalData.xml
@@ -109,24 +109,27 @@
UseProxy
- {{_CREDS.magento/paypal_express_checkout_us_business_account}}
+ {{_CREDS.magento/paypal_express_checkout_us_business_account}}
- {{_CREDS.magento/paypal_express_checkout_us_api_username}}
+ {{_CREDS.magento/paypal_express_checkout_us_api_username}}
- {{_CREDS.magento/paypal_express_checkout_us_api_password}}
+ {{_CREDS.magento/paypal_express_checkout_us_api_password}}
- {{_CREDS.magento/paypal_express_checkout_us_api_signature}}
+ {{_CREDS.magento/paypal_express_checkout_us_api_signature}}
- 0
+ 0
- 1
+ 1
- 0
+ 0
+
+
+ Alex
diff --git a/app/code/Magento/Paypal/Test/Mftf/Suite/suite.xml b/app/code/Magento/Paypal/Test/Mftf/Suite/suite.xml
index 621f2e6a67688..d1b7937180a09 100644
--- a/app/code/Magento/Paypal/Test/Mftf/Suite/suite.xml
+++ b/app/code/Magento/Paypal/Test/Mftf/Suite/suite.xml
@@ -8,9 +8,9 @@
-
-
-
+
+
+
\ No newline at end of file
diff --git a/app/code/Magento/Paypal/Test/Mftf/Test/CheckDefaultValueOfPayPalCustomizeButtonTest.xml b/app/code/Magento/Paypal/Test/Mftf/Test/AdminCheckDefaultValueOfPayPalCustomizeButtonTest.xml
similarity index 89%
rename from app/code/Magento/Paypal/Test/Mftf/Test/CheckDefaultValueOfPayPalCustomizeButtonTest.xml
rename to app/code/Magento/Paypal/Test/Mftf/Test/AdminCheckDefaultValueOfPayPalCustomizeButtonTest.xml
index 0a90295c5528a..4b28f00a132a8 100644
--- a/app/code/Magento/Paypal/Test/Mftf/Test/CheckDefaultValueOfPayPalCustomizeButtonTest.xml
+++ b/app/code/Magento/Paypal/Test/Mftf/Test/AdminCheckDefaultValueOfPayPalCustomizeButtonTest.xml
@@ -8,12 +8,12 @@
-
+
-
+
-
-
+
+
diff --git a/app/code/Magento/Paypal/Test/Mftf/Test/CheckCreditButtonConfiguration.xml b/app/code/Magento/Paypal/Test/Mftf/Test/StorefrontCheckCreditButtonConfigurationTest.xml
similarity index 97%
rename from app/code/Magento/Paypal/Test/Mftf/Test/CheckCreditButtonConfiguration.xml
rename to app/code/Magento/Paypal/Test/Mftf/Test/StorefrontCheckCreditButtonConfigurationTest.xml
index a0f13e8ae6617..96213831cdd01 100644
--- a/app/code/Magento/Paypal/Test/Mftf/Test/CheckCreditButtonConfiguration.xml
+++ b/app/code/Magento/Paypal/Test/Mftf/Test/StorefrontCheckCreditButtonConfigurationTest.xml
@@ -8,9 +8,9 @@
-
+
-
+
@@ -48,8 +48,8 @@
-
-
+
+
diff --git a/app/code/Magento/Paypal/Test/Mftf/Test/PayPalSmartButtonInCheckoutPage.xml b/app/code/Magento/Paypal/Test/Mftf/Test/StorefrontPaypalSmartButtonInCheckoutPageTest.xml
similarity index 57%
rename from app/code/Magento/Paypal/Test/Mftf/Test/PayPalSmartButtonInCheckoutPage.xml
rename to app/code/Magento/Paypal/Test/Mftf/Test/StorefrontPaypalSmartButtonInCheckoutPageTest.xml
index 5fd81d4089005..4f28c52679a89 100644
--- a/app/code/Magento/Paypal/Test/Mftf/Test/PayPalSmartButtonInCheckoutPage.xml
+++ b/app/code/Magento/Paypal/Test/Mftf/Test/StorefrontPaypalSmartButtonInCheckoutPageTest.xml
@@ -8,12 +8,12 @@
-
+
-
+
-
-
+
+
@@ -32,10 +32,10 @@
-
-
-
-
+
+
+
+
@@ -43,10 +43,10 @@
-
-
-
-
+
+
+
+
@@ -68,15 +68,15 @@
-
+
-
+
-
+
From 6b6013db8c53b47116cd64eeaaf28d0223fbf4e8 Mon Sep 17 00:00:00 2001
From: Soumya Unnikrishnan
Date: Fri, 23 Aug 2019 15:42:51 -0500
Subject: [PATCH 089/937] MQE-1686: Paypal integration test leveraging Adobe
Vault - PayPalSmartButtonInCheckoutPage fixed as per review comments
---
.../Test/Mftf/Section/PayPalExpressCheckoutConfigSection.xml | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/app/code/Magento/Paypal/Test/Mftf/Section/PayPalExpressCheckoutConfigSection.xml b/app/code/Magento/Paypal/Test/Mftf/Section/PayPalExpressCheckoutConfigSection.xml
index 0be7a7873825c..382033f249ce0 100644
--- a/app/code/Magento/Paypal/Test/Mftf/Section/PayPalExpressCheckoutConfigSection.xml
+++ b/app/code/Magento/Paypal/Test/Mftf/Section/PayPalExpressCheckoutConfigSection.xml
@@ -54,7 +54,7 @@
-
+
From dbc514c634cf4d447291e2cf7cf2f83d112e9480 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Torben=20Ho=CC=88hn?=
Date: Fri, 23 Aug 2019 23:08:24 +0200
Subject: [PATCH 090/937] add config for disabling swatch tooltips
---
.../Block/Product/Renderer/Configurable.php | 82 +++++++++++++------
.../Magento/Swatches/etc/adminhtml/system.xml | 4 +
app/code/Magento/Swatches/etc/config.xml | 1 +
.../templates/product/listing/renderer.phtml | 5 +-
.../templates/product/view/renderer.phtml | 3 +-
.../view/frontend/web/js/swatch-renderer.js | 13 +--
6 files changed, 74 insertions(+), 34 deletions(-)
diff --git a/app/code/Magento/Swatches/Block/Product/Renderer/Configurable.php b/app/code/Magento/Swatches/Block/Product/Renderer/Configurable.php
index 0848f566f67bb..35bf199681720 100644
--- a/app/code/Magento/Swatches/Block/Product/Renderer/Configurable.php
+++ b/app/code/Magento/Swatches/Block/Product/Renderer/Configurable.php
@@ -3,6 +3,7 @@
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
+declare(strict_types = 1);
namespace Magento\Swatches\Block\Product\Renderer;
use Magento\Catalog\Block\Product\Context;
@@ -57,6 +58,16 @@ class Configurable extends \Magento\ConfigurableProduct\Block\Product\View\Type\
*/
const SWATCH_THUMBNAIL_NAME = 'swatchThumb';
+ /**
+ * Config path which contains number of swatches per product
+ */
+ const XML_PATH_SWATCHES_PER_PRODUCT = 'catalog/frontend/swatches_per_product';
+
+ /**
+ * Config path if swatch tooltips are enabled
+ */
+ const XML_PATH_SHOW_SWATCH_TOOLTIP = 'catalog/frontend/show_swatch_tooltip';
+
/**
* @var Product
*/
@@ -93,19 +104,19 @@ class Configurable extends \Magento\ConfigurableProduct\Block\Product\View\Type\
/**
* @SuppressWarnings(PHPMD.ExcessiveParameterList)
- * @param Context $context
- * @param ArrayUtils $arrayUtils
- * @param EncoderInterface $jsonEncoder
- * @param Data $helper
- * @param CatalogProduct $catalogProduct
- * @param CurrentCustomer $currentCustomer
- * @param PriceCurrencyInterface $priceCurrency
- * @param ConfigurableAttributeData $configurableAttributeData
- * @param SwatchData $swatchHelper
- * @param Media $swatchMediaHelper
- * @param array $data
+ * @param Context $context
+ * @param ArrayUtils $arrayUtils
+ * @param EncoderInterface $jsonEncoder
+ * @param Data $helper
+ * @param CatalogProduct $catalogProduct
+ * @param CurrentCustomer $currentCustomer
+ * @param PriceCurrencyInterface $priceCurrency
+ * @param ConfigurableAttributeData $configurableAttributeData
+ * @param SwatchData $swatchHelper
+ * @param Media $swatchMediaHelper
+ * @param array $data
* @param SwatchAttributesProvider|null $swatchAttributesProvider
- * @param UrlBuilder|null $imageUrlBuilder
+ * @param UrlBuilder|null $imageUrlBuilder
*/
public function __construct(
Context $context,
@@ -172,7 +183,6 @@ public function getJsonSwatchConfig()
$attributesData = $this->getSwatchAttributesData();
$allOptionIds = $this->getConfigurableOptionsIds($attributesData);
$swatchesData = $this->swatchHelper->getSwatchesByOptionsId($allOptionIds);
-
$config = [];
foreach ($attributesData as $attributeId => $attributeDataArray) {
if (isset($attributeDataArray['options'])) {
@@ -200,7 +210,20 @@ public function getJsonSwatchConfig()
public function getNumberSwatchesPerProduct()
{
return $this->_scopeConfig->getValue(
- 'catalog/frontend/swatches_per_product',
+ self::XML_PATH_SWATCHES_PER_PRODUCT,
+ ScopeInterface::SCOPE_STORE
+ );
+ }
+
+ /**
+ * Get config if swatch tooltips should be rendered.
+ *
+ * @return string
+ */
+ public function getShowSwatchTooltip()
+ {
+ return $this->_scopeConfig->getValue(
+ self::XML_PATH_SHOW_SWATCH_TOOLTIP,
ScopeInterface::SCOPE_STORE
);
}
@@ -209,11 +232,13 @@ public function getNumberSwatchesPerProduct()
* Set product to block
*
* @param Product $product
+ *
* @return $this
*/
public function setProduct(Product $product)
{
$this->product = $product;
+
return $this;
}
@@ -244,10 +269,10 @@ protected function getSwatchAttributesData()
/**
* Init isProductHasSwatchAttribute.
*
+ * @return void
* @deprecated 100.1.5 Method isProductHasSwatchAttribute() is used instead of this.
*
* @codeCoverageIgnore
- * @return void
*/
protected function initIsProductHasSwatchAttribute()
{
@@ -263,6 +288,7 @@ protected function initIsProductHasSwatchAttribute()
protected function isProductHasSwatchAttribute()
{
$swatchAttributes = $this->swatchAttributesProvider->provide($this->getProduct());
+
return count($swatchAttributes) > 0;
}
@@ -272,6 +298,7 @@ protected function isProductHasSwatchAttribute()
* @param array $options
* @param array $swatchesCollectionArray
* @param array $attributeDataArray
+ *
* @return array
*/
protected function addSwatchDataForAttribute(
@@ -294,9 +321,10 @@ protected function addSwatchDataForAttribute(
/**
* Add media from variation
*
- * @param array $swatch
+ * @param array $swatch
* @param integer $optionId
- * @param array $attributeDataArray
+ * @param array $attributeDataArray
+ *
* @return array
*/
protected function addAdditionalMediaData(array $swatch, $optionId, array $attributeDataArray)
@@ -305,11 +333,12 @@ protected function addAdditionalMediaData(array $swatch, $optionId, array $attri
&& $attributeDataArray['use_product_image_for_swatch']
) {
$variationMedia = $this->getVariationMedia($attributeDataArray['attribute_code'], $optionId);
- if (! empty($variationMedia)) {
+ if (!empty($variationMedia)) {
$swatch['type'] = Swatch::SWATCH_TYPE_VISUAL_IMAGE;
$swatch = array_merge($swatch, $variationMedia);
}
}
+
return $swatch;
}
@@ -317,12 +346,12 @@ protected function addAdditionalMediaData(array $swatch, $optionId, array $attri
* Retrieve Swatch data for config
*
* @param array $swatchDataArray
+ *
* @return array
*/
protected function extractNecessarySwatchData(array $swatchDataArray)
{
$result['type'] = $swatchDataArray['type'];
-
if ($result['type'] == Swatch::SWATCH_TYPE_VISUAL_IMAGE && !empty($swatchDataArray['value'])) {
$result['value'] = $this->swatchMediaHelper->getSwatchAttributeImage(
Swatch::SWATCH_IMAGE_NAME,
@@ -342,8 +371,9 @@ protected function extractNecessarySwatchData(array $swatchDataArray)
/**
* Generate Product Media array
*
- * @param string $attributeCode
+ * @param string $attributeCode
* @param integer $optionId
+ *
* @return array
*/
protected function getVariationMedia($attributeCode, $optionId)
@@ -352,14 +382,12 @@ protected function getVariationMedia($attributeCode, $optionId)
$this->getProduct(),
[$attributeCode => $optionId]
);
-
if (!$variationProduct) {
$variationProduct = $this->swatchHelper->loadFirstVariationWithImage(
$this->getProduct(),
[$attributeCode => $optionId]
);
}
-
$variationMediaArray = [];
if ($variationProduct) {
$variationMediaArray = [
@@ -375,7 +403,8 @@ protected function getVariationMedia($attributeCode, $optionId)
* Get swatch product image.
*
* @param Product $childProduct
- * @param string $imageType
+ * @param string $imageType
+ *
* @return string
*/
protected function getSwatchProductImage(Product $childProduct, $imageType)
@@ -387,7 +416,6 @@ protected function getSwatchProductImage(Product $childProduct, $imageType)
$swatchImageId = $imageType == Swatch::SWATCH_IMAGE_NAME ? 'swatch_image_base' : 'swatch_thumb_base';
$imageAttributes = ['type' => 'image'];
}
-
if (!empty($swatchImageId) && !empty($imageAttributes['type'])) {
return $this->imageUrlBuilder->getUrl($childProduct->getData($imageAttributes['type']), $swatchImageId);
}
@@ -397,7 +425,8 @@ protected function getSwatchProductImage(Product $childProduct, $imageType)
* Check if product have image.
*
* @param Product $product
- * @param string $imageType
+ * @param string $imageType
+ *
* @return bool
*/
protected function isProductHasImage(Product $product, $imageType)
@@ -409,6 +438,7 @@ protected function isProductHasImage(Product $product, $imageType)
* Get configurable options ids.
*
* @param array $attributeData
+ *
* @return array
* @since 100.0.3
*/
@@ -425,6 +455,7 @@ protected function getConfigurableOptionsIds(array $attributeData)
}
}
}
+
return array_keys($ids);
}
@@ -509,7 +540,6 @@ public function getJsonSwatchSizeConfig()
{
$imageConfig = $this->swatchMediaHelper->getImageConfig();
$sizeConfig = [];
-
$sizeConfig[self::SWATCH_IMAGE_NAME]['width'] = $imageConfig[Swatch::SWATCH_IMAGE_NAME]['width'];
$sizeConfig[self::SWATCH_IMAGE_NAME]['height'] = $imageConfig[Swatch::SWATCH_IMAGE_NAME]['height'];
$sizeConfig[self::SWATCH_THUMBNAIL_NAME]['height'] = $imageConfig[Swatch::SWATCH_THUMBNAIL_NAME]['height'];
diff --git a/app/code/Magento/Swatches/etc/adminhtml/system.xml b/app/code/Magento/Swatches/etc/adminhtml/system.xml
index 2cf40ae83cc3b..6fbf110fadcd3 100644
--- a/app/code/Magento/Swatches/etc/adminhtml/system.xml
+++ b/app/code/Magento/Swatches/etc/adminhtml/system.xml
@@ -17,6 +17,10 @@
Show Swatches in Product List
Magento\Config\Model\Config\Source\Yesno
+
+ Show Swatch Tooltip
+ Magento\Config\Model\Config\Source\Yesno
+
diff --git a/app/code/Magento/Swatches/etc/config.xml b/app/code/Magento/Swatches/etc/config.xml
index 65b36558c2796..4140acc4974d6 100644
--- a/app/code/Magento/Swatches/etc/config.xml
+++ b/app/code/Magento/Swatches/etc/config.xml
@@ -11,6 +11,7 @@
16
1
+ 1
diff --git a/app/code/Magento/Swatches/view/frontend/templates/product/listing/renderer.phtml b/app/code/Magento/Swatches/view/frontend/templates/product/listing/renderer.phtml
index 777277a15d8cd..3c2f15dea0ab4 100644
--- a/app/code/Magento/Swatches/view/frontend/templates/product/listing/renderer.phtml
+++ b/app/code/Magento/Swatches/view/frontend/templates/product/listing/renderer.phtml
@@ -22,7 +22,8 @@ $productId = $block->getProduct()->getId();
"jsonConfig": = /* @noEscape */ $block->getJsonConfig() ?>,
"jsonSwatchConfig": = /* @noEscape */ $block->getJsonSwatchConfig() ?>,
"mediaCallback": "= $block->escapeJs($block->escapeUrl($block->getMediaCallback())) ?>",
- "jsonSwatchImageSizeConfig": = /* @noEscape */ $block->getJsonSwatchSizeConfig() ?>
+ "jsonSwatchImageSizeConfig": = /* @noEscape */ $block->getJsonSwatchSizeConfig() ?>,
+ "showTooltip": = $block->escapeJs($block->getShowSwatchTooltip()) ?>
}
}
}
@@ -39,4 +40,4 @@ $productId = $block->getProduct()->getId();
}
}
}
-
\ No newline at end of file
+
diff --git a/app/code/Magento/Swatches/view/frontend/templates/product/view/renderer.phtml b/app/code/Magento/Swatches/view/frontend/templates/product/view/renderer.phtml
index c85a6908413b5..46666e880bb03 100644
--- a/app/code/Magento/Swatches/view/frontend/templates/product/view/renderer.phtml
+++ b/app/code/Magento/Swatches/view/frontend/templates/product/view/renderer.phtml
@@ -15,7 +15,8 @@
"jsonSwatchConfig": = /* @noEscape */ $swatchOptions = $block->getJsonSwatchConfig() ?>,
"mediaCallback": "= $block->escapeJs($block->escapeUrl($block->getMediaCallback())) ?>",
"gallerySwitchStrategy": "= $block->escapeJs($block->getVar('gallery_switch_strategy', 'Magento_ConfigurableProduct')) ?: 'replace'; ?>",
- "jsonSwatchImageSizeConfig": = /* @noEscape */ $block->getJsonSwatchSizeConfig() ?>
+ "jsonSwatchImageSizeConfig": = /* @noEscape */ $block->getJsonSwatchSizeConfig() ?>,
+ "showTooltip": = $block->escapeJs($block->getShowSwatchTooltip()) ?>
}
},
"*" : {
diff --git a/app/code/Magento/Swatches/view/frontend/web/js/swatch-renderer.js b/app/code/Magento/Swatches/view/frontend/web/js/swatch-renderer.js
index d6302cff83bff..aa7d0a08ce697 100644
--- a/app/code/Magento/Swatches/view/frontend/web/js/swatch-renderer.js
+++ b/app/code/Magento/Swatches/view/frontend/web/js/swatch-renderer.js
@@ -385,7 +385,8 @@ define([
var $widget = this,
container = this.element,
classes = this.options.classes,
- chooseText = this.options.jsonConfig.chooseText;
+ chooseText = this.options.jsonConfig.chooseText,
+ showTooltip = this.options.showTooltip;
$widget.optionsMap = {};
@@ -452,10 +453,12 @@ define([
});
});
- // Connect Tooltip
- container
- .find('[option-type="1"], [option-type="2"], [option-type="0"], [option-type="3"]')
- .SwatchRendererTooltip();
+ if (showTooltip === 1) {
+ // Connect Tooltip
+ container
+ .find('[option-type="1"], [option-type="2"], [option-type="0"], [option-type="3"]')
+ .SwatchRendererTooltip();
+ }
// Hide all elements below more button
$('.' + classes.moreButton).nextAll().hide();
From 3e6104de227981da9631986aacb60a249fa063bc Mon Sep 17 00:00:00 2001
From: Raul E Watson
Date: Sun, 25 Aug 2019 07:04:18 +0100
Subject: [PATCH 091/937] Update Magento_Analytics ReadMe
---
app/code/Magento/Analytics/README.md | 42 +++++++++++++++++-----------
1 file changed, 26 insertions(+), 16 deletions(-)
diff --git a/app/code/Magento/Analytics/README.md b/app/code/Magento/Analytics/README.md
index aa424182e2ebd..cb78a27dae8e0 100644
--- a/app/code/Magento/Analytics/README.md
+++ b/app/code/Magento/Analytics/README.md
@@ -1,18 +1,28 @@
-# Magento_Analytics Module
+# Magento_Analytics module
The Magento_Analytics module integrates your Magento instance with the [Magento Business Intelligence (MBI)](https://magento.com/products/business-intelligence) to use [Advanced Reporting](https://devdocs.magento.com/guides/v2.3/advanced-reporting/modules.html) functionality.
The module implements the following functionality:
-* enabling subscription to the MBI and automatic re-subscription
-* changing the base URL with the same MBI account remained
-* declaring the configuration schemas for report data collection
-* collecting the Magento instance data as reports for the MBI
-* introducing API that provides the collected data
-* extending Magento configuration with the module parameters:
- * subscription status (enabled/disabled)
- * industry (a business area in which the instance website works)
- * time of data collection (time of the day when the module collects data)
+- Enabling subscription to the MBI and automatic re-subscription
+- Changing the base URL with the same MBI account remained
+- Declaring the configuration schemas for report data collection
+- Collecting the Magento instance data as reports for the MBI
+- Introducing API that provides the collected data
+- Extending Magento configuration with the module parameters:
+ - Subscription status (enabled/disabled)
+ - Industry (a business area in which the instance website works)
+ - Time of data collection (time of the day when the module collects data)
+
+## Installation details
+
+Before disabling or uninstalling this module, note that the following modules depends on this module:
+- Magento_CatalogAnalytics
+- Magento_CustomerAnalytics
+- Magento_QuoteAnalytics
+- Magento_ReviewAnalytics
+- Magento_SalesAnalytics
+- Magento_WishlistAnalytics
## Structure
@@ -29,12 +39,12 @@ The subscription to the MBI service is enabled during the installation process o
Configuration settings for the Analytics module can be modified in the Admin Panel on the Stores > Configuration page under the General > Advanced Reporting tab.
The following options can be adjusted:
-* Advanced Reporting Service (Enabled/Disabled)
- * Alters the status of the Advanced Reporting subscription
-* Time of day to send data (Hour/Minute/Second in the store's time zone)
- * Defines when the data collection process for the Advanced Reporting service occurs
-* Industry
- * Defines the industry of the store in order to create a personalized Advanced Reporting experience
+- Advanced Reporting Service (Enabled/Disabled)
+ - Alters the status of the Advanced Reporting subscription
+- Time of day to send data (Hour/Minute/Second in the store's time zone)
+ - Defines when the data collection process for the Advanced Reporting service occurs
+- Industry
+ - Defines the industry of the store in order to create a personalized Advanced Reporting experience
## Extensibility
From b089cc2088fc68a8424561b3585d5ff49d0d020b Mon Sep 17 00:00:00 2001
From: yuriichayka
Date: Mon, 26 Aug 2019 00:57:04 +0300
Subject: [PATCH 092/937] initial commit for the issue
---
.../ProductAlert/Controller/Add/StockTest.php | 103 ++++++++++++++++++
.../Controller/Unsubscribe/StockTest.php | 76 +++++++++++++
.../_files/customer_unsubscribe_stock.php | 30 +++++
3 files changed, 209 insertions(+)
create mode 100644 dev/tests/integration/testsuite/Magento/ProductAlert/Controller/Add/StockTest.php
create mode 100644 dev/tests/integration/testsuite/Magento/ProductAlert/Controller/Unsubscribe/StockTest.php
create mode 100644 dev/tests/integration/testsuite/Magento/ProductAlert/_files/customer_unsubscribe_stock.php
diff --git a/dev/tests/integration/testsuite/Magento/ProductAlert/Controller/Add/StockTest.php b/dev/tests/integration/testsuite/Magento/ProductAlert/Controller/Add/StockTest.php
new file mode 100644
index 0000000000000..2235876de9822
--- /dev/null
+++ b/dev/tests/integration/testsuite/Magento/ProductAlert/Controller/Add/StockTest.php
@@ -0,0 +1,103 @@
+objectManager = Bootstrap::getObjectManager();
+
+ $this->customerSession = $this->objectManager->get(Session::class);
+ $this->dataUrlHelper = $this->objectManager->get(Data::class);
+
+ $this->resource = $this->objectManager->get(ResourceConnection::class);
+ $this->connectionMock = $this->resource->getConnection();
+ }
+
+ /**
+ * @magentoAppArea frontend
+ * @magentoDataFixture Magento/Catalog/_files/product_simple_out_of_stock.php
+ * @magentoDataFixture Magento/Customer/_files/customer.php
+ */
+ public function testSubscribe()
+ {
+ $productId = 1;
+ $customerId = 1;
+
+ $this->customerSession->setCustomerId($customerId);
+
+ $encodedParameterValue = $this->getUrlEncodedParameter($productId);
+ $this->getRequest()->setMethod('GET');
+ $this->getRequest()->setQueryValue('product_id', $productId);
+ $this->getRequest()->setQueryValue(Action::PARAM_NAME_URL_ENCODED, $encodedParameterValue);
+ $this->dispatch('productalert/add/stock');
+
+ $select = $this->connectionMock->select()->from($this->resource->getTableName('product_alert_stock'))
+ ->where('`customer_id` LIKE ?', '1');
+ $result = $this->connectionMock->fetchAll($select);
+ $this->assertCount(1, $result);
+ }
+
+ /**
+ * @param int $productId
+ *
+ * @return string
+ */
+ private function getUrlEncodedParameter(int $productId):string
+ {
+ $baseUrl = $this->objectManager->get(StoreManagerInterface::class)->getStore()->getBaseUrl();
+ $encodedParameterValue = urlencode(
+ $this->dataUrlHelper->getEncodedUrl($baseUrl . 'productalert/add/stock/product_id/' . $productId)
+ );
+
+ return $encodedParameterValue;
+ }
+}
diff --git a/dev/tests/integration/testsuite/Magento/ProductAlert/Controller/Unsubscribe/StockTest.php b/dev/tests/integration/testsuite/Magento/ProductAlert/Controller/Unsubscribe/StockTest.php
new file mode 100644
index 0000000000000..b57f046b0925e
--- /dev/null
+++ b/dev/tests/integration/testsuite/Magento/ProductAlert/Controller/Unsubscribe/StockTest.php
@@ -0,0 +1,76 @@
+objectManager = Bootstrap::getObjectManager();
+ $this->customerSession = $this->objectManager->get(Session::class);
+ $this->resource = $this->objectManager->get(ResourceConnection::class);
+ $this->connectionMock = $this->resource->getConnection();
+ }
+
+ /**
+ * @magentoAppArea frontend
+ * @magentoDataFixture Magento/Catalog/_files/product_simple_out_of_stock.php
+ * @magentoDataFixture Magento/Customer/_files/customer.php
+ * @magentoDataFixture Magento/ProductAlert/_files/customer_unsubscribe_stock.php
+ */
+ public function testSubscribe()
+ {
+ $productId = 1;
+ $customerId = 1;
+
+ $this->customerSession->setCustomerId($customerId);
+ $select = $this->connectionMock->select()->from($this->resource->getTableName('product_alert_stock'))
+ ->where('`customer_id` LIKE ?', $customerId);
+
+ $this->getRequest()->setPostValue('product', $productId)->setMethod('POST');
+ $this->dispatch('productalert/unsubscribe/stock');
+
+ $result = $this->connectionMock->fetchAll($select);
+ $this->assertCount(0, $result);
+ }
+}
diff --git a/dev/tests/integration/testsuite/Magento/ProductAlert/_files/customer_unsubscribe_stock.php b/dev/tests/integration/testsuite/Magento/ProductAlert/_files/customer_unsubscribe_stock.php
new file mode 100644
index 0000000000000..e0f0f4f8d83df
--- /dev/null
+++ b/dev/tests/integration/testsuite/Magento/ProductAlert/_files/customer_unsubscribe_stock.php
@@ -0,0 +1,30 @@
+create(Stock::class);
+
+/** @var \Magento\Framework\Stdlib\DateTime\DateTime $dateTime */
+$dateTime = $objectManager->get(DateTimeFactory::class)->create();
+$date = $dateTime->gmtDate(null, ($dateTime->gmtTimestamp() - 3600));
+
+$resource->getConnection()->insert(
+ $resource->getMainTable(),
+ [
+ 'customer_id' => 1,
+ 'product_id' => 1,
+ 'website_id' => 1,
+ 'store_id' => 1,
+ 'add_date' => $date,
+ 'send_date' => null,
+ 'send_count' => 0,
+ 'status' => 0
+ ]
+);
From 36c00d2d7f0b1992ab84ed7df961959dca76de8c Mon Sep 17 00:00:00 2001
From: yuriichayka
Date: Mon, 26 Aug 2019 13:07:47 +0300
Subject: [PATCH 093/937] magento/magento2#23279: Integration test for
unsubscribing from 'Back in stock notification' Added integration tests for
ProductAlert\Controller\Unsubscribe\Stock and
ProductAlert\Controller\Add\Stock
---
.../ProductAlert/Controller/Add/StockTest.php | 18 ++++++++++++-----
.../Controller/Unsubscribe/StockTest.php | 20 +++++++++++++------
.../_files/customer_unsubscribe_stock.php | 7 +++++--
3 files changed, 32 insertions(+), 13 deletions(-)
diff --git a/dev/tests/integration/testsuite/Magento/ProductAlert/Controller/Add/StockTest.php b/dev/tests/integration/testsuite/Magento/ProductAlert/Controller/Add/StockTest.php
index 2235876de9822..2e4da9992642f 100644
--- a/dev/tests/integration/testsuite/Magento/ProductAlert/Controller/Add/StockTest.php
+++ b/dev/tests/integration/testsuite/Magento/ProductAlert/Controller/Add/StockTest.php
@@ -7,6 +7,7 @@
namespace Magento\ProductAlert\Controller\Add;
+use Magento\Catalog\Api\ProductRepositoryInterface;
use Magento\Framework\App\ResourceConnection;
use Magento\Framework\ObjectManagerInterface;
use Magento\Framework\App\Action\Action;
@@ -20,6 +21,7 @@
* Test for Magento\ProductAlert\Controller\Add\Stock class.
*
* @magentoAppIsolation enabled
+ * @magentoDbIsolation enabled
*/
class StockTest extends AbstractController
{
@@ -50,6 +52,11 @@ class StockTest extends AbstractController
*/
protected $connectionMock;
+ /**
+ * @var ProductRepositoryInterface
+ */
+ private $productRepository;
+
protected function setUp()
{
parent::setUp();
@@ -60,6 +67,7 @@ protected function setUp()
$this->resource = $this->objectManager->get(ResourceConnection::class);
$this->connectionMock = $this->resource->getConnection();
+ $this->productRepository = $this->objectManager->create(ProductRepositoryInterface::class);
}
/**
@@ -67,9 +75,9 @@ protected function setUp()
* @magentoDataFixture Magento/Catalog/_files/product_simple_out_of_stock.php
* @magentoDataFixture Magento/Customer/_files/customer.php
*/
- public function testSubscribe()
+ public function testSubscribeStockNotification()
{
- $productId = 1;
+ $productId = $this->productRepository->get('simple-out-of-stock')->getId();
$customerId = 1;
$this->customerSession->setCustomerId($customerId);
@@ -81,17 +89,17 @@ public function testSubscribe()
$this->dispatch('productalert/add/stock');
$select = $this->connectionMock->select()->from($this->resource->getTableName('product_alert_stock'))
- ->where('`customer_id` LIKE ?', '1');
+ ->where('`product_id` LIKE ?', $productId);
$result = $this->connectionMock->fetchAll($select);
$this->assertCount(1, $result);
}
/**
- * @param int $productId
+ * @param $productId
*
* @return string
*/
- private function getUrlEncodedParameter(int $productId):string
+ private function getUrlEncodedParameter($productId):string
{
$baseUrl = $this->objectManager->get(StoreManagerInterface::class)->getStore()->getBaseUrl();
$encodedParameterValue = urlencode(
diff --git a/dev/tests/integration/testsuite/Magento/ProductAlert/Controller/Unsubscribe/StockTest.php b/dev/tests/integration/testsuite/Magento/ProductAlert/Controller/Unsubscribe/StockTest.php
index b57f046b0925e..1d56edab9a8a5 100644
--- a/dev/tests/integration/testsuite/Magento/ProductAlert/Controller/Unsubscribe/StockTest.php
+++ b/dev/tests/integration/testsuite/Magento/ProductAlert/Controller/Unsubscribe/StockTest.php
@@ -7,9 +7,10 @@
namespace Magento\ProductAlert\Controller\Unsubscribe;
+use Magento\Catalog\Api\ProductRepositoryInterface;
use Magento\Framework\App\ResourceConnection;
+use Magento\Framework\DB\Adapter\AdapterInterface;
use Magento\Framework\ObjectManagerInterface;
-use Magento\Framework\Url\Helper\Data;
use Magento\Customer\Model\Session;
use Magento\TestFramework\Helper\Bootstrap;
use Magento\TestFramework\TestCase\AbstractController;
@@ -18,6 +19,7 @@
* Test for Magento\ProductAlert\Controller\Unsubscribe\Stock class.
*
* @magentoAppIsolation enabled
+ * @magentoDbIsolation enabled
*/
class StockTest extends AbstractController
{
@@ -39,10 +41,15 @@ class StockTest extends AbstractController
/**
* Connection adapter
*
- * @var \Magento\Framework\DB\Adapter\AdapterInterface
+ * @var AdapterInterface
*/
protected $connectionMock;
+ /**
+ * @var ProductRepositoryInterface
+ */
+ private $productRepository;
+
protected function setUp()
{
parent::setUp();
@@ -50,6 +57,7 @@ protected function setUp()
$this->customerSession = $this->objectManager->get(Session::class);
$this->resource = $this->objectManager->get(ResourceConnection::class);
$this->connectionMock = $this->resource->getConnection();
+ $this->productRepository = $this->objectManager->create(ProductRepositoryInterface::class);
}
/**
@@ -58,18 +66,18 @@ protected function setUp()
* @magentoDataFixture Magento/Customer/_files/customer.php
* @magentoDataFixture Magento/ProductAlert/_files/customer_unsubscribe_stock.php
*/
- public function testSubscribe()
+ public function testUnsubscribeStockNotification()
{
- $productId = 1;
$customerId = 1;
+ $productId = $this->productRepository->get('simple-out-of-stock')->getId();
$this->customerSession->setCustomerId($customerId);
- $select = $this->connectionMock->select()->from($this->resource->getTableName('product_alert_stock'))
- ->where('`customer_id` LIKE ?', $customerId);
$this->getRequest()->setPostValue('product', $productId)->setMethod('POST');
$this->dispatch('productalert/unsubscribe/stock');
+ $select = $this->connectionMock->select()->from($this->resource->getTableName('product_alert_stock'))
+ ->where('`product_id` LIKE ?', $productId);
$result = $this->connectionMock->fetchAll($select);
$this->assertCount(0, $result);
}
diff --git a/dev/tests/integration/testsuite/Magento/ProductAlert/_files/customer_unsubscribe_stock.php b/dev/tests/integration/testsuite/Magento/ProductAlert/_files/customer_unsubscribe_stock.php
index e0f0f4f8d83df..3308b2b1829db 100644
--- a/dev/tests/integration/testsuite/Magento/ProductAlert/_files/customer_unsubscribe_stock.php
+++ b/dev/tests/integration/testsuite/Magento/ProductAlert/_files/customer_unsubscribe_stock.php
@@ -4,22 +4,25 @@
* See COPYING.txt for license details.
*/
+use Magento\Catalog\Api\ProductRepositoryInterface;
use Magento\Framework\Stdlib\DateTime\DateTimeFactory;
use Magento\ProductAlert\Model\ResourceModel\Stock;
use Magento\TestFramework\Helper\Bootstrap;
$objectManager = Bootstrap::getObjectManager();
-$resource = $objectManager->create(Stock::class);
+$resource = $objectManager->get(Stock::class);
/** @var \Magento\Framework\Stdlib\DateTime\DateTime $dateTime */
$dateTime = $objectManager->get(DateTimeFactory::class)->create();
$date = $dateTime->gmtDate(null, ($dateTime->gmtTimestamp() - 3600));
+$productRepository = $objectManager->create(ProductRepositoryInterface::class);
+$productId = $productRepository->get('simple-out-of-stock')->getId();
$resource->getConnection()->insert(
$resource->getMainTable(),
[
'customer_id' => 1,
- 'product_id' => 1,
+ 'product_id' => $productId,
'website_id' => 1,
'store_id' => 1,
'add_date' => $date,
From 8c33bbd093c9680f2e9d04616818047ec9893203 Mon Sep 17 00:00:00 2001
From: Yuliya Labudova
Date: Mon, 26 Aug 2019 14:08:52 +0300
Subject: [PATCH 094/937] MAGETWO-94565: Catalog product collection filters
produce errors and cause inconsistent behaviour
- Replace using category collection to using db.
---
.../Catalog/Model/ResourceModel/Category.php | 40 ++++++++++++++++++
.../ResourceModel/Product/Collection.php | 41 +++++++++++--------
2 files changed, 63 insertions(+), 18 deletions(-)
diff --git a/app/code/Magento/Catalog/Model/ResourceModel/Category.php b/app/code/Magento/Catalog/Model/ResourceModel/Category.php
index 536fda7e093d3..3794dbf46579f 100644
--- a/app/code/Magento/Catalog/Model/ResourceModel/Category.php
+++ b/app/code/Magento/Catalog/Model/ResourceModel/Category.php
@@ -9,11 +9,14 @@
*
* @author Magento Core Team
*/
+declare(strict_types=1);
+
namespace Magento\Catalog\Model\ResourceModel;
use Magento\Catalog\Model\Indexer\Category\Product\Processor;
use Magento\Framework\DataObject;
use Magento\Framework\EntityManager\EntityManager;
+use Magento\Catalog\Setup\CategorySetup;
/**
* Resource model for category entity
@@ -1132,4 +1135,41 @@ private function getAggregateCount()
}
return $this->aggregateCount;
}
+
+ /**
+ * Get category with children.
+ *
+ * @param int $categoryId
+ * @return array
+ */
+ public function getCategoryWithChildren(int $categoryId): array
+ {
+ $connection = $this->getConnection();
+
+ $select = $connection->select()
+ ->from(
+ ['eav_attribute' => $this->getTable('eav_attribute')],
+ ['attribute_id']
+ )->where('entity_type_id = ?', CategorySetup::CATEGORY_ENTITY_TYPE_ID)
+ ->where('attribute_code = ?', 'is_anchor')
+ ->limit(1);
+ $attributeId = $connection->fetchRow($select);
+
+ $select = $connection->select()
+ ->from(
+ ['cce' => $this->getTable('catalog_category_entity')],
+ ['entity_id', 'parent_id', 'path']
+ )->join(
+ ['cce_int' => $this->getTable('catalog_category_entity_int')],
+ 'cce.entity_id = cce_int.entity_id',
+ ['is_anchor' => 'cce_int.value']
+ )->where(
+ 'cce_int.attribute_id = ?',
+ $attributeId['attribute_id']
+ )->where(
+ "cce.path LIKE '%/{$categoryId}' OR cce.path LIKE '%/{$categoryId}/%'"
+ )->order('path');
+
+ return $connection->fetchAll($select);
+ }
}
diff --git a/app/code/Magento/Catalog/Model/ResourceModel/Product/Collection.php b/app/code/Magento/Catalog/Model/ResourceModel/Product/Collection.php
index dffa49d97838c..71b03620b342b 100644
--- a/app/code/Magento/Catalog/Model/ResourceModel/Product/Collection.php
+++ b/app/code/Magento/Catalog/Model/ResourceModel/Product/Collection.php
@@ -23,7 +23,7 @@
use Magento\Framework\Indexer\DimensionFactory;
use Magento\Store\Model\Indexer\WebsiteDimensionProvider;
use Magento\Store\Model\Store;
-use Magento\Catalog\Model\ResourceModel\Category\CollectionFactory;
+use Magento\Catalog\Model\ResourceModel\Category;
/**
* Product collection
@@ -305,9 +305,9 @@ class Collection extends \Magento\Catalog\Model\ResourceModel\Collection\Abstrac
private $urlFinder;
/**
- * @var CollectionFactory
+ * @var Category
*/
- private $categoryCollectionFactory;
+ private $categoryResourceModel;
/**
* Collection constructor
@@ -337,7 +337,7 @@ class Collection extends \Magento\Catalog\Model\ResourceModel\Collection\Abstrac
* @param TableMaintainer|null $tableMaintainer
* @param PriceTableResolver|null $priceTableResolver
* @param DimensionFactory|null $dimensionFactory
- * @param CollectionFactory|null $categoryCollectionFactory
+ * @param Category|null $categoryResourceModel
*
* @SuppressWarnings(PHPMD.ExcessiveParameterList)
*/
@@ -367,7 +367,7 @@ public function __construct(
TableMaintainer $tableMaintainer = null,
PriceTableResolver $priceTableResolver = null,
DimensionFactory $dimensionFactory = null,
- CollectionFactory $categoryCollectionFactory = null
+ Category $categoryResourceModel = null
) {
$this->moduleManager = $moduleManager;
$this->_catalogProductFlatState = $catalogProductFlatState;
@@ -401,8 +401,8 @@ public function __construct(
$this->priceTableResolver = $priceTableResolver ?: ObjectManager::getInstance()->get(PriceTableResolver::class);
$this->dimensionFactory = $dimensionFactory
?: ObjectManager::getInstance()->get(DimensionFactory::class);
- $this->categoryCollectionFactory = $categoryCollectionFactory ?: ObjectManager::getInstance()
- ->get(CollectionFactory::class);
+ $this->categoryResourceModel = $categoryResourceModel ?: ObjectManager::getInstance()
+ ->get(Category::class);
}
/**
@@ -2104,18 +2104,23 @@ protected function _applyZeroStoreProductLimitations()
private function getChildrenCategories(int $categoryId): array
{
$categoryIds[] = $categoryId;
-
- /** @var \Magento\Catalog\Model\ResourceModel\Category\Collection $categoryCollection */
- $categoryCollection = $this->categoryCollectionFactory->create();
- $categories = $categoryCollection
- ->addAttributeToFilter(
- ['is_anchor', 'path'],
- [1, ['like' => $categoryId . '/%']]
- )->getItems();
- foreach ($categories as $category) {
- $categoryChildren = $category->getChildren();
- $categoryIds = array_merge($categoryIds, explode(',', $categoryChildren));
+ $anchorCategory = [];
+
+ $categories = $this->categoryResourceModel->getCategoryWithChildren($categoryId);
+ $firstCategory = array_shift($categories);
+ if ($firstCategory['is_anchor'] == 1) {
+ $anchorCategory[] = (int)$firstCategory['entity_id'];
+ foreach ($categories as $category) {
+ if (in_array($category['parent_id'], $categoryIds)
+ && in_array($category['parent_id'], $anchorCategory)) {
+ $categoryIds[] = (int)$category['entity_id'];
+ if ($category['is_anchor'] == 1) {
+ $anchorCategory[] = (int)$category['entity_id'];
+ }
+ }
+ }
}
+
return $categoryIds;
}
From 3ccf1d99d3db16ae2dc9a6ebd97e62b931af6720 Mon Sep 17 00:00:00 2001
From: Yuliya Labudova
Date: Mon, 26 Aug 2019 17:43:38 +0300
Subject: [PATCH 095/937] MAGETWO-94565: Catalog product collection filters
produce errors and cause inconsistent behaviour
- Fix magento category installation.
---
app/code/Magento/Catalog/Model/ResourceModel/Category.php | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/app/code/Magento/Catalog/Model/ResourceModel/Category.php b/app/code/Magento/Catalog/Model/ResourceModel/Category.php
index cfc82d9b4ae94..d50570930923e 100644
--- a/app/code/Magento/Catalog/Model/ResourceModel/Category.php
+++ b/app/code/Magento/Catalog/Model/ResourceModel/Category.php
@@ -278,7 +278,7 @@ protected function _beforeSave(\Magento\Framework\DataObject $object)
if ($object->getPosition() === null) {
$object->setPosition($this->_getMaxPosition($object->getPath()) + 1);
}
- $path = explode('/', $object->getPath());
+ $path = explode('/', (string)$object->getPath());
$level = count($path) - ($object->getId() ? 1 : 0);
$toUpdateChild = array_diff($path, [$object->getId()]);
@@ -317,7 +317,7 @@ protected function _afterSave(\Magento\Framework\DataObject $object)
/**
* Add identifier for new category
*/
- if (substr($object->getPath(), -1) == '/') {
+ if (substr((string)$object->getPath(), -1) == '/') {
$object->setPath($object->getPath() . $object->getId());
$this->_savePath($object);
}
From dc084e09e1a55cc4349453b236cfaa6213313317 Mon Sep 17 00:00:00 2001
From: Soumya Unnikrishnan
Date: Mon, 26 Aug 2019 14:27:47 -0500
Subject: [PATCH 096/937] MQE-1686: Paypal integration test leveraging Adobe
Vault - PayPalSmartButtonInCheckoutPage removed suite and added groups
instead
---
.../Magento/Paypal/Test/Mftf/Suite/suite.xml | 16 ----------------
...ckDefaultValueOfPayPalCustomizeButtonTest.xml | 1 +
...refrontCheckCreditButtonConfigurationTest.xml | 1 +
...efrontPaypalSmartButtonInCheckoutPageTest.xml | 4 +---
4 files changed, 3 insertions(+), 19 deletions(-)
delete mode 100644 app/code/Magento/Paypal/Test/Mftf/Suite/suite.xml
diff --git a/app/code/Magento/Paypal/Test/Mftf/Suite/suite.xml b/app/code/Magento/Paypal/Test/Mftf/Suite/suite.xml
deleted file mode 100644
index d1b7937180a09..0000000000000
--- a/app/code/Magento/Paypal/Test/Mftf/Suite/suite.xml
+++ /dev/null
@@ -1,16 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/app/code/Magento/Paypal/Test/Mftf/Test/AdminCheckDefaultValueOfPayPalCustomizeButtonTest.xml b/app/code/Magento/Paypal/Test/Mftf/Test/AdminCheckDefaultValueOfPayPalCustomizeButtonTest.xml
index 4b28f00a132a8..5c10bc9536fcf 100644
--- a/app/code/Magento/Paypal/Test/Mftf/Test/AdminCheckDefaultValueOfPayPalCustomizeButtonTest.xml
+++ b/app/code/Magento/Paypal/Test/Mftf/Test/AdminCheckDefaultValueOfPayPalCustomizeButtonTest.xml
@@ -16,6 +16,7 @@
+
diff --git a/app/code/Magento/Paypal/Test/Mftf/Test/StorefrontCheckCreditButtonConfigurationTest.xml b/app/code/Magento/Paypal/Test/Mftf/Test/StorefrontCheckCreditButtonConfigurationTest.xml
index 96213831cdd01..d8cea82bcc2f5 100644
--- a/app/code/Magento/Paypal/Test/Mftf/Test/StorefrontCheckCreditButtonConfigurationTest.xml
+++ b/app/code/Magento/Paypal/Test/Mftf/Test/StorefrontCheckCreditButtonConfigurationTest.xml
@@ -16,6 +16,7 @@
+
diff --git a/app/code/Magento/Paypal/Test/Mftf/Test/StorefrontPaypalSmartButtonInCheckoutPageTest.xml b/app/code/Magento/Paypal/Test/Mftf/Test/StorefrontPaypalSmartButtonInCheckoutPageTest.xml
index 4f28c52679a89..fea1cf3966b99 100644
--- a/app/code/Magento/Paypal/Test/Mftf/Test/StorefrontPaypalSmartButtonInCheckoutPageTest.xml
+++ b/app/code/Magento/Paypal/Test/Mftf/Test/StorefrontPaypalSmartButtonInCheckoutPageTest.xml
@@ -16,9 +16,7 @@
-
-
-
+
From 52cdae7e754ab4a12b06e9bf2df05127cb5a7a53 Mon Sep 17 00:00:00 2001
From: Raul E Watson
Date: Tue, 27 Aug 2019 00:35:46 +0100
Subject: [PATCH 097/937] Add changes requested during CR
---
app/code/Magento/Analytics/README.md | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/app/code/Magento/Analytics/README.md b/app/code/Magento/Analytics/README.md
index cb78a27dae8e0..e0f1c818c7a94 100644
--- a/app/code/Magento/Analytics/README.md
+++ b/app/code/Magento/Analytics/README.md
@@ -4,10 +4,10 @@ The Magento_Analytics module integrates your Magento instance with the [Magento
The module implements the following functionality:
-- Enabling subscription to the MBI and automatic re-subscription
+- Enabling subscription to Magento Business Intelligence (MBI) and automatic re-subscription
- Changing the base URL with the same MBI account remained
- Declaring the configuration schemas for report data collection
-- Collecting the Magento instance data as reports for the MBI
+- Collecting the Magento instance data as reports for MBI
- Introducing API that provides the collected data
- Extending Magento configuration with the module parameters:
- Subscription status (enabled/disabled)
From 8048c09d7f37460c8dda1938fde85a2e36bce49b Mon Sep 17 00:00:00 2001
From: Rus0
Date: Mon, 26 Aug 2019 21:23:46 -0500
Subject: [PATCH 098/937] Adding verification of stock and catalog flag for
showing out of stock products, the wishlist shows the products if they are
out of stock with the flag show out of stock.
---
app/code/Magento/Wishlist/Model/Wishlist.php | 160 ++++++++++++-------
1 file changed, 105 insertions(+), 55 deletions(-)
diff --git a/app/code/Magento/Wishlist/Model/Wishlist.php b/app/code/Magento/Wishlist/Model/Wishlist.php
index 9797ab58b0766..bf43fbd6f4363 100644
--- a/app/code/Magento/Wishlist/Model/Wishlist.php
+++ b/app/code/Magento/Wishlist/Model/Wishlist.php
@@ -7,30 +7,49 @@
namespace Magento\Wishlist\Model;
+use Exception;
+use InvalidArgumentException;
use Magento\Catalog\Api\ProductRepositoryInterface;
+use Magento\Catalog\Model\Product;
+use Magento\Catalog\Model\ProductFactory;
+use Magento\CatalogInventory\Model\Configuration;
+use Magento\Framework\App\Config\ScopeConfigInterface;
use Magento\Framework\App\ObjectManager;
+use Magento\Framework\DataObject;
+use Magento\Framework\DataObject\IdentityInterface;
+use Magento\Framework\Exception\LocalizedException;
use Magento\Framework\Exception\NoSuchEntityException;
+use Magento\Framework\Math\Random;
+use Magento\Framework\Model\AbstractModel;
+use Magento\Framework\Model\Context;
+use Magento\Framework\Registry;
use Magento\Framework\Serialize\Serializer\Json;
+use Magento\Framework\Stdlib\DateTime;
+use Magento\Store\Model\ScopeInterface;
+use Magento\Store\Model\Store;
+use Magento\Store\Model\StoreManagerInterface;
+use Magento\Wishlist\Helper\Data;
use Magento\Wishlist\Model\ResourceModel\Item\CollectionFactory;
use Magento\Wishlist\Model\ResourceModel\Wishlist as ResourceWishlist;
use Magento\Wishlist\Model\ResourceModel\Wishlist\Collection;
+use Magento\CatalogInventory\Model\Stock\StockItemRepository;
/**
* Wishlist model
*
* @method int getShared()
- * @method \Magento\Wishlist\Model\Wishlist setShared(int $value)
+ * @method Wishlist setShared(int $value)
* @method string getSharingCode()
- * @method \Magento\Wishlist\Model\Wishlist setSharingCode(string $value)
+ * @method Wishlist setSharingCode(string $value)
* @method string getUpdatedAt()
- * @method \Magento\Wishlist\Model\Wishlist setUpdatedAt(string $value)
+ * @method Wishlist setUpdatedAt(string $value)
* @SuppressWarnings(PHPMD.CouplingBetweenObjects)
* @SuppressWarnings(PHPMD.TooManyFields)
*
* @api
* @since 100.0.2
*/
-class Wishlist extends \Magento\Framework\Model\AbstractModel implements \Magento\Framework\DataObject\IdentityInterface
+class Wishlist extends AbstractModel implements IdentityInterface
{
/**
* Cache tag
@@ -47,14 +66,14 @@ class Wishlist extends \Magento\Framework\Model\AbstractModel implements \Magent
/**
* Wishlist item collection
*
- * @var \Magento\Wishlist\Model\ResourceModel\Item\Collection
+ * @var ResourceModel\Item\Collection
*/
protected $_itemCollection;
/**
* Store filter for wishlist
*
- * @var \Magento\Store\Model\Store
+ * @var Store
*/
protected $_store;
@@ -68,7 +87,7 @@ class Wishlist extends \Magento\Framework\Model\AbstractModel implements \Magent
/**
* Wishlist data
*
- * @var \Magento\Wishlist\Helper\Data
+ * @var Data
*/
protected $_wishlistData;
@@ -80,12 +99,12 @@ class Wishlist extends \Magento\Framework\Model\AbstractModel implements \Magent
protected $_catalogProduct;
/**
- * @var \Magento\Store\Model\StoreManagerInterface
+ * @var StoreManagerInterface
*/
protected $_storeManager;
/**
- * @var \Magento\Framework\Stdlib\DateTime\DateTime
+ * @var DateTime\DateTime
*/
protected $_date;
@@ -100,17 +119,17 @@ class Wishlist extends \Magento\Framework\Model\AbstractModel implements \Magent
protected $_wishlistCollectionFactory;
/**
- * @var \Magento\Catalog\Model\ProductFactory
+ * @var ProductFactory
*/
protected $_productFactory;
/**
- * @var \Magento\Framework\Math\Random
+ * @var Random
*/
protected $mathRandom;
/**
- * @var \Magento\Framework\Stdlib\DateTime
+ * @var DateTime
*/
protected $dateTime;
@@ -129,43 +148,56 @@ class Wishlist extends \Magento\Framework\Model\AbstractModel implements \Magent
*/
private $serializer;
+ /**
+ * @var StockItemRepository
+ */
+ private $stockItemRepository;
+
+ /**
+ * @var ScopeConfigInterface
+ */
+ private $scopeConfig;
+
/**
* Constructor
*
- * @param \Magento\Framework\Model\Context $context
- * @param \Magento\Framework\Registry $registry
+ * @param Context $context
+ * @param Registry $registry
* @param \Magento\Catalog\Helper\Product $catalogProduct
- * @param \Magento\Wishlist\Helper\Data $wishlistData
+ * @param Data $wishlistData
* @param ResourceWishlist $resource
* @param Collection $resourceCollection
- * @param \Magento\Store\Model\StoreManagerInterface $storeManager
- * @param \Magento\Framework\Stdlib\DateTime\DateTime $date
+ * @param StoreManagerInterface $storeManager
+ * @param DateTime\DateTime $date
* @param ItemFactory $wishlistItemFactory
* @param CollectionFactory $wishlistCollectionFactory
- * @param \Magento\Catalog\Model\ProductFactory $productFactory
- * @param \Magento\Framework\Math\Random $mathRandom
- * @param \Magento\Framework\Stdlib\DateTime $dateTime
+ * @param ProductFactory $productFactory
+ * @param Random $mathRandom
+ * @param DateTime $dateTime
* @param ProductRepositoryInterface $productRepository
+ * @param StockItemRepository $stockItemRepository
* @param bool $useCurrentWebsite
* @param array $data
* @param Json|null $serializer
* @SuppressWarnings(PHPMD.ExcessiveParameterList)
*/
public function __construct(
- \Magento\Framework\Model\Context $context,
- \Magento\Framework\Registry $registry,
+ Context $context,
+ Registry $registry,
\Magento\Catalog\Helper\Product $catalogProduct,
- \Magento\Wishlist\Helper\Data $wishlistData,
+ Data $wishlistData,
ResourceWishlist $resource,
Collection $resourceCollection,
- \Magento\Store\Model\StoreManagerInterface $storeManager,
- \Magento\Framework\Stdlib\DateTime\DateTime $date,
+ StoreManagerInterface $storeManager,
+ DateTime\DateTime $date,
ItemFactory $wishlistItemFactory,
CollectionFactory $wishlistCollectionFactory,
- \Magento\Catalog\Model\ProductFactory $productFactory,
- \Magento\Framework\Math\Random $mathRandom,
- \Magento\Framework\Stdlib\DateTime $dateTime,
+ ProductFactory $productFactory,
+ Random $mathRandom,
+ DateTime $dateTime,
ProductRepositoryInterface $productRepository,
+ StockItemRepository $stockItemRepository,
+ ScopeConfigInterface $scopeConfig = null,
$useCurrentWebsite = true,
array $data = [],
Json $serializer = null
@@ -183,6 +215,8 @@ public function __construct(
$this->serializer = $serializer ?: ObjectManager::getInstance()->get(Json::class);
parent::__construct($context, $registry, $resource, $resourceCollection, $data);
$this->productRepository = $productRepository;
+ $this->stockItemRepository = $stockItemRepository;
+ $this->scopeConfig = $scopeConfig ?: ObjectManager::getInstance()->get(ScopeConfigInterface::class);
}
/**
@@ -290,13 +324,13 @@ public function afterSave()
/**
* Add catalog product object data to wishlist
*
- * @param \Magento\Catalog\Model\Product $product
+ * @param Product $product
* @param int $qty
* @param bool $forciblySetQty
*
* @return Item
*/
- protected function _addCatalogProduct(\Magento\Catalog\Model\Product $product, $qty = 1, $forciblySetQty = false)
+ protected function _addCatalogProduct(Product $product, $qty = 1, $forciblySetQty = false)
{
$item = null;
foreach ($this->getItemCollection() as $_item) {
@@ -311,7 +345,7 @@ protected function _addCatalogProduct(\Magento\Catalog\Model\Product $product, $
$item = $this->_wishlistItemFactory->create();
$item->setProductId($product->getId());
$item->setWishlistId($this->getId());
- $item->setAddedAt((new \DateTime())->format(\Magento\Framework\Stdlib\DateTime::DATETIME_PHP_FORMAT));
+ $item->setAddedAt((new \DateTime())->format(DateTime::DATETIME_PHP_FORMAT));
$item->setStoreId($storeId);
$item->setOptions($product->getCustomOptions());
$item->setProduct($product);
@@ -333,7 +367,7 @@ protected function _addCatalogProduct(\Magento\Catalog\Model\Product $product, $
/**
* Retrieve wishlist item collection
*
- * @return \Magento\Wishlist\Model\ResourceModel\Item\Collection
+ * @return ResourceModel\Item\Collection
*/
public function getItemCollection()
{
@@ -365,8 +399,9 @@ public function getItem($itemId)
/**
* Adding item to wishlist
*
- * @param Item $item
+ * @param Item $item
* @return $this
+ * @throws Exception
*/
public function addItem(Item $item)
{
@@ -383,13 +418,13 @@ public function addItem(Item $item)
*
* Returns new item or string on error.
*
- * @param int|\Magento\Catalog\Model\Product $product
- * @param \Magento\Framework\DataObject|array|string|null $buyRequest
+ * @param int|Product $product
+ * @param DataObject|array|string|null $buyRequest
* @param bool $forciblySetQty
- * @throws \Magento\Framework\Exception\LocalizedException
* @return Item|string
* @SuppressWarnings(PHPMD.CyclomaticComplexity)
* @SuppressWarnings(PHPMD.NPathComplexity)
+ *@throws LocalizedException
*/
public function addNewItem($product, $buyRequest = null, $forciblySetQty = false)
{
@@ -398,7 +433,7 @@ public function addNewItem($product, $buyRequest = null, $forciblySetQty = false
* a) we have new instance and do not interfere with other products in wishlist
* b) product has full set of attributes
*/
- if ($product instanceof \Magento\Catalog\Model\Product) {
+ if ($product instanceof Product) {
$productId = $product->getId();
// Maybe force some store by wishlist internal properties
$storeId = $product->hasWishlistStoreId() ? $product->getWishlistStoreId() : $product->getStoreId();
@@ -414,10 +449,19 @@ public function addNewItem($product, $buyRequest = null, $forciblySetQty = false
try {
$product = $this->productRepository->getById($productId, false, $storeId);
} catch (NoSuchEntityException $e) {
- throw new \Magento\Framework\Exception\LocalizedException(__('Cannot specify product.'));
+ throw new LocalizedException(__('Cannot specify product.'));
+ }
+
+ $stockItem = $this->stockItemRepository->get($product->getId());
+ $showOutOfStock = $this->scopeConfig->isSetFlag(
+ Configuration::XML_PATH_SHOW_OUT_OF_STOCK,
+ ScopeInterface::SCOPE_STORE
+ );
+ if (!$stockItem->getIsInStock() && !$showOutOfStock) {
+ throw new LocalizedException(__('Cannot add product without stock to wishlist.'));
}
- if ($buyRequest instanceof \Magento\Framework\DataObject) {
+ if ($buyRequest instanceof DataObject) {
$_buyRequest = $buyRequest;
} elseif (is_string($buyRequest)) {
$isInvalidItemConfiguration = false;
@@ -426,20 +470,20 @@ public function addNewItem($product, $buyRequest = null, $forciblySetQty = false
if (!is_array($buyRequestData)) {
$isInvalidItemConfiguration = true;
}
- } catch (\InvalidArgumentException $exception) {
+ } catch (InvalidArgumentException $exception) {
$isInvalidItemConfiguration = true;
}
if ($isInvalidItemConfiguration) {
- throw new \InvalidArgumentException('Invalid wishlist item configuration.');
+ throw new InvalidArgumentException('Invalid wishlist item configuration.');
}
- $_buyRequest = new \Magento\Framework\DataObject($buyRequestData);
+ $_buyRequest = new DataObject($buyRequestData);
} elseif (is_array($buyRequest)) {
- $_buyRequest = new \Magento\Framework\DataObject($buyRequest);
+ $_buyRequest = new DataObject($buyRequest);
} else {
- $_buyRequest = new \Magento\Framework\DataObject();
+ $_buyRequest = new DataObject();
}
- /* @var $product \Magento\Catalog\Model\Product */
+ /* @var $product Product */
$cartCandidates = $product->getTypeInstance()->processConfiguration($_buyRequest, clone $product);
/**
@@ -486,6 +530,7 @@ public function addNewItem($product, $buyRequest = null, $forciblySetQty = false
*
* @param int $customerId
* @return $this
+ * @throws LocalizedException
*/
public function setCustomerId($customerId)
{
@@ -496,6 +541,7 @@ public function setCustomerId($customerId)
* Retrieve customer id
*
* @return int
+ * @throws LocalizedException
*/
public function getCustomerId()
{
@@ -506,6 +552,7 @@ public function getCustomerId()
* Retrieve data for save
*
* @return array
+ * @throws LocalizedException
*/
public function getDataForSave()
{
@@ -520,6 +567,7 @@ public function getDataForSave()
* Retrieve shared store ids for current website or all stores if $current is false
*
* @return array
+ * @throws NoSuchEntityException
*/
public function getSharedStoreIds()
{
@@ -553,7 +601,8 @@ public function setSharedStoreIds($storeIds)
/**
* Retrieve wishlist store object
*
- * @return \Magento\Store\Model\Store
+ * @return Store
+ * @throws NoSuchEntityException
*/
public function getStore()
{
@@ -566,7 +615,7 @@ public function getStore()
/**
* Set wishlist store
*
- * @param \Magento\Store\Model\Store $store
+ * @param Store $store
* @return $this
*/
public function setStore($store)
@@ -605,6 +654,7 @@ public function isSalable()
*
* @param int $customerId
* @return bool
+ * @throws LocalizedException
*/
public function isOwner($customerId)
{
@@ -626,10 +676,10 @@ public function isOwner($customerId)
* For more options see \Magento\Catalog\Helper\Product->addParamsToBuyRequest()
*
* @param int|Item $itemId
- * @param \Magento\Framework\DataObject $buyRequest
- * @param null|array|\Magento\Framework\DataObject $params
+ * @param DataObject $buyRequest
+ * @param null|array|DataObject $params
* @return $this
- * @throws \Magento\Framework\Exception\LocalizedException
+ * @throws LocalizedException
*
* @see \Magento\Catalog\Helper\Product::addParamsToBuyRequest()
* @SuppressWarnings(PHPMD.CyclomaticComplexity)
@@ -645,16 +695,16 @@ public function updateItem($itemId, $buyRequest, $params = null)
$item = $this->getItem((int)$itemId);
}
if (!$item) {
- throw new \Magento\Framework\Exception\LocalizedException(__('We can\'t specify a wish list item.'));
+ throw new LocalizedException(__('We can\'t specify a wish list item.'));
}
$product = $item->getProduct();
$productId = $product->getId();
if ($productId) {
if (!$params) {
- $params = new \Magento\Framework\DataObject();
+ $params = new DataObject();
} elseif (is_array($params)) {
- $params = new \Magento\Framework\DataObject($params);
+ $params = new DataObject($params);
}
$params->setCurrentConfig($item->getBuyRequest());
$buyRequest = $this->_catalogProduct->addParamsToBuyRequest($buyRequest, $params);
@@ -677,7 +727,7 @@ public function updateItem($itemId, $buyRequest, $params = null)
* Error message
*/
if (is_string($resultItem)) {
- throw new \Magento\Framework\Exception\LocalizedException(__($resultItem));
+ throw new LocalizedException(__($resultItem));
}
if ($resultItem->getId() != $itemId) {
@@ -691,7 +741,7 @@ public function updateItem($itemId, $buyRequest, $params = null)
$resultItem->setOrigData('qty', 0);
}
} else {
- throw new \Magento\Framework\Exception\LocalizedException(__('The product does not exist.'));
+ throw new LocalizedException(__('The product does not exist.'));
}
return $this;
}
From 35620e2723c70ee1284682fe4abd2504594e2e6b Mon Sep 17 00:00:00 2001
From: Yuliya Labudova
Date: Tue, 27 Aug 2019 11:04:42 +0300
Subject: [PATCH 099/937] MAGETWO-94565: Catalog product collection filters
produce errors and cause inconsistent behaviour
- Fix strict types.
---
app/code/Magento/Catalog/Model/ResourceModel/Category.php | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/app/code/Magento/Catalog/Model/ResourceModel/Category.php b/app/code/Magento/Catalog/Model/ResourceModel/Category.php
index d50570930923e..b6f565f5fae4e 100644
--- a/app/code/Magento/Catalog/Model/ResourceModel/Category.php
+++ b/app/code/Magento/Catalog/Model/ResourceModel/Category.php
@@ -355,7 +355,7 @@ protected function _getMaxPosition($path)
{
$connection = $this->getConnection();
$positionField = $connection->quoteIdentifier('position');
- $level = count(explode('/', $path));
+ $level = count(explode('/', (string)$path));
$bind = ['c_level' => $level, 'c_path' => $path . '/%'];
$select = $connection->select()->from(
$this->getTable('catalog_category_entity'),
@@ -720,7 +720,7 @@ public function getCategories($parent, $recursionLevel = 0, $sorted = false, $as
*/
public function getParentCategories($category)
{
- $pathIds = array_reverse(explode(',', $category->getPathInStore()));
+ $pathIds = array_reverse(explode(',', (string)$category->getPathInStore()));
/** @var \Magento\Catalog\Model\ResourceModel\Category\Collection $categories */
$categories = $this->_categoryCollectionFactory->create();
return $categories->setStore(
From 9377d04ac9ff7d4603759e0b4a944fa89eeef423 Mon Sep 17 00:00:00 2001
From: Lusine Papyan
Date: Tue, 27 Aug 2019 13:50:10 +0400
Subject: [PATCH 100/937] MC-18826: Increase test coverage for Cart & Checkout
and Order Processing functional areas
- Automation test for MC-6411
---
...EditCustomerInformationFromActionGroup.xml | 7 ++
...inOrderSelectShippingMethodActionGroup.xml | 23 ++++
.../AdminInvoicePaymentShippingSection.xml | 4 +-
...leRatesShippingMethodStatusActionGroup.xml | 7 ++
...ustomStoreShippingMethodTableRatesTest.xml | 119 ++++++++++++++++++
.../tests/_data/test_tablerates.csv | 13 ++
6 files changed, 172 insertions(+), 1 deletion(-)
create mode 100644 app/code/Magento/Sales/Test/Mftf/ActionGroup/AdminOrderSelectShippingMethodActionGroup.xml
create mode 100644 app/code/Magento/Shipping/Test/Mftf/Test/AdminCreateOrderCustomStoreShippingMethodTableRatesTest.xml
create mode 100644 dev/tests/acceptance/tests/_data/test_tablerates.csv
diff --git a/app/code/Magento/Customer/Test/Mftf/ActionGroup/AdminEditCustomerInformationFromActionGroup.xml b/app/code/Magento/Customer/Test/Mftf/ActionGroup/AdminEditCustomerInformationFromActionGroup.xml
index 09033955ecc60..fa8931bc53141 100644
--- a/app/code/Magento/Customer/Test/Mftf/ActionGroup/AdminEditCustomerInformationFromActionGroup.xml
+++ b/app/code/Magento/Customer/Test/Mftf/ActionGroup/AdminEditCustomerInformationFromActionGroup.xml
@@ -30,4 +30,11 @@
+
+
+
+
+
+
+
diff --git a/app/code/Magento/Sales/Test/Mftf/ActionGroup/AdminOrderSelectShippingMethodActionGroup.xml b/app/code/Magento/Sales/Test/Mftf/ActionGroup/AdminOrderSelectShippingMethodActionGroup.xml
new file mode 100644
index 0000000000000..87f0c4d7e470e
--- /dev/null
+++ b/app/code/Magento/Sales/Test/Mftf/ActionGroup/AdminOrderSelectShippingMethodActionGroup.xml
@@ -0,0 +1,23 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/app/code/Magento/Sales/Test/Mftf/Section/AdminInvoicePaymentShippingSection.xml b/app/code/Magento/Sales/Test/Mftf/Section/AdminInvoicePaymentShippingSection.xml
index fda886a839802..a0b93c66f3a59 100644
--- a/app/code/Magento/Sales/Test/Mftf/Section/AdminInvoicePaymentShippingSection.xml
+++ b/app/code/Magento/Sales/Test/Mftf/Section/AdminInvoicePaymentShippingSection.xml
@@ -17,5 +17,7 @@
+
+
-
\ No newline at end of file
+
diff --git a/app/code/Magento/Shipping/Test/Mftf/ActionGroup/AdminChangeTableRatesShippingMethodStatusActionGroup.xml b/app/code/Magento/Shipping/Test/Mftf/ActionGroup/AdminChangeTableRatesShippingMethodStatusActionGroup.xml
index e506ca3a7662f..2df78f3a0d1aa 100644
--- a/app/code/Magento/Shipping/Test/Mftf/ActionGroup/AdminChangeTableRatesShippingMethodStatusActionGroup.xml
+++ b/app/code/Magento/Shipping/Test/Mftf/ActionGroup/AdminChangeTableRatesShippingMethodStatusActionGroup.xml
@@ -17,4 +17,11 @@
+
+
+
+
+
+
+
diff --git a/app/code/Magento/Shipping/Test/Mftf/Test/AdminCreateOrderCustomStoreShippingMethodTableRatesTest.xml b/app/code/Magento/Shipping/Test/Mftf/Test/AdminCreateOrderCustomStoreShippingMethodTableRatesTest.xml
new file mode 100644
index 0000000000000..bfb94c4293135
--- /dev/null
+++ b/app/code/Magento/Shipping/Test/Mftf/Test/AdminCreateOrderCustomStoreShippingMethodTableRatesTest.xml
@@ -0,0 +1,119 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/dev/tests/acceptance/tests/_data/test_tablerates.csv b/dev/tests/acceptance/tests/_data/test_tablerates.csv
new file mode 100644
index 0000000000000..d5a59ae6bccf2
--- /dev/null
+++ b/dev/tests/acceptance/tests/_data/test_tablerates.csv
@@ -0,0 +1,13 @@
+Country,Region/State,"Zip/Postal Code","Order Subtotal (and above)","Shipping Price"
+USA,*,*,0.0000,7.9900
+USA,*,*,7.0000,6.9900
+USA,*,*,13.0000,5.9900
+USA,*,*,25.9900,4.9900
+USA,AK,*,0.0000,8.9900
+USA,AK,*,7.0000,7.9900
+USA,AK,*,13.0000,6.9900
+USA,AK,*,25.9900,5.9900
+USA,HI,*,0.0000,8.9900
+USA,HI,*,7.0000,7.9900
+USA,HI,*,13.0000,6.9900
+USA,HI,*,25.9900,5.9900
From 665aad5966ff70c0fdbda79786062a97128ff8d8 Mon Sep 17 00:00:00 2001
From: yuriichayka
Date: Tue, 27 Aug 2019 14:11:14 +0300
Subject: [PATCH 101/937] magento/magento2#23279: Integration test for
unsubscribing from 'Back in stock notification' Added
customer_unsubscribe_stock_rollback.php for cleaning entries
---
.../customer_unsubscribe_stock_rollback.php | 20 +++++++++++++++++++
1 file changed, 20 insertions(+)
create mode 100644 dev/tests/integration/testsuite/Magento/ProductAlert/_files/customer_unsubscribe_stock_rollback.php
diff --git a/dev/tests/integration/testsuite/Magento/ProductAlert/_files/customer_unsubscribe_stock_rollback.php b/dev/tests/integration/testsuite/Magento/ProductAlert/_files/customer_unsubscribe_stock_rollback.php
new file mode 100644
index 0000000000000..2952dfbca11e4
--- /dev/null
+++ b/dev/tests/integration/testsuite/Magento/ProductAlert/_files/customer_unsubscribe_stock_rollback.php
@@ -0,0 +1,20 @@
+get(Stock::class);
+
+$productRepository = $objectManager->create(ProductRepositoryInterface::class);
+$productId = $productRepository->get('simple-out-of-stock')->getId();
+
+$resource->getConnection()->delete(
+ $resource->getMainTable(),
+ 'product_id = ' . $productId
+);
From 2cee2dcaefb851350ed10a18450cc1f010aa3922 Mon Sep 17 00:00:00 2001
From: Dave Macaulay
Date: Tue, 27 Aug 2019 11:10:19 -0500
Subject: [PATCH 102/937] MC-18995: Page Builder & PWA Studio Compatibility
- Fix Product Widget list rendering through GraphQL
---
.../CmsGraphQl/Plugin/DesignLoader.php | 68 +++++++++++++++++++
.../Magento/CmsGraphQl/etc/graphql/di.xml | 3 +
2 files changed, 71 insertions(+)
create mode 100644 app/code/Magento/CmsGraphQl/Plugin/DesignLoader.php
diff --git a/app/code/Magento/CmsGraphQl/Plugin/DesignLoader.php b/app/code/Magento/CmsGraphQl/Plugin/DesignLoader.php
new file mode 100644
index 0000000000000..d1df15c7026df
--- /dev/null
+++ b/app/code/Magento/CmsGraphQl/Plugin/DesignLoader.php
@@ -0,0 +1,68 @@
+designLoader = $designLoader;
+ $this->messageManager = $messageManager;
+ }
+
+ /**
+ * Before create load the design files
+ *
+ * @param \Magento\Catalog\Block\Product\ImageFactory $subject
+ * @param Product $product
+ * @param string $imageId
+ * @param array|null $attributes
+ *
+ * @SuppressWarnings(PHPMD.UnusedFormalParameter)
+ */
+ public function beforeCreate(
+ \Magento\Catalog\Block\Product\ImageFactory $subject,
+ Product $product,
+ string $imageId,
+ array $attributes = null
+ ) {
+ try {
+ $this->designLoader->load();
+ } catch (\Magento\Framework\Exception\LocalizedException $e) {
+ if ($e->getPrevious() instanceof \Magento\Framework\Config\Dom\ValidationException) {
+ /** @var MessageInterface $message */
+ $message = $this->messageManager
+ ->createMessage(MessageInterface::TYPE_ERROR)
+ ->setText($e->getMessage());
+ $this->messageManager->addUniqueMessages([$message]);
+ }
+ }
+ }
+}
\ No newline at end of file
diff --git a/app/code/Magento/CmsGraphQl/etc/graphql/di.xml b/app/code/Magento/CmsGraphQl/etc/graphql/di.xml
index 78c1071d8e07c..1be6d819a0dc9 100644
--- a/app/code/Magento/CmsGraphQl/etc/graphql/di.xml
+++ b/app/code/Magento/CmsGraphQl/etc/graphql/di.xml
@@ -18,4 +18,7 @@
+
+
+
From 9f5714841e063f1d54b41a1b5374059552277162 Mon Sep 17 00:00:00 2001
From: Krissy Hiserote
Date: Tue, 27 Aug 2019 13:56:47 -0500
Subject: [PATCH 103/937] MC-16650: Product Attribute Type Price Not Displaying
- use a different request generator for price, fix tests, and code
---
.../Catalog/Model/Layer/FilterList.php | 4 +-
.../Test/Unit/Model/Layer/FilterListTest.php | 9 +-
.../Model/Layer/Filter/Decimal.php | 27 ++----
.../Model/Search/RequestGenerator.php | 9 +-
.../Model/Search/RequestGenerator/Price.php | 46 +++++++++++
.../Search/RequestGenerator/DecimalTest.php | 18 +---
.../Search/RequestGenerator/PriceTest.php | 82 +++++++++++++++++++
app/code/Magento/CatalogSearch/etc/di.xml | 1 +
8 files changed, 150 insertions(+), 46 deletions(-)
create mode 100644 app/code/Magento/CatalogSearch/Model/Search/RequestGenerator/Price.php
create mode 100644 app/code/Magento/CatalogSearch/Test/Unit/Model/Search/RequestGenerator/PriceTest.php
diff --git a/app/code/Magento/Catalog/Model/Layer/FilterList.php b/app/code/Magento/Catalog/Model/Layer/FilterList.php
index 7f06c97d3e8d9..b8e9b8ad4aaa5 100644
--- a/app/code/Magento/Catalog/Model/Layer/FilterList.php
+++ b/app/code/Magento/Catalog/Model/Layer/FilterList.php
@@ -7,8 +7,6 @@
namespace Magento\Catalog\Model\Layer;
-use Magento\Catalog\Model\Product\Attribute\Backend\Price;
-
/**
* Layer navigation filters
*/
@@ -112,7 +110,7 @@ protected function getAttributeFilterClass(\Magento\Catalog\Model\ResourceModel\
{
$filterClassName = $this->filterTypes[self::ATTRIBUTE_FILTER];
- if ($attribute->getBackendModel() === Price::class) {
+ if ($attribute->getFrontendInput() === 'price') {
$filterClassName = $this->filterTypes[self::PRICE_FILTER];
} elseif ($attribute->getBackendType() === 'decimal') {
$filterClassName = $this->filterTypes[self::DECIMAL_FILTER];
diff --git a/app/code/Magento/Catalog/Test/Unit/Model/Layer/FilterListTest.php b/app/code/Magento/Catalog/Test/Unit/Model/Layer/FilterListTest.php
index 2d3c764cb6907..6943bc27fd77c 100644
--- a/app/code/Magento/Catalog/Test/Unit/Model/Layer/FilterListTest.php
+++ b/app/code/Magento/Catalog/Test/Unit/Model/Layer/FilterListTest.php
@@ -8,7 +8,6 @@
namespace Magento\Catalog\Test\Unit\Model\Layer;
use \Magento\Catalog\Model\Layer\FilterList;
-use Magento\Catalog\Model\Product\Attribute\Backend\Price;
class FilterListTest extends \PHPUnit\Framework\TestCase
{
@@ -97,8 +96,8 @@ public function getFiltersDataProvider()
{
return [
[
- 'method' => 'getBackendModel',
- 'value' => Price::class,
+ 'method' => 'getFrontendInput',
+ 'value' => 'price',
'expectedClass' => 'PriceFilterClass',
],
[
@@ -107,8 +106,8 @@ public function getFiltersDataProvider()
'expectedClass' => 'DecimalFilterClass',
],
[
- 'method' => 'getBackendModel',
- 'value' => null,
+ 'method' => 'getFrontendInput',
+ 'value' => 'text',
'expectedClass' => 'AttributeFilterClass',
]
];
diff --git a/app/code/Magento/CatalogSearch/Model/Layer/Filter/Decimal.php b/app/code/Magento/CatalogSearch/Model/Layer/Filter/Decimal.php
index 4c83c3f7184f1..596dc1bfc561d 100644
--- a/app/code/Magento/CatalogSearch/Model/Layer/Filter/Decimal.php
+++ b/app/code/Magento/CatalogSearch/Model/Layer/Filter/Decimal.php
@@ -72,11 +72,17 @@ public function apply(\Magento\Framework\App\RequestInterface $request)
list($from, $to) = explode('-', $filter);
+ // When the range is 10-20 we only need to get products that are in the 10-19.99 range.
+ $toValue = $to;
+ if (!empty($toValue) && $from !== $toValue) {
+ $toValue -= 0.001;
+ }
+
$this->getLayer()
->getProductCollection()
->addFieldToFilter(
$this->getAttributeModel()->getAttributeCode(),
- ['from' => $from, 'to' => $this->getToRangeValue($from, $to)]
+ ['from' => $from, 'to' => $toValue]
);
$this->getLayer()->getState()->addFilter(
@@ -149,23 +155,4 @@ protected function renderRangeLabel($fromPrice, $toPrice)
return __('%1 - %2', $formattedFromPrice, $this->priceCurrency->format($toPrice));
}
}
-
- /**
- * Get the to range value
- *
- * When the range is 10-20 we only need to get products that are in the 10-19.99 range.
- * 20 should be in the next range group.
- *
- * @param float|string $from
- * @param float|string $to
- * @return float|string
- */
- private function getToRangeValue($from, $to)
- {
- if (!empty($to) && $from !== $to) {
- $to -= 0.001;
- }
-
- return $to;
- }
}
diff --git a/app/code/Magento/CatalogSearch/Model/Search/RequestGenerator.php b/app/code/Magento/CatalogSearch/Model/Search/RequestGenerator.php
index 0adc2fcecbfa7..82264c5d4cc23 100644
--- a/app/code/Magento/CatalogSearch/Model/Search/RequestGenerator.php
+++ b/app/code/Magento/CatalogSearch/Model/Search/RequestGenerator.php
@@ -3,6 +3,8 @@
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
+declare(strict_types=1);
+
namespace Magento\CatalogSearch\Model\Search;
use Magento\Catalog\Api\Data\EavAttributeInterface;
@@ -78,6 +80,7 @@ private function generateRequest($attributeType, $container, $useFulltext)
{
$request = [];
foreach ($this->getSearchableAttributes() as $attribute) {
+ /** @var $attribute Attribute */
if ($attribute->getData($attributeType)) {
if (!in_array($attribute->getAttributeCode(), ['price', 'category_ids'], true)) {
$queryName = $attribute->getAttributeCode() . '_query';
@@ -97,12 +100,14 @@ private function generateRequest($attributeType, $container, $useFulltext)
],
];
$bucketName = $attribute->getAttributeCode() . self::BUCKET_SUFFIX;
- $generator = $this->generatorResolver->getGeneratorForType($attribute->getBackendType());
+ $generatorType = $attribute->getFrontendInput() === 'price'
+ ? $attribute->getFrontendInput()
+ : $attribute->getBackendType();
+ $generator = $this->generatorResolver->getGeneratorForType($generatorType);
$request['filters'][$filterName] = $generator->getFilterData($attribute, $filterName);
$request['aggregations'][$bucketName] = $generator->getAggregationData($attribute, $bucketName);
}
}
- /** @var $attribute Attribute */
if (!$attribute->getIsSearchable() || in_array($attribute->getAttributeCode(), ['price', 'sku'], true)) {
// Some fields have their own specific handlers
continue;
diff --git a/app/code/Magento/CatalogSearch/Model/Search/RequestGenerator/Price.php b/app/code/Magento/CatalogSearch/Model/Search/RequestGenerator/Price.php
new file mode 100644
index 0000000000000..7bf124844c618
--- /dev/null
+++ b/app/code/Magento/CatalogSearch/Model/Search/RequestGenerator/Price.php
@@ -0,0 +1,46 @@
+ FilterInterface::TYPE_RANGE,
+ 'name' => $filterName,
+ 'field' => $attribute->getAttributeCode(),
+ 'from' => '$' . $attribute->getAttributeCode() . '.from$',
+ 'to' => '$' . $attribute->getAttributeCode() . '.to$',
+ ];
+ }
+
+ /**
+ * @inheritdoc
+ */
+ public function getAggregationData(Attribute $attribute, $bucketName)
+ {
+ return [
+ 'type' => BucketInterface::TYPE_DYNAMIC,
+ 'name' => $bucketName,
+ 'field' => $attribute->getAttributeCode(),
+ 'method' => '$price_dynamic_algorithm$',
+ 'metric' => [['type' => 'count']],
+ ];
+ }
+}
diff --git a/app/code/Magento/CatalogSearch/Test/Unit/Model/Search/RequestGenerator/DecimalTest.php b/app/code/Magento/CatalogSearch/Test/Unit/Model/Search/RequestGenerator/DecimalTest.php
index f04188fbf7bdd..350344372612a 100644
--- a/app/code/Magento/CatalogSearch/Test/Unit/Model/Search/RequestGenerator/DecimalTest.php
+++ b/app/code/Magento/CatalogSearch/Test/Unit/Model/Search/RequestGenerator/DecimalTest.php
@@ -11,7 +11,6 @@
use Magento\CatalogSearch\Model\Search\RequestGenerator\Decimal;
use Magento\Framework\Search\Request\BucketInterface;
use Magento\Framework\Search\Request\FilterInterface;
-use Magento\Framework\App\Config\ScopeConfigInterface;
/**
* Test catalog search range request generator.
@@ -24,23 +23,14 @@ class DecimalTest extends \PHPUnit\Framework\TestCase
/** @var Attribute|\PHPUnit_Framework_MockObject_MockObject */
private $attribute;
- /** @var \Magento\Framework\App\Config\ScopeConfigInterface|\PHPUnit_Framework_MockObject_MockObject */
- private $scopeConfigMock;
-
protected function setUp()
{
$this->attribute = $this->getMockBuilder(Attribute::class)
->disableOriginalConstructor()
->setMethods(['getAttributeCode'])
->getMockForAbstractClass();
- $this->scopeConfigMock = $this->getMockBuilder(ScopeConfigInterface::class)
- ->setMethods(['getValue'])
- ->getMockForAbstractClass();
$objectManager = new \Magento\Framework\TestFramework\Unit\Helper\ObjectManager($this);
- $this->decimal = $objectManager->getObject(
- Decimal::class,
- ['scopeConfig' => $this->scopeConfigMock]
- );
+ $this->decimal = $objectManager->getObject(Decimal::class);
}
public function testGetFilterData()
@@ -65,20 +55,16 @@ public function testGetAggregationData()
{
$bucketName = 'test_bucket_name';
$attributeCode = 'test_attribute_code';
- $method = 'manual';
$expected = [
'type' => BucketInterface::TYPE_DYNAMIC,
'name' => $bucketName,
'field' => $attributeCode,
- 'method' => $method,
+ 'method' => 'manual',
'metric' => [['type' => 'count']],
];
$this->attribute->expects($this->atLeastOnce())
->method('getAttributeCode')
->willReturn($attributeCode);
- $this->scopeConfigMock->expects($this->once())
- ->method('getValue')
- ->willReturn($method);
$actual = $this->decimal->getAggregationData($this->attribute, $bucketName);
$this->assertEquals($expected, $actual);
}
diff --git a/app/code/Magento/CatalogSearch/Test/Unit/Model/Search/RequestGenerator/PriceTest.php b/app/code/Magento/CatalogSearch/Test/Unit/Model/Search/RequestGenerator/PriceTest.php
new file mode 100644
index 0000000000000..3635430197591
--- /dev/null
+++ b/app/code/Magento/CatalogSearch/Test/Unit/Model/Search/RequestGenerator/PriceTest.php
@@ -0,0 +1,82 @@
+attribute = $this->getMockBuilder(Attribute::class)
+ ->disableOriginalConstructor()
+ ->setMethods(['getAttributeCode'])
+ ->getMockForAbstractClass();
+ $this->scopeConfigMock = $this->getMockBuilder(ScopeConfigInterface::class)
+ ->setMethods(['getValue'])
+ ->getMockForAbstractClass();
+ $objectManager = new \Magento\Framework\TestFramework\Unit\Helper\ObjectManager($this);
+ $this->price = $objectManager->getObject(
+ Price::class,
+ ['scopeConfig' => $this->scopeConfigMock]
+ );
+ }
+
+ public function testGetFilterData()
+ {
+ $filterName = 'test_filter_name';
+ $attributeCode = 'test_attribute_code';
+ $expected = [
+ 'type' => FilterInterface::TYPE_RANGE,
+ 'name' => $filterName,
+ 'field' => $attributeCode,
+ 'from' => '$' . $attributeCode . '.from$',
+ 'to' => '$' . $attributeCode . '.to$',
+ ];
+ $this->attribute->expects($this->atLeastOnce())
+ ->method('getAttributeCode')
+ ->willReturn($attributeCode);
+ $actual = $this->price->getFilterData($this->attribute, $filterName);
+ $this->assertEquals($expected, $actual);
+ }
+
+ public function testGetAggregationData()
+ {
+ $bucketName = 'test_bucket_name';
+ $attributeCode = 'test_attribute_code';
+ $method = 'price_dynamic_algorithm';
+ $expected = [
+ 'type' => BucketInterface::TYPE_DYNAMIC,
+ 'name' => $bucketName,
+ 'field' => $attributeCode,
+ 'method' => '$'. $method . '$',
+ 'metric' => [['type' => 'count']],
+ ];
+ $this->attribute->expects($this->atLeastOnce())
+ ->method('getAttributeCode')
+ ->willReturn($attributeCode);
+ $actual = $this->price->getAggregationData($this->attribute, $bucketName);
+ $this->assertEquals($expected, $actual);
+ }
+}
diff --git a/app/code/Magento/CatalogSearch/etc/di.xml b/app/code/Magento/CatalogSearch/etc/di.xml
index 7359bd6b454b9..6c9010f306e14 100644
--- a/app/code/Magento/CatalogSearch/etc/di.xml
+++ b/app/code/Magento/CatalogSearch/etc/di.xml
@@ -279,6 +279,7 @@
\Magento\CatalogSearch\Model\Search\RequestGenerator\General
- Magento\CatalogSearch\Model\Search\RequestGenerator\Decimal
+ - Magento\CatalogSearch\Model\Search\RequestGenerator\Price
From 8f491d3dcc905b12b08b5327999ce51e658a34ac Mon Sep 17 00:00:00 2001
From: Rus0
Date: Tue, 27 Aug 2019 14:27:21 -0500
Subject: [PATCH 104/937] building errors
---
app/code/Magento/Wishlist/Model/Wishlist.php | 11 +-
.../Wishlist/Test/Unit/Model/WishlistTest.php | 173 ++++++++++++------
2 files changed, 122 insertions(+), 62 deletions(-)
diff --git a/app/code/Magento/Wishlist/Model/Wishlist.php b/app/code/Magento/Wishlist/Model/Wishlist.php
index bf43fbd6f4363..0d9c74edb3d4c 100644
--- a/app/code/Magento/Wishlist/Model/Wishlist.php
+++ b/app/code/Magento/Wishlist/Model/Wishlist.php
@@ -176,6 +176,7 @@ class Wishlist extends AbstractModel implements IdentityInterface
* @param DateTime $dateTime
* @param ProductRepositoryInterface $productRepository
* @param StockItemRepository $stockItemRepository
+ * @param ScopeConfigInterface|null $scopeConfig
* @param bool $useCurrentWebsite
* @param array $data
* @param Json|null $serializer
@@ -400,7 +401,7 @@ public function getItem($itemId)
* Adding item to wishlist
*
* @param Item $item
- * @return $this
+ * @return $this
* @throws Exception
*/
public function addItem(Item $item)
@@ -424,7 +425,8 @@ public function addItem(Item $item)
* @return Item|string
* @SuppressWarnings(PHPMD.CyclomaticComplexity)
* @SuppressWarnings(PHPMD.NPathComplexity)
- *@throws LocalizedException
+ * @throws LocalizedException
+ * @throws InvalidArgumentException
*/
public function addNewItem($product, $buyRequest = null, $forciblySetQty = false)
{
@@ -452,7 +454,8 @@ public function addNewItem($product, $buyRequest = null, $forciblySetQty = false
throw new LocalizedException(__('Cannot specify product.'));
}
- $stockItem = $this->stockItemRepository->get($product->getId());
+ /** @var \Magento\CatalogInventory\Api\Data\StockItemInterface $stockItem */
+ $stockItem = $this->stockItemRepository->get($productId);
$showOutOfStock = $this->scopeConfig->isSetFlag(
Configuration::XML_PATH_SHOW_OUT_OF_STOCK,
ScopeInterface::SCOPE_STORE
@@ -470,7 +473,7 @@ public function addNewItem($product, $buyRequest = null, $forciblySetQty = false
if (!is_array($buyRequestData)) {
$isInvalidItemConfiguration = true;
}
- } catch (InvalidArgumentException $exception) {
+ } catch (Exception $exception) {
$isInvalidItemConfiguration = true;
}
if ($isInvalidItemConfiguration) {
diff --git a/app/code/Magento/Wishlist/Test/Unit/Model/WishlistTest.php b/app/code/Magento/Wishlist/Test/Unit/Model/WishlistTest.php
index ff8a3a3b87cec..cbbccf29e63b8 100644
--- a/app/code/Magento/Wishlist/Test/Unit/Model/WishlistTest.php
+++ b/app/code/Magento/Wishlist/Test/Unit/Model/WishlistTest.php
@@ -5,76 +5,103 @@
*/
namespace Magento\Wishlist\Test\Unit\Model;
+use ArrayIterator;
+use Magento\Catalog\Api\ProductRepositoryInterface;
+use Magento\Catalog\Helper\Product as HelperProduct;
+use Magento\Catalog\Model\Product;
+use Magento\Catalog\Model\Product\Type\AbstractType;
+use Magento\Catalog\Model\ProductFactory;
+use Magento\CatalogInventory\Model\Stock\Item as StockItem;
+use Magento\CatalogInventory\Model\Stock\StockItemRepository;
+use Magento\Framework\App\Config\ScopeConfigInterface;
+use Magento\Framework\DataObject;
+use Magento\Framework\Event\ManagerInterface;
+use Magento\Framework\Exception\LocalizedException;
+use Magento\Framework\Math\Random;
+use Magento\Framework\Model\Context;
+use Magento\Framework\Registry;
+use Magento\Framework\Serialize\Serializer\Json;
+use Magento\Framework\Stdlib\DateTime;
+use Magento\Store\Model\StoreManagerInterface;
+use Magento\Wishlist\Helper\Data;
+use Magento\Wishlist\Model\Item;
+use Magento\Wishlist\Model\ItemFactory;
+use Magento\Wishlist\Model\ResourceModel\Item\Collection;
+use Magento\Wishlist\Model\ResourceModel\Item\CollectionFactory;
+use Magento\Wishlist\Model\ResourceModel\Wishlist as WishlistResource;
+use Magento\Wishlist\Model\ResourceModel\Wishlist\Collection as WishlistCollection;
use Magento\Wishlist\Model\Wishlist;
+use PHPUnit\Framework\TestCase;
+use PHPUnit_Framework_MockObject_MockObject;
/**
* @SuppressWarnings(PHPMD.CouplingBetweenObjects)
* @SuppressWarnings(PHPMD.TooManyFields)
*/
-class WishlistTest extends \PHPUnit\Framework\TestCase
+class WishlistTest extends TestCase
{
/**
- * @var \Magento\Framework\Registry|\PHPUnit_Framework_MockObject_MockObject
+ * @var Registry|PHPUnit_Framework_MockObject_MockObject
*/
protected $registry;
/**
- * @var \Magento\Catalog\Helper\Product|\PHPUnit_Framework_MockObject_MockObject
+ * @var HelperProduct|PHPUnit_Framework_MockObject_MockObject
*/
protected $productHelper;
/**
- * @var \Magento\Wishlist\Helper\Data|\PHPUnit_Framework_MockObject_MockObject
+ * @var Data|PHPUnit_Framework_MockObject_MockObject
*/
protected $helper;
/**
- * @var \Magento\Wishlist\Model\ResourceModel\Wishlist|\PHPUnit_Framework_MockObject_MockObject
+ * @var WishlistResource|PHPUnit_Framework_MockObject_MockObject
*/
protected $resource;
/**
- * @var \Magento\Wishlist\Model\ResourceModel\Wishlist\Collection|\PHPUnit_Framework_MockObject_MockObject
+ * @var WishlistCollection|PHPUnit_Framework_MockObject_MockObject
*/
protected $collection;
/**
- * @var \Magento\Store\Model\StoreManagerInterface|\PHPUnit_Framework_MockObject_MockObject
+ * @var StoreManagerInterface|PHPUnit_Framework_MockObject_MockObject
*/
protected $storeManager;
/**
- * @var \Magento\Framework\Stdlib\DateTime\DateTime|\PHPUnit_Framework_MockObject_MockObject
+ * @var DateTime\DateTime|PHPUnit_Framework_MockObject_MockObject
*/
protected $date;
/**
- * @var \Magento\Wishlist\Model\ItemFactory|\PHPUnit_Framework_MockObject_MockObject
+ * @var ItemFactory|PHPUnit_Framework_MockObject_MockObject
*/
protected $itemFactory;
/**
- * @var \Magento\Wishlist\Model\ResourceModel\Item\CollectionFactory|\PHPUnit_Framework_MockObject_MockObject
+ * @var CollectionFactory|PHPUnit_Framework_MockObject_MockObject
*/
protected $itemsFactory;
/**
- * @var \Magento\Catalog\Model\ProductFactory|\PHPUnit_Framework_MockObject_MockObject
+ * @var ProductFactory|PHPUnit_Framework_MockObject_MockObject
*/
protected $productFactory;
/**
- * @var \Magento\Framework\Math\Random|\PHPUnit_Framework_MockObject_MockObject
+ * @var Random|PHPUnit_Framework_MockObject_MockObject
*/
protected $mathRandom;
/**
- * @var \Magento\Framework\Stdlib\DateTime|\PHPUnit_Framework_MockObject_MockObject
+ * @var DateTime|PHPUnit_Framework_MockObject_MockObject
*/
protected $dateTime;
/**
- * @var \Magento\Framework\Event\ManagerInterface|\PHPUnit_Framework_MockObject_MockObject
+ * @var ManagerInterface|PHPUnit_Framework_MockObject_MockObject
*/
protected $eventDispatcher;
@@ -84,63 +111,79 @@ class WishlistTest extends \PHPUnit\Framework\TestCase
protected $wishlist;
/**
- * @var \Magento\Catalog\Api\ProductRepositoryInterface|\PHPUnit_Framework_MockObject_MockObject
+ * @var ProductRepositoryInterface|PHPUnit_Framework_MockObject_MockObject
*/
protected $productRepository;
/**
- * @var \Magento\Framework\Serialize\Serializer\Json|\PHPUnit_Framework_MockObject_MockObject
+ * @var Json|PHPUnit_Framework_MockObject_MockObject
*/
protected $serializer;
+ /**
+ * @var StockItemRepository|PHPUnit_Framework_MockObject_MockObject
+ */
+ private $stockItemRepository;
+
+ /**
+ * @var StockItemRepository|PHPUnit_Framework_MockObject_MockObject
+ */
+ private $scopeConfig;
+
protected function setUp()
{
- $context = $this->getMockBuilder(\Magento\Framework\Model\Context::class)
+ $context = $this->getMockBuilder(Context::class)
->disableOriginalConstructor()
->getMock();
- $this->eventDispatcher = $this->getMockBuilder(\Magento\Framework\Event\ManagerInterface::class)
+ $this->eventDispatcher = $this->getMockBuilder(ManagerInterface::class)
->getMock();
- $this->registry = $this->getMockBuilder(\Magento\Framework\Registry::class)
+ $this->registry = $this->getMockBuilder(Registry::class)
->disableOriginalConstructor()
->getMock();
- $this->productHelper = $this->getMockBuilder(\Magento\Catalog\Helper\Product::class)
+ $this->productHelper = $this->getMockBuilder(HelperProduct::class)
->disableOriginalConstructor()
->getMock();
- $this->helper = $this->getMockBuilder(\Magento\Wishlist\Helper\Data::class)
+ $this->helper = $this->getMockBuilder(Data::class)
->disableOriginalConstructor()
->getMock();
- $this->resource = $this->getMockBuilder(\Magento\Wishlist\Model\ResourceModel\Wishlist::class)
+ $this->resource = $this->getMockBuilder(WishlistResource::class)
->disableOriginalConstructor()
->getMock();
- $this->collection = $this->getMockBuilder(\Magento\Wishlist\Model\ResourceModel\Wishlist\Collection::class)
+ $this->collection = $this->getMockBuilder(WishlistCollection::class)
->disableOriginalConstructor()
->getMock();
- $this->storeManager = $this->getMockBuilder(\Magento\Store\Model\StoreManagerInterface::class)
+ $this->storeManager = $this->getMockBuilder(StoreManagerInterface::class)
->getMock();
- $this->date = $this->getMockBuilder(\Magento\Framework\Stdlib\DateTime\DateTime::class)
+ $this->date = $this->getMockBuilder(DateTime\DateTime::class)
->disableOriginalConstructor()
->getMock();
- $this->itemFactory = $this->getMockBuilder(\Magento\Wishlist\Model\ItemFactory::class)
+ $this->itemFactory = $this->getMockBuilder(ItemFactory::class)
->disableOriginalConstructor()
->setMethods(['create'])
->getMock();
- $this->itemsFactory = $this->getMockBuilder(\Magento\Wishlist\Model\ResourceModel\Item\CollectionFactory::class)
+ $this->itemsFactory = $this->getMockBuilder(CollectionFactory::class)
->disableOriginalConstructor()
->setMethods(['create'])
->getMock();
- $this->productFactory = $this->getMockBuilder(\Magento\Catalog\Model\ProductFactory::class)
+ $this->productFactory = $this->getMockBuilder(ProductFactory::class)
->disableOriginalConstructor()
->setMethods(['create'])
->getMock();
- $this->mathRandom = $this->getMockBuilder(\Magento\Framework\Math\Random::class)
+ $this->mathRandom = $this->getMockBuilder(Random::class)
->disableOriginalConstructor()
->getMock();
- $this->dateTime = $this->getMockBuilder(\Magento\Framework\Stdlib\DateTime::class)
+ $this->dateTime = $this->getMockBuilder(DateTime::class)
->disableOriginalConstructor()
->getMock();
- $this->productRepository = $this->createMock(\Magento\Catalog\Api\ProductRepositoryInterface::class);
- $this->serializer = $this->getMockBuilder(\Magento\Framework\Serialize\Serializer\Json::class)
+ $this->productRepository = $this->createMock(ProductRepositoryInterface::class);
+ $this->stockItemRepository = $this->createMock(StockItemRepository::class);
+ $this->scopeConfig = $this->createMock(ScopeConfigInterface::class);
+
+ $this->scopeConfig = $this->getMockBuilder(ScopeConfigInterface::class)
+ ->disableOriginalConstructor()
+ ->getMock();
+ $this->serializer = $this->getMockBuilder(Json::class)
->disableOriginalConstructor()
->getMock();
@@ -163,6 +206,8 @@ protected function setUp()
$this->mathRandom,
$this->dateTime,
$this->productRepository,
+ $this->stockItemRepository,
+ $this->scopeConfig,
false,
[],
$this->serializer
@@ -186,7 +231,7 @@ public function testLoadByCustomerId()
->will($this->returnValue($sharingCode));
$this->assertInstanceOf(
- \Magento\Wishlist\Model\Wishlist::class,
+ Wishlist::class,
$this->wishlist->loadByCustomerId($customerId, true)
);
$this->assertEquals($customerId, $this->wishlist->getCustomerId());
@@ -194,10 +239,10 @@ public function testLoadByCustomerId()
}
/**
- * @param int|\Magento\Wishlist\Model\Item|\PHPUnit_Framework_MockObject_MockObject $itemId
- * @param \Magento\Framework\DataObject $buyRequest
- * @param null|array|\Magento\Framework\DataObject $param
- * @throws \Magento\Framework\Exception\LocalizedException
+ * @param int|Item|PHPUnit_Framework_MockObject_MockObject $itemId
+ * @param DataObject $buyRequest
+ * @param null|array|DataObject $param
+ * @throws LocalizedException
*
* @dataProvider updateItemDataProvider
*/
@@ -205,9 +250,9 @@ public function testUpdateItem($itemId, $buyRequest, $param)
{
$storeId = 1;
$productId = 1;
- $stores = [(new \Magento\Framework\DataObject())->setId($storeId)];
+ $stores = [(new DataObject())->setId($storeId)];
- $newItem = $this->getMockBuilder(\Magento\Wishlist\Model\Item::class)
+ $newItem = $this->getMockBuilder(Item::class)
->setMethods(
['setProductId', 'setWishlistId', 'setStoreId', 'setOptions', 'setProduct', 'setQty', 'getItem', 'save']
)
@@ -228,12 +273,16 @@ public function testUpdateItem($itemId, $buyRequest, $param)
$this->storeManager->expects($this->any())->method('getStore')->will($this->returnValue($stores[0]));
$product = $this->getMockBuilder(
- \Magento\Catalog\Model\Product::class
+ Product::class
)->disableOriginalConstructor()->getMock();
$product->expects($this->any())->method('getId')->will($this->returnValue($productId));
$product->expects($this->any())->method('getStoreId')->will($this->returnValue($storeId));
- $instanceType = $this->getMockBuilder(\Magento\Catalog\Model\Product\Type\AbstractType::class)
+ $stockItem = $this->getMockBuilder(StockItem::class)->disableOriginalConstructor()->getMock();
+ $stockItem->expects($this->any())->method('getIsInStock')->will($this->returnValue(true));
+ $this->stockItemRepository->expects($this->any())->method('get')->will($this->returnValue($stockItem));
+
+ $instanceType = $this->getMockBuilder(AbstractType::class)
->disableOriginalConstructor()
->getMock();
$instanceType->expects($this->once())
@@ -241,13 +290,13 @@ public function testUpdateItem($itemId, $buyRequest, $param)
->will(
$this->returnValue(
$this->getMockBuilder(
- \Magento\Catalog\Model\Product::class
+ Product::class
)->disableOriginalConstructor()->getMock()
)
);
$newProduct = $this->getMockBuilder(
- \Magento\Catalog\Model\Product::class
+ Product::class
)->disableOriginalConstructor()->getMock();
$newProduct->expects($this->any())
->method('setStoreId')
@@ -257,12 +306,12 @@ public function testUpdateItem($itemId, $buyRequest, $param)
->method('getTypeInstance')
->will($this->returnValue($instanceType));
- $item = $this->getMockBuilder(\Magento\Wishlist\Model\Item::class)->disableOriginalConstructor()->getMock();
+ $item = $this->getMockBuilder(Item::class)->disableOriginalConstructor()->getMock();
$item->expects($this->once())
->method('getProduct')
->will($this->returnValue($product));
- $items = $this->getMockBuilder(\Magento\Wishlist\Model\ResourceModel\Item\Collection::class)
+ $items = $this->getMockBuilder(Collection::class)
->disableOriginalConstructor()
->getMock();
@@ -280,7 +329,7 @@ public function testUpdateItem($itemId, $buyRequest, $param)
->will($this->returnValue($item));
$items->expects($this->any())
->method('getIterator')
- ->will($this->returnValue(new \ArrayIterator([$item])));
+ ->will($this->returnValue(new ArrayIterator([$item])));
$this->itemsFactory->expects($this->any())
->method('create')
@@ -292,7 +341,7 @@ public function testUpdateItem($itemId, $buyRequest, $param)
->will($this->returnValue($newProduct));
$this->assertInstanceOf(
- \Magento\Wishlist\Model\Wishlist::class,
+ Wishlist::class,
$this->wishlist->updateItem($itemId, $buyRequest, $param)
);
}
@@ -303,7 +352,7 @@ public function testUpdateItem($itemId, $buyRequest, $param)
public function updateItemDataProvider()
{
return [
- '0' => [1, new \Magento\Framework\DataObject(), null]
+ '0' => [1, new DataObject(), null]
];
}
@@ -311,24 +360,26 @@ public function testAddNewItem()
{
$productId = 1;
$storeId = 1;
- $buyRequest = json_encode([
- 'number' => 42,
- 'string' => 'string_value',
- 'boolean' => true,
- 'collection' => [1, 2, 3],
- 'product' => 1,
- 'form_key' => 'abc'
- ]);
+ $buyRequest = json_encode(
+ [
+ 'number' => 42,
+ 'string' => 'string_value',
+ 'boolean' => true,
+ 'collection' => [1, 2, 3],
+ 'product' => 1,
+ 'form_key' => 'abc'
+ ]
+ );
$result = 'product';
- $instanceType = $this->getMockBuilder(\Magento\Catalog\Model\Product\Type\AbstractType::class)
+ $instanceType = $this->getMockBuilder(AbstractType::class)
->disableOriginalConstructor()
->getMock();
$instanceType->expects($this->once())
->method('processConfiguration')
->willReturn('product');
- $productMock = $this->getMockBuilder(\Magento\Catalog\Model\Product::class)
+ $productMock = $this->getMockBuilder(Product::class)
->disableOriginalConstructor()
->setMethods(['getId', 'hasWishlistStoreId', 'getStoreId', 'getTypeInstance'])
->getMock();
@@ -358,6 +409,12 @@ function ($value) {
}
);
+ $stockItem = $this->getMockBuilder(
+ StockItem::class
+ )->disableOriginalConstructor()->getMock();
+ $stockItem->expects($this->any())->method('getIsInStock')->will($this->returnValue(true));
+ $this->stockItemRepository->expects($this->any())->method('get')->will($this->returnValue($stockItem));
+
$this->assertEquals($result, $this->wishlist->addNewItem($productMock, $buyRequest));
}
}
From 06d9d2dc5db67791e6eadcd73881d915a034329f Mon Sep 17 00:00:00 2001
From: Volodymyr Vygovskyi
Date: Wed, 28 Aug 2019 09:47:30 +0300
Subject: [PATCH 105/937] added quote mask generation to fixture, refactoring
---
.../UpdateConfigurableCartItemsTest.php | 19 ++-----------------
.../quote_with_configurable_product.php | 8 ++++++++
2 files changed, 10 insertions(+), 17 deletions(-)
diff --git a/dev/tests/api-functional/testsuite/Magento/GraphQl/ConfigurableProduct/UpdateConfigurableCartItemsTest.php b/dev/tests/api-functional/testsuite/Magento/GraphQl/ConfigurableProduct/UpdateConfigurableCartItemsTest.php
index b13a75fa8c4e7..4f4e7ecab6fe3 100644
--- a/dev/tests/api-functional/testsuite/Magento/GraphQl/ConfigurableProduct/UpdateConfigurableCartItemsTest.php
+++ b/dev/tests/api-functional/testsuite/Magento/GraphQl/ConfigurableProduct/UpdateConfigurableCartItemsTest.php
@@ -49,7 +49,8 @@ class UpdateConfigurableCartItemsTest extends GraphQlAbstract
public function testUpdateConfigurableCartItemQuantity()
{
$reservedOrderId = 'test_cart_with_configurable';
- $maskedQuoteId = $this->getMaskedQuoteId($reservedOrderId);
+ $maskedQuoteId = $this->getMaskedQuoteIdByReservedOrderId->execute($reservedOrderId);
+
$productSku = 'simple_10';
$newQuantity = 123;
$quoteItem = $this->getQuoteItemBySku($productSku, $reservedOrderId);
@@ -125,20 +126,4 @@ private function getQuoteItemBySku(string $sku, string $reservedOrderId)
return $item;
}
-
- /**
- * @param $reservedOrderId
- * @return string
- * @throws NoSuchEntityException
- */
- private function getMaskedQuoteId(string $reservedOrderId): string
- {
- $quote = $this->quoteFactory->create();
- $this->quoteResource->load($quote, $reservedOrderId, 'reserved_order_id');
- $quoteIdMask = $this->quoteIdMaskFactory->create();
- $quoteIdMask->setQuoteId($quote->getId())
- ->save();
-
- return $this->getMaskedQuoteIdByReservedOrderId->execute($reservedOrderId);
- }
}
diff --git a/dev/tests/integration/testsuite/Magento/ConfigurableProduct/_files/quote_with_configurable_product.php b/dev/tests/integration/testsuite/Magento/ConfigurableProduct/_files/quote_with_configurable_product.php
index 150ce3b3108e5..7f108623f02f2 100644
--- a/dev/tests/integration/testsuite/Magento/ConfigurableProduct/_files/quote_with_configurable_product.php
+++ b/dev/tests/integration/testsuite/Magento/ConfigurableProduct/_files/quote_with_configurable_product.php
@@ -40,3 +40,11 @@
/** @var $objectManager \Magento\TestFramework\ObjectManager */
$objectManager = Bootstrap::getObjectManager();
$objectManager->removeSharedInstance(\Magento\Checkout\Model\Session::class);
+
+/** @var \Magento\Quote\Model\QuoteIdMask $quoteIdMask */
+$quoteIdMask = \Magento\TestFramework\Helper\Bootstrap::getObjectManager()
+ ->create(\Magento\Quote\Model\QuoteIdMaskFactory::class)
+ ->create();
+$quoteIdMask->setQuoteId($cart->getQuote()->getId());
+$quoteIdMask->setDataChanges(true);
+$quoteIdMask->save();
From 9a8cf3a5affede83010fa31879a59f7f482b1db3 Mon Sep 17 00:00:00 2001
From: Vitaliy Boyko
Date: Wed, 28 Aug 2019 11:10:25 +0300
Subject: [PATCH 106/937] graphQl-812: test Add Variation From Another
Configurable ProductToCart
---
.../AddConfigurableProductToCartTest.php | 42 +++++++++++++++++++
1 file changed, 42 insertions(+)
diff --git a/dev/tests/api-functional/testsuite/Magento/GraphQl/ConfigurableProduct/AddConfigurableProductToCartTest.php b/dev/tests/api-functional/testsuite/Magento/GraphQl/ConfigurableProduct/AddConfigurableProductToCartTest.php
index 0e334999599b4..36120c0535d49 100644
--- a/dev/tests/api-functional/testsuite/Magento/GraphQl/ConfigurableProduct/AddConfigurableProductToCartTest.php
+++ b/dev/tests/api-functional/testsuite/Magento/GraphQl/ConfigurableProduct/AddConfigurableProductToCartTest.php
@@ -67,6 +67,48 @@ public function testAddConfigurableProductToCart()
self::assertArrayHasKey('value_label', $option);
}
+ /**
+ * @magentoApiDataFixture Magento/ConfigurableProduct/_files/configurable_products.php
+ * @magentoApiDataFixture Magento/Checkout/_files/active_quote.php
+ */
+ public function testAddVariationFromAnotherConfigurableProductToCart()
+ {
+ $searchResponse = $this->graphQlQuery($this->getFetchProductQuery('configurable_12345'));
+ $product = current($searchResponse['products']['items']);
+ $attributeId = (int) $product['configurable_options'][0]['attribute_id'];
+ $optionId = $product['configurable_options'][0]['values'][1]['value_index'];
+
+ $quantity = 2;
+ $maskedQuoteId = $this->getMaskedQuoteIdByReservedOrderId->execute('test_order_1');
+ $parentSku = $product['sku'];
+
+ //'configurable' -> ['simple_10', 'simple_20']
+ //'configurable_12345' -> ['simple_30', 'simple_40']
+ //'simple_20' has same configurable option value index (super attribute) as 'simple_40'
+ //therefore 'simple_40' should be added to cart
+ $sku = 'simple_20';
+
+ $query = $this->getQuery(
+ $maskedQuoteId,
+ $parentSku,
+ $sku,
+ $quantity
+ );
+
+ $response = $this->graphQlMutation($query);
+
+ $cartItem = current($response['addConfigurableProductsToCart']['cart']['items']);
+ self::assertEquals($quantity, $cartItem['quantity']);
+ self::assertEquals($parentSku, $cartItem['product']['sku']);
+ self::assertArrayHasKey('configurable_options', $cartItem);
+
+ $option = current($cartItem['configurable_options']);
+ self::assertEquals($attributeId, $option['id']);
+ self::assertEquals($optionId, $option['value_id']);
+ self::assertArrayHasKey('option_label', $option);
+ self::assertArrayHasKey('value_label', $option);
+ }
+
/**
* @magentoApiDataFixture Magento/ConfigurableProduct/_files/product_configurable_sku.php
* @magentoApiDataFixture Magento/Checkout/_files/active_quote.php
From bce207730cb040446d4ce68651b391d4970c14bd Mon Sep 17 00:00:00 2001
From: Lusine Papyan
Date: Wed, 28 Aug 2019 16:37:19 +0400
Subject: [PATCH 107/937] MC-18821: Increase test coverage for Catalog
functional area
- Automation test for MC-13641
---
.../Suite/MagentoDeveloperModeTestSuite.xml | 20 ++++
...TabForSwatchProductAtributeActionGroup.xml | 8 ++
.../Mftf/Section/AdminManageSwatchSection.xml | 1 +
...fProductWithCustomProductAttributeTest.xml | 97 +++++++++++++++++++
4 files changed, 126 insertions(+)
create mode 100644 app/code/Magento/Deploy/Test/Mftf/Suite/MagentoDeveloperModeTestSuite.xml
create mode 100644 app/code/Magento/Swatches/Test/Mftf/Test/AdminSaveConfProductWithCustomProductAttributeTest.xml
diff --git a/app/code/Magento/Deploy/Test/Mftf/Suite/MagentoDeveloperModeTestSuite.xml b/app/code/Magento/Deploy/Test/Mftf/Suite/MagentoDeveloperModeTestSuite.xml
new file mode 100644
index 0000000000000..750f7233342b8
--- /dev/null
+++ b/app/code/Magento/Deploy/Test/Mftf/Suite/MagentoDeveloperModeTestSuite.xml
@@ -0,0 +1,20 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/app/code/Magento/Swatches/Test/Mftf/ActionGroup/AdminEditPropertiesTabForSwatchProductAtributeActionGroup.xml b/app/code/Magento/Swatches/Test/Mftf/ActionGroup/AdminEditPropertiesTabForSwatchProductAtributeActionGroup.xml
index 05ab5a53468a2..879487d93a655 100644
--- a/app/code/Magento/Swatches/Test/Mftf/ActionGroup/AdminEditPropertiesTabForSwatchProductAtributeActionGroup.xml
+++ b/app/code/Magento/Swatches/Test/Mftf/ActionGroup/AdminEditPropertiesTabForSwatchProductAtributeActionGroup.xml
@@ -20,6 +20,14 @@
+
+
+
+
+
+
+
+
diff --git a/app/code/Magento/Swatches/Test/Mftf/Section/AdminManageSwatchSection.xml b/app/code/Magento/Swatches/Test/Mftf/Section/AdminManageSwatchSection.xml
index c3ef0a7324bfd..899a032488c5e 100644
--- a/app/code/Magento/Swatches/Test/Mftf/Section/AdminManageSwatchSection.xml
+++ b/app/code/Magento/Swatches/Test/Mftf/Section/AdminManageSwatchSection.xml
@@ -21,6 +21,7 @@
+
diff --git a/app/code/Magento/Swatches/Test/Mftf/Test/AdminSaveConfProductWithCustomProductAttributeTest.xml b/app/code/Magento/Swatches/Test/Mftf/Test/AdminSaveConfProductWithCustomProductAttributeTest.xml
new file mode 100644
index 0000000000000..a7e1d5cad65ea
--- /dev/null
+++ b/app/code/Magento/Swatches/Test/Mftf/Test/AdminSaveConfProductWithCustomProductAttributeTest.xml
@@ -0,0 +1,97 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
From d617c3ca6541d1528bf26c26738b909d55424def Mon Sep 17 00:00:00 2001
From: Oleksii Lisovyi
Date: Wed, 28 Aug 2019 18:51:39 +0300
Subject: [PATCH 108/937] Sales - fix displaying available allowed countries
while editing order address in Admin panel
---
.../Block/Adminhtml/Order/Address/Form.php | 8 +++++
.../Adminhtml/Order/Create/Form/Address.php | 31 +++++++++++++------
2 files changed, 30 insertions(+), 9 deletions(-)
diff --git a/app/code/Magento/Sales/Block/Adminhtml/Order/Address/Form.php b/app/code/Magento/Sales/Block/Adminhtml/Order/Address/Form.php
index 12e59e63f6f7c..1efa149b390ef 100644
--- a/app/code/Magento/Sales/Block/Adminhtml/Order/Address/Form.php
+++ b/app/code/Magento/Sales/Block/Adminhtml/Order/Address/Form.php
@@ -136,4 +136,12 @@ public function getFormValues()
{
return $this->_getAddress()->getData();
}
+
+ /**
+ * @inheritDoc
+ */
+ protected function getAddressStoreId()
+ {
+ return $this->_getAddress()->getOrder()->getStoreId();
+ }
}
diff --git a/app/code/Magento/Sales/Block/Adminhtml/Order/Create/Form/Address.php b/app/code/Magento/Sales/Block/Adminhtml/Order/Create/Form/Address.php
index e4b9dd4c63b93..3fe943c1b194c 100644
--- a/app/code/Magento/Sales/Block/Adminhtml/Order/Create/Form/Address.php
+++ b/app/code/Magento/Sales/Block/Adminhtml/Order/Create/Form/Address.php
@@ -271,21 +271,24 @@ protected function _prepareForm()
$this->_form->setValues($this->getFormValues());
- if ($this->_form->getElement('country_id')->getValue()) {
- $countryId = $this->_form->getElement('country_id')->getValue();
- $this->_form->getElement('country_id')->setValue(null);
- foreach ($this->_form->getElement('country_id')->getValues() as $country) {
+ $countryElement = $this->_form->getElement('country_id');
+
+ $this->processCountryOptions($countryElement);
+
+ if ($countryElement->getValue()) {
+ $countryId = $countryElement->getValue();
+ $countryElement->setValue(null);
+ foreach ($countryElement->getValues() as $country) {
if ($country['value'] == $countryId) {
- $this->_form->getElement('country_id')->setValue($countryId);
+ $countryElement->setValue($countryId);
}
}
}
- if ($this->_form->getElement('country_id')->getValue() === null) {
- $this->_form->getElement('country_id')->setValue(
+ if ($countryElement->getValue() === null) {
+ $countryElement->setValue(
$this->directoryHelper->getDefaultCountry($this->getStore())
);
}
- $this->processCountryOptions($this->_form->getElement('country_id'));
// Set custom renderer for VAT field if needed
$vatIdElement = $this->_form->getElement('vat_id');
if ($vatIdElement && $this->getDisplayVatValidationButton() !== false) {
@@ -309,7 +312,7 @@ protected function _prepareForm()
*/
private function processCountryOptions(\Magento\Framework\Data\Form\Element\AbstractElement $countryElement)
{
- $storeId = $this->getBackendQuoteSession()->getStoreId();
+ $storeId = $this->getAddressStoreId();
$options = $this->getCountriesCollection()
->loadByStore($storeId)
->toOptionArray();
@@ -388,4 +391,14 @@ public function getAddressAsString(\Magento\Customer\Api\Data\AddressInterface $
return $this->escapeHtml($result);
}
+
+ /**
+ * Return address store id.
+ *
+ * @return int
+ */
+ protected function getAddressStoreId()
+ {
+ return $this->getBackendQuoteSession()->getStoreId();
+ }
}
From 4800a57e287aa946a796a06ae113f5372ea0b24b Mon Sep 17 00:00:00 2001
From: Max Lesechko
Date: Wed, 28 Aug 2019 10:45:22 -0500
Subject: [PATCH 109/937] MC-19684: Some minute values cannot be set for
Analytics data collection
---
.../AdminConfigurationTimeToSendDataTest.xml | 6 +--
.../Block/Agreement/Edit/AgreementsForm.xml | 2 +-
.../Customer/Test/Block/Form/CustomerForm.php | 2 +-
.../Block/Adminhtml/Queue/Edit/QueueForm.xml | 2 +-
.../Block/Adminhtml/Sales/Coupons/Filter.xml | 2 +-
.../Block/Adminhtml/Sales/TaxRule/Filter.xml | 2 +-
.../Adminhtml/Rating/Edit/RatingForm.xml | 2 +-
.../Block/Adminhtml/Report/Filter/Form.xml | 2 +-
lib/web/mage/validation.js | 45 -------------------
lib/web/mage/validation/validation.js | 22 ++++-----
10 files changed, 18 insertions(+), 69 deletions(-)
diff --git a/app/code/Magento/Analytics/Test/Mftf/Test/AdminConfigurationTimeToSendDataTest.xml b/app/code/Magento/Analytics/Test/Mftf/Test/AdminConfigurationTimeToSendDataTest.xml
index 58e62500b8203..8ebd8cb594bee 100644
--- a/app/code/Magento/Analytics/Test/Mftf/Test/AdminConfigurationTimeToSendDataTest.xml
+++ b/app/code/Magento/Analytics/Test/Mftf/Test/AdminConfigurationTimeToSendDataTest.xml
@@ -25,9 +25,9 @@
-
-
-
+
+
+
diff --git a/dev/tests/functional/tests/app/Magento/CheckoutAgreements/Test/Block/Adminhtml/Block/Agreement/Edit/AgreementsForm.xml b/dev/tests/functional/tests/app/Magento/CheckoutAgreements/Test/Block/Adminhtml/Block/Agreement/Edit/AgreementsForm.xml
index 95d99f9fa76cd..f98f9ca7cfe24 100644
--- a/dev/tests/functional/tests/app/Magento/CheckoutAgreements/Test/Block/Adminhtml/Block/Agreement/Edit/AgreementsForm.xml
+++ b/dev/tests/functional/tests/app/Magento/CheckoutAgreements/Test/Block/Adminhtml/Block/Agreement/Edit/AgreementsForm.xml
@@ -18,7 +18,7 @@
select
- [name="stores[0]"]
+ [name="stores[]"]
multiselectgrouplist
diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Block/Form/CustomerForm.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Block/Form/CustomerForm.php
index 61166339475b7..dc1e901a3feae 100644
--- a/dev/tests/functional/tests/app/Magento/Customer/Test/Block/Form/CustomerForm.php
+++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Block/Form/CustomerForm.php
@@ -29,7 +29,7 @@ class CustomerForm extends Form
*
* @var string
*/
- protected $customerAttribute = "[orig-name='%s[]']";
+ protected $customerAttribute = "[name='%s[]']";
/**
* Validation text message for a field.
diff --git a/dev/tests/functional/tests/app/Magento/Newsletter/Test/Block/Adminhtml/Queue/Edit/QueueForm.xml b/dev/tests/functional/tests/app/Magento/Newsletter/Test/Block/Adminhtml/Queue/Edit/QueueForm.xml
index 4d2acc76c8703..c1970955013e8 100644
--- a/dev/tests/functional/tests/app/Magento/Newsletter/Test/Block/Adminhtml/Queue/Edit/QueueForm.xml
+++ b/dev/tests/functional/tests/app/Magento/Newsletter/Test/Block/Adminhtml/Queue/Edit/QueueForm.xml
@@ -11,7 +11,7 @@
input[name='start_at']
- select[name="stores[0]"]
+ select[name="stores[]"]
multiselectgrouplist
diff --git a/dev/tests/functional/tests/app/Magento/Reports/Test/Block/Adminhtml/Sales/Coupons/Filter.xml b/dev/tests/functional/tests/app/Magento/Reports/Test/Block/Adminhtml/Sales/Coupons/Filter.xml
index 51809448e4edb..d66c3b702f076 100644
--- a/dev/tests/functional/tests/app/Magento/Reports/Test/Block/Adminhtml/Sales/Coupons/Filter.xml
+++ b/dev/tests/functional/tests/app/Magento/Reports/Test/Block/Adminhtml/Sales/Coupons/Filter.xml
@@ -29,7 +29,7 @@
select
- [name="order_statuses[0]"]
+ [name="order_statuses[]"]
multiselect
diff --git a/dev/tests/functional/tests/app/Magento/Reports/Test/Block/Adminhtml/Sales/TaxRule/Filter.xml b/dev/tests/functional/tests/app/Magento/Reports/Test/Block/Adminhtml/Sales/TaxRule/Filter.xml
index 5820de6772e1c..08e783e1329a4 100644
--- a/dev/tests/functional/tests/app/Magento/Reports/Test/Block/Adminhtml/Sales/TaxRule/Filter.xml
+++ b/dev/tests/functional/tests/app/Magento/Reports/Test/Block/Adminhtml/Sales/TaxRule/Filter.xml
@@ -23,7 +23,7 @@
select
- [name="order_statuses[0]"]
+ [name="order_statuses[]"]
multiselect
diff --git a/dev/tests/functional/tests/app/Magento/Review/Test/Block/Adminhtml/Rating/Edit/RatingForm.xml b/dev/tests/functional/tests/app/Magento/Review/Test/Block/Adminhtml/Rating/Edit/RatingForm.xml
index 504ce64bf2a73..3e1a1c727c668 100644
--- a/dev/tests/functional/tests/app/Magento/Review/Test/Block/Adminhtml/Rating/Edit/RatingForm.xml
+++ b/dev/tests/functional/tests/app/Magento/Review/Test/Block/Adminhtml/Rating/Edit/RatingForm.xml
@@ -12,7 +12,7 @@
css selector
- [name="stores[0]"]
+ [name="stores[]"]
multiselectgrouplist
diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Report/Filter/Form.xml b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Report/Filter/Form.xml
index 294f64966bde9..d868798eba79d 100644
--- a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Report/Filter/Form.xml
+++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Report/Filter/Form.xml
@@ -26,7 +26,7 @@
select
- [name="order_statuses[0]"]
+ [name="order_statuses[]"]
multiselect
diff --git a/lib/web/mage/validation.js b/lib/web/mage/validation.js
index b284f0002bc66..55921c054e61a 100644
--- a/lib/web/mage/validation.js
+++ b/lib/web/mage/validation.js
@@ -1925,7 +1925,6 @@
* @protected
*/
_create: function () {
- this._prepareArrayInputs();
this.validate = this.element.validate(this.options);
// ARIA (adding aria-required attribute)
@@ -1938,50 +1937,6 @@
this._listenFormValidate();
},
- /**
- * Validation creation.
- *
- * @protected
- */
- _prepareArrayInputs: function () {
- /* Store original names for array inputs */
- var originalElements = [],
- originalSubmitHandler = this.options.submitHandler;
-
- /* For all array inputs, assign index so that validation is proper */
- this.element.find('[name$="[]"]').each(function (key, input) {
- var originalName, name;
-
- input = $(input);
- originalName = input.attr('name');
- name = originalName.replace('[]', '[' + key + ']');
- $(input).attr('name', name);
- $(input).attr('orig-name', originalName);
- originalElements.push({
- element: $(input),
- name: originalName
- });
- });
-
- if (originalElements.length) {
- /**
- * Before submitting the actual form, remove the previously assigned indices
- * @param {Object} form
- */
- this.options.submitHandler = function (form) {
- originalElements.forEach(function (element) {
- element.element.attr('name', element.name);
- element.element.removeAttr('orig-name');
- });
-
- console.error(this.submit);
-
- /* Call the originalSubmitHandler if it's a function */
- typeof originalSubmitHandler === 'function' ? originalSubmitHandler(form) : form.submit();
- };
- }
- },
-
/**
* Validation listening.
*
diff --git a/lib/web/mage/validation/validation.js b/lib/web/mage/validation/validation.js
index 69cb984b0d82d..74b00e34e9160 100644
--- a/lib/web/mage/validation/validation.js
+++ b/lib/web/mage/validation/validation.js
@@ -49,23 +49,17 @@
'validate-one-checkbox-required-by-name': [
function (value, element, params) {
var checkedCount = 0,
- selector,
- container,
- origNameSelector,
- nameSelector;
+ container;
if (element.type === 'checkbox') {
- /* If orig-name attribute is present, use it for validation. Else use name */
- origNameSelector = '[orig-name="' + element.getAttribute('orig-name') + '"]';
- nameSelector = '[name="' + element.name + '"]';
- selector = element.getAttribute('orig-name') ? origNameSelector : nameSelector;
- $(selector).each(function () {
- if ($(this).is(':checked')) {
- checkedCount += 1;
-
- return false;
+ $('[name="' + element.name + '"]').each(
+ function () {
+ if ($(this).is(':checked')) {
+ checkedCount += 1;
+ return false;
+ }
}
- });
+ );
}
container = '#' + params;
From 6993da4ebf8d30a5ef278e5a3c233985ebdbb02d Mon Sep 17 00:00:00 2001
From: Max Lesechko
Date: Wed, 28 Aug 2019 11:41:53 -0500
Subject: [PATCH 110/937] MC-19684: Some minute values cannot be set for
Analytics data collection
---
lib/web/mage/validation/validation.js | 1 +
1 file changed, 1 insertion(+)
diff --git a/lib/web/mage/validation/validation.js b/lib/web/mage/validation/validation.js
index 74b00e34e9160..0f2c4c06b119b 100644
--- a/lib/web/mage/validation/validation.js
+++ b/lib/web/mage/validation/validation.js
@@ -56,6 +56,7 @@
function () {
if ($(this).is(':checked')) {
checkedCount += 1;
+
return false;
}
}
From efd076e6f9417ee1799c69383d8d914f9c40d240 Mon Sep 17 00:00:00 2001
From: Krissy Hiserote
Date: Wed, 28 Aug 2019 15:08:41 -0500
Subject: [PATCH 111/937] MC-16650: Product Attribute Type Price Not Displaying
- fix test failures
---
.../Test/Unit/Model/Layer/FilterListTest.php | 10 ++++--
.../LayerNavigationOfCatalogSearchTest.xml | 2 +-
.../attribute_special_price_filterable.php | 2 +-
.../_files/multiple_visible_products.php | 32 ++++++++++++++++---
.../multiple_visible_products_rollback.php | 7 ++++
.../Model/Layer/Filter/DecimalTest.php | 2 +-
6 files changed, 45 insertions(+), 10 deletions(-)
diff --git a/app/code/Magento/Catalog/Test/Unit/Model/Layer/FilterListTest.php b/app/code/Magento/Catalog/Test/Unit/Model/Layer/FilterListTest.php
index 6943bc27fd77c..731c5efd99746 100644
--- a/app/code/Magento/Catalog/Test/Unit/Model/Layer/FilterListTest.php
+++ b/app/code/Magento/Catalog/Test/Unit/Model/Layer/FilterListTest.php
@@ -73,9 +73,13 @@ public function testGetFilters($method, $value, $expectedClass)
$this->objectManagerMock->expects($this->at(1))
->method('create')
- ->with($expectedClass, [
- 'data' => ['attribute_model' => $this->attributeMock],
- 'layer' => $this->layerMock])
+ ->with(
+ $expectedClass,
+ [
+ 'data' => ['attribute_model' => $this->attributeMock],
+ 'layer' => $this->layerMock
+ ]
+ )
->will($this->returnValue('filter'));
$this->attributeMock->expects($this->once())
diff --git a/app/code/Magento/CatalogSearch/Test/Mftf/Test/LayerNavigationOfCatalogSearchTest.xml b/app/code/Magento/CatalogSearch/Test/Mftf/Test/LayerNavigationOfCatalogSearchTest.xml
index e91fb9b7a55cc..210b474af2e02 100644
--- a/app/code/Magento/CatalogSearch/Test/Mftf/Test/LayerNavigationOfCatalogSearchTest.xml
+++ b/app/code/Magento/CatalogSearch/Test/Mftf/Test/LayerNavigationOfCatalogSearchTest.xml
@@ -14,7 +14,7 @@
-
+
diff --git a/dev/tests/integration/testsuite/Magento/Catalog/Model/Layer/Filter/_files/attribute_special_price_filterable.php b/dev/tests/integration/testsuite/Magento/Catalog/Model/Layer/Filter/_files/attribute_special_price_filterable.php
index 3c92db99cd4f1..eedff7aaefb1d 100644
--- a/dev/tests/integration/testsuite/Magento/Catalog/Model/Layer/Filter/_files/attribute_special_price_filterable.php
+++ b/dev/tests/integration/testsuite/Magento/Catalog/Model/Layer/Filter/_files/attribute_special_price_filterable.php
@@ -9,4 +9,4 @@
\Magento\Catalog\Setup\CategorySetup::class
);
-$installer->updateAttribute('catalog_product', 'special_price', 'is_filterable', 1);
\ No newline at end of file
+$installer->updateAttribute('catalog_product', 'special_price', 'is_filterable', 1);
diff --git a/dev/tests/integration/testsuite/Magento/Catalog/_files/multiple_visible_products.php b/dev/tests/integration/testsuite/Magento/Catalog/_files/multiple_visible_products.php
index 4ace41d23c872..f5c22c570911f 100644
--- a/dev/tests/integration/testsuite/Magento/Catalog/_files/multiple_visible_products.php
+++ b/dev/tests/integration/testsuite/Magento/Catalog/_files/multiple_visible_products.php
@@ -4,6 +4,30 @@
* See COPYING.txt for license details.
*/
+$category = \Magento\TestFramework\Helper\Bootstrap::getObjectManager()->create(\Magento\Catalog\Model\Category::class);
+$category->isObjectNew(true);
+$category->setId(
+ 100
+)->setCreatedAt(
+ '2014-06-23 09:50:07'
+)->setName(
+ 'Category 100'
+)->setParentId(
+ 2
+)->setPath(
+ '1/2/100'
+)->setLevel(
+ 2
+)->setAvailableSortBy(
+ ['position', 'name']
+)->setDefaultSortBy(
+ 'name'
+)->setIsActive(
+ true
+)->setPosition(
+ 1
+)->save();
+
/** @var $product \Magento\Catalog\Model\Product */
$product = \Magento\TestFramework\Helper\Bootstrap::getObjectManager()->create(\Magento\Catalog\Model\Product::class);
$product->isObjectNew(true);
@@ -25,7 +49,7 @@
->setVisibility(\Magento\Catalog\Model\Product\Visibility::VISIBILITY_BOTH)
->setStatus(\Magento\Catalog\Model\Product\Attribute\Source\Status::STATUS_ENABLED)
->setWebsiteIds([1])
- ->setCategoryIds([2])
+ ->setCategoryIds([100])
->setStockData(['use_config_manage_stock' => 1, 'qty' => 100, 'is_qty_decimal' => 0, 'is_in_stock' => 1])
->setSpecialPrice('10')
->save();
@@ -50,7 +74,7 @@
->setVisibility(\Magento\Catalog\Model\Product\Visibility::VISIBILITY_BOTH)
->setStatus(\Magento\Catalog\Model\Product\Attribute\Source\Status::STATUS_ENABLED)
->setWebsiteIds([1])
- ->setCategoryIds([2])
+ ->setCategoryIds([100])
->setStockData(['use_config_manage_stock' => 1, 'qty' => 50, 'is_qty_decimal' => 0, 'is_in_stock' => 1])
->setSpecialPrice('20')
->save();
@@ -70,7 +94,7 @@
->setVisibility(\Magento\Catalog\Model\Product\Visibility::VISIBILITY_BOTH)
->setStatus(\Magento\Catalog\Model\Product\Attribute\Source\Status::STATUS_ENABLED)
->setWebsiteIds([1])
- ->setCategoryIds([2])
+ ->setCategoryIds([100])
->setStockData(['use_config_manage_stock' => 1, 'qty' => 140, 'is_qty_decimal' => 0, 'is_in_stock' => 1])
->setSpecialPrice('30')
- ->save();
+ ->save();
\ No newline at end of file
diff --git a/dev/tests/integration/testsuite/Magento/Catalog/_files/multiple_visible_products_rollback.php b/dev/tests/integration/testsuite/Magento/Catalog/_files/multiple_visible_products_rollback.php
index a9155d3fadf0b..76876c39b7d72 100644
--- a/dev/tests/integration/testsuite/Magento/Catalog/_files/multiple_visible_products_rollback.php
+++ b/dev/tests/integration/testsuite/Magento/Catalog/_files/multiple_visible_products_rollback.php
@@ -12,6 +12,13 @@
$registry->unregister('isSecureArea');
$registry->register('isSecureArea', true);
+/** @var $category \Magento\Catalog\Model\Category */
+$category = \Magento\TestFramework\Helper\Bootstrap::getObjectManager()->create(\Magento\Catalog\Model\Category::class);
+$category->load(100);
+if ($category->getId()) {
+ $category->delete();
+}
+
/** @var \Magento\Catalog\Api\ProductRepositoryInterface $productRepository */
$productRepository = $objectManager->create(\Magento\Catalog\Api\ProductRepositoryInterface::class);
diff --git a/dev/tests/integration/testsuite/Magento/CatalogSearch/Model/Layer/Filter/DecimalTest.php b/dev/tests/integration/testsuite/Magento/CatalogSearch/Model/Layer/Filter/DecimalTest.php
index 33dea3ea37179..63973ac0fbe20 100644
--- a/dev/tests/integration/testsuite/Magento/CatalogSearch/Model/Layer/Filter/DecimalTest.php
+++ b/dev/tests/integration/testsuite/Magento/CatalogSearch/Model/Layer/Filter/DecimalTest.php
@@ -61,7 +61,7 @@ public function testApplyProductCollection()
/** @var $objectManager \Magento\TestFramework\ObjectManager */
$objectManager = \Magento\TestFramework\Helper\Bootstrap::getObjectManager();
$category = $objectManager->create(\Magento\Catalog\Model\Category::class);
- $category->load(2);
+ $category->load(100);
$this->_model->getLayer()->setCurrentCategory($category);
/** @var $attribute \Magento\Catalog\Model\Entity\Attribute */
From f29efd3e44ecbf424d9e3126f3b968b286abff5e Mon Sep 17 00:00:00 2001
From: RomanKis
Date: Thu, 29 Aug 2019 13:29:25 +0300
Subject: [PATCH 112/937] graphQl-509: `save_in_address_book` has no impact on
Address Book
---
.../SaveQuoteAddressToCustomerAddressBook.php | 95 +++++++++++++++++++
.../Model/Cart/SetBillingAddressOnCart.php | 18 +++-
.../Model/Cart/SetShippingAddressesOnCart.php | 20 +++-
.../Magento/QuoteGraphQl/etc/schema.graphqls | 2 +-
4 files changed, 131 insertions(+), 4 deletions(-)
create mode 100644 app/code/Magento/QuoteGraphQl/Model/Cart/Address/SaveQuoteAddressToCustomerAddressBook.php
diff --git a/app/code/Magento/QuoteGraphQl/Model/Cart/Address/SaveQuoteAddressToCustomerAddressBook.php b/app/code/Magento/QuoteGraphQl/Model/Cart/Address/SaveQuoteAddressToCustomerAddressBook.php
new file mode 100644
index 0000000000000..e9aa4ba745b9f
--- /dev/null
+++ b/app/code/Magento/QuoteGraphQl/Model/Cart/Address/SaveQuoteAddressToCustomerAddressBook.php
@@ -0,0 +1,95 @@
+addressFactory = $addressFactory;
+ $this->addressRepository = $addressRepository;
+ $this->regionFactory = $regionFactory;
+ }
+
+ /**
+ *
+ * @param QuoteAddress $quoteAddress
+ * @param int $customerId
+ *
+ * @return void
+ * @throws GraphQlInputException
+ */
+ public function execute(QuoteAddress $quoteAddress, int $customerId): void
+ {
+ try {
+ /** @var AddressInterface $customerAddress */
+ $customerAddress = $this->addressFactory->create();
+ $customerAddress->setFirstname($quoteAddress->getFirstname())
+ ->setLastname($quoteAddress->getLastname())
+ ->setMiddlename($quoteAddress->getMiddlename())
+ ->setPrefix($quoteAddress->getPrefix())
+ ->setSuffix($quoteAddress->getSuffix())
+ ->setVatId($quoteAddress->getVatId())
+ ->setCountryId($quoteAddress->getCountryId())
+ ->setCompany($quoteAddress->getCompany())
+ ->setRegionId($quoteAddress->getRegionId())
+ ->setFax($quoteAddress->getFax())
+ ->setCity($quoteAddress->getCity())
+ ->setPostcode($quoteAddress->getPostcode())
+ ->setStreet($quoteAddress->getStreet())
+ ->setTelephone($quoteAddress->getTelephone())
+ ->setCustomerId($customerId);
+
+ /** @var RegionInterface $region */
+ $region = $this->regionFactory->create();
+ $region->setRegionCode($quoteAddress->getRegionCode())
+ ->setRegion($quoteAddress->getRegion())
+ ->setRegionId($quoteAddress->getRegionId());
+ $customerAddress->setRegion($region);
+
+ $this->addressRepository->save($customerAddress);
+ } catch (LocalizedException $e) {
+ throw new GraphQlInputException(__($e->getMessage()), $e);
+ }
+ }
+}
diff --git a/app/code/Magento/QuoteGraphQl/Model/Cart/SetBillingAddressOnCart.php b/app/code/Magento/QuoteGraphQl/Model/Cart/SetBillingAddressOnCart.php
index 673debefd0874..22dff2d5550ba 100644
--- a/app/code/Magento/QuoteGraphQl/Model/Cart/SetBillingAddressOnCart.php
+++ b/app/code/Magento/QuoteGraphQl/Model/Cart/SetBillingAddressOnCart.php
@@ -13,6 +13,7 @@
use Magento\GraphQl\Model\Query\ContextInterface;
use Magento\Quote\Api\Data\CartInterface;
use Magento\Quote\Model\Quote\Address;
+use Magento\QuoteGraphQl\Model\Cart\Address\SaveQuoteAddressToCustomerAddressBook;
/**
* Set billing address for a specified shopping cart
@@ -29,16 +30,24 @@ class SetBillingAddressOnCart
*/
private $assignBillingAddressToCart;
+ /**
+ * @var SaveQuoteAddressToCustomerAddressBook
+ */
+ private $saveQuoteAddressToCustomerAddressBook;
+
/**
* @param QuoteAddressFactory $quoteAddressFactory
* @param AssignBillingAddressToCart $assignBillingAddressToCart
+ * @param SaveQuoteAddressToCustomerAddressBook $saveQuoteAddressToCustomerAddressBook
*/
public function __construct(
QuoteAddressFactory $quoteAddressFactory,
- AssignBillingAddressToCart $assignBillingAddressToCart
+ AssignBillingAddressToCart $assignBillingAddressToCart,
+ SaveQuoteAddressToCustomerAddressBook $saveQuoteAddressToCustomerAddressBook
) {
$this->quoteAddressFactory = $quoteAddressFactory;
$this->assignBillingAddressToCart = $assignBillingAddressToCart;
+ $this->saveQuoteAddressToCustomerAddressBook = $saveQuoteAddressToCustomerAddressBook;
}
/**
@@ -101,6 +110,12 @@ private function createBillingAddress(
): Address {
if (null === $customerAddressId) {
$billingAddress = $this->quoteAddressFactory->createBasedOnInputData($addressInput);
+
+ $customerId = $context->getUserId();
+ // need to save address only for registered user and if save_in_address_book = true
+ if (0 !== $customerId && !empty($addressInput['save_in_address_book'])) {
+ $this->saveQuoteAddressToCustomerAddressBook->execute($billingAddress, $customerId);
+ }
} else {
if (false === $context->getExtensionAttributes()->getIsCustomer()) {
throw new GraphQlAuthorizationException(__('The current customer isn\'t authorized.'));
@@ -111,6 +126,7 @@ private function createBillingAddress(
(int)$context->getUserId()
);
}
+
return $billingAddress;
}
}
diff --git a/app/code/Magento/QuoteGraphQl/Model/Cart/SetShippingAddressesOnCart.php b/app/code/Magento/QuoteGraphQl/Model/Cart/SetShippingAddressesOnCart.php
index 77719bed5b16f..c3d147bb4727b 100644
--- a/app/code/Magento/QuoteGraphQl/Model/Cart/SetShippingAddressesOnCart.php
+++ b/app/code/Magento/QuoteGraphQl/Model/Cart/SetShippingAddressesOnCart.php
@@ -11,6 +11,7 @@
use Magento\Framework\GraphQl\Exception\GraphQlInputException;
use Magento\GraphQl\Model\Query\ContextInterface;
use Magento\Quote\Api\Data\CartInterface;
+use Magento\QuoteGraphQl\Model\Cart\Address\SaveQuoteAddressToCustomerAddressBook;
/**
* Set single shipping address for a specified shopping cart
@@ -27,16 +28,24 @@ class SetShippingAddressesOnCart implements SetShippingAddressesOnCartInterface
*/
private $assignShippingAddressToCart;
+ /**
+ * @var SaveQuoteAddressToCustomerAddressBook
+ */
+ private $saveQuoteAddressToCustomerAddressBook;
+
/**
* @param QuoteAddressFactory $quoteAddressFactory
* @param AssignShippingAddressToCart $assignShippingAddressToCart
+ * @param SaveQuoteAddressToCustomerAddressBook $saveQuoteAddressToCustomerAddressBook
*/
public function __construct(
QuoteAddressFactory $quoteAddressFactory,
- AssignShippingAddressToCart $assignShippingAddressToCart
+ AssignShippingAddressToCart $assignShippingAddressToCart,
+ SaveQuoteAddressToCustomerAddressBook $saveQuoteAddressToCustomerAddressBook
) {
$this->quoteAddressFactory = $quoteAddressFactory;
$this->assignShippingAddressToCart = $assignShippingAddressToCart;
+ $this->saveQuoteAddressToCustomerAddressBook = $saveQuoteAddressToCustomerAddressBook;
}
/**
@@ -65,8 +74,15 @@ public function execute(ContextInterface $context, CartInterface $cart, array $s
);
}
+ $customerId = $context->getUserId();
+
if (null === $customerAddressId) {
$shippingAddress = $this->quoteAddressFactory->createBasedOnInputData($addressInput);
+
+ // need to save address only for registered user and if save_in_address_book = true
+ if (0 !== $customerId && !empty($addressInput['save_in_address_book'])) {
+ $this->saveQuoteAddressToCustomerAddressBook->execute($shippingAddress, $customerId);
+ }
} else {
if (false === $context->getExtensionAttributes()->getIsCustomer()) {
throw new GraphQlAuthorizationException(__('The current customer isn\'t authorized.'));
@@ -74,7 +90,7 @@ public function execute(ContextInterface $context, CartInterface $cart, array $s
$shippingAddress = $this->quoteAddressFactory->createBasedOnCustomerAddress(
(int)$customerAddressId,
- $context->getUserId()
+ $customerId
);
}
diff --git a/app/code/Magento/QuoteGraphQl/etc/schema.graphqls b/app/code/Magento/QuoteGraphQl/etc/schema.graphqls
index 6d7f4daf40ded..b9199a0774c27 100644
--- a/app/code/Magento/QuoteGraphQl/etc/schema.graphqls
+++ b/app/code/Magento/QuoteGraphQl/etc/schema.graphqls
@@ -108,7 +108,7 @@ input CartAddressInput {
postcode: String
country_code: String!
telephone: String!
- save_in_address_book: Boolean!
+ save_in_address_book: Boolean
}
input SetShippingMethodsOnCartInput {
From 883d9f52e1b360b5c3c3b9b9f0a7f512531dfe83 Mon Sep 17 00:00:00 2001
From: Oleksii Lisovyi
Date: Thu, 29 Aug 2019 15:25:58 +0300
Subject: [PATCH 113/937] Sales - fix displaying available allowed countries
while editing order address in Admin panel
- fixed unit test
---
.../Test/Unit/Block/Adminhtml/Order/Address/FormTest.php | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/app/code/Magento/Sales/Test/Unit/Block/Adminhtml/Order/Address/FormTest.php b/app/code/Magento/Sales/Test/Unit/Block/Adminhtml/Order/Address/FormTest.php
index 94148cc515382..2b08daf02134e 100644
--- a/app/code/Magento/Sales/Test/Unit/Block/Adminhtml/Order/Address/FormTest.php
+++ b/app/code/Magento/Sales/Test/Unit/Block/Adminhtml/Order/Address/FormTest.php
@@ -95,6 +95,11 @@ protected function setUp()
'_orderCreate' => $this->orderCreate
]
);
+
+ // Do not display VAT validation button on edit order address form
+ // Emulate fix done in controller
+ /** @see \Magento\Sales\Controller\Adminhtml\Order\Address::execute */
+ $this->addressBlock->setDisplayVatValidationButton(false);
}
public function testGetForm()
From 26653c9bf1b8eede1f58fbe471fdaf34e20a5cca Mon Sep 17 00:00:00 2001
From: Veronika Kurochkina
Date: Wed, 28 Aug 2019 15:52:11 +0300
Subject: [PATCH 114/937] MAGETWO-44170: Not pass function test
\Magento\Catalog\Test\TestCase\Product\ProductTypeSwitchingOnUpdateTest
- Fix modularity issue
---
...AdminProductTypeSwitchingOnEditingTest.xml | 52 +-----------
...AdminProductTypeSwitchingOnEditingTest.xml | 76 ++----------------
...AdminProductTypeSwitchingOnEditingTest.xml | 79 +++++++++++++++++++
3 files changed, 88 insertions(+), 119 deletions(-)
create mode 100644 app/code/Magento/Downloadable/Test/Mftf/Test/AdminProductTypeSwitchingOnEditingTest.xml
diff --git a/app/code/Magento/Catalog/Test/Mftf/Test/AdminProductTypeSwitchingOnEditingTest.xml b/app/code/Magento/Catalog/Test/Mftf/Test/AdminProductTypeSwitchingOnEditingTest.xml
index 45f404478809a..42623f43d4e82 100644
--- a/app/code/Magento/Catalog/Test/Mftf/Test/AdminProductTypeSwitchingOnEditingTest.xml
+++ b/app/code/Magento/Catalog/Test/Mftf/Test/AdminProductTypeSwitchingOnEditingTest.xml
@@ -11,6 +11,7 @@
+
@@ -61,6 +62,7 @@
+
@@ -91,54 +93,4 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/app/code/Magento/ConfigurableProduct/Test/Mftf/Test/AdminProductTypeSwitchingOnEditingTest.xml b/app/code/Magento/ConfigurableProduct/Test/Mftf/Test/AdminProductTypeSwitchingOnEditingTest.xml
index 071ee8d18920f..8253dcf58f9fd 100644
--- a/app/code/Magento/ConfigurableProduct/Test/Mftf/Test/AdminProductTypeSwitchingOnEditingTest.xml
+++ b/app/code/Magento/ConfigurableProduct/Test/Mftf/Test/AdminProductTypeSwitchingOnEditingTest.xml
@@ -11,6 +11,7 @@
+
@@ -60,8 +61,8 @@
-
-
+
+
@@ -75,6 +76,7 @@
+
@@ -113,6 +115,7 @@
+
@@ -163,8 +166,8 @@
-
-
+
+
@@ -175,69 +178,4 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/app/code/Magento/Downloadable/Test/Mftf/Test/AdminProductTypeSwitchingOnEditingTest.xml b/app/code/Magento/Downloadable/Test/Mftf/Test/AdminProductTypeSwitchingOnEditingTest.xml
new file mode 100644
index 0000000000000..80e86ab4d747c
--- /dev/null
+++ b/app/code/Magento/Downloadable/Test/Mftf/Test/AdminProductTypeSwitchingOnEditingTest.xml
@@ -0,0 +1,79 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
From c4ea11883671af962804a233e8dc1c08360034a9 Mon Sep 17 00:00:00 2001
From: Krissy Hiserote
Date: Thu, 29 Aug 2019 09:26:13 -0500
Subject: [PATCH 115/937] MC-16650: Product Attribute Type Price Not Displaying
- remove decimal filter integration test
---
.../attribute_special_price_filterable.php | 12 ---
.../_files/multiple_visible_products.php | 100 ------------------
.../multiple_visible_products_rollback.php | 35 ------
.../Model/Layer/Filter/DecimalTest.php | 36 +------
4 files changed, 1 insertion(+), 182 deletions(-)
delete mode 100644 dev/tests/integration/testsuite/Magento/Catalog/Model/Layer/Filter/_files/attribute_special_price_filterable.php
delete mode 100644 dev/tests/integration/testsuite/Magento/Catalog/_files/multiple_visible_products.php
delete mode 100644 dev/tests/integration/testsuite/Magento/Catalog/_files/multiple_visible_products_rollback.php
diff --git a/dev/tests/integration/testsuite/Magento/Catalog/Model/Layer/Filter/_files/attribute_special_price_filterable.php b/dev/tests/integration/testsuite/Magento/Catalog/Model/Layer/Filter/_files/attribute_special_price_filterable.php
deleted file mode 100644
index eedff7aaefb1d..0000000000000
--- a/dev/tests/integration/testsuite/Magento/Catalog/Model/Layer/Filter/_files/attribute_special_price_filterable.php
+++ /dev/null
@@ -1,12 +0,0 @@
-create(
- \Magento\Catalog\Setup\CategorySetup::class
-);
-
-$installer->updateAttribute('catalog_product', 'special_price', 'is_filterable', 1);
diff --git a/dev/tests/integration/testsuite/Magento/Catalog/_files/multiple_visible_products.php b/dev/tests/integration/testsuite/Magento/Catalog/_files/multiple_visible_products.php
deleted file mode 100644
index f5c22c570911f..0000000000000
--- a/dev/tests/integration/testsuite/Magento/Catalog/_files/multiple_visible_products.php
+++ /dev/null
@@ -1,100 +0,0 @@
-create(\Magento\Catalog\Model\Category::class);
-$category->isObjectNew(true);
-$category->setId(
- 100
-)->setCreatedAt(
- '2014-06-23 09:50:07'
-)->setName(
- 'Category 100'
-)->setParentId(
- 2
-)->setPath(
- '1/2/100'
-)->setLevel(
- 2
-)->setAvailableSortBy(
- ['position', 'name']
-)->setDefaultSortBy(
- 'name'
-)->setIsActive(
- true
-)->setPosition(
- 1
-)->save();
-
-/** @var $product \Magento\Catalog\Model\Product */
-$product = \Magento\TestFramework\Helper\Bootstrap::getObjectManager()->create(\Magento\Catalog\Model\Product::class);
-$product->isObjectNew(true);
-$product->setTypeId(\Magento\Catalog\Model\Product\Type::TYPE_SIMPLE)
- ->setId(10)
- ->setAttributeSetId(4)
- ->setName('Simple Product1')
- ->setSku('simple1')
- ->setTaxClassId('none')
- ->setDescription('description')
- ->setShortDescription('short description')
- ->setOptionsContainer('container1')
- ->setMsrpDisplayActualPriceType(\Magento\Msrp\Model\Product\Attribute\Source\Type::TYPE_IN_CART)
- ->setPrice(15)
- ->setWeight(10)
- ->setMetaTitle('meta title')
- ->setMetaKeyword('meta keyword')
- ->setMetaDescription('meta description')
- ->setVisibility(\Magento\Catalog\Model\Product\Visibility::VISIBILITY_BOTH)
- ->setStatus(\Magento\Catalog\Model\Product\Attribute\Source\Status::STATUS_ENABLED)
- ->setWebsiteIds([1])
- ->setCategoryIds([100])
- ->setStockData(['use_config_manage_stock' => 1, 'qty' => 100, 'is_qty_decimal' => 0, 'is_in_stock' => 1])
- ->setSpecialPrice('10')
- ->save();
-
-$product = \Magento\TestFramework\Helper\Bootstrap::getObjectManager()->create(\Magento\Catalog\Model\Product::class);
-$product->isObjectNew(true);
-$product->setTypeId(\Magento\Catalog\Model\Product\Type::TYPE_SIMPLE)
- ->setId(11)
- ->setAttributeSetId(4)
- ->setName('Simple Product2')
- ->setSku('simple2')
- ->setTaxClassId('none')
- ->setDescription('description')
- ->setShortDescription('short description')
- ->setOptionsContainer('container1')
- ->setMsrpDisplayActualPriceType(\Magento\Msrp\Model\Product\Attribute\Source\Type::TYPE_ON_GESTURE)
- ->setPrice(25)
- ->setWeight(20)
- ->setMetaTitle('meta title')
- ->setMetaKeyword('meta keyword')
- ->setMetaDescription('meta description')
- ->setVisibility(\Magento\Catalog\Model\Product\Visibility::VISIBILITY_BOTH)
- ->setStatus(\Magento\Catalog\Model\Product\Attribute\Source\Status::STATUS_ENABLED)
- ->setWebsiteIds([1])
- ->setCategoryIds([100])
- ->setStockData(['use_config_manage_stock' => 1, 'qty' => 50, 'is_qty_decimal' => 0, 'is_in_stock' => 1])
- ->setSpecialPrice('20')
- ->save();
-
-$product = \Magento\TestFramework\Helper\Bootstrap::getObjectManager()->create(\Magento\Catalog\Model\Product::class);
-$product->isObjectNew(true);
-$product->setTypeId(\Magento\Catalog\Model\Product\Type::TYPE_SIMPLE)
- ->setId(12)
- ->setAttributeSetId(4)
- ->setName('Simple Product3')
- ->setSku('simple3')
- ->setTaxClassId('none')
- ->setDescription('description')
- ->setShortDescription('short description')
- ->setPrice(35)
- ->setWeight(30)
- ->setVisibility(\Magento\Catalog\Model\Product\Visibility::VISIBILITY_BOTH)
- ->setStatus(\Magento\Catalog\Model\Product\Attribute\Source\Status::STATUS_ENABLED)
- ->setWebsiteIds([1])
- ->setCategoryIds([100])
- ->setStockData(['use_config_manage_stock' => 1, 'qty' => 140, 'is_qty_decimal' => 0, 'is_in_stock' => 1])
- ->setSpecialPrice('30')
- ->save();
\ No newline at end of file
diff --git a/dev/tests/integration/testsuite/Magento/Catalog/_files/multiple_visible_products_rollback.php b/dev/tests/integration/testsuite/Magento/Catalog/_files/multiple_visible_products_rollback.php
deleted file mode 100644
index 76876c39b7d72..0000000000000
--- a/dev/tests/integration/testsuite/Magento/Catalog/_files/multiple_visible_products_rollback.php
+++ /dev/null
@@ -1,35 +0,0 @@
-get(\Magento\Framework\Registry::class);
-
-$registry->unregister('isSecureArea');
-$registry->register('isSecureArea', true);
-
-/** @var $category \Magento\Catalog\Model\Category */
-$category = \Magento\TestFramework\Helper\Bootstrap::getObjectManager()->create(\Magento\Catalog\Model\Category::class);
-$category->load(100);
-if ($category->getId()) {
- $category->delete();
-}
-
-/** @var \Magento\Catalog\Api\ProductRepositoryInterface $productRepository */
-$productRepository = $objectManager->create(\Magento\Catalog\Api\ProductRepositoryInterface::class);
-
-foreach (['simple1', 'simple2', 'simple3'] as $sku) {
- try {
- $product = $productRepository->get($sku, false, null, true);
- $productRepository->delete($product);
- } catch (\Magento\Framework\Exception\NoSuchEntityException $exception) {
- //Product already removed
- }
-}
-
-$registry->unregister('isSecureArea');
-$registry->register('isSecureArea', false);
diff --git a/dev/tests/integration/testsuite/Magento/CatalogSearch/Model/Layer/Filter/DecimalTest.php b/dev/tests/integration/testsuite/Magento/CatalogSearch/Model/Layer/Filter/DecimalTest.php
index 63973ac0fbe20..b75a984178f24 100644
--- a/dev/tests/integration/testsuite/Magento/CatalogSearch/Model/Layer/Filter/DecimalTest.php
+++ b/dev/tests/integration/testsuite/Magento/CatalogSearch/Model/Layer/Filter/DecimalTest.php
@@ -48,41 +48,7 @@ protected function setUp()
->create(\Magento\CatalogSearch\Model\Layer\Filter\Decimal::class, ['layer' => $layer]);
$this->_model->setAttributeModel($attribute);
}
-
- /**
- * Test the product collection returns the correct number of items after the filter is applied.
- *
- * @magentoDataFixture Magento/Catalog/Model/Layer/Filter/_files/attribute_special_price_filterable.php
- * @magentoDataFixture Magento/Catalog/_files/multiple_visible_products.php
- * @magentoDbIsolation disabled
- */
- public function testApplyProductCollection()
- {
- /** @var $objectManager \Magento\TestFramework\ObjectManager */
- $objectManager = \Magento\TestFramework\Helper\Bootstrap::getObjectManager();
- $category = $objectManager->create(\Magento\Catalog\Model\Category::class);
- $category->load(100);
- $this->_model->getLayer()->setCurrentCategory($category);
-
- /** @var $attribute \Magento\Catalog\Model\Entity\Attribute */
- $attribute = $objectManager->create(\Magento\Catalog\Model\Entity\Attribute::class);
- $attribute->loadByCode('catalog_product', 'special_price');
- $this->_model->setAttributeModel($attribute);
-
- /** @var $objectManager \Magento\TestFramework\ObjectManager */
- $objectManager = \Magento\TestFramework\Helper\Bootstrap::getObjectManager();
- /** @var $request \Magento\TestFramework\Request */
- $request = $objectManager->get(\Magento\TestFramework\Request::class);
- $request->setParam('special_price', '10-20');
- $result = $this->_model->apply($request);
- $collection = $this->_model->getLayer()->getProductCollection();
- $size = $collection->getSize();
- $this->assertEquals(
- 1,
- $size
- );
- }
-
+
/**
* Test the filter label is correct
*/
From 91f8f886b47578956a6059c8b4273e5800fc213c Mon Sep 17 00:00:00 2001
From: Rus0
Date: Thu, 29 Aug 2019 16:43:06 -0500
Subject: [PATCH 116/937] adding backward compatibility in constructor
---
app/code/Magento/Wishlist/Model/Wishlist.php | 14 ++++++++------
1 file changed, 8 insertions(+), 6 deletions(-)
diff --git a/app/code/Magento/Wishlist/Model/Wishlist.php b/app/code/Magento/Wishlist/Model/Wishlist.php
index 0d9c74edb3d4c..827607e72f807 100644
--- a/app/code/Magento/Wishlist/Model/Wishlist.php
+++ b/app/code/Magento/Wishlist/Model/Wishlist.php
@@ -175,11 +175,11 @@ class Wishlist extends AbstractModel implements IdentityInterface
* @param Random $mathRandom
* @param DateTime $dateTime
* @param ProductRepositoryInterface $productRepository
- * @param StockItemRepository $stockItemRepository
- * @param ScopeConfigInterface|null $scopeConfig
* @param bool $useCurrentWebsite
* @param array $data
* @param Json|null $serializer
+ * @param StockItemRepository|null $stockItemRepository
+ * @param ScopeConfigInterface|null $scopeConfig
* @SuppressWarnings(PHPMD.ExcessiveParameterList)
*/
public function __construct(
@@ -197,11 +197,11 @@ public function __construct(
Random $mathRandom,
DateTime $dateTime,
ProductRepositoryInterface $productRepository,
- StockItemRepository $stockItemRepository,
- ScopeConfigInterface $scopeConfig = null,
$useCurrentWebsite = true,
array $data = [],
- Json $serializer = null
+ Json $serializer = null,
+ StockItemRepository $stockItemRepository = null,
+ ScopeConfigInterface $scopeConfig = null
) {
$this->_useCurrentWebsite = $useCurrentWebsite;
$this->_catalogProduct = $catalogProduct;
@@ -216,7 +216,9 @@ public function __construct(
$this->serializer = $serializer ?: ObjectManager::getInstance()->get(Json::class);
parent::__construct($context, $registry, $resource, $resourceCollection, $data);
$this->productRepository = $productRepository;
- $this->stockItemRepository = $stockItemRepository;
+ $this->stockItemRepository = $stockItemRepository ?: ObjectManager::getInstance()->get(
+ StockItemRepository::class
+ );
$this->scopeConfig = $scopeConfig ?: ObjectManager::getInstance()->get(ScopeConfigInterface::class);
}
From 6753604a30cb29fcc1772bc90e639e0a2f459c3c Mon Sep 17 00:00:00 2001
From: Rus0
Date: Thu, 29 Aug 2019 21:53:18 -0500
Subject: [PATCH 117/937] wrong order of constructor
---
app/code/Magento/Wishlist/Test/Unit/Model/WishlistTest.php | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/app/code/Magento/Wishlist/Test/Unit/Model/WishlistTest.php b/app/code/Magento/Wishlist/Test/Unit/Model/WishlistTest.php
index cbbccf29e63b8..4d4d1a235de1d 100644
--- a/app/code/Magento/Wishlist/Test/Unit/Model/WishlistTest.php
+++ b/app/code/Magento/Wishlist/Test/Unit/Model/WishlistTest.php
@@ -206,11 +206,11 @@ protected function setUp()
$this->mathRandom,
$this->dateTime,
$this->productRepository,
- $this->stockItemRepository,
- $this->scopeConfig,
false,
[],
- $this->serializer
+ $this->serializer,
+ $this->stockItemRepository,
+ $this->scopeConfig
);
}
From 1a7bbc4b1d23a5bbaa555893f3a1406121b3ec28 Mon Sep 17 00:00:00 2001
From: RomanKis
Date: Fri, 30 Aug 2019 11:59:42 +0300
Subject: [PATCH 118/937] graphQl-509: `save_in_address_book` has no impact on
Address Book
---
.../Quote/Customer/CheckoutEndToEndTest.php | 2 -
.../Customer/SetBillingAddressOnCartTest.php | 160 ++++++++++++++++-
.../Customer/SetShippingAddressOnCartTest.php | 165 +++++++++++++++++-
.../Guest/AllowGuestCheckoutOptionTest.php | 2 -
.../Quote/Guest/CheckoutEndToEndTest.php | 2 -
.../Guest/SetBillingAddressOnCartTest.php | 7 -
.../Guest/SetShippingAddressOnCartTest.php | 6 -
7 files changed, 313 insertions(+), 31 deletions(-)
diff --git a/dev/tests/api-functional/testsuite/Magento/GraphQl/Quote/Customer/CheckoutEndToEndTest.php b/dev/tests/api-functional/testsuite/Magento/GraphQl/Quote/Customer/CheckoutEndToEndTest.php
index 5a4cc88d69623..578c7faa3c6e6 100644
--- a/dev/tests/api-functional/testsuite/Magento/GraphQl/Quote/Customer/CheckoutEndToEndTest.php
+++ b/dev/tests/api-functional/testsuite/Magento/GraphQl/Quote/Customer/CheckoutEndToEndTest.php
@@ -259,7 +259,6 @@ private function setBillingAddress(string $cartId): void
telephone: "88776655"
region: "TX"
country_code: "US"
- save_in_address_book: false
}
}
}
@@ -298,7 +297,6 @@ private function setShippingAddress(string $cartId): array
postcode: "887766"
country_code: "US"
telephone: "88776655"
- save_in_address_book: false
}
}
]
diff --git a/dev/tests/api-functional/testsuite/Magento/GraphQl/Quote/Customer/SetBillingAddressOnCartTest.php b/dev/tests/api-functional/testsuite/Magento/GraphQl/Quote/Customer/SetBillingAddressOnCartTest.php
index 011930e723273..9a9c50c140571 100644
--- a/dev/tests/api-functional/testsuite/Magento/GraphQl/Quote/Customer/SetBillingAddressOnCartTest.php
+++ b/dev/tests/api-functional/testsuite/Magento/GraphQl/Quote/Customer/SetBillingAddressOnCartTest.php
@@ -7,6 +7,9 @@
namespace Magento\GraphQl\Quote\Customer;
+use Magento\Customer\Api\AddressRepositoryInterface;
+use Magento\Customer\Api\CustomerRepositoryInterface;
+use Magento\Framework\Api\SearchCriteriaBuilder;
use Magento\GraphQl\Quote\GetMaskedQuoteIdByReservedOrderId;
use Magento\Integration\Api\CustomerTokenServiceInterface;
use Magento\Quote\Model\QuoteFactory;
@@ -45,6 +48,19 @@ class SetBillingAddressOnCartTest extends GraphQlAbstract
*/
private $customerTokenService;
+ /**
+ * @var AddressRepositoryInterface
+ */
+ private $customerAddressRepository;
+ /**
+ * @var SearchCriteriaBuilder
+ */
+ private $searchCriteriaBuilder;
+ /**
+ * @var CustomerRepositoryInterface
+ */
+ private $customerRepository;
+
protected function setUp()
{
$objectManager = Bootstrap::getObjectManager();
@@ -53,6 +69,9 @@ protected function setUp()
$this->quoteFactory = $objectManager->get(QuoteFactory::class);
$this->quoteIdToMaskedId = $objectManager->get(QuoteIdToMaskedQuoteIdInterface::class);
$this->customerTokenService = $objectManager->get(CustomerTokenServiceInterface::class);
+ $this->customerAddressRepository = $objectManager->get(AddressRepositoryInterface::class);
+ $this->searchCriteriaBuilder = $objectManager->get(SearchCriteriaBuilder::class);
+ $this->customerRepository = $objectManager->get(CustomerRepositoryInterface::class);
}
/**
@@ -81,7 +100,6 @@ public function testSetNewBillingAddress()
postcode: "887766"
country_code: "US"
telephone: "88776655"
- save_in_address_book: false
}
}
}
@@ -140,7 +158,6 @@ public function testSetNewBillingAddressWithUseForShippingParameter()
postcode: "887766"
country_code: "US"
telephone: "88776655"
- save_in_address_book: false
}
use_for_shipping: true
}
@@ -301,7 +318,6 @@ public function testSetNewBillingAddressAndFromAddressBookAtSameTime()
postcode: "887766"
country_code: "US"
telephone: "88776655"
- save_in_address_book: false
}
}
}
@@ -383,7 +399,6 @@ public function testSetNewBillingAddressWithUseForShippingAndMultishipping()
postcode: "887766"
country_code: "US"
telephone: "88776655"
- save_in_address_book: false
}
use_for_shipping: true
}
@@ -620,7 +635,6 @@ public function testSetNewBillingAddressWithRedundantStreetLine()
postcode: "887766"
country_code: "US"
telephone: "88776655"
- save_in_address_book: false
}
}
}
@@ -663,7 +677,6 @@ public function testSetBillingAddressWithLowerCaseCountry()
postcode: "887766"
country_code: "us"
telephone: "88776655"
- save_in_address_book: false
}
}
}
@@ -696,6 +709,141 @@ public function testSetBillingAddressWithLowerCaseCountry()
$this->assertNewAddressFields($billingAddressResponse);
}
+
+ /**
+ * @magentoApiDataFixture Magento/Customer/_files/customer.php
+ * @magentoApiDataFixture Magento/GraphQl/Catalog/_files/simple_product.php
+ * @magentoApiDataFixture Magento/GraphQl/Quote/_files/customer/create_empty_cart.php
+ * @magentoApiDataFixture Magento/GraphQl/Quote/_files/add_simple_product.php
+ */
+ public function testSetNewBillingAddressWithSaveInAddressBook()
+ {
+ $maskedQuoteId = $this->getMaskedQuoteIdByReservedOrderId->execute('test_quote');
+ $query = <<graphQlMutation($query, [], '', $this->getHeaderMap());
+ $customer = $this->customerRepository->get('customer@example.com');
+ $searchCriteria = $this->searchCriteriaBuilder->addFilter('parent_id', $customer->getId())->create();
+ $addresses = $this->customerAddressRepository->getList($searchCriteria)->getItems();
+
+ self::assertCount(1, $addresses);
+ self::assertArrayHasKey('cart', $response['setBillingAddressOnCart']);
+
+ $cartResponse = $response['setBillingAddressOnCart']['cart'];
+ self::assertArrayHasKey('billing_address', $cartResponse);
+ $billingAddressResponse = $cartResponse['billing_address'];
+ $this->assertNewAddressFields($billingAddressResponse);
+
+ foreach ($addresses as $address) {
+ $this->customerAddressRepository->delete($address);
+ }
+ }
+
+ /**
+ * @magentoApiDataFixture Magento/Customer/_files/customer.php
+ * @magentoApiDataFixture Magento/GraphQl/Catalog/_files/simple_product.php
+ * @magentoApiDataFixture Magento/GraphQl/Quote/_files/customer/create_empty_cart.php
+ * @magentoApiDataFixture Magento/GraphQl/Quote/_files/add_simple_product.php
+ */
+ public function testSetNewBillingAddressWithNotSaveInAddressBook()
+ {
+ $maskedQuoteId = $this->getMaskedQuoteIdByReservedOrderId->execute('test_quote');
+ $query = <<graphQlMutation($query, [], '', $this->getHeaderMap());
+ $customer = $this->customerRepository->get('customer@example.com');
+ $searchCriteria = $this->searchCriteriaBuilder->addFilter('parent_id', $customer->getId())->create();
+ $addresses = $this->customerAddressRepository->getList($searchCriteria)->getItems();
+
+ self::assertCount(0, $addresses);
+ self::assertArrayHasKey('cart', $response['setBillingAddressOnCart']);
+
+ $cartResponse = $response['setBillingAddressOnCart']['cart'];
+ self::assertArrayHasKey('billing_address', $cartResponse);
+ $billingAddressResponse = $cartResponse['billing_address'];
+ $this->assertNewAddressFields($billingAddressResponse);
+
+ foreach ($addresses as $address) {
+ $this->customerAddressRepository->delete($address);
+ }
+ }
+
/**
* Verify the all the whitelisted fields for a New Address Object
*
diff --git a/dev/tests/api-functional/testsuite/Magento/GraphQl/Quote/Customer/SetShippingAddressOnCartTest.php b/dev/tests/api-functional/testsuite/Magento/GraphQl/Quote/Customer/SetShippingAddressOnCartTest.php
index 15ee125955062..72b6a4aea6730 100644
--- a/dev/tests/api-functional/testsuite/Magento/GraphQl/Quote/Customer/SetShippingAddressOnCartTest.php
+++ b/dev/tests/api-functional/testsuite/Magento/GraphQl/Quote/Customer/SetShippingAddressOnCartTest.php
@@ -7,6 +7,9 @@
namespace Magento\GraphQl\Quote\Customer;
+use Magento\Customer\Api\AddressRepositoryInterface;
+use Magento\Customer\Api\CustomerRepositoryInterface;
+use Magento\Framework\Api\SearchCriteriaBuilder;
use Magento\GraphQl\Quote\GetMaskedQuoteIdByReservedOrderId;
use Magento\Integration\Api\CustomerTokenServiceInterface;
use Magento\Quote\Model\QuoteFactory;
@@ -45,6 +48,21 @@ class SetShippingAddressOnCartTest extends GraphQlAbstract
*/
private $customerTokenService;
+ /**
+ * @var AddressRepositoryInterface
+ */
+ private $customerAddressRepository;
+
+ /**
+ * @var SearchCriteriaBuilder
+ */
+ private $searchCriteriaBuilder;
+
+ /**
+ * @var CustomerRepositoryInterface
+ */
+ private $customerRepository;
+
protected function setUp()
{
$objectManager = Bootstrap::getObjectManager();
@@ -53,6 +71,9 @@ protected function setUp()
$this->quoteIdToMaskedId = $objectManager->get(QuoteIdToMaskedQuoteIdInterface::class);
$this->getMaskedQuoteIdByReservedOrderId = $objectManager->get(GetMaskedQuoteIdByReservedOrderId::class);
$this->customerTokenService = $objectManager->get(CustomerTokenServiceInterface::class);
+ $this->customerAddressRepository = $objectManager->get(AddressRepositoryInterface::class);
+ $this->searchCriteriaBuilder = $objectManager->get(SearchCriteriaBuilder::class);
+ $this->customerRepository = $objectManager->get(CustomerRepositoryInterface::class);
}
/**
@@ -82,7 +103,6 @@ public function testSetNewShippingAddressOnCartWithSimpleProduct()
postcode: "887766"
country_code: "US"
telephone: "88776655"
- save_in_address_book: false
}
}
]
@@ -146,7 +166,6 @@ public function testSetNewShippingAddressOnCartWithVirtualProduct()
postcode: "887766"
country_code: "US"
telephone: "88776655"
- save_in_address_book: false
}
}
]
@@ -274,7 +293,6 @@ public function testSetNewShippingAddressAndFromAddressBookAtSameTime()
postcode: "887766"
country_code: "US"
telephone: "88776655"
- save_in_address_book: false
}
}
]
@@ -456,7 +474,6 @@ public function testSetMultipleNewShippingAddresses()
postcode: "887766"
country_code: "US"
telephone: "88776655"
- save_in_address_book: false
}
},
{
@@ -470,7 +487,6 @@ public function testSetMultipleNewShippingAddresses()
postcode: "887766"
country_code: "US"
telephone: "88776655"
- save_in_address_book: false
}
}
]
@@ -514,7 +530,6 @@ public function testSetNewShippingAddressOnCartWithRedundantStreetLine()
postcode: "887766"
country_code: "US"
telephone: "88776655"
- save_in_address_book: false
}
}
]
@@ -655,6 +670,144 @@ public function testSetShippingAddressWithLowerCaseCountry()
$this->assertEquals('CA', $address['region']['code']);
}
+ /**
+ * @magentoApiDataFixture Magento/Customer/_files/customer.php
+ * @magentoApiDataFixture Magento/GraphQl/Catalog/_files/simple_product.php
+ * @magentoApiDataFixture Magento/GraphQl/Quote/_files/customer/create_empty_cart.php
+ * @magentoApiDataFixture Magento/GraphQl/Quote/_files/add_simple_product.php
+ */
+ public function testSetNewShippingAddressWithSaveInAddressBook()
+ {
+ $maskedQuoteId = $this->getMaskedQuoteIdByReservedOrderId->execute('test_quote');
+ $query = <<graphQlMutation($query, [], '', $this->getHeaderMap());
+ $customer = $this->customerRepository->get('customer@example.com');
+ $searchCriteria = $this->searchCriteriaBuilder->addFilter('parent_id', $customer->getId())->create();
+ $addresses = $this->customerAddressRepository->getList($searchCriteria)->getItems();
+
+ self::assertCount(1, $addresses);
+ self::assertArrayHasKey('cart', $response['setShippingAddressesOnCart']);
+
+ $cartResponse = $response['setShippingAddressesOnCart']['cart'];
+ self::assertArrayHasKey('shipping_addresses', $cartResponse);
+ $shippingAddressResponse = current($cartResponse['shipping_addresses']);
+ $this->assertNewShippingAddressFields($shippingAddressResponse);
+
+ foreach ($addresses as $address) {
+ $this->customerAddressRepository->delete($address);
+ }
+ }
+
+ /**
+ * @magentoApiDataFixture Magento/Customer/_files/customer.php
+ * @magentoApiDataFixture Magento/GraphQl/Catalog/_files/simple_product.php
+ * @magentoApiDataFixture Magento/GraphQl/Quote/_files/customer/create_empty_cart.php
+ * @magentoApiDataFixture Magento/GraphQl/Quote/_files/add_simple_product.php
+ */
+ public function testSetNewShippingAddressWithNotSaveInAddressBook()
+ {
+ $maskedQuoteId = $this->getMaskedQuoteIdByReservedOrderId->execute('test_quote');
+ $query = <<graphQlMutation($query, [], '', $this->getHeaderMap());
+ $customer = $this->customerRepository->get('customer@example.com');
+ $searchCriteria = $this->searchCriteriaBuilder->addFilter('parent_id', $customer->getId())->create();
+ $addresses = $this->customerAddressRepository->getList($searchCriteria)->getItems();
+
+ self::assertCount(0, $addresses);
+ self::assertArrayHasKey('cart', $response['setShippingAddressesOnCart']);
+
+ $cartResponse = $response['setShippingAddressesOnCart']['cart'];
+ self::assertArrayHasKey('shipping_addresses', $cartResponse);
+ $shippingAddressResponse = current($cartResponse['shipping_addresses']);
+ $this->assertNewShippingAddressFields($shippingAddressResponse);
+
+ foreach ($addresses as $address) {
+ $this->customerAddressRepository->delete($address);
+ }
+ }
+
/**
* Verify the all the whitelisted fields for a New Address Object
*
diff --git a/dev/tests/api-functional/testsuite/Magento/GraphQl/Quote/Guest/AllowGuestCheckoutOptionTest.php b/dev/tests/api-functional/testsuite/Magento/GraphQl/Quote/Guest/AllowGuestCheckoutOptionTest.php
index 16f291be91078..23128e55af32f 100644
--- a/dev/tests/api-functional/testsuite/Magento/GraphQl/Quote/Guest/AllowGuestCheckoutOptionTest.php
+++ b/dev/tests/api-functional/testsuite/Magento/GraphQl/Quote/Guest/AllowGuestCheckoutOptionTest.php
@@ -108,7 +108,6 @@ public function testSetBillingAddressToGuestCustomerCart()
postcode: "887766"
country_code: "US"
telephone: "88776655"
- save_in_address_book: false
}
}
}
@@ -221,7 +220,6 @@ public function testSetNewShippingAddressOnCartWithGuestCheckoutDisabled()
postcode: "887766"
country_code: "US"
telephone: "88776655"
- save_in_address_book: false
}
}
]
diff --git a/dev/tests/api-functional/testsuite/Magento/GraphQl/Quote/Guest/CheckoutEndToEndTest.php b/dev/tests/api-functional/testsuite/Magento/GraphQl/Quote/Guest/CheckoutEndToEndTest.php
index ed5aa9303d875..04ecde833de85 100644
--- a/dev/tests/api-functional/testsuite/Magento/GraphQl/Quote/Guest/CheckoutEndToEndTest.php
+++ b/dev/tests/api-functional/testsuite/Magento/GraphQl/Quote/Guest/CheckoutEndToEndTest.php
@@ -219,7 +219,6 @@ private function setBillingAddress(string $cartId): void
telephone: "88776655"
region: "TX"
country_code: "US"
- save_in_address_book: false
}
}
}
@@ -258,7 +257,6 @@ private function setShippingAddress(string $cartId): array
postcode: "887766"
country_code: "US"
telephone: "88776655"
- save_in_address_book: false
}
}
]
diff --git a/dev/tests/api-functional/testsuite/Magento/GraphQl/Quote/Guest/SetBillingAddressOnCartTest.php b/dev/tests/api-functional/testsuite/Magento/GraphQl/Quote/Guest/SetBillingAddressOnCartTest.php
index 730e65b4ba8aa..5a3d45005c911 100644
--- a/dev/tests/api-functional/testsuite/Magento/GraphQl/Quote/Guest/SetBillingAddressOnCartTest.php
+++ b/dev/tests/api-functional/testsuite/Magento/GraphQl/Quote/Guest/SetBillingAddressOnCartTest.php
@@ -52,7 +52,6 @@ public function testSetNewBillingAddress()
postcode: "887766"
country_code: "US"
telephone: "88776655"
- save_in_address_book: false
}
}
}
@@ -110,7 +109,6 @@ public function testSetNewBillingAddressWithUseForShippingParameter()
postcode: "887766"
country_code: "US"
telephone: "88776655"
- save_in_address_book: false
}
use_for_shipping: true
}
@@ -186,7 +184,6 @@ public function testSetBillingAddressToCustomerCart()
postcode: "887766"
country_code: "US"
telephone: "88776655"
- save_in_address_book: false
}
}
}
@@ -263,7 +260,6 @@ public function testSetBillingAddressOnNonExistentCart()
postcode: "887766"
country_code: "US"
telephone: "88776655"
- save_in_address_book: false
}
}
}
@@ -391,7 +387,6 @@ public function testSetNewBillingAddressWithUseForShippingAndMultishipping()
postcode: "887766"
country_code: "US"
telephone: "88776655"
- save_in_address_book: false
}
use_for_shipping: true
}
@@ -437,7 +432,6 @@ public function testSetNewBillingAddressRedundantStreetLine()
postcode: "887766"
country_code: "US"
telephone: "88776655"
- save_in_address_book: false
}
}
}
@@ -480,7 +474,6 @@ public function testSetBillingAddressWithLowerCaseCountry()
postcode: "887766"
country_code: "us"
telephone: "88776655"
- save_in_address_book: false
}
}
}
diff --git a/dev/tests/api-functional/testsuite/Magento/GraphQl/Quote/Guest/SetShippingAddressOnCartTest.php b/dev/tests/api-functional/testsuite/Magento/GraphQl/Quote/Guest/SetShippingAddressOnCartTest.php
index 537c8f09a0a98..262aac45a968b 100644
--- a/dev/tests/api-functional/testsuite/Magento/GraphQl/Quote/Guest/SetShippingAddressOnCartTest.php
+++ b/dev/tests/api-functional/testsuite/Magento/GraphQl/Quote/Guest/SetShippingAddressOnCartTest.php
@@ -53,7 +53,6 @@ public function testSetNewShippingAddressOnCartWithSimpleProduct()
postcode: "887766"
country_code: "US"
telephone: "88776655"
- save_in_address_book: false
}
}
]
@@ -116,7 +115,6 @@ public function testSetNewShippingAddressOnCartWithVirtualProduct()
postcode: "887766"
country_code: "US"
telephone: "88776655"
- save_in_address_book: false
}
}
]
@@ -268,7 +266,6 @@ public function testSetNewShippingAddressOnCartWithRedundantStreetLine()
postcode: "887766"
country_code: "US"
telephone: "88776655"
- save_in_address_book: false
}
}
]
@@ -337,7 +334,6 @@ public function testSetMultipleNewShippingAddresses()
postcode: "887766"
country_code: "US"
telephone: "88776655"
- save_in_address_book: false
}
},
{
@@ -351,7 +347,6 @@ public function testSetMultipleNewShippingAddresses()
postcode: "887766"
country_code: "US"
telephone: "88776655"
- save_in_address_book: false
}
}
]
@@ -391,7 +386,6 @@ public function testSetShippingAddressOnNonExistentCart()
postcode: "887766"
country_code: "US"
telephone: "88776655"
- save_in_address_book: false
}
}
}
From 5d620d111d52b8274ec94bc1e628c05b48ad120d Mon Sep 17 00:00:00 2001
From: Dmytro Poperechnyy
Date: Fri, 30 Aug 2019 18:33:01 -0500
Subject: [PATCH 119/937] MC-19247: Broken translations with advanced bundling
---
.../Backend/view/adminhtml/layout/default.xml | 1 -
.../Theme/view/frontend/layout/default.xml | 1 -
.../Block/Html/Head/Dictionary.php | 58 +++++++++++++++++++
.../Magento/Translation/Model/FileManager.php | 20 +++++++
.../Translation/view/base/layout/default.xml | 14 +++++
.../view/base/templates/dictionary.phtml | 18 ++++++
lib/web/mage/translate.js | 21 +++----
7 files changed, 118 insertions(+), 15 deletions(-)
create mode 100644 app/code/Magento/Translation/Block/Html/Head/Dictionary.php
create mode 100644 app/code/Magento/Translation/view/base/layout/default.xml
create mode 100644 app/code/Magento/Translation/view/base/templates/dictionary.phtml
diff --git a/app/code/Magento/Backend/view/adminhtml/layout/default.xml b/app/code/Magento/Backend/view/adminhtml/layout/default.xml
index a7faab0bc4673..b450102d7fc3d 100644
--- a/app/code/Magento/Backend/view/adminhtml/layout/default.xml
+++ b/app/code/Magento/Backend/view/adminhtml/layout/default.xml
@@ -77,7 +77,6 @@
-
diff --git a/app/code/Magento/Theme/view/frontend/layout/default.xml b/app/code/Magento/Theme/view/frontend/layout/default.xml
index 07d344cb3658f..e783648f7e3e2 100644
--- a/app/code/Magento/Theme/view/frontend/layout/default.xml
+++ b/app/code/Magento/Theme/view/frontend/layout/default.xml
@@ -12,7 +12,6 @@
-
diff --git a/app/code/Magento/Translation/Block/Html/Head/Dictionary.php b/app/code/Magento/Translation/Block/Html/Head/Dictionary.php
new file mode 100644
index 0000000000000..ef7b6d0ac8bfd
--- /dev/null
+++ b/app/code/Magento/Translation/Block/Html/Head/Dictionary.php
@@ -0,0 +1,58 @@
+pageConfig = $pageConfig;
+ $this->fileManager = $fileManager;
+ }
+
+ /**
+ * Get translation dictionary file as an asset for the page.
+ *
+ * @return string
+ */
+ public function getTranslationDictionaryFile(): string
+ {
+ $translateDictionaryConfig = $this->fileManager->createTranslateDictionaryConfigAsset(JsConfig::DICTIONARY_FILE_NAME);
+ $translateDictionaryConfigRelPath = $translateDictionaryConfig->getFilePath();
+
+ return $this->_assetRepo->getUrl($translateDictionaryConfigRelPath);
+ }
+}
diff --git a/app/code/Magento/Translation/Model/FileManager.php b/app/code/Magento/Translation/Model/FileManager.php
index 387173f6de0ba..43bd357c50691 100644
--- a/app/code/Magento/Translation/Model/FileManager.php
+++ b/app/code/Magento/Translation/Model/FileManager.php
@@ -8,6 +8,8 @@
use Magento\Framework\App\Filesystem\DirectoryList;
use Magento\Framework\App\ObjectManager;
use Magento\Translation\Model\Inline\File as TranslationFile;
+use Magento\Framework\View\Asset\File\FallbackContext as FileFallbackContext;
+use Magento\Framework\View\Asset\File;
/**
* A service for handling Translation config files
@@ -39,6 +41,11 @@ class FileManager
*/
private $translationFile;
+ /**
+ * @var FileFallbackContext
+ */
+ private $staticContext;
+
/**
* @param \Magento\Framework\View\Asset\Repository $assetRepo
* @param \Magento\Framework\App\Filesystem\DirectoryList $directoryList
@@ -55,6 +62,7 @@ public function __construct(
$this->directoryList = $directoryList;
$this->driverFile = $driverFile;
$this->translationFile = $translationFile ?: ObjectManager::getInstance()->get(TranslationFile::class);
+ $this->staticContext = $assetRepo->getStaticViewFileContext();
}
/**
@@ -137,4 +145,16 @@ public function getTranslationFileVersion()
return sha1($translationFileHash . $this->getTranslationFilePath());
}
+
+ /**
+ * Create a view asset for translate dictionary config.
+ *
+ * @param string $fileName
+ * @return File
+ */
+ public function createTranslateDictionaryConfigAsset(string $fileName): File
+ {
+ $relPath = $this->staticContext->getConfigPath() . '/' . $fileName;
+ return $this->assetRepo->createArbitrary($relPath, '');
+ }
}
diff --git a/app/code/Magento/Translation/view/base/layout/default.xml b/app/code/Magento/Translation/view/base/layout/default.xml
new file mode 100644
index 0000000000000..76f93e625d1e7
--- /dev/null
+++ b/app/code/Magento/Translation/view/base/layout/default.xml
@@ -0,0 +1,14 @@
+
+
+
+
+
+
+
+
+
diff --git a/app/code/Magento/Translation/view/base/templates/dictionary.phtml b/app/code/Magento/Translation/view/base/templates/dictionary.phtml
new file mode 100644
index 0000000000000..93b4a7c84def1
--- /dev/null
+++ b/app/code/Magento/Translation/view/base/templates/dictionary.phtml
@@ -0,0 +1,18 @@
+
+
+
diff --git a/lib/web/mage/translate.js b/lib/web/mage/translate.js
index a9c30bf577918..261d680c9ffab 100644
--- a/lib/web/mage/translate.js
+++ b/lib/web/mage/translate.js
@@ -3,17 +3,12 @@
* See COPYING.txt for license details.
*/
-/* eslint-disable strict */
-(function (factory) {
- if (typeof define === 'function' && define.amd) {
- define([
- 'jquery',
- 'mage/mage'
- ], factory);
- } else {
- factory(jQuery);
- }
-}(function ($) {
+define([
+ 'jquery',
+ 'mage/mage',
+ 'text!dictionary'
+], function ($, mage, d) {
+ var dictionary = JSON.parse(d);
$.extend(true, $, {
mage: {
translate: (function () {
@@ -22,7 +17,7 @@
* @type {Object}
* @private
*/
- var _data = {};
+ var _data = dictionary;
/**
* Add new translation (two string parameters) or several translations (object)
@@ -51,4 +46,4 @@
$.mage.__ = $.proxy($.mage.translate.translate, $.mage.translate);
return $.mage.__;
-}));
+});
From 2f7b1d964b95ec89bcc80318103573c4378cdf3b Mon Sep 17 00:00:00 2001
From: Vitaliy Boyko
Date: Sat, 31 Aug 2019 11:57:01 +0300
Subject: [PATCH 120/937] graphQl-812: Added test case for configurable
products with different super attributes
---
.../AddConfigurableProductToCartTest.php | 37 +++-
.../_files/configurable_attribute_2.php | 62 +++++++
.../configurable_attribute_2_rollback.php | 28 +++
...roducts_with_different_super_attribute.php | 162 ++++++++++++++++++
...ith_different_super_attribute_rollback.php | 14 ++
5 files changed, 302 insertions(+), 1 deletion(-)
create mode 100644 dev/tests/integration/testsuite/Magento/ConfigurableProduct/_files/configurable_attribute_2.php
create mode 100644 dev/tests/integration/testsuite/Magento/ConfigurableProduct/_files/configurable_attribute_2_rollback.php
create mode 100644 dev/tests/integration/testsuite/Magento/ConfigurableProduct/_files/configurable_products_with_different_super_attribute.php
create mode 100644 dev/tests/integration/testsuite/Magento/ConfigurableProduct/_files/configurable_products_with_different_super_attribute_rollback.php
diff --git a/dev/tests/api-functional/testsuite/Magento/GraphQl/ConfigurableProduct/AddConfigurableProductToCartTest.php b/dev/tests/api-functional/testsuite/Magento/GraphQl/ConfigurableProduct/AddConfigurableProductToCartTest.php
index 36120c0535d49..9145f06542fdd 100644
--- a/dev/tests/api-functional/testsuite/Magento/GraphQl/ConfigurableProduct/AddConfigurableProductToCartTest.php
+++ b/dev/tests/api-functional/testsuite/Magento/GraphQl/ConfigurableProduct/AddConfigurableProductToCartTest.php
@@ -7,6 +7,7 @@
namespace Magento\GraphQl\ConfigurableProduct;
+use Exception;
use Magento\GraphQl\Quote\GetMaskedQuoteIdByReservedOrderId;
use Magento\TestFramework\Helper\Bootstrap;
use Magento\TestFramework\TestCase\GraphQlAbstract;
@@ -68,10 +69,12 @@ public function testAddConfigurableProductToCart()
}
/**
+ * TODO: Verify whether exception should be thrown in this scenario
+ *
* @magentoApiDataFixture Magento/ConfigurableProduct/_files/configurable_products.php
* @magentoApiDataFixture Magento/Checkout/_files/active_quote.php
*/
- public function testAddVariationFromAnotherConfigurableProductToCart()
+ public function testAddVariationFromAnotherConfigurableProductWithTheSameSuperAttributeToCart()
{
$searchResponse = $this->graphQlQuery($this->getFetchProductQuery('configurable_12345'));
$product = current($searchResponse['products']['items']);
@@ -109,6 +112,38 @@ public function testAddVariationFromAnotherConfigurableProductToCart()
self::assertArrayHasKey('value_label', $option);
}
+ /**
+ * @magentoApiDataFixture Magento/ConfigurableProduct/_files/configurable_products_with_different_super_attribute.php
+ * @magentoApiDataFixture Magento/Checkout/_files/active_quote.php
+ *
+ * @expectedException Exception
+ * @expectedExceptionMessage You need to choose options for your item.
+ */
+ public function testAddVariationFromAnotherConfigurableProductWithDifferentSuperAttributeToCart()
+ {
+ $searchResponse = $this->graphQlQuery($this->getFetchProductQuery('configurable_12345'));
+ $product = current($searchResponse['products']['items']);
+
+ $quantity = 2;
+ $maskedQuoteId = $this->getMaskedQuoteIdByReservedOrderId->execute('test_order_1');
+ $parentSku = $product['sku'];
+
+ //'configurable' -> ['simple_10', 'simple_20']
+ //'configurable_12345' -> ['simple_30', 'simple_40']
+ //'simple_20' hasn't any common configurable option with 'configurable_12345' children
+ //therefore exception is thrown
+ $sku = 'simple_20';
+
+ $query = $this->getQuery(
+ $maskedQuoteId,
+ $parentSku,
+ $sku,
+ $quantity
+ );
+
+ $this->graphQlMutation($query);
+ }
+
/**
* @magentoApiDataFixture Magento/ConfigurableProduct/_files/product_configurable_sku.php
* @magentoApiDataFixture Magento/Checkout/_files/active_quote.php
diff --git a/dev/tests/integration/testsuite/Magento/ConfigurableProduct/_files/configurable_attribute_2.php b/dev/tests/integration/testsuite/Magento/ConfigurableProduct/_files/configurable_attribute_2.php
new file mode 100644
index 0000000000000..4de079ba3b6ee
--- /dev/null
+++ b/dev/tests/integration/testsuite/Magento/ConfigurableProduct/_files/configurable_attribute_2.php
@@ -0,0 +1,62 @@
+get(\Magento\Eav\Model\Config::class);
+$attribute2 = $eavConfig->getAttribute('catalog_product', 'test_configurable_2');
+
+$eavConfig->clear();
+
+/** @var $installer \Magento\Catalog\Setup\CategorySetup */
+$installer = Bootstrap::getObjectManager()->create(\Magento\Catalog\Setup\CategorySetup::class);
+
+if (!$attribute2->getId()) {
+
+ /** @var $attribute \Magento\Catalog\Model\ResourceModel\Eav\Attribute */
+ $attribute2 = Bootstrap::getObjectManager()->create(
+ \Magento\Catalog\Model\ResourceModel\Eav\Attribute::class
+ );
+
+ /** @var AttributeRepositoryInterface $attributeRepository */
+ $attributeRepository = Bootstrap::getObjectManager()->create(AttributeRepositoryInterface::class);
+
+ $attribute2->setData(
+ [
+ 'attribute_code' => 'test_configurable_2',
+ 'entity_type_id' => $installer->getEntityTypeId('catalog_product'),
+ 'is_global' => 1,
+ 'is_user_defined' => 1,
+ 'frontend_input' => 'select',
+ 'is_unique' => 0,
+ 'is_required' => 0,
+ 'is_searchable' => 0,
+ 'is_visible_in_advanced_search' => 0,
+ 'is_comparable' => 0,
+ 'is_filterable' => 0,
+ 'is_filterable_in_search' => 0,
+ 'is_used_for_promo_rules' => 0,
+ 'is_html_allowed_on_front' => 1,
+ 'is_visible_on_front' => 0,
+ 'used_in_product_listing' => 0,
+ 'used_for_sort_by' => 0,
+ 'frontend_label' => ['Test Configurable 2'],
+ 'backend_type' => 'int',
+ 'option' => [
+ 'value' => ['option_0' => ['Option 1'], 'option_1' => ['Option 2']],
+ 'order' => ['option_0' => 1, 'option_1' => 2],
+ ],
+ ]
+ );
+
+ $attributeRepository->save($attribute2);
+
+ /* Assign attribute to attribute set */
+ $installer->addAttributeToGroup('catalog_product', 'Default', 'General', $attribute2->getId());
+}
+
+$eavConfig->clear();
diff --git a/dev/tests/integration/testsuite/Magento/ConfigurableProduct/_files/configurable_attribute_2_rollback.php b/dev/tests/integration/testsuite/Magento/ConfigurableProduct/_files/configurable_attribute_2_rollback.php
new file mode 100644
index 0000000000000..84f6ec58d3e4f
--- /dev/null
+++ b/dev/tests/integration/testsuite/Magento/ConfigurableProduct/_files/configurable_attribute_2_rollback.php
@@ -0,0 +1,28 @@
+get(\Magento\Framework\Registry::class);
+
+$registry->unregister('isSecureArea');
+$registry->register('isSecureArea', true);
+$productCollection = \Magento\TestFramework\Helper\Bootstrap::getObjectManager()
+ ->get(\Magento\Catalog\Model\ResourceModel\Product\Collection::class);
+foreach ($productCollection as $product) {
+ $product->delete();
+}
+
+$eavConfig = \Magento\TestFramework\Helper\Bootstrap::getObjectManager()->get(\Magento\Eav\Model\Config::class);
+$attribute = $eavConfig->getAttribute('catalog_product', 'test_configurable_2');
+if ($attribute instanceof \Magento\Eav\Model\Entity\Attribute\AbstractAttribute
+ && $attribute->getId()
+) {
+ $attribute->delete();
+}
+$eavConfig->clear();
+
+$registry->unregister('isSecureArea');
+$registry->register('isSecureArea', false);
diff --git a/dev/tests/integration/testsuite/Magento/ConfigurableProduct/_files/configurable_products_with_different_super_attribute.php b/dev/tests/integration/testsuite/Magento/ConfigurableProduct/_files/configurable_products_with_different_super_attribute.php
new file mode 100644
index 0000000000000..1bf816425a9c9
--- /dev/null
+++ b/dev/tests/integration/testsuite/Magento/ConfigurableProduct/_files/configurable_products_with_different_super_attribute.php
@@ -0,0 +1,162 @@
+get(ProductRepositoryInterface::class);
+
+/** @var $installer CategorySetup */
+$installer = Bootstrap::getObjectManager()->create(CategorySetup::class);
+
+/* Create simple products per each option value*/
+/** @var AttributeOptionInterface[] $options */
+$options = $attribute->getOptions();
+
+$attributeValues = [];
+$attributeSetId = $installer->getAttributeSetId('catalog_product', 'Default');
+$associatedProductIds = [];
+$productIds = [10, 20];
+array_shift($options); //remove the first option which is empty
+
+foreach ($options as $option) {
+ /** @var $product Product */
+ $product = Bootstrap::getObjectManager()->create(Product::class);
+ $productId = array_shift($productIds);
+ $product->setTypeId(Type::TYPE_SIMPLE)
+ ->setId($productId)
+ ->setAttributeSetId($attributeSetId)
+ ->setWebsiteIds([1])
+ ->setName('Configurable Option' . $option->getLabel())
+ ->setSku('simple_' . $productId)
+ ->setPrice($productId)
+ ->setTestConfigurable($option->getValue())
+ ->setVisibility(Visibility::VISIBILITY_NOT_VISIBLE)
+ ->setStatus(Status::STATUS_ENABLED)
+ ->setStockData(['use_config_manage_stock' => 1, 'qty' => 100, 'is_qty_decimal' => 0, 'is_in_stock' => 1]);
+ $product = $productRepository->save($product);
+
+ $attributeValues[] = [
+ 'label' => 'test',
+ 'attribute_id' => $attribute->getId(),
+ 'value_index' => $option->getValue(),
+ ];
+ $associatedProductIds[] = $product->getId();
+}
+
+/** @var $product Product */
+$product = Bootstrap::getObjectManager()->create(Product::class);
+/** @var Factory $optionsFactory */
+$optionsFactory = Bootstrap::getObjectManager()->create(Factory::class);
+$configurableAttributesData = [
+ [
+ 'attribute_id' => $attribute->getId(),
+ 'code' => $attribute->getAttributeCode(),
+ 'label' => $attribute->getStoreLabel(),
+ 'position' => '0',
+ 'values' => $attributeValues,
+ ],
+];
+$configurableOptions = $optionsFactory->create($configurableAttributesData);
+$extensionConfigurableAttributes = $product->getExtensionAttributes();
+$extensionConfigurableAttributes->setConfigurableProductOptions($configurableOptions);
+$extensionConfigurableAttributes->setConfigurableProductLinks($associatedProductIds);
+$product->setExtensionAttributes($extensionConfigurableAttributes);
+
+$product->setTypeId(Configurable::TYPE_CODE)
+ ->setId(1)
+ ->setAttributeSetId($attributeSetId)
+ ->setWebsiteIds([1])
+ ->setName('Configurable Product')
+ ->setSku('configurable')
+ ->setVisibility(Visibility::VISIBILITY_BOTH)
+ ->setStatus(Status::STATUS_ENABLED)
+ ->setStockData(['use_config_manage_stock' => 1, 'is_in_stock' => 1]);
+$productRepository->cleanCache();
+$productRepository->save($product);
+
+/* Create simple products per each option value*/
+/** @var AttributeOptionInterface[] $options */
+$options = $attribute2->getOptions();
+
+$attributeValues = [];
+$attributeSetId = $installer->getAttributeSetId('catalog_product', 'Default');
+$associatedProductIds = [];
+$productIds = [30, 40];
+array_shift($options); //remove the first option which is empty
+
+foreach ($options as $option) {
+ /** @var $product Product */
+ $product = Bootstrap::getObjectManager()->create(Product::class);
+ $productId = array_shift($productIds);
+ $product->setTypeId(Type::TYPE_SIMPLE)
+ ->setId($productId)
+ ->setAttributeSetId($attributeSetId)
+ ->setWebsiteIds([1])
+ ->setName('Configurable Option' . $option->getLabel())
+ ->setSku('simple_' . $productId)
+ ->setPrice($productId)
+ ->setTestConfigurable2($option->getValue())
+ ->setVisibility(Visibility::VISIBILITY_NOT_VISIBLE)
+ ->setStatus(Status::STATUS_ENABLED)
+ ->setStockData(['use_config_manage_stock' => 1, 'qty' => 100, 'is_qty_decimal' => 0, 'is_in_stock' => 1]);
+ $product = $productRepository->save($product);
+
+ $attributeValues[] = [
+ 'label' => 'test',
+ 'attribute_id' => $attribute2->getId(),
+ 'value_index' => $option->getValue(),
+ ];
+ $associatedProductIds[] = $product->getId();
+}
+
+/** @var $product Product */
+$product = Bootstrap::getObjectManager()->create(Product::class);
+
+/** @var Factory $optionsFactory */
+$optionsFactory = Bootstrap::getObjectManager()->create(Factory::class);
+
+$configurableAttributesData = [
+ [
+ 'attribute_id' => $attribute2->getId(),
+ 'code' => $attribute2->getAttributeCode(),
+ 'label' => $attribute2->getStoreLabel(),
+ 'position' => '1',
+ 'values' => $attributeValues,
+ ],
+];
+
+$configurableOptions = $optionsFactory->create($configurableAttributesData);
+
+$extensionConfigurableAttributes = $product->getExtensionAttributes();
+$extensionConfigurableAttributes->setConfigurableProductOptions($configurableOptions);
+$extensionConfigurableAttributes->setConfigurableProductLinks($associatedProductIds);
+
+$product->setExtensionAttributes($extensionConfigurableAttributes);
+
+$product->setTypeId(Configurable::TYPE_CODE)
+ ->setId(11)
+ ->setAttributeSetId($attributeSetId)
+ ->setWebsiteIds([1])
+ ->setName('Configurable Product 12345')
+ ->setSku('configurable_12345')
+ ->setVisibility(Visibility::VISIBILITY_BOTH)
+ ->setStatus(Status::STATUS_ENABLED)
+ ->setStockData(['use_config_manage_stock' => 1, 'is_in_stock' => 1]);
+$productRepository->cleanCache();
+$productRepository->save($product);
diff --git a/dev/tests/integration/testsuite/Magento/ConfigurableProduct/_files/configurable_products_with_different_super_attribute_rollback.php b/dev/tests/integration/testsuite/Magento/ConfigurableProduct/_files/configurable_products_with_different_super_attribute_rollback.php
new file mode 100644
index 0000000000000..d4fa2a97c4934
--- /dev/null
+++ b/dev/tests/integration/testsuite/Magento/ConfigurableProduct/_files/configurable_products_with_different_super_attribute_rollback.php
@@ -0,0 +1,14 @@
+unregister('isSecureArea');
+$registry->register('isSecureArea', true);
+
+require __DIR__ . '/configurable_attribute_2_rollback.php';
+
+$registry->unregister('isSecureArea');
+$registry->register('isSecureArea', false);
From 8f9d81d78c90ea4ad35714b7004e6545d0c465cc Mon Sep 17 00:00:00 2001
From: Veronika Kurochkina
Date: Mon, 2 Sep 2019 12:13:02 +0300
Subject: [PATCH 121/937] MAGETWO-44170: Not pass function test
\Magento\Catalog\Test\TestCase\Product\ProductTypeSwitchingOnUpdateTest
- Fix mftf
---
.../Test/AdminProductTypeSwitchingOnEditingTest.xml | 4 ++--
.../Test/AdminProductTypeSwitchingOnEditingTest.xml | 12 ++++++------
.../Test/AdminProductTypeSwitchingOnEditingTest.xml | 8 ++++----
3 files changed, 12 insertions(+), 12 deletions(-)
diff --git a/app/code/Magento/Catalog/Test/Mftf/Test/AdminProductTypeSwitchingOnEditingTest.xml b/app/code/Magento/Catalog/Test/Mftf/Test/AdminProductTypeSwitchingOnEditingTest.xml
index 42623f43d4e82..a11646cc46875 100644
--- a/app/code/Magento/Catalog/Test/Mftf/Test/AdminProductTypeSwitchingOnEditingTest.xml
+++ b/app/code/Magento/Catalog/Test/Mftf/Test/AdminProductTypeSwitchingOnEditingTest.xml
@@ -11,7 +11,7 @@
-
+
@@ -62,7 +62,7 @@
-
+
diff --git a/app/code/Magento/ConfigurableProduct/Test/Mftf/Test/AdminProductTypeSwitchingOnEditingTest.xml b/app/code/Magento/ConfigurableProduct/Test/Mftf/Test/AdminProductTypeSwitchingOnEditingTest.xml
index 8253dcf58f9fd..fa21d20eb4456 100644
--- a/app/code/Magento/ConfigurableProduct/Test/Mftf/Test/AdminProductTypeSwitchingOnEditingTest.xml
+++ b/app/code/Magento/ConfigurableProduct/Test/Mftf/Test/AdminProductTypeSwitchingOnEditingTest.xml
@@ -10,8 +10,8 @@
xsi:noNamespaceSchemaLocation="urn:magento:mftf:Test/etc/testSchema.xsd">
-
-
+
+
@@ -75,8 +75,8 @@
-
-
+
+
@@ -114,8 +114,8 @@
-
-
+
+
diff --git a/app/code/Magento/Downloadable/Test/Mftf/Test/AdminProductTypeSwitchingOnEditingTest.xml b/app/code/Magento/Downloadable/Test/Mftf/Test/AdminProductTypeSwitchingOnEditingTest.xml
index 80e86ab4d747c..8cb0d5fde9863 100644
--- a/app/code/Magento/Downloadable/Test/Mftf/Test/AdminProductTypeSwitchingOnEditingTest.xml
+++ b/app/code/Magento/Downloadable/Test/Mftf/Test/AdminProductTypeSwitchingOnEditingTest.xml
@@ -10,8 +10,8 @@
xsi:noNamespaceSchemaLocation="urn:magento:mftf:Test/etc/testSchema.xsd">
-
-
+
+
@@ -27,8 +27,8 @@
-
-
+
+
From 7563129bcce08c1d99347eba76f1af9d564b7039 Mon Sep 17 00:00:00 2001
From: "bruce.ayko"
Date: Mon, 2 Sep 2019 17:43:19 +0100
Subject: [PATCH 122/937] Price Indexer Performance Issue With Out of Stock
Products - Relates to issue https://github.com/magento/magento2/issues/24414
---
.../Model/Indexer/ProductPriceIndexFilter.php | 8 ++++++++
1 file changed, 8 insertions(+)
diff --git a/app/code/Magento/CatalogInventory/Model/Indexer/ProductPriceIndexFilter.php b/app/code/Magento/CatalogInventory/Model/Indexer/ProductPriceIndexFilter.php
index f9a49d4f8d121..8bcc5ea1dc2c3 100644
--- a/app/code/Magento/CatalogInventory/Model/Indexer/ProductPriceIndexFilter.php
+++ b/app/code/Magento/CatalogInventory/Model/Indexer/ProductPriceIndexFilter.php
@@ -104,6 +104,14 @@ public function modifyPrice(IndexTableStructure $priceTable, array $entityIds =
$select->where('stock_item.use_config_manage_stock = 0 AND stock_item.manage_stock = 1');
}
+ if ($entityIds !== null) {
+ if (count($entityIds) > 1) {
+ $select->where('stock_item.product_id in (?)', $entityIds);
+ } else {
+ $select->where('stock_item.product_id = ?', $entityIds);
+ }
+ }
+
$select->group('stock_item.product_id');
$select->having('max_is_in_stock = 0');
From 475518eb607bd879a21f149cc186119992b46299 Mon Sep 17 00:00:00 2001
From: Lusine Papyan
Date: Tue, 3 Sep 2019 10:58:24 +0400
Subject: [PATCH 123/937] MC-18823: Increase test coverage for Framework and
Performance functional areas
- Automation test for MC-11158
---
.../Section/AdminShippingMethodDHLSection.xml | 31 +++
.../AdminShippingMethodFedExSection.xml | 33 +++
.../AdminShippingMethodFlatRateSection.xml | 6 +
...AdminShippingMethodFreeShippingSection.xml | 20 ++
.../AdminShippingMethodTableRatesSection.xml | 8 +
.../Section/AdminShippingMethodUPSSection.xml | 39 +++
.../AdminShippingMethodUSPSSection.xml | 34 +++
.../Test/Mftf/Suite/AppConfigDumpSuite.xml | 19 ++
...utFieldsDisabledAfterAppConfigDumpTest.xml | 247 ++++++++++++++++++
9 files changed, 437 insertions(+)
create mode 100644 app/code/Magento/Shipping/Test/Mftf/Section/AdminShippingMethodDHLSection.xml
create mode 100644 app/code/Magento/Shipping/Test/Mftf/Section/AdminShippingMethodFedExSection.xml
create mode 100644 app/code/Magento/Shipping/Test/Mftf/Section/AdminShippingMethodFreeShippingSection.xml
create mode 100644 app/code/Magento/Shipping/Test/Mftf/Section/AdminShippingMethodUPSSection.xml
create mode 100644 app/code/Magento/Shipping/Test/Mftf/Section/AdminShippingMethodUSPSSection.xml
create mode 100644 app/code/Magento/Shipping/Test/Mftf/Suite/AppConfigDumpSuite.xml
create mode 100644 app/code/Magento/Shipping/Test/Mftf/Test/AdminCheckInputFieldsDisabledAfterAppConfigDumpTest.xml
diff --git a/app/code/Magento/Shipping/Test/Mftf/Section/AdminShippingMethodDHLSection.xml b/app/code/Magento/Shipping/Test/Mftf/Section/AdminShippingMethodDHLSection.xml
new file mode 100644
index 0000000000000..de603d281153e
--- /dev/null
+++ b/app/code/Magento/Shipping/Test/Mftf/Section/AdminShippingMethodDHLSection.xml
@@ -0,0 +1,31 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/app/code/Magento/Shipping/Test/Mftf/Section/AdminShippingMethodFedExSection.xml b/app/code/Magento/Shipping/Test/Mftf/Section/AdminShippingMethodFedExSection.xml
new file mode 100644
index 0000000000000..61902a96030bc
--- /dev/null
+++ b/app/code/Magento/Shipping/Test/Mftf/Section/AdminShippingMethodFedExSection.xml
@@ -0,0 +1,33 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/app/code/Magento/Shipping/Test/Mftf/Section/AdminShippingMethodFlatRateSection.xml b/app/code/Magento/Shipping/Test/Mftf/Section/AdminShippingMethodFlatRateSection.xml
index a7ed0ab498bea..99c191a5225cc 100644
--- a/app/code/Magento/Shipping/Test/Mftf/Section/AdminShippingMethodFlatRateSection.xml
+++ b/app/code/Magento/Shipping/Test/Mftf/Section/AdminShippingMethodFlatRateSection.xml
@@ -11,5 +11,11 @@
diff --git a/app/code/Magento/Shipping/Test/Mftf/Section/AdminShippingMethodFreeShippingSection.xml b/app/code/Magento/Shipping/Test/Mftf/Section/AdminShippingMethodFreeShippingSection.xml
new file mode 100644
index 0000000000000..bf8b5b9c33672
--- /dev/null
+++ b/app/code/Magento/Shipping/Test/Mftf/Section/AdminShippingMethodFreeShippingSection.xml
@@ -0,0 +1,20 @@
+
+
+
+
+
+
diff --git a/app/code/Magento/Shipping/Test/Mftf/Section/AdminShippingMethodTableRatesSection.xml b/app/code/Magento/Shipping/Test/Mftf/Section/AdminShippingMethodTableRatesSection.xml
index 3c570201c9970..944fc06047aa5 100644
--- a/app/code/Magento/Shipping/Test/Mftf/Section/AdminShippingMethodTableRatesSection.xml
+++ b/app/code/Magento/Shipping/Test/Mftf/Section/AdminShippingMethodTableRatesSection.xml
@@ -14,5 +14,13 @@
+
+
+
+
+
+
+
+
diff --git a/app/code/Magento/Shipping/Test/Mftf/Section/AdminShippingMethodUPSSection.xml b/app/code/Magento/Shipping/Test/Mftf/Section/AdminShippingMethodUPSSection.xml
new file mode 100644
index 0000000000000..3eda77a31b423
--- /dev/null
+++ b/app/code/Magento/Shipping/Test/Mftf/Section/AdminShippingMethodUPSSection.xml
@@ -0,0 +1,39 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/app/code/Magento/Shipping/Test/Mftf/Section/AdminShippingMethodUSPSSection.xml b/app/code/Magento/Shipping/Test/Mftf/Section/AdminShippingMethodUSPSSection.xml
new file mode 100644
index 0000000000000..c85883fcd8879
--- /dev/null
+++ b/app/code/Magento/Shipping/Test/Mftf/Section/AdminShippingMethodUSPSSection.xml
@@ -0,0 +1,34 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/app/code/Magento/Shipping/Test/Mftf/Suite/AppConfigDumpSuite.xml b/app/code/Magento/Shipping/Test/Mftf/Suite/AppConfigDumpSuite.xml
new file mode 100644
index 0000000000000..762d17bdf87f1
--- /dev/null
+++ b/app/code/Magento/Shipping/Test/Mftf/Suite/AppConfigDumpSuite.xml
@@ -0,0 +1,19 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/app/code/Magento/Shipping/Test/Mftf/Test/AdminCheckInputFieldsDisabledAfterAppConfigDumpTest.xml b/app/code/Magento/Shipping/Test/Mftf/Test/AdminCheckInputFieldsDisabledAfterAppConfigDumpTest.xml
new file mode 100644
index 0000000000000..519fecc313f71
--- /dev/null
+++ b/app/code/Magento/Shipping/Test/Mftf/Test/AdminCheckInputFieldsDisabledAfterAppConfigDumpTest.xml
@@ -0,0 +1,247 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
From 8ca33f1f5f808e32c41ba4cffa5c3519addf3c89 Mon Sep 17 00:00:00 2001
From: Lusine Papyan
Date: Tue, 3 Sep 2019 12:49:07 +0400
Subject: [PATCH 124/937] MAGETWO-98748: Incorrect behavior in the category
menu on the Storefront
- Updated automated test script
---
...tCategoryHighlightedAndProductDisplayedTest.xml | 14 +++++++++++++-
1 file changed, 13 insertions(+), 1 deletion(-)
diff --git a/app/code/Magento/Catalog/Test/Mftf/Test/StorefrontCategoryHighlightedAndProductDisplayedTest.xml b/app/code/Magento/Catalog/Test/Mftf/Test/StorefrontCategoryHighlightedAndProductDisplayedTest.xml
index c036712398bf9..3e72df9133898 100644
--- a/app/code/Magento/Catalog/Test/Mftf/Test/StorefrontCategoryHighlightedAndProductDisplayedTest.xml
+++ b/app/code/Magento/Catalog/Test/Mftf/Test/StorefrontCategoryHighlightedAndProductDisplayedTest.xml
@@ -15,7 +15,7 @@
-
+
@@ -31,10 +31,18 @@
+
+
+
+
+
+
+
+
@@ -69,5 +77,9 @@
+
+
+
+
From 82ece5da8382e99fddc5f154ed762ef602bc17c6 Mon Sep 17 00:00:00 2001
From: Vitalii Zabaznov
Date: Tue, 3 Sep 2019 15:13:46 -0500
Subject: [PATCH 125/937] MC-18719: private cookie version increments each post
request
---
app/code/Magento/Persistent/etc/frontend/sections.xml | 9 +++++++++
1 file changed, 9 insertions(+)
diff --git a/app/code/Magento/Persistent/etc/frontend/sections.xml b/app/code/Magento/Persistent/etc/frontend/sections.xml
index 16b44c502fc47..a2a3796bc6a50 100644
--- a/app/code/Magento/Persistent/etc/frontend/sections.xml
+++ b/app/code/Magento/Persistent/etc/frontend/sections.xml
@@ -10,4 +10,13 @@
+
+
+
+
+
+
+
+
+
From 22c4ee1413212f4b55cff5014d48966c26582fe5 Mon Sep 17 00:00:00 2001
From: Arnob Saha
Date: Fri, 16 Aug 2019 09:34:55 -0500
Subject: [PATCH 126/937] MC-19152: Custom dropdown customer address attribute
option id showing on guest checkout
- Moving test to EE module
---
.../web/js/model/address-converter.js | 1 +
.../frontend/web/js/view/billing-address.js | 25 ++++++++++++++++-
.../address-renderer/default.js | 27 ++++++++++++++++++-
.../web/js/view/shipping-information/list.js | 3 ++-
.../web/template/billing-address/details.html | 15 ++---------
.../address-renderer/default.html | 15 ++---------
6 files changed, 57 insertions(+), 29 deletions(-)
diff --git a/app/code/Magento/Checkout/view/frontend/web/js/model/address-converter.js b/app/code/Magento/Checkout/view/frontend/web/js/model/address-converter.js
index 9b20a782c38d9..d319ea5014138 100644
--- a/app/code/Magento/Checkout/view/frontend/web/js/model/address-converter.js
+++ b/app/code/Magento/Checkout/view/frontend/web/js/model/address-converter.js
@@ -18,6 +18,7 @@ define([
return {
/**
* Convert address form data to Address object
+ *
* @param {Object} formData
* @returns {Object}
*/
diff --git a/app/code/Magento/Checkout/view/frontend/web/js/view/billing-address.js b/app/code/Magento/Checkout/view/frontend/web/js/view/billing-address.js
index 59d1daa757138..e728a5c0fcdd5 100644
--- a/app/code/Magento/Checkout/view/frontend/web/js/view/billing-address.js
+++ b/app/code/Magento/Checkout/view/frontend/web/js/view/billing-address.js
@@ -159,7 +159,6 @@ function (
}
addressData['save_in_address_book'] = this.saveInAddressBook() ? 1 : 0;
newBillingAddress = createBillingAddress(addressData);
-
// New address must be selected as a billing address
selectBillingAddress(newBillingAddress);
checkoutData.setSelectedBillingAddress(newBillingAddress.getKey());
@@ -237,6 +236,30 @@ function (
*/
getCode: function (parent) {
return _.isFunction(parent.getCode) ? parent.getCode() : 'shared';
+ },
+
+ /**
+ * Get customer attribute label
+ *
+ * @param {*} attribute
+ * @returns {*}
+ */
+ getCustomAttributeLabel: function (attribute) {
+ var resultAttribute;
+
+ if (typeof attribute === 'string') {
+ return attribute;
+ }
+
+ if (attribute.label) {
+ return attribute.label;
+ }
+
+ resultAttribute = _.findWhere(this.source.get('customAttributes')[attribute['attribute_code']], {
+ value: attribute.value
+ });
+
+ return resultAttribute && resultAttribute.label || attribute.value;
}
});
});
diff --git a/app/code/Magento/Checkout/view/frontend/web/js/view/shipping-information/address-renderer/default.js b/app/code/Magento/Checkout/view/frontend/web/js/view/shipping-information/address-renderer/default.js
index acc9f1c2391d9..009178cbb19b9 100644
--- a/app/code/Magento/Checkout/view/frontend/web/js/view/shipping-information/address-renderer/default.js
+++ b/app/code/Magento/Checkout/view/frontend/web/js/view/shipping-information/address-renderer/default.js
@@ -5,8 +5,9 @@
define([
'uiComponent',
+ 'underscore',
'Magento_Customer/js/customer-data'
-], function (Component, customerData) {
+], function (Component, _, customerData) {
'use strict';
var countryData = customerData.get('directory-data');
@@ -22,6 +23,30 @@ define([
*/
getCountryName: function (countryId) {
return countryData()[countryId] != undefined ? countryData()[countryId].name : ''; //eslint-disable-line
+ },
+
+ /**
+ * Get customer attribute label
+ *
+ * @param {*} attribute
+ * @returns {*}
+ */
+ getCustomAttributeLabel: function (attribute) {
+ var resultAttribute;
+
+ if (typeof attribute === 'string') {
+ return attribute;
+ }
+
+ if (attribute.label) {
+ return attribute.label;
+ }
+
+ resultAttribute = _.findWhere(this.source.get('customAttributes')[attribute['attribute_code']], {
+ value: attribute.value
+ });
+
+ return resultAttribute && resultAttribute.label || attribute.value;
}
});
});
diff --git a/app/code/Magento/Checkout/view/frontend/web/js/view/shipping-information/list.js b/app/code/Magento/Checkout/view/frontend/web/js/view/shipping-information/list.js
index 28eb83c8be3e3..3bb2715c78a7b 100644
--- a/app/code/Magento/Checkout/view/frontend/web/js/view/shipping-information/list.js
+++ b/app/code/Magento/Checkout/view/frontend/web/js/view/shipping-information/list.js
@@ -16,7 +16,8 @@ define([
var defaultRendererTemplate = {
parent: '${ $.$data.parentName }',
name: '${ $.$data.name }',
- component: 'Magento_Checkout/js/view/shipping-information/address-renderer/default'
+ component: 'Magento_Checkout/js/view/shipping-information/address-renderer/default',
+ provider: 'checkoutProvider'
};
return Component.extend({
diff --git a/app/code/Magento/Checkout/view/frontend/web/template/billing-address/details.html b/app/code/Magento/Checkout/view/frontend/web/template/billing-address/details.html
index a0827d17d6622..23bbce48fee2c 100644
--- a/app/code/Magento/Checkout/view/frontend/web/template/billing-address/details.html
+++ b/app/code/Magento/Checkout/view/frontend/web/template/billing-address/details.html
@@ -13,19 +13,8 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
From e703cc8a5ad1721cf2293b5aff31e3ee60e484ba Mon Sep 17 00:00:00 2001
From: Dmytro Poperechnyy
Date: Tue, 3 Sep 2019 18:10:13 -0500
Subject: [PATCH 127/937] MC-19247: Broken translations with advanced bundling
- Split mage/translate for adminhtml and frontend;
---
.../Backend/view/adminhtml/layout/default.xml | 1 +
.../view/adminhtml/requirejs-config.js | 3 +-
.../view/adminhtml/web/js/translate.js | 54 +++++++++++++++++++
.../Block/Html/Head/Dictionary.php | 18 +++++++
.../view/base/templates/dictionary.phtml | 4 +-
5 files changed, 78 insertions(+), 2 deletions(-)
create mode 100644 app/code/Magento/Backend/view/adminhtml/web/js/translate.js
diff --git a/app/code/Magento/Backend/view/adminhtml/layout/default.xml b/app/code/Magento/Backend/view/adminhtml/layout/default.xml
index b450102d7fc3d..a7faab0bc4673 100644
--- a/app/code/Magento/Backend/view/adminhtml/layout/default.xml
+++ b/app/code/Magento/Backend/view/adminhtml/layout/default.xml
@@ -77,6 +77,7 @@
+
diff --git a/app/code/Magento/Backend/view/adminhtml/requirejs-config.js b/app/code/Magento/Backend/view/adminhtml/requirejs-config.js
index ae0e84e2d27f8..e886f28cd158b 100644
--- a/app/code/Magento/Backend/view/adminhtml/requirejs-config.js
+++ b/app/code/Magento/Backend/view/adminhtml/requirejs-config.js
@@ -6,7 +6,8 @@
var config = {
map: {
'*': {
- 'mediaUploader': 'Magento_Backend/js/media-uploader'
+ 'mediaUploader': 'Magento_Backend/js/media-uploader',
+ 'mage/translate': 'Magento_Backend/js/translate'
}
}
};
diff --git a/app/code/Magento/Backend/view/adminhtml/web/js/translate.js b/app/code/Magento/Backend/view/adminhtml/web/js/translate.js
new file mode 100644
index 0000000000000..a9c30bf577918
--- /dev/null
+++ b/app/code/Magento/Backend/view/adminhtml/web/js/translate.js
@@ -0,0 +1,54 @@
+/**
+ * Copyright © Magento, Inc. All rights reserved.
+ * See COPYING.txt for license details.
+ */
+
+/* eslint-disable strict */
+(function (factory) {
+ if (typeof define === 'function' && define.amd) {
+ define([
+ 'jquery',
+ 'mage/mage'
+ ], factory);
+ } else {
+ factory(jQuery);
+ }
+}(function ($) {
+ $.extend(true, $, {
+ mage: {
+ translate: (function () {
+ /**
+ * Key-value translations storage
+ * @type {Object}
+ * @private
+ */
+ var _data = {};
+
+ /**
+ * Add new translation (two string parameters) or several translations (object)
+ */
+ this.add = function () {
+ if (arguments.length > 1) {
+ _data[arguments[0]] = arguments[1];
+ } else if (typeof arguments[0] === 'object') {
+ $.extend(_data, arguments[0]);
+ }
+ };
+
+ /**
+ * Make a translation with parsing (to handle case when _data represents tuple)
+ * @param {String} text
+ * @return {String}
+ */
+ this.translate = function (text) {
+ return _data[text] ? _data[text] : text;
+ };
+
+ return this;
+ }())
+ }
+ });
+ $.mage.__ = $.proxy($.mage.translate.translate, $.mage.translate);
+
+ return $.mage.__;
+}));
diff --git a/app/code/Magento/Translation/Block/Html/Head/Dictionary.php b/app/code/Magento/Translation/Block/Html/Head/Dictionary.php
index ef7b6d0ac8bfd..69e03f6b5e92d 100644
--- a/app/code/Magento/Translation/Block/Html/Head/Dictionary.php
+++ b/app/code/Magento/Translation/Block/Html/Head/Dictionary.php
@@ -26,21 +26,29 @@ class Dictionary extends Template
*/
protected $pageConfig;
+ /**
+ * @var JsConfig
+ */
+ private $config;
+
/**
* @param Template\Context $context
* @param PageConfig $pageConfig
* @param FileManager $fileManager
+ * @param JsConfig $config
* @param array $data
*/
public function __construct(
Template\Context $context,
PageConfig $pageConfig,
FileManager $fileManager,
+ JsConfig $config,
array $data = []
) {
parent::__construct($context, $data);
$this->pageConfig = $pageConfig;
$this->fileManager = $fileManager;
+ $this->config = $config;
}
/**
@@ -55,4 +63,14 @@ public function getTranslationDictionaryFile(): string
return $this->_assetRepo->getUrl($translateDictionaryConfigRelPath);
}
+
+ /**
+ * Is js translation set to dictionary mode
+ *
+ * @return bool
+ */
+ public function dictionaryEnabled(): bool
+ {
+ return $this->config->dictionaryEnabled();
+ }
}
diff --git a/app/code/Magento/Translation/view/base/templates/dictionary.phtml b/app/code/Magento/Translation/view/base/templates/dictionary.phtml
index 93b4a7c84def1..385b898a5e52c 100644
--- a/app/code/Magento/Translation/view/base/templates/dictionary.phtml
+++ b/app/code/Magento/Translation/view/base/templates/dictionary.phtml
@@ -6,7 +6,8 @@
/** @var \Magento\Translation\Block\Html\Head\Dictionary $block */
?>
-
+dictionaryEnabled()) : ?>
+
+
From 830e0c17b2d70fc6eae463f2232fae81dd665e5c Mon Sep 17 00:00:00 2001
From: Vaha
Date: Wed, 4 Sep 2019 11:48:49 +0300
Subject: [PATCH 128/937] magento/graphql-ce#893 improved strict typing in
SelectedShippingMethod
---
.../SelectedShippingMethod.php | 18 ++++++++-----
.../Magento/QuoteGraphQl/etc/schema.graphqls | 12 ++++-----
.../GetSelectedShippingMethodTest.php | 26 ++++++++++++-------
.../Guest/GetSelectedShippingMethodTest.php | 26 ++++++++++++-------
4 files changed, 50 insertions(+), 32 deletions(-)
diff --git a/app/code/Magento/QuoteGraphQl/Model/Resolver/ShippingAddress/SelectedShippingMethod.php b/app/code/Magento/QuoteGraphQl/Model/Resolver/ShippingAddress/SelectedShippingMethod.php
index f2dacf6d007f3..86a61a313b79f 100644
--- a/app/code/Magento/QuoteGraphQl/Model/Resolver/ShippingAddress/SelectedShippingMethod.php
+++ b/app/code/Magento/QuoteGraphQl/Model/Resolver/ShippingAddress/SelectedShippingMethod.php
@@ -31,8 +31,8 @@ public function resolve(Field $field, $context, ResolveInfo $info, array $value
/** @var Address $address */
$address = $value['model'];
$rates = $address->getAllShippingRates();
- $carrierTitle = null;
- $methodTitle = null;
+ $carrierTitle = '';
+ $methodTitle = '';
if (count($rates) > 0 && !empty($address->getShippingMethod())) {
list($carrierCode, $methodCode) = explode('_', $address->getShippingMethod(), 2);
@@ -65,12 +65,18 @@ public function resolve(Field $field, $context, ResolveInfo $info, array $value
];
} else {
$data = [
- 'carrier_code' => null,
- 'method_code' => null,
+ 'carrier_code' => '',
+ 'method_code' => '',
'carrier_title' => $carrierTitle,
'method_title' => $methodTitle,
- 'amount' => null,
- 'base_amount' => null,
+ 'amount' => [
+ 'value' => null,
+ 'currency' => null,
+ ],
+ 'base_amount' => [
+ 'value' => null,
+ 'currency' => null,
+ ],
];
}
return $data;
diff --git a/app/code/Magento/QuoteGraphQl/etc/schema.graphqls b/app/code/Magento/QuoteGraphQl/etc/schema.graphqls
index c458b5e9dc05d..f242aded3878b 100644
--- a/app/code/Magento/QuoteGraphQl/etc/schema.graphqls
+++ b/app/code/Magento/QuoteGraphQl/etc/schema.graphqls
@@ -239,12 +239,12 @@ type CartAddressCountry {
}
type SelectedShippingMethod {
- carrier_code: String
- method_code: String
- carrier_title: String
- method_title: String
- amount: Money
- base_amount: Money
+ carrier_code: String!
+ method_code: String!
+ carrier_title: String!
+ method_title: String!
+ amount: Money!
+ base_amount: Money!
}
type AvailableShippingMethod {
diff --git a/dev/tests/api-functional/testsuite/Magento/GraphQl/Quote/Customer/GetSelectedShippingMethodTest.php b/dev/tests/api-functional/testsuite/Magento/GraphQl/Quote/Customer/GetSelectedShippingMethodTest.php
index 9bb36bf8f0929..e42f675455eed 100644
--- a/dev/tests/api-functional/testsuite/Magento/GraphQl/Quote/Customer/GetSelectedShippingMethodTest.php
+++ b/dev/tests/api-functional/testsuite/Magento/GraphQl/Quote/Customer/GetSelectedShippingMethodTest.php
@@ -110,16 +110,16 @@ public function testGetSelectedShippingMethodBeforeSet()
self::assertArrayHasKey('selected_shipping_method', $shippingAddress);
self::assertArrayHasKey('carrier_code', $shippingAddress['selected_shipping_method']);
- self::assertNull($shippingAddress['selected_shipping_method']['carrier_code']);
+ self::assertEmpty($shippingAddress['selected_shipping_method']['carrier_code']);
self::assertArrayHasKey('method_code', $shippingAddress['selected_shipping_method']);
- self::assertNull($shippingAddress['selected_shipping_method']['method_code']);
+ self::assertEmpty($shippingAddress['selected_shipping_method']['method_code']);
self::assertArrayHasKey('carrier_title', $shippingAddress['selected_shipping_method']);
- self::assertNull($shippingAddress['selected_shipping_method']['carrier_title']);
+ self::assertEmpty($shippingAddress['selected_shipping_method']['carrier_title']);
self::assertArrayHasKey('method_title', $shippingAddress['selected_shipping_method']);
- self::assertNull($shippingAddress['selected_shipping_method']['method_title']);
+ self::assertEmpty($shippingAddress['selected_shipping_method']['method_title']);
}
/**
@@ -183,12 +183,18 @@ public function testGetGetSelectedShippingMethodIfShippingMethodIsNotSet()
$shippingAddress = current($response['cart']['shipping_addresses']);
self::assertArrayHasKey('selected_shipping_method', $shippingAddress);
- self::assertNull($shippingAddress['selected_shipping_method']['carrier_code']);
- self::assertNull($shippingAddress['selected_shipping_method']['method_code']);
- self::assertNull($shippingAddress['selected_shipping_method']['carrier_title']);
- self::assertNull($shippingAddress['selected_shipping_method']['method_title']);
- self::assertNull($shippingAddress['selected_shipping_method']['amount']);
- self::assertNull($shippingAddress['selected_shipping_method']['base_amount']);
+ self::assertEmpty($shippingAddress['selected_shipping_method']['carrier_code']);
+ self::assertEmpty($shippingAddress['selected_shipping_method']['method_code']);
+ self::assertEmpty($shippingAddress['selected_shipping_method']['carrier_title']);
+ self::assertEmpty($shippingAddress['selected_shipping_method']['method_title']);
+
+ self::assertArrayHasKey('amount', $shippingAddress['selected_shipping_method']);
+ self::assertNull($shippingAddress['selected_shipping_method']['amount']['value']);
+ self::assertNull($shippingAddress['selected_shipping_method']['amount']['currency']);
+
+ self::assertArrayHasKey('base_amount', $shippingAddress['selected_shipping_method']);
+ self::assertNull($shippingAddress['selected_shipping_method']['base_amount']['value']);
+ self::assertNull($shippingAddress['selected_shipping_method']['base_amount']['currency']);
}
/**
diff --git a/dev/tests/api-functional/testsuite/Magento/GraphQl/Quote/Guest/GetSelectedShippingMethodTest.php b/dev/tests/api-functional/testsuite/Magento/GraphQl/Quote/Guest/GetSelectedShippingMethodTest.php
index 5d1033b39819e..eaab4b16a8530 100644
--- a/dev/tests/api-functional/testsuite/Magento/GraphQl/Quote/Guest/GetSelectedShippingMethodTest.php
+++ b/dev/tests/api-functional/testsuite/Magento/GraphQl/Quote/Guest/GetSelectedShippingMethodTest.php
@@ -101,16 +101,16 @@ public function testGetSelectedShippingMethodBeforeSet()
self::assertArrayHasKey('selected_shipping_method', $shippingAddress);
self::assertArrayHasKey('carrier_code', $shippingAddress['selected_shipping_method']);
- self::assertNull($shippingAddress['selected_shipping_method']['carrier_code']);
+ self::assertEmpty($shippingAddress['selected_shipping_method']['carrier_code']);
self::assertArrayHasKey('method_code', $shippingAddress['selected_shipping_method']);
- self::assertNull($shippingAddress['selected_shipping_method']['method_code']);
+ self::assertEmpty($shippingAddress['selected_shipping_method']['method_code']);
self::assertArrayHasKey('carrier_title', $shippingAddress['selected_shipping_method']);
- self::assertNull($shippingAddress['selected_shipping_method']['carrier_title']);
+ self::assertEmpty($shippingAddress['selected_shipping_method']['carrier_title']);
self::assertArrayHasKey('method_title', $shippingAddress['selected_shipping_method']);
- self::assertNull($shippingAddress['selected_shipping_method']['method_title']);
+ self::assertEmpty($shippingAddress['selected_shipping_method']['method_title']);
}
/**
@@ -153,12 +153,18 @@ public function testGetGetSelectedShippingMethodIfShippingMethodIsNotSet()
$shippingAddress = current($response['cart']['shipping_addresses']);
self::assertArrayHasKey('selected_shipping_method', $shippingAddress);
- self::assertNull($shippingAddress['selected_shipping_method']['carrier_code']);
- self::assertNull($shippingAddress['selected_shipping_method']['method_code']);
- self::assertNull($shippingAddress['selected_shipping_method']['carrier_title']);
- self::assertNull($shippingAddress['selected_shipping_method']['method_title']);
- self::assertNull($shippingAddress['selected_shipping_method']['amount']);
- self::assertNull($shippingAddress['selected_shipping_method']['base_amount']);
+ self::assertEmpty($shippingAddress['selected_shipping_method']['carrier_code']);
+ self::assertEmpty($shippingAddress['selected_shipping_method']['method_code']);
+ self::assertEmpty($shippingAddress['selected_shipping_method']['carrier_title']);
+ self::assertEmpty($shippingAddress['selected_shipping_method']['method_title']);
+
+ self::assertArrayHasKey('amount', $shippingAddress['selected_shipping_method']);
+ self::assertNull($shippingAddress['selected_shipping_method']['amount']['value']);
+ self::assertNull($shippingAddress['selected_shipping_method']['amount']['currency']);
+
+ self::assertArrayHasKey('base_amount', $shippingAddress['selected_shipping_method']);
+ self::assertNull($shippingAddress['selected_shipping_method']['base_amount']['value']);
+ self::assertNull($shippingAddress['selected_shipping_method']['base_amount']['currency']);
}
/**
From 882bbaec90da72afbe74ca4540d332146da8536a Mon Sep 17 00:00:00 2001
From: Yuliya Labudova
Date: Wed, 4 Sep 2019 12:37:12 +0300
Subject: [PATCH 129/937] MAGETWO-94565: Catalog product collection filters
produce errors and cause inconsistent behaviour
- Change fetchRow to fetchOne.
---
app/code/Magento/Catalog/Model/ResourceModel/Category.php | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
diff --git a/app/code/Magento/Catalog/Model/ResourceModel/Category.php b/app/code/Magento/Catalog/Model/ResourceModel/Category.php
index b6f565f5fae4e..fb8c089ed9f9a 100644
--- a/app/code/Magento/Catalog/Model/ResourceModel/Category.php
+++ b/app/code/Magento/Catalog/Model/ResourceModel/Category.php
@@ -1148,14 +1148,13 @@ public function getCategoryWithChildren(int $categoryId): array
{
$connection = $this->getConnection();
- $select = $connection->select()
+ $selectAttributeCode = $connection->select()
->from(
['eav_attribute' => $this->getTable('eav_attribute')],
['attribute_id']
)->where('entity_type_id = ?', CategorySetup::CATEGORY_ENTITY_TYPE_ID)
->where('attribute_code = ?', 'is_anchor')
->limit(1);
- $attributeId = $connection->fetchRow($select);
$select = $connection->select()
->from(
@@ -1167,7 +1166,7 @@ public function getCategoryWithChildren(int $categoryId): array
['is_anchor' => 'cce_int.value']
)->where(
'cce_int.attribute_id = ?',
- $attributeId['attribute_id']
+ $connection->fetchOne($selectAttributeCode)
)->where(
"cce.path LIKE '%/{$categoryId}' OR cce.path LIKE '%/{$categoryId}/%'"
)->order('path');
From 60ce6fad3d6ce5c32cfdd3b3b5cf711b7183b7f6 Mon Sep 17 00:00:00 2001
From: Veronika Kurochkina
Date: Tue, 3 Sep 2019 14:26:10 +0300
Subject: [PATCH 130/937] MC-18826: Increase test coverage for Cart & Checkout
and Order Processing functional areas
- Integration test for MAGETWO-99376
---
.../Sales/Model/ResourceModel/OrderTest.php | 55 +++++++++++++++++++
.../Store/_files/store_with_long_name.php | 50 +++++++++++++++++
.../_files/store_with_long_name_rollback.php | 34 ++++++++++++
3 files changed, 139 insertions(+)
create mode 100644 dev/tests/integration/testsuite/Magento/Store/_files/store_with_long_name.php
create mode 100644 dev/tests/integration/testsuite/Magento/Store/_files/store_with_long_name_rollback.php
diff --git a/dev/tests/integration/testsuite/Magento/Sales/Model/ResourceModel/OrderTest.php b/dev/tests/integration/testsuite/Magento/Sales/Model/ResourceModel/OrderTest.php
index d6fe86b6232d3..9e102fab1d963 100644
--- a/dev/tests/integration/testsuite/Magento/Sales/Model/ResourceModel/OrderTest.php
+++ b/dev/tests/integration/testsuite/Magento/Sales/Model/ResourceModel/OrderTest.php
@@ -3,8 +3,14 @@
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
+declare(strict_types=1);
+
namespace Magento\Sales\Model\ResourceModel;
+use Magento\Store\Api\StoreRepositoryInterface;
+use Magento\Store\Model\StoreManagerInterface;
+use Magento\Framework\Event\ManagerInterface;
+
class OrderTest extends \PHPUnit\Framework\TestCase
{
/**
@@ -22,13 +28,31 @@ class OrderTest extends \PHPUnit\Framework\TestCase
*/
protected $objectManager;
+ /**
+ * @var StoreManagerInterface
+ */
+ private $storeManager;
+
+ /**
+ * @var StoreRepositoryInterface
+ */
+ private $storeRepository;
+
+ /**
+ * @inheritdoc
+ */
protected function setUp()
{
$this->objectManager = \Magento\TestFramework\Helper\Bootstrap::getObjectManager();
$this->resourceModel = $this->objectManager->create(\Magento\Sales\Model\ResourceModel\Order::class);
$this->orderIncrementId = '100000001';
+ $this->storeManager = $this->objectManager->get(StoreManagerInterface::class);
+ $this->storeRepository = $this->objectManager->get(StoreRepositoryInterface::class);
}
+ /**
+ * @inheritdoc
+ */
protected function tearDown()
{
$registry = $this->objectManager->get(\Magento\Framework\Registry::class);
@@ -43,6 +67,9 @@ protected function tearDown()
$registry->unregister('isSecureArea');
$registry->register('isSecureArea', false);
+ $defaultStore = $this->storeRepository->get('default');
+ $this->storeManager->setCurrentStore($defaultStore->getId());
+
parent::tearDown();
}
@@ -108,4 +135,32 @@ public function testSaveOrder()
$this->assertNotNull($order->getCreatedAt());
$this->assertNotNull($order->getUpdatedAt());
}
+
+ /**
+ * Check that store name with length within 255 chars can be saved in table sales_order
+ *
+ * @magentoDataFixture Magento/Store/_files/store_with_long_name.php
+ * @return void
+ */
+ public function testSaveStoreName()
+ {
+ $storeName = str_repeat('a', 220);
+ $store = $this->storeRepository->get('test_2');
+ $this->storeManager->setCurrentStore($store->getId());
+ $eventManager = $this->objectManager->get(ManagerInterface::class);
+ $eventManager->dispatch('store_add', ['store' => $store]);
+ $order = $this->objectManager->create(\Magento\Sales\Model\Order::class);
+ $payment = $this->objectManager->create(\Magento\Sales\Model\Order\Payment::class);
+ $payment->setMethod('checkmo');
+ $order->setStoreId($store->getId())->setPayment($payment);
+ $this->resourceModel->save($order);
+ $this->resourceModel->load($order, $storeName, 'store_name');
+ $name = [
+ 'Main Website',
+ 'Main Website Store',
+ $storeName,
+ ];
+ $expectedStoreName = implode(PHP_EOL, $name);
+ $this->assertEquals($expectedStoreName, $order->getStoreName());
+ }
}
diff --git a/dev/tests/integration/testsuite/Magento/Store/_files/store_with_long_name.php b/dev/tests/integration/testsuite/Magento/Store/_files/store_with_long_name.php
new file mode 100644
index 0000000000000..c225519e2b2b8
--- /dev/null
+++ b/dev/tests/integration/testsuite/Magento/Store/_files/store_with_long_name.php
@@ -0,0 +1,50 @@
+create(\Magento\Store\Model\Store::class);
+$storeName = str_repeat('a', 220);
+if (!$store->load('test', 'code')->getId()) {
+ $store->setData(
+ [
+ 'code' => 'test_2',
+ 'website_id' => '1',
+ 'group_id' => '1',
+ 'name' => $storeName,
+ 'sort_order' => '10',
+ 'is_active' => '1',
+ ]
+ );
+ $store->save();
+} else {
+ if ($store->getId()) {
+ /** @var \Magento\TestFramework\Helper\Bootstrap $registry */
+ $registry = \Magento\TestFramework\Helper\Bootstrap::getObjectManager()->get(
+ \Magento\Framework\Registry::class
+ );
+ $registry->unregister('isSecureArea');
+ $registry->register('isSecureArea', true);
+
+ $store->delete();
+
+ $registry->unregister('isSecureArea');
+ $registry->register('isSecureArea', false);
+
+ $store = \Magento\TestFramework\Helper\Bootstrap::getObjectManager()->create(\Magento\Store\Model\Store::class);
+ $store->setData(
+ [
+ 'code' => 'test_2',
+ 'website_id' => '1',
+ 'group_id' => '1',
+ 'name' => $storeName,
+ 'sort_order' => '10',
+ 'is_active' => '1',
+ ]
+ );
+ $store->save();
+ }
+}
diff --git a/dev/tests/integration/testsuite/Magento/Store/_files/store_with_long_name_rollback.php b/dev/tests/integration/testsuite/Magento/Store/_files/store_with_long_name_rollback.php
new file mode 100644
index 0000000000000..5fe19e1e97df1
--- /dev/null
+++ b/dev/tests/integration/testsuite/Magento/Store/_files/store_with_long_name_rollback.php
@@ -0,0 +1,34 @@
+get(Registry::class);
+$registry->unregister('isSecureArea');
+$registry->register('isSecureArea', true);
+
+/** @var Store $store */
+$store = $objectManager->get(Store::class);
+$store->load('test_2', 'code');
+if ($store->getId()) {
+ $store->delete();
+}
+
+/** @var Store $store */
+$store = $objectManager->get(Store::class);
+$store->load('test_2', 'code');
+if ($store->getId()) {
+ $store->delete();
+}
+
+$registry->unregister('isSecureArea');
+$registry->register('isSecureArea', false);
From 976bd23483deb6a02c5e2eb2ee8754e834db026e Mon Sep 17 00:00:00 2001
From: Nikita Chubukov
Date: Wed, 4 Sep 2019 12:37:37 +0300
Subject: [PATCH 131/937] MC-15256: Exported customer without modification can
not be imported
- Fix CR comments
---
.../CustomerImportExport/Model/Import/CustomerTest.php | 2 +-
.../Model/Import/_files/customers_to_import.csv | 4 ++--
.../Import/_files/customers_with_gender_to_import.csv | 7 +++++++
3 files changed, 10 insertions(+), 3 deletions(-)
create mode 100644 dev/tests/integration/testsuite/Magento/CustomerImportExport/Model/Import/_files/customers_with_gender_to_import.csv
diff --git a/dev/tests/integration/testsuite/Magento/CustomerImportExport/Model/Import/CustomerTest.php b/dev/tests/integration/testsuite/Magento/CustomerImportExport/Model/Import/CustomerTest.php
index daab687408749..77ceae27e0774 100644
--- a/dev/tests/integration/testsuite/Magento/CustomerImportExport/Model/Import/CustomerTest.php
+++ b/dev/tests/integration/testsuite/Magento/CustomerImportExport/Model/Import/CustomerTest.php
@@ -78,7 +78,7 @@ public function testImportData()
$expectAddedCustomers = 5;
$source = new \Magento\ImportExport\Model\Import\Source\Csv(
- __DIR__ . '/_files/customers_to_import.csv',
+ __DIR__ . '/_files/customers_with_gender_to_import.csv',
$this->directoryWrite
);
diff --git a/dev/tests/integration/testsuite/Magento/CustomerImportExport/Model/Import/_files/customers_to_import.csv b/dev/tests/integration/testsuite/Magento/CustomerImportExport/Model/Import/_files/customers_to_import.csv
index 96c14c67607aa..30a283ce0502f 100644
--- a/dev/tests/integration/testsuite/Magento/CustomerImportExport/Model/Import/_files/customers_to_import.csv
+++ b/dev/tests/integration/testsuite/Magento/CustomerImportExport/Model/Import/_files/customers_to_import.csv
@@ -1,7 +1,7 @@
email,_website,_store,confirmation,created_at,created_in,default_billing,default_shipping,disable_auto_group_change,dob,firstname,gender,group_id,lastname,middlename,password_hash,prefix,rp_token,rp_token_created_at,store_id,suffix,taxvat,website_id,password
-AnthonyANealy@magento.com,base,admin,,5/6/2012 15:53,Admin,1,1,0,5/6/2010,Anthony,Female,1,Nealy,A.,6a9c9bfb2ba88a6ad2a64e7402df44a763e0c48cd21d7af9e7e796cd4677ee28:RF,,,,0,,,1,
+AnthonyANealy@magento.com,base,admin,,5/6/2012 15:53,Admin,1,1,0,5/6/2010,Anthony,Male,1,Nealy,A.,6a9c9bfb2ba88a6ad2a64e7402df44a763e0c48cd21d7af9e7e796cd4677ee28:RF,,,,0,,,1,
LoriBBanks@magento.com,admin,admin,,5/6/2012 15:59,Admin,3,3,0,5/6/2010,Lori,Female,1,Banks,B.,7ad6dbdc83d3e9f598825dc58b84678c7351e4281f6bc2b277a32dcd88b9756b:pz,,,,0,,,0,
CharlesTAlston@teleworm.us,base,admin,,5/6/2012 16:13,Admin,4,4,0,,Jhon,Female,1,Doe,T.,145d12bfff8a6a279eb61e277e3d727c0ba95acc1131237f1594ddbb7687a564:l1,,,,0,,,2,
-customer@example.com,base,admin,,5/6/2012 16:15,Admin,4,4,0,,Firstname,Female,1,Lastname,T.,145d12bfff8a6a279eb61e277e3d727c0ba95acc1131237f1594ddbb7687a564:l1,,,,0,,,2,
+customer@example.com,base,admin,,5/6/2012 16:15,Admin,4,4,0,,Firstname,Male,1,Lastname,T.,145d12bfff8a6a279eb61e277e3d727c0ba95acc1131237f1594ddbb7687a564:l1,,,,0,,,2,
julie.worrell@example.com,base,admin,,5/6/2012 16:19,Admin,4,4,0,,Julie,Female,1,Worrell,T.,145d12bfff8a6a279eb61e277e3d727c0ba95acc1131237f1594ddbb7687a564:l1,,,,0,,,2,
david.lamar@example.com,base,admin,,5/6/2012 16:25,Admin,4,4,0,,David,,1,Lamar,T.,145d12bfff8a6a279eb61e277e3d727c0ba95acc1131237f1594ddbb7687a564:l1,,,,0,,,2,
diff --git a/dev/tests/integration/testsuite/Magento/CustomerImportExport/Model/Import/_files/customers_with_gender_to_import.csv b/dev/tests/integration/testsuite/Magento/CustomerImportExport/Model/Import/_files/customers_with_gender_to_import.csv
new file mode 100644
index 0000000000000..96c14c67607aa
--- /dev/null
+++ b/dev/tests/integration/testsuite/Magento/CustomerImportExport/Model/Import/_files/customers_with_gender_to_import.csv
@@ -0,0 +1,7 @@
+email,_website,_store,confirmation,created_at,created_in,default_billing,default_shipping,disable_auto_group_change,dob,firstname,gender,group_id,lastname,middlename,password_hash,prefix,rp_token,rp_token_created_at,store_id,suffix,taxvat,website_id,password
+AnthonyANealy@magento.com,base,admin,,5/6/2012 15:53,Admin,1,1,0,5/6/2010,Anthony,Female,1,Nealy,A.,6a9c9bfb2ba88a6ad2a64e7402df44a763e0c48cd21d7af9e7e796cd4677ee28:RF,,,,0,,,1,
+LoriBBanks@magento.com,admin,admin,,5/6/2012 15:59,Admin,3,3,0,5/6/2010,Lori,Female,1,Banks,B.,7ad6dbdc83d3e9f598825dc58b84678c7351e4281f6bc2b277a32dcd88b9756b:pz,,,,0,,,0,
+CharlesTAlston@teleworm.us,base,admin,,5/6/2012 16:13,Admin,4,4,0,,Jhon,Female,1,Doe,T.,145d12bfff8a6a279eb61e277e3d727c0ba95acc1131237f1594ddbb7687a564:l1,,,,0,,,2,
+customer@example.com,base,admin,,5/6/2012 16:15,Admin,4,4,0,,Firstname,Female,1,Lastname,T.,145d12bfff8a6a279eb61e277e3d727c0ba95acc1131237f1594ddbb7687a564:l1,,,,0,,,2,
+julie.worrell@example.com,base,admin,,5/6/2012 16:19,Admin,4,4,0,,Julie,Female,1,Worrell,T.,145d12bfff8a6a279eb61e277e3d727c0ba95acc1131237f1594ddbb7687a564:l1,,,,0,,,2,
+david.lamar@example.com,base,admin,,5/6/2012 16:25,Admin,4,4,0,,David,,1,Lamar,T.,145d12bfff8a6a279eb61e277e3d727c0ba95acc1131237f1594ddbb7687a564:l1,,,,0,,,2,
From bf3df0dec2729159a7c7ca4129c586ee9ede7163 Mon Sep 17 00:00:00 2001
From: Lusine Papyan
Date: Wed, 4 Sep 2019 16:51:29 +0400
Subject: [PATCH 132/937] MC-18823: Increase test coverage for Framework and
Performance functional areas
- Automation test for MC-11158
---
.../AdminCheckInputFieldsDisabledAfterAppConfigDumpTest.xml | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/app/code/Magento/Shipping/Test/Mftf/Test/AdminCheckInputFieldsDisabledAfterAppConfigDumpTest.xml b/app/code/Magento/Shipping/Test/Mftf/Test/AdminCheckInputFieldsDisabledAfterAppConfigDumpTest.xml
index 519fecc313f71..c144d6f21b647 100644
--- a/app/code/Magento/Shipping/Test/Mftf/Test/AdminCheckInputFieldsDisabledAfterAppConfigDumpTest.xml
+++ b/app/code/Magento/Shipping/Test/Mftf/Test/AdminCheckInputFieldsDisabledAfterAppConfigDumpTest.xml
@@ -11,7 +11,7 @@
-
+
From cd8f6bff21f80b91723d42398c834fc3a3777ff6 Mon Sep 17 00:00:00 2001
From: Ravi Chandra
Date: Wed, 4 Sep 2019 19:48:08 +0530
Subject: [PATCH 133/937] product back redirect navigate from customer view
cart product
---
.../Adminhtml/Product/Edit/Button/Back.php | 19 ++++++++++++++++++-
.../Block/Adminhtml/Edit/Tab/Cart.php | 14 ++++++++++----
2 files changed, 28 insertions(+), 5 deletions(-)
diff --git a/app/code/Magento/Catalog/Block/Adminhtml/Product/Edit/Button/Back.php b/app/code/Magento/Catalog/Block/Adminhtml/Product/Edit/Button/Back.php
index db42bb66c9bd1..60e17599f6dec 100644
--- a/app/code/Magento/Catalog/Block/Adminhtml/Product/Edit/Button/Back.php
+++ b/app/code/Magento/Catalog/Block/Adminhtml/Product/Edit/Button/Back.php
@@ -11,15 +11,32 @@
class Back extends Generic
{
/**
+ * Get Button Data
+ *
* @return array
*/
public function getButtonData()
{
return [
'label' => __('Back'),
- 'on_click' => sprintf("location.href = '%s';", $this->getUrl('*/*/')),
+ 'on_click' => sprintf("location.href = '%s';", $this->getBackUrl()),
'class' => 'back',
'sort_order' => 10
];
}
+ /**
+ * Get URL for back
+ *
+ * @return string
+ */
+ private function getBackUrl()
+ {
+ if ($this->context->getRequestParam('customerId')) {
+ return $this->getUrl(
+ 'customer/index/edit',
+ ['id' => $this->context->getRequestParam('customerId')]
+ );
+ }
+ return $this->getUrl('*/*/');
+ }
}
diff --git a/app/code/Magento/Customer/Block/Adminhtml/Edit/Tab/Cart.php b/app/code/Magento/Customer/Block/Adminhtml/Edit/Tab/Cart.php
index db560f7de3ecb..3709f4914c477 100644
--- a/app/code/Magento/Customer/Block/Adminhtml/Edit/Tab/Cart.php
+++ b/app/code/Magento/Customer/Block/Adminhtml/Edit/Tab/Cart.php
@@ -75,7 +75,7 @@ public function __construct(
}
/**
- * {@inheritdoc}
+ * @inheritdoc
*/
protected function _construct()
{
@@ -119,7 +119,7 @@ protected function _prepareCollection()
}
/**
- * {@inheritdoc}
+ * @inheritdoc
*/
protected function _prepareColumns()
{
@@ -201,7 +201,7 @@ public function getCustomerId()
}
/**
- * {@inheritdoc}
+ * @inheritdoc
*/
public function getGridUrl()
{
@@ -224,7 +224,13 @@ public function getGridParentHtml()
*/
public function getRowUrl($row)
{
- return $this->getUrl('catalog/product/edit', ['id' => $row->getProductId()]);
+ return $this->getUrl(
+ 'catalog/product/edit',
+ [
+ 'id' => $row->getProductId(),
+ 'customerId' => $this->getCustomerId()
+ ]
+ );
}
/**
From 71d1ebc5d9287f885f07ca75060d86a4a03f678a Mon Sep 17 00:00:00 2001
From: Rus0
Date: Wed, 4 Sep 2019 10:14:43 -0500
Subject: [PATCH 134/937] Semantic build failed
---
app/code/Magento/Wishlist/Model/Wishlist.php | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/app/code/Magento/Wishlist/Model/Wishlist.php b/app/code/Magento/Wishlist/Model/Wishlist.php
index 827607e72f807..21a900b234390 100644
--- a/app/code/Magento/Wishlist/Model/Wishlist.php
+++ b/app/code/Magento/Wishlist/Model/Wishlist.php
@@ -370,7 +370,8 @@ protected function _addCatalogProduct(Product $product, $qty = 1, $forciblySetQt
/**
* Retrieve wishlist item collection
*
- * @return ResourceModel\Item\Collection
+ * @return \Magento\Wishlist\Model\ResourceModel\Item\Collection
+ * @throws NoSuchEntityException
*/
public function getItemCollection()
{
@@ -606,7 +607,7 @@ public function setSharedStoreIds($storeIds)
/**
* Retrieve wishlist store object
*
- * @return Store
+ * @return \Magento\Store\Model\Store
* @throws NoSuchEntityException
*/
public function getStore()
From aa55e958b40dabdb839ae413cdebebe49e0df4e3 Mon Sep 17 00:00:00 2001
From: Oleksandr Iegorov
Date: Wed, 4 Sep 2019 11:11:09 -0500
Subject: [PATCH 135/937] MC-19791: Poor performance on sales order update -
string to integer
---
.../Magento/Framework/Model/ResourceModel/Db/AbstractDb.php | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/lib/internal/Magento/Framework/Model/ResourceModel/Db/AbstractDb.php b/lib/internal/Magento/Framework/Model/ResourceModel/Db/AbstractDb.php
index fc0edf931fa9c..67cd6679de98d 100644
--- a/lib/internal/Magento/Framework/Model/ResourceModel/Db/AbstractDb.php
+++ b/lib/internal/Magento/Framework/Model/ResourceModel/Db/AbstractDb.php
@@ -793,7 +793,10 @@ protected function saveNewObject(\Magento\Framework\Model\AbstractModel $object)
*/
protected function updateObject(\Magento\Framework\Model\AbstractModel $object)
{
- $condition = $this->getConnection()->quoteInto($this->getIdFieldName() . '=?', $object->getId());
+ //quoting integer values as strings may decrease query performance on some environments
+ $condition = is_int($object->getId())
+ ? $this->getIdFieldName() . '=' . (int) $object->getId()
+ : $this->getConnection()->quoteInto($this->getIdFieldName() . '=?', $object->getId());
/**
* Not auto increment primary key support
*/
From 6cbe1f482913d24e15e4b6df1549bae5bc49a7e2 Mon Sep 17 00:00:00 2001
From: Oleksandr Iegorov
Date: Wed, 4 Sep 2019 11:16:25 -0500
Subject: [PATCH 136/937] MC-19791: Poor performance on sales order update -
string to integer
---
.../Magento/Framework/Model/ResourceModel/Db/AbstractDb.php | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/lib/internal/Magento/Framework/Model/ResourceModel/Db/AbstractDb.php b/lib/internal/Magento/Framework/Model/ResourceModel/Db/AbstractDb.php
index 67cd6679de98d..3fd44db548149 100644
--- a/lib/internal/Magento/Framework/Model/ResourceModel/Db/AbstractDb.php
+++ b/lib/internal/Magento/Framework/Model/ResourceModel/Db/AbstractDb.php
@@ -793,8 +793,8 @@ protected function saveNewObject(\Magento\Framework\Model\AbstractModel $object)
*/
protected function updateObject(\Magento\Framework\Model\AbstractModel $object)
{
- //quoting integer values as strings may decrease query performance on some environments
- $condition = is_int($object->getId())
+ //quoting numeric values as strings may decrease query performance on some environments
+ $condition = is_numeric($object->getId())
? $this->getIdFieldName() . '=' . (int) $object->getId()
: $this->getConnection()->quoteInto($this->getIdFieldName() . '=?', $object->getId());
/**
From 4b2db0f7a29e5c13cfbc06c33b401ba9d34bd0c2 Mon Sep 17 00:00:00 2001
From: Oleksandr Iegorov
Date: Wed, 4 Sep 2019 12:19:38 -0500
Subject: [PATCH 137/937] MC-19791: Poor performance on sales order update -
string to integer
---
.../Model/Test/Unit/ResourceModel/Db/AbstractDbTest.php | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/lib/internal/Magento/Framework/Model/Test/Unit/ResourceModel/Db/AbstractDbTest.php b/lib/internal/Magento/Framework/Model/Test/Unit/ResourceModel/Db/AbstractDbTest.php
index b69f50cf4f341..fea17c3c0b8c2 100644
--- a/lib/internal/Magento/Framework/Model/Test/Unit/ResourceModel/Db/AbstractDbTest.php
+++ b/lib/internal/Magento/Framework/Model/Test/Unit/ResourceModel/Db/AbstractDbTest.php
@@ -489,7 +489,7 @@ public function testPrepareDataForUpdate()
->with(
'tableName',
$newData,
- 'idFieldName'
+ 'idFieldName=0'
);
$select = $this->getMockBuilder(\Magento\Framework\DB\Select::class)
->disableOriginalConstructor()
From 9a1b78154950da21073ee762ccd43e3e789766c5 Mon Sep 17 00:00:00 2001
From: Rus0
Date: Wed, 4 Sep 2019 12:41:44 -0500
Subject: [PATCH 138/937] Refactor the way for getting the stock, using the
current product instead of instantiating a new stock item
---
app/code/Magento/Wishlist/Model/Wishlist.php | 38 ++++++++++----------
1 file changed, 20 insertions(+), 18 deletions(-)
diff --git a/app/code/Magento/Wishlist/Model/Wishlist.php b/app/code/Magento/Wishlist/Model/Wishlist.php
index 21a900b234390..d8e244b7827d3 100644
--- a/app/code/Magento/Wishlist/Model/Wishlist.php
+++ b/app/code/Magento/Wishlist/Model/Wishlist.php
@@ -32,7 +32,6 @@
use Magento\Wishlist\Model\ResourceModel\Item\CollectionFactory;
use Magento\Wishlist\Model\ResourceModel\Wishlist as ResourceWishlist;
use Magento\Wishlist\Model\ResourceModel\Wishlist\Collection;
-use Magento\CatalogInventory\Model\Stock\StockItemRepository;
/**
* Wishlist model
@@ -148,11 +147,6 @@ class Wishlist extends AbstractModel implements IdentityInterface
*/
private $serializer;
- /**
- * @var StockItemRepository
- */
- private $stockItemRepository;
-
/**
* @var ScopeConfigInterface
*/
@@ -178,7 +172,6 @@ class Wishlist extends AbstractModel implements IdentityInterface
* @param bool $useCurrentWebsite
* @param array $data
* @param Json|null $serializer
- * @param StockItemRepository|null $stockItemRepository
* @param ScopeConfigInterface|null $scopeConfig
* @SuppressWarnings(PHPMD.ExcessiveParameterList)
*/
@@ -200,7 +193,6 @@ public function __construct(
$useCurrentWebsite = true,
array $data = [],
Json $serializer = null,
- StockItemRepository $stockItemRepository = null,
ScopeConfigInterface $scopeConfig = null
) {
$this->_useCurrentWebsite = $useCurrentWebsite;
@@ -216,9 +208,6 @@ public function __construct(
$this->serializer = $serializer ?: ObjectManager::getInstance()->get(Json::class);
parent::__construct($context, $registry, $resource, $resourceCollection, $data);
$this->productRepository = $productRepository;
- $this->stockItemRepository = $stockItemRepository ?: ObjectManager::getInstance()->get(
- StockItemRepository::class
- );
$this->scopeConfig = $scopeConfig ?: ObjectManager::getInstance()->get(ScopeConfigInterface::class);
}
@@ -452,18 +441,13 @@ public function addNewItem($product, $buyRequest = null, $forciblySetQty = false
}
try {
+ /** @var Product $product */
$product = $this->productRepository->getById($productId, false, $storeId);
} catch (NoSuchEntityException $e) {
throw new LocalizedException(__('Cannot specify product.'));
}
- /** @var \Magento\CatalogInventory\Api\Data\StockItemInterface $stockItem */
- $stockItem = $this->stockItemRepository->get($productId);
- $showOutOfStock = $this->scopeConfig->isSetFlag(
- Configuration::XML_PATH_SHOW_OUT_OF_STOCK,
- ScopeInterface::SCOPE_STORE
- );
- if (!$stockItem->getIsInStock() && !$showOutOfStock) {
+ if ($this->isInStock($product)) {
throw new LocalizedException(__('Cannot add product without stock to wishlist.'));
}
@@ -655,6 +639,24 @@ public function isSalable()
return false;
}
+ /**
+ * Retrieve if product has stock or config is set for showing out of stock products
+ *
+ * @param \Magento\Catalog\Api\Data\ProductInterface $product
+ * @return bool
+ */
+ public function isInStock(\Magento\Catalog\Api\Data\ProductInterface $product)
+ {
+ /** @var \Magento\CatalogInventory\Api\Data\StockItemInterface $stockItem */
+ $stockItem = $product->getExtensionAttributes()->getStockItem();
+ $showOutOfStock = $this->scopeConfig->isSetFlag(
+ Configuration::XML_PATH_SHOW_OUT_OF_STOCK,
+ ScopeInterface::SCOPE_STORE
+ );
+ $isInStock = $stockItem ? $stockItem->getIsInStock() : false;
+ return !$isInStock && !$showOutOfStock;
+ }
+
/**
* Check customer is owner this wishlist
*
From 964105c807e31449f41cdaba8fd79068d2daa694 Mon Sep 17 00:00:00 2001
From: Rus0
Date: Wed, 4 Sep 2019 14:04:22 -0500
Subject: [PATCH 139/937] Another refactor, optimal way for receiving the
object
---
app/code/Magento/Wishlist/Model/Wishlist.php | 20 ++++++++++++----
.../Wishlist/Test/Unit/Model/WishlistTest.php | 24 +++++++++++--------
2 files changed, 29 insertions(+), 15 deletions(-)
diff --git a/app/code/Magento/Wishlist/Model/Wishlist.php b/app/code/Magento/Wishlist/Model/Wishlist.php
index d8e244b7827d3..329f3e591e25b 100644
--- a/app/code/Magento/Wishlist/Model/Wishlist.php
+++ b/app/code/Magento/Wishlist/Model/Wishlist.php
@@ -12,6 +12,8 @@
use Magento\Catalog\Api\ProductRepositoryInterface;
use Magento\Catalog\Model\Product;
use Magento\Catalog\Model\ProductFactory;
+use Magento\CatalogInventory\Api\Data\StockItemInterface;
+use Magento\CatalogInventory\Api\StockRegistryInterface;
use Magento\CatalogInventory\Model\Configuration;
use Magento\Framework\App\Config\ScopeConfigInterface;
use Magento\Framework\App\ObjectManager;
@@ -152,6 +154,11 @@ class Wishlist extends AbstractModel implements IdentityInterface
*/
private $scopeConfig;
+ /**
+ * @var StockRegistryInterface|null
+ */
+ private $stockRegistry;
+
/**
* Constructor
*
@@ -172,6 +179,7 @@ class Wishlist extends AbstractModel implements IdentityInterface
* @param bool $useCurrentWebsite
* @param array $data
* @param Json|null $serializer
+ * @param StockRegistryInterface|null $stockRegistry
* @param ScopeConfigInterface|null $scopeConfig
* @SuppressWarnings(PHPMD.ExcessiveParameterList)
*/
@@ -193,6 +201,7 @@ public function __construct(
$useCurrentWebsite = true,
array $data = [],
Json $serializer = null,
+ StockRegistryInterface $stockRegistry = null,
ScopeConfigInterface $scopeConfig = null
) {
$this->_useCurrentWebsite = $useCurrentWebsite;
@@ -209,6 +218,7 @@ public function __construct(
parent::__construct($context, $registry, $resource, $resourceCollection, $data);
$this->productRepository = $productRepository;
$this->scopeConfig = $scopeConfig ?: ObjectManager::getInstance()->get(ScopeConfigInterface::class);
+ $this->stockRegistry = $stockRegistry ?: ObjectManager::getInstance()->get(StockRegistryInterface::class);
}
/**
@@ -447,7 +457,7 @@ public function addNewItem($product, $buyRequest = null, $forciblySetQty = false
throw new LocalizedException(__('Cannot specify product.'));
}
- if ($this->isInStock($product)) {
+ if ($this->isInStock($productId)) {
throw new LocalizedException(__('Cannot add product without stock to wishlist.'));
}
@@ -642,13 +652,13 @@ public function isSalable()
/**
* Retrieve if product has stock or config is set for showing out of stock products
*
- * @param \Magento\Catalog\Api\Data\ProductInterface $product
+ * @param int $productId
* @return bool
*/
- public function isInStock(\Magento\Catalog\Api\Data\ProductInterface $product)
+ private function isInStock($productId)
{
- /** @var \Magento\CatalogInventory\Api\Data\StockItemInterface $stockItem */
- $stockItem = $product->getExtensionAttributes()->getStockItem();
+ /** @var StockItemInterface $stockItem */
+ $stockItem = $this->stockRegistry->getStockItem($productId);
$showOutOfStock = $this->scopeConfig->isSetFlag(
Configuration::XML_PATH_SHOW_OUT_OF_STOCK,
ScopeInterface::SCOPE_STORE
diff --git a/app/code/Magento/Wishlist/Test/Unit/Model/WishlistTest.php b/app/code/Magento/Wishlist/Test/Unit/Model/WishlistTest.php
index 4d4d1a235de1d..eb788efc0d622 100644
--- a/app/code/Magento/Wishlist/Test/Unit/Model/WishlistTest.php
+++ b/app/code/Magento/Wishlist/Test/Unit/Model/WishlistTest.php
@@ -11,6 +11,7 @@
use Magento\Catalog\Model\Product;
use Magento\Catalog\Model\Product\Type\AbstractType;
use Magento\Catalog\Model\ProductFactory;
+use Magento\CatalogInventory\Api\StockRegistryInterface;
use Magento\CatalogInventory\Model\Stock\Item as StockItem;
use Magento\CatalogInventory\Model\Stock\StockItemRepository;
use Magento\Framework\App\Config\ScopeConfigInterface;
@@ -123,12 +124,12 @@ class WishlistTest extends TestCase
/**
* @var StockItemRepository|PHPUnit_Framework_MockObject_MockObject
*/
- private $stockItemRepository;
+ private $scopeConfig;
/**
- * @var StockItemRepository|PHPUnit_Framework_MockObject_MockObject
+ * @var StockRegistryInterface|PHPUnit_Framework_MockObject_MockObject
*/
- private $scopeConfig;
+ private $stockRegistry;
protected function setUp()
{
@@ -177,7 +178,7 @@ protected function setUp()
->disableOriginalConstructor()
->getMock();
$this->productRepository = $this->createMock(ProductRepositoryInterface::class);
- $this->stockItemRepository = $this->createMock(StockItemRepository::class);
+ $this->stockRegistry = $this->createMock(StockRegistryInterface::class);
$this->scopeConfig = $this->createMock(ScopeConfigInterface::class);
$this->scopeConfig = $this->getMockBuilder(ScopeConfigInterface::class)
@@ -209,7 +210,7 @@ protected function setUp()
false,
[],
$this->serializer,
- $this->stockItemRepository,
+ $this->stockRegistry,
$this->scopeConfig
);
}
@@ -280,7 +281,9 @@ public function testUpdateItem($itemId, $buyRequest, $param)
$stockItem = $this->getMockBuilder(StockItem::class)->disableOriginalConstructor()->getMock();
$stockItem->expects($this->any())->method('getIsInStock')->will($this->returnValue(true));
- $this->stockItemRepository->expects($this->any())->method('get')->will($this->returnValue($stockItem));
+ $this->stockRegistry->expects($this->any())
+ ->method('getStockItem')
+ ->will($this->returnValue($stockItem));
$instanceType = $this->getMockBuilder(AbstractType::class)
->disableOriginalConstructor()
@@ -289,9 +292,7 @@ public function testUpdateItem($itemId, $buyRequest, $param)
->method('processConfiguration')
->will(
$this->returnValue(
- $this->getMockBuilder(
- Product::class
- )->disableOriginalConstructor()->getMock()
+ $this->getMockBuilder(Product::class)->disableOriginalConstructor()->getMock()
)
);
@@ -413,7 +414,10 @@ function ($value) {
StockItem::class
)->disableOriginalConstructor()->getMock();
$stockItem->expects($this->any())->method('getIsInStock')->will($this->returnValue(true));
- $this->stockItemRepository->expects($this->any())->method('get')->will($this->returnValue($stockItem));
+
+ $this->stockRegistry->expects($this->any())
+ ->method('getStockItem')
+ ->will($this->returnValue($stockItem));
$this->assertEquals($result, $this->wishlist->addNewItem($productMock, $buyRequest));
}
From 1129337146a2d18c95d845dd4b3e1391b8eab27a Mon Sep 17 00:00:00 2001
From: Oleksandr Iegorov
Date: Wed, 4 Sep 2019 15:11:48 -0500
Subject: [PATCH 140/937] MC-19791: Poor performance on sales order update -
string to integer
---
.../Test/Unit/ResourceModel/Db/AbstractDbTest.php | 10 ++++------
1 file changed, 4 insertions(+), 6 deletions(-)
diff --git a/lib/internal/Magento/Framework/Model/Test/Unit/ResourceModel/Db/AbstractDbTest.php b/lib/internal/Magento/Framework/Model/Test/Unit/ResourceModel/Db/AbstractDbTest.php
index fea17c3c0b8c2..4236c4f076dcb 100644
--- a/lib/internal/Magento/Framework/Model/Test/Unit/ResourceModel/Db/AbstractDbTest.php
+++ b/lib/internal/Magento/Framework/Model/Test/Unit/ResourceModel/Db/AbstractDbTest.php
@@ -429,12 +429,10 @@ public function testPrepareDataForUpdate()
\Magento\Framework\Model\Context::class
);
$registryMock = $this->createMock(\Magento\Framework\Registry::class);
- $resourceMock = $this->createPartialMock(AbstractDb::class, [
- '_construct',
- 'getConnection',
- '__wakeup',
- 'getIdFieldName'
- ]);
+ $resourceMock = $this->createPartialMock(
+ AbstractDb::class,
+ ['_construct', 'getConnection', '__wakeup', 'getIdFieldName']
+ );
$connectionInterfaceMock = $this->createMock(AdapterInterface::class);
$resourceMock->expects($this->any())
->method('getConnection')
From 1dcb0a501d950fb048f5ae47299e5e8167252360 Mon Sep 17 00:00:00 2001
From: Vitalii Zabaznov
Date: Wed, 4 Sep 2019 15:49:37 -0500
Subject: [PATCH 141/937] MC-18719: private cookie version increments each post
request
---
app/code/Magento/Persistent/etc/frontend/sections.xml | 8 +-------
1 file changed, 1 insertion(+), 7 deletions(-)
diff --git a/app/code/Magento/Persistent/etc/frontend/sections.xml b/app/code/Magento/Persistent/etc/frontend/sections.xml
index a2a3796bc6a50..7466fbe990b02 100644
--- a/app/code/Magento/Persistent/etc/frontend/sections.xml
+++ b/app/code/Magento/Persistent/etc/frontend/sections.xml
@@ -10,13 +10,7 @@
-
-
-
-
-
-
-
+
From 90a85ed358050f7cfeadbca4311da1670a31878f Mon Sep 17 00:00:00 2001
From: Dmytro Poperechnyy
Date: Wed, 4 Sep 2019 19:34:01 -0500
Subject: [PATCH 142/937] MC-19247: Broken translations with advanced bundling
- Move block to view model;
---
.../Html/Head => ViewModel}/Dictionary.php | 27 +++++--------------
.../Translation/view/base/layout/default.xml | 6 ++++-
.../view/base/templates/dictionary.phtml | 23 ++++++++--------
3 files changed, 23 insertions(+), 33 deletions(-)
rename app/code/Magento/Translation/{Block/Html/Head => ViewModel}/Dictionary.php (57%)
diff --git a/app/code/Magento/Translation/Block/Html/Head/Dictionary.php b/app/code/Magento/Translation/ViewModel/Dictionary.php
similarity index 57%
rename from app/code/Magento/Translation/Block/Html/Head/Dictionary.php
rename to app/code/Magento/Translation/ViewModel/Dictionary.php
index 69e03f6b5e92d..c7bb972980e3d 100644
--- a/app/code/Magento/Translation/Block/Html/Head/Dictionary.php
+++ b/app/code/Magento/Translation/ViewModel/Dictionary.php
@@ -4,49 +4,35 @@
* See COPYING.txt for license details.
*/
-namespace Magento\Translation\Block\Html\Head;
+namespace Magento\Translation\ViewModel;
-use Magento\Framework\View\Element\Template;
+use Magento\Framework\View\Element\Block\ArgumentInterface;
use Magento\Translation\Model\FileManager;
-use Magento\Framework\View\Page\Config as PageConfig;
use Magento\Translation\Model\Js\Config as JsConfig;
/**
- * Block responsible for getting translate dictionary file for the layout.
+ * View model responsible for getting translate dictionary file for the layout.
*/
-class Dictionary extends Template
+class Dictionary implements ArgumentInterface
{
/**
* @var FileManager
*/
private $fileManager;
- /**
- * @var PageConfig
- */
- protected $pageConfig;
-
/**
* @var JsConfig
*/
private $config;
/**
- * @param Template\Context $context
- * @param PageConfig $pageConfig
* @param FileManager $fileManager
* @param JsConfig $config
- * @param array $data
*/
public function __construct(
- Template\Context $context,
- PageConfig $pageConfig,
FileManager $fileManager,
- JsConfig $config,
- array $data = []
+ JsConfig $config
) {
- parent::__construct($context, $data);
- $this->pageConfig = $pageConfig;
$this->fileManager = $fileManager;
$this->config = $config;
}
@@ -59,9 +45,8 @@ public function __construct(
public function getTranslationDictionaryFile(): string
{
$translateDictionaryConfig = $this->fileManager->createTranslateDictionaryConfigAsset(JsConfig::DICTIONARY_FILE_NAME);
- $translateDictionaryConfigRelPath = $translateDictionaryConfig->getFilePath();
- return $this->_assetRepo->getUrl($translateDictionaryConfigRelPath);
+ return $translateDictionaryConfig->getUrl();
}
/**
diff --git a/app/code/Magento/Translation/view/base/layout/default.xml b/app/code/Magento/Translation/view/base/layout/default.xml
index 76f93e625d1e7..8e0408037386a 100644
--- a/app/code/Magento/Translation/view/base/layout/default.xml
+++ b/app/code/Magento/Translation/view/base/layout/default.xml
@@ -8,7 +8,11 @@
-
+
+
+ Magento\Translation\ViewModel\Dictionary
+
+
diff --git a/app/code/Magento/Translation/view/base/templates/dictionary.phtml b/app/code/Magento/Translation/view/base/templates/dictionary.phtml
index 385b898a5e52c..f8d30149cf4fb 100644
--- a/app/code/Magento/Translation/view/base/templates/dictionary.phtml
+++ b/app/code/Magento/Translation/view/base/templates/dictionary.phtml
@@ -4,17 +4,18 @@
* See COPYING.txt for license details.
*/
-/** @var \Magento\Translation\Block\Html\Head\Dictionary $block */
+/** @var \Magento\Translation\ViewModel\Dictionary $viewModel */
+$viewModel = $block->getData('dictionary_view_model');
?>
-dictionaryEnabled()) : ?>
-
-
+
+ });
+
From b7d0657594e234d2f2b92335c6c48f769c5fdbe2 Mon Sep 17 00:00:00 2001
From: vital_pantsialeyeu
Date: Fri, 30 Aug 2019 17:58:31 +0300
Subject: [PATCH 143/937] MAGETWO-69825: [GITHUB #9891] Subcategory
"liquid-hand-soap" is not opened in category "soap"
- Implemented validation URL key during category creation
---
.../CategoryUrlPathAutogeneratorObserver.php | 11 +++++++----
...ategoryWithRestrictedUrlKeyNotCreatedTest.xml | 16 ++++++++--------
app/code/Magento/CatalogUrlRewrite/etc/di.xml | 11 +++++++++++
.../Magento/CatalogUrlRewrite/i18n/en_US.csv | 3 ++-
.../Controller/Adminhtml/CategoryTest.php | 4 ++--
5 files changed, 30 insertions(+), 15 deletions(-)
diff --git a/app/code/Magento/CatalogUrlRewrite/Observer/CategoryUrlPathAutogeneratorObserver.php b/app/code/Magento/CatalogUrlRewrite/Observer/CategoryUrlPathAutogeneratorObserver.php
index 2fd45bf3c0bc6..54ef7102fcc47 100644
--- a/app/code/Magento/CatalogUrlRewrite/Observer/CategoryUrlPathAutogeneratorObserver.php
+++ b/app/code/Magento/CatalogUrlRewrite/Observer/CategoryUrlPathAutogeneratorObserver.php
@@ -24,9 +24,9 @@ class CategoryUrlPathAutogeneratorObserver implements ObserverInterface
/**
* Reserved endpoint names.
*
- * @var array
+ * @var string[]
*/
- private $invalidValues = ['admin', 'soap', 'rest', 'graphql'];
+ private $invalidValues = [];
/**
* @var \Magento\CatalogUrlRewrite\Model\CategoryUrlPathGenerator
@@ -59,13 +59,15 @@ class CategoryUrlPathAutogeneratorObserver implements ObserverInterface
* @param \Magento\CatalogUrlRewrite\Service\V1\StoreViewService $storeViewService
* @param CategoryRepositoryInterface $categoryRepository
* @param \Magento\Backend\App\Area\FrontNameResolver $frontNameResolver
+ * @param string[] $invalidValues
*/
public function __construct(
CategoryUrlPathGenerator $categoryUrlPathGenerator,
ChildrenCategoriesProvider $childrenCategoriesProvider,
StoreViewService $storeViewService,
CategoryRepositoryInterface $categoryRepository,
- \Magento\Backend\App\Area\FrontNameResolver $frontNameResolver = null
+ \Magento\Backend\App\Area\FrontNameResolver $frontNameResolver = null,
+ array $invalidValues = []
) {
$this->categoryUrlPathGenerator = $categoryUrlPathGenerator;
$this->childrenCategoriesProvider = $childrenCategoriesProvider;
@@ -73,6 +75,7 @@ public function __construct(
$this->categoryRepository = $categoryRepository;
$this->frontNameResolver = $frontNameResolver ?: \Magento\Framework\App\ObjectManager::getInstance()
->get(\Magento\Backend\App\Area\FrontNameResolver::class);
+ $this->invalidValues = $invalidValues;
}
/**
@@ -116,7 +119,7 @@ private function updateUrlKey($category, $urlKey)
if (in_array($urlKey, $this->getInvalidValues())) {
throw new \Magento\Framework\Exception\LocalizedException(
__(
- 'URL key "%1" conflicts with reserved endpoint names: %2. Try another url key.',
+ 'URL key "%1" matches a reserved endpoint name (%2). Use another URL key.',
$urlKey,
implode(', ', $this->getInvalidValues())
)
diff --git a/app/code/Magento/CatalogUrlRewrite/Test/Mftf/Test/AdminCategoryWithRestrictedUrlKeyNotCreatedTest.xml b/app/code/Magento/CatalogUrlRewrite/Test/Mftf/Test/AdminCategoryWithRestrictedUrlKeyNotCreatedTest.xml
index 1e71d8e152651..0212be38f4265 100644
--- a/app/code/Magento/CatalogUrlRewrite/Test/Mftf/Test/AdminCategoryWithRestrictedUrlKeyNotCreatedTest.xml
+++ b/app/code/Magento/CatalogUrlRewrite/Test/Mftf/Test/AdminCategoryWithRestrictedUrlKeyNotCreatedTest.xml
@@ -45,12 +45,12 @@
-
+
-
+
@@ -66,12 +66,12 @@
-
+
-
+
@@ -87,12 +87,12 @@
-
+
-
+
@@ -108,12 +108,12 @@
-
+
-
+
diff --git a/app/code/Magento/CatalogUrlRewrite/etc/di.xml b/app/code/Magento/CatalogUrlRewrite/etc/di.xml
index e6fbcaefd0768..2a74b5cd92b28 100644
--- a/app/code/Magento/CatalogUrlRewrite/etc/di.xml
+++ b/app/code/Magento/CatalogUrlRewrite/etc/di.xml
@@ -45,4 +45,15 @@
+
+
+
+ - admin
+ - soap
+ - rest
+ - graphql
+ - standard
+
+
+
diff --git a/app/code/Magento/CatalogUrlRewrite/i18n/en_US.csv b/app/code/Magento/CatalogUrlRewrite/i18n/en_US.csv
index b3335dc3523ca..0f21e8ddf9fc9 100644
--- a/app/code/Magento/CatalogUrlRewrite/i18n/en_US.csv
+++ b/app/code/Magento/CatalogUrlRewrite/i18n/en_US.csv
@@ -5,4 +5,5 @@
"Product URL Suffix","Product URL Suffix"
"Use Categories Path for Product URLs","Use Categories Path for Product URLs"
"Create Permanent Redirect for URLs if URL Key Changed","Create Permanent Redirect for URLs if URL Key Changed"
-"Generate "category/product" URL Rewrites","Generate "category/product" URL Rewrites"
\ No newline at end of file
+"Generate "category/product" URL Rewrites","Generate "category/product" URL Rewrites"
+"URL key ""%1"" matches a reserved endpoint name (%2). Use another URL key.","URL key ""%1"" matches a reserved endpoint name (%2). Use another URL key."
diff --git a/dev/tests/integration/testsuite/Magento/Catalog/Controller/Adminhtml/CategoryTest.php b/dev/tests/integration/testsuite/Magento/Catalog/Controller/Adminhtml/CategoryTest.php
index bfe02f2aa2e10..6340900404bd3 100644
--- a/dev/tests/integration/testsuite/Magento/Catalog/Controller/Adminhtml/CategoryTest.php
+++ b/dev/tests/integration/testsuite/Magento/Catalog/Controller/Adminhtml/CategoryTest.php
@@ -592,8 +592,8 @@ public function testSaveWithCustomBackendNameAction()
$this->assertSessionMessages(
$this->equalTo(
[
- 'URL key "backend" conflicts with reserved endpoint names: '
- . 'admin, soap, rest, graphql, backend. Try another url key.'
+ 'URL key "backend" matches a reserved endpoint name '
+ . '(admin, soap, rest, graphql, standard, backend). Use another URL key.'
]
),
MessageInterface::TYPE_ERROR
From a6d39e805405cca7954d43cf8591652997953234 Mon Sep 17 00:00:00 2001
From: Lusine Papyan
Date: Thu, 5 Sep 2019 12:31:41 +0400
Subject: [PATCH 144/937] MAGETWO-69825: [GITHUB #9891] Subcategory
"liquid-hand-soap" is not opened in category "soap"
- Updated automated test script
---
.../AdminCategoryRestrictedUrlMessageData.xml | 17 +++++++++++
...goryWithRestrictedUrlKeyNotCreatedTest.xml | 28 +++++++++----------
2 files changed, 31 insertions(+), 14 deletions(-)
create mode 100644 app/code/Magento/CatalogUrlRewrite/Test/Mftf/Data/AdminCategoryRestrictedUrlMessageData.xml
diff --git a/app/code/Magento/CatalogUrlRewrite/Test/Mftf/Data/AdminCategoryRestrictedUrlMessageData.xml b/app/code/Magento/CatalogUrlRewrite/Test/Mftf/Data/AdminCategoryRestrictedUrlMessageData.xml
new file mode 100644
index 0000000000000..b463b0524d5ff
--- /dev/null
+++ b/app/code/Magento/CatalogUrlRewrite/Test/Mftf/Data/AdminCategoryRestrictedUrlMessageData.xml
@@ -0,0 +1,17 @@
+
+
+
+
+
+ URL key "admin" matches a reserved endpoint name (admin, soap, rest, graphql, standard). Use another URL key.
+ URL key "soap" matches a reserved endpoint name (admin, soap, rest, graphql, standard). Use another URL key.
+ URL key "rest" matches a reserved endpoint name (admin, soap, rest, graphql, standard). Use another URL key.
+ URL key "graphql" matches a reserved endpoint name (admin, soap, rest, graphql, standard). Use another URL key.
+
+
diff --git a/app/code/Magento/CatalogUrlRewrite/Test/Mftf/Test/AdminCategoryWithRestrictedUrlKeyNotCreatedTest.xml b/app/code/Magento/CatalogUrlRewrite/Test/Mftf/Test/AdminCategoryWithRestrictedUrlKeyNotCreatedTest.xml
index 0212be38f4265..6538ec6e935df 100644
--- a/app/code/Magento/CatalogUrlRewrite/Test/Mftf/Test/AdminCategoryWithRestrictedUrlKeyNotCreatedTest.xml
+++ b/app/code/Magento/CatalogUrlRewrite/Test/Mftf/Test/AdminCategoryWithRestrictedUrlKeyNotCreatedTest.xml
@@ -10,11 +10,11 @@
-
+
-
+
@@ -45,19 +45,19 @@
-
+
-
+
-
+
@@ -66,19 +66,19 @@
-
+
-
+
-
+
@@ -87,19 +87,19 @@
-
+
-
+
-
+
@@ -108,19 +108,19 @@
-
+
-
+
-
+
From 6276dca764d88fa9f5c880924b7a01fabc73a9cd Mon Sep 17 00:00:00 2001
From: vital_sery
Date: Wed, 7 Aug 2019 15:17:14 +0300
Subject: [PATCH 145/937] MC-18709: [WYSIWYG]Spinner is Always Displayed on
Media Gallery popup
---
lib/web/mage/loader.js | 5 ++++-
lib/web/mage/loader_old.js | 5 ++++-
2 files changed, 8 insertions(+), 2 deletions(-)
diff --git a/lib/web/mage/loader.js b/lib/web/mage/loader.js
index 83299efba422b..29034f93e8ba9 100644
--- a/lib/web/mage/loader.js
+++ b/lib/web/mage/loader.js
@@ -69,7 +69,10 @@ define([
show: function (e, ctx) {
this._render();
this.loaderStarted++;
- this.spinner.show();
+
+ if (this.loaderStarted === 1) {
+ this.spinner.show();
+ }
if (ctx) {
this.spinner
diff --git a/lib/web/mage/loader_old.js b/lib/web/mage/loader_old.js
index f759758acd12a..e008beb12d134 100644
--- a/lib/web/mage/loader_old.js
+++ b/lib/web/mage/loader_old.js
@@ -81,7 +81,10 @@
show: function (e, ctx) {
this._render();
this.loaderStarted++;
- this.spinner.show();
+
+ if (this.loaderStarted === 1) {
+ this.spinner.show();
+ }
if (ctx) {
this.spinner
From 7170855e27c6acd709740ba8183bad72ddb07def Mon Sep 17 00:00:00 2001
From: Lusine Papyan
Date: Tue, 13 Aug 2019 11:20:04 +0300
Subject: [PATCH 146/937] MC-18709: [WYSIWYG]Spinner is Always Displayed on
Media Gallery popup
- Added automated test script
---
.../AdminCMSBlockContentActionGroup.xml | 26 ++++++++
.../CmsNewBlockBlockActionsSection.xml | 14 +++++
...lleryPopupUploadImagesWithoutErrorTest.xml | 62 +++++++++++++++++++
3 files changed, 102 insertions(+)
create mode 100644 app/code/Magento/Cms/Test/Mftf/ActionGroup/AdminCMSBlockContentActionGroup.xml
create mode 100644 app/code/Magento/Cms/Test/Mftf/Test/AdminMediaGalleryPopupUploadImagesWithoutErrorTest.xml
diff --git a/app/code/Magento/Cms/Test/Mftf/ActionGroup/AdminCMSBlockContentActionGroup.xml b/app/code/Magento/Cms/Test/Mftf/ActionGroup/AdminCMSBlockContentActionGroup.xml
new file mode 100644
index 0000000000000..56fc28faa8d5f
--- /dev/null
+++ b/app/code/Magento/Cms/Test/Mftf/ActionGroup/AdminCMSBlockContentActionGroup.xml
@@ -0,0 +1,26 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/app/code/Magento/Cms/Test/Mftf/Section/CmsNewBlockBlockActionsSection.xml b/app/code/Magento/Cms/Test/Mftf/Section/CmsNewBlockBlockActionsSection.xml
index 2efa7f62fc4ec..182254df2dc53 100644
--- a/app/code/Magento/Cms/Test/Mftf/Section/CmsNewBlockBlockActionsSection.xml
+++ b/app/code/Magento/Cms/Test/Mftf/Section/CmsNewBlockBlockActionsSection.xml
@@ -24,9 +24,23 @@
+
+
+
diff --git a/app/code/Magento/Cms/Test/Mftf/Test/AdminMediaGalleryPopupUploadImagesWithoutErrorTest.xml b/app/code/Magento/Cms/Test/Mftf/Test/AdminMediaGalleryPopupUploadImagesWithoutErrorTest.xml
new file mode 100644
index 0000000000000..bef967edcc68a
--- /dev/null
+++ b/app/code/Magento/Cms/Test/Mftf/Test/AdminMediaGalleryPopupUploadImagesWithoutErrorTest.xml
@@ -0,0 +1,62 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
From cc766ae751598d603157d17be25faeaac3567244 Mon Sep 17 00:00:00 2001
From: Lusine Papyan
Date: Wed, 4 Sep 2019 13:10:54 +0300
Subject: [PATCH 147/937] MC-18709: [WYSIWYG]Spinner is Always Displayed on
Media Gallery popup
- Updated automated test script
---
.../Mftf/ActionGroup/AdminCMSBlockContentActionGroup.xml | 2 +-
.../Test/Mftf/Section/CmsNewBlockBlockActionsSection.xml | 2 +-
.../AdminMediaGalleryPopupUploadImagesWithoutErrorTest.xml | 6 +++---
3 files changed, 5 insertions(+), 5 deletions(-)
diff --git a/app/code/Magento/Cms/Test/Mftf/ActionGroup/AdminCMSBlockContentActionGroup.xml b/app/code/Magento/Cms/Test/Mftf/ActionGroup/AdminCMSBlockContentActionGroup.xml
index 56fc28faa8d5f..79bccbe705dc0 100644
--- a/app/code/Magento/Cms/Test/Mftf/ActionGroup/AdminCMSBlockContentActionGroup.xml
+++ b/app/code/Magento/Cms/Test/Mftf/ActionGroup/AdminCMSBlockContentActionGroup.xml
@@ -7,7 +7,7 @@
-->
-
+
diff --git a/app/code/Magento/Cms/Test/Mftf/Section/CmsNewBlockBlockActionsSection.xml b/app/code/Magento/Cms/Test/Mftf/Section/CmsNewBlockBlockActionsSection.xml
index 182254df2dc53..eac67ec9395b8 100644
--- a/app/code/Magento/Cms/Test/Mftf/Section/CmsNewBlockBlockActionsSection.xml
+++ b/app/code/Magento/Cms/Test/Mftf/Section/CmsNewBlockBlockActionsSection.xml
@@ -39,7 +39,7 @@
diff --git a/app/code/Magento/Cms/Test/Mftf/Test/AdminMediaGalleryPopupUploadImagesWithoutErrorTest.xml b/app/code/Magento/Cms/Test/Mftf/Test/AdminMediaGalleryPopupUploadImagesWithoutErrorTest.xml
index bef967edcc68a..bc1688c9d692b 100644
--- a/app/code/Magento/Cms/Test/Mftf/Test/AdminMediaGalleryPopupUploadImagesWithoutErrorTest.xml
+++ b/app/code/Magento/Cms/Test/Mftf/Test/AdminMediaGalleryPopupUploadImagesWithoutErrorTest.xml
@@ -10,7 +10,7 @@
-
+
@@ -40,7 +40,7 @@
-
+
@@ -53,7 +53,7 @@
-
+
From a52986d80245ee6dbce53317c05b74a598668fad Mon Sep 17 00:00:00 2001
From: Krissy Hiserote
Date: Thu, 5 Sep 2019 12:51:40 -0500
Subject: [PATCH 148/937] MC-16650: Product Attribute Type Price Not Displaying
---
.../Test/Mftf/Section/StorefrontCategoryFilterSection.xml | 2 +-
.../Magento/CatalogSearch/Model/Layer/Filter/Decimal.php | 5 ++++-
.../CatalogSearch/Model/Search/RequestGenerator/Price.php | 4 ++--
3 files changed, 7 insertions(+), 4 deletions(-)
diff --git a/app/code/Magento/Catalog/Test/Mftf/Section/StorefrontCategoryFilterSection.xml b/app/code/Magento/Catalog/Test/Mftf/Section/StorefrontCategoryFilterSection.xml
index fe3d3e298cbc9..faee605e77319 100644
--- a/app/code/Magento/Catalog/Test/Mftf/Section/StorefrontCategoryFilterSection.xml
+++ b/app/code/Magento/Catalog/Test/Mftf/Section/StorefrontCategoryFilterSection.xml
@@ -11,6 +11,6 @@
diff --git a/app/code/Magento/CatalogSearch/Model/Layer/Filter/Decimal.php b/app/code/Magento/CatalogSearch/Model/Layer/Filter/Decimal.php
index 596dc1bfc561d..3b0c4dfb6df2f 100644
--- a/app/code/Magento/CatalogSearch/Model/Layer/Filter/Decimal.php
+++ b/app/code/Magento/CatalogSearch/Model/Layer/Filter/Decimal.php
@@ -14,6 +14,9 @@
*/
class Decimal extends AbstractFilter
{
+ /** Decimal delta for filter */
+ private const DECIMAL_DELTA = 0.001;
+
/**
* @var \Magento\Framework\Pricing\PriceCurrencyInterface
*/
@@ -75,7 +78,7 @@ public function apply(\Magento\Framework\App\RequestInterface $request)
// When the range is 10-20 we only need to get products that are in the 10-19.99 range.
$toValue = $to;
if (!empty($toValue) && $from !== $toValue) {
- $toValue -= 0.001;
+ $toValue -= self::DECIMAL_DELTA;
}
$this->getLayer()
diff --git a/app/code/Magento/CatalogSearch/Model/Search/RequestGenerator/Price.php b/app/code/Magento/CatalogSearch/Model/Search/RequestGenerator/Price.php
index 7bf124844c618..949806d14f45a 100644
--- a/app/code/Magento/CatalogSearch/Model/Search/RequestGenerator/Price.php
+++ b/app/code/Magento/CatalogSearch/Model/Search/RequestGenerator/Price.php
@@ -19,7 +19,7 @@ class Price implements GeneratorInterface
/**
* @inheritdoc
*/
- public function getFilterData(Attribute $attribute, $filterName)
+ public function getFilterData(Attribute $attribute, $filterName): array
{
return [
'type' => FilterInterface::TYPE_RANGE,
@@ -33,7 +33,7 @@ public function getFilterData(Attribute $attribute, $filterName)
/**
* @inheritdoc
*/
- public function getAggregationData(Attribute $attribute, $bucketName)
+ public function getAggregationData(Attribute $attribute, $bucketName): array
{
return [
'type' => BucketInterface::TYPE_DYNAMIC,
From 3a56634c62f7b9a2f4e2fe09367e269ec846a684 Mon Sep 17 00:00:00 2001
From: Sergey Dovbenko
Date: Thu, 5 Sep 2019 21:06:54 +0000
Subject: [PATCH 149/937] Added description BraintreeInput
---
app/code/Magento/BraintreeGraphQl/etc/schema.graphqls | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/app/code/Magento/BraintreeGraphQl/etc/schema.graphqls b/app/code/Magento/BraintreeGraphQl/etc/schema.graphqls
index 0492f8aaf989b..4be092bb1b219 100644
--- a/app/code/Magento/BraintreeGraphQl/etc/schema.graphqls
+++ b/app/code/Magento/BraintreeGraphQl/etc/schema.graphqls
@@ -11,9 +11,9 @@ input PaymentMethodInput {
}
input BraintreeInput {
- payment_method_nonce: String!
- is_active_payment_token_enabler: Boolean!
- device_data: String
+ payment_method_nonce: String! @doc(description:"Required input for Braintrees payments")
+ is_active_payment_token_enabler: Boolean! @doc(description:"Required input for Braintrees payments")
+ device_data: String @doc(description:"Additional information for Braintrees payments")
}
input BraintreeCcVaultInput {
From c2561b7613743ec7ff3a5e03fdba69be5f1bbce3 Mon Sep 17 00:00:00 2001
From: Prabhu Ram
Date: Thu, 5 Sep 2019 16:17:40 -0500
Subject: [PATCH 150/937] MC-19253: Update schema - Intial schema update
---
app/code/Magento/QuoteGraphQl/etc/schema.graphqls | 12 ++++++++++++
1 file changed, 12 insertions(+)
diff --git a/app/code/Magento/QuoteGraphQl/etc/schema.graphqls b/app/code/Magento/QuoteGraphQl/etc/schema.graphqls
index c458b5e9dc05d..ce23283f95bfb 100644
--- a/app/code/Magento/QuoteGraphQl/etc/schema.graphqls
+++ b/app/code/Magento/QuoteGraphQl/etc/schema.graphqls
@@ -152,6 +152,7 @@ type CartPrices {
discount: CartDiscount
subtotal_with_discount_excluding_tax: Money
applied_taxes: [CartTaxItem]
+ discounts: CartPromotions
}
type CartTaxItem {
@@ -318,10 +319,21 @@ interface CartItemInterface @typeResolver(class: "Magento\\QuoteGraphQl\\Model\\
product: ProductInterface!
}
+type Discount {
+ amount: Money!
+ label: String!
+}
+
type CartItemPrices {
price: Money!
row_total: Money!
row_total_including_tax: Money!
+ discounts: [Discount]
+ discount: Money
+}
+
+type CartPromotions {
+ discounts: [Discount] @doc(description: "Shows discount breakdown at Cart level")
}
type SelectedCustomizableOption {
From 9f0f64df8b2637f012979c75c3ac15ec883d3de1 Mon Sep 17 00:00:00 2001
From: Prabhu Ram
Date: Thu, 5 Sep 2019 16:19:07 -0500
Subject: [PATCH 151/937] MC-19254: Implement the schema changes - implemented
discount breakdown for cart items
---
.../Quote/Model/Quote/Item/AbstractItem.php | 2 ++
.../Model/Resolver/CartItemPrices.php | 29 ++++++++++++++++++-
.../Magento/SalesRule/Model/RulesApplier.php | 28 ++++++++++++++++--
3 files changed, 55 insertions(+), 4 deletions(-)
diff --git a/app/code/Magento/Quote/Model/Quote/Item/AbstractItem.php b/app/code/Magento/Quote/Model/Quote/Item/AbstractItem.php
index a6fa6828a04e7..691f19da0467f 100644
--- a/app/code/Magento/Quote/Model/Quote/Item/AbstractItem.php
+++ b/app/code/Magento/Quote/Model/Quote/Item/AbstractItem.php
@@ -35,6 +35,8 @@
* @method \Magento\Quote\Model\Quote\Item\AbstractItem setBaseDiscountCalculationPrice($price)
* @method int[] getAppliedRuleIds()
* @method \Magento\Quote\Model\Quote\Item\AbstractItem setAppliedRuleIds(array $ruleIds)
+ * @method array getDiscountBreakdown()
+ * @method \Magento\Quote\Model\Quote\Item\AbstractItem setDiscountBreakdown(array $data)
* @method float getBaseTaxAmount()
* @method float getBaseDiscountTaxCompensation()
* @method float getBaseRowTotal()
diff --git a/app/code/Magento/QuoteGraphQl/Model/Resolver/CartItemPrices.php b/app/code/Magento/QuoteGraphQl/Model/Resolver/CartItemPrices.php
index a591c74e78db3..6c4a0d11fda35 100644
--- a/app/code/Magento/QuoteGraphQl/Model/Resolver/CartItemPrices.php
+++ b/app/code/Magento/QuoteGraphQl/Model/Resolver/CartItemPrices.php
@@ -7,6 +7,7 @@
namespace Magento\QuoteGraphQl\Model\Resolver;
+use Magento\Directory\Block\Currency;
use Magento\Framework\Exception\LocalizedException;
use Magento\Framework\GraphQl\Config\Element\Field;
use Magento\Framework\GraphQl\Query\ResolverInterface;
@@ -55,7 +56,6 @@ public function resolve(Field $field, $context, ResolveInfo $info, array $value
// But the totals should be calculated even if no address is set
$this->totals = $this->totalsCollector->collectQuoteTotals($cartItem->getQuote());
}
-
$currencyCode = $cartItem->getQuote()->getQuoteCurrencyCode();
return [
@@ -71,6 +71,33 @@ public function resolve(Field $field, $context, ResolveInfo $info, array $value
'currency' => $currencyCode,
'value' => $cartItem->getRowTotalInclTax(),
],
+ 'discount' => [
+ 'currency' => $currencyCode,
+ 'value' => $cartItem->getDiscountAmount(),
+ ],
+ 'discounts' => $this->getDiscountValues($cartItem, $currencyCode)
];
}
+
+ /**
+ * Get Discount Values
+ *
+ * @param Item $cartItem
+ * @param Currency $currencyCode
+ * @return array
+ */
+ private function getDiscountValues($cartItem, $currencyCode)
+ {
+ $discountValues=[];
+ foreach ($cartItem->getDiscountBreakdown() as $key => $value) {
+ $discount = [];
+ $amount = [];
+ $discount['label'] = $key;
+ $amount['value'] = $value;
+ $amount['currency'] = $currencyCode;
+ $discount['amount'] = $amount;
+ $discountValues[] = $discount;
+ }
+ return $discountValues;
+ }
}
diff --git a/app/code/Magento/SalesRule/Model/RulesApplier.php b/app/code/Magento/SalesRule/Model/RulesApplier.php
index f771a4f1e3892..c51d2a1f59d90 100644
--- a/app/code/Magento/SalesRule/Model/RulesApplier.php
+++ b/app/code/Magento/SalesRule/Model/RulesApplier.php
@@ -144,7 +144,7 @@ public function addDiscountDescription($address, $rule)
*/
protected function applyRule($item, $rule, $address, $couponCode)
{
- $discountData = $this->getDiscountData($item, $rule);
+ $discountData = $this->getDiscountData($item, $rule, $address);
$this->setDiscountData($discountData, $item);
$this->maintainAddressCouponCode($address, $rule, $couponCode);
@@ -158,20 +158,21 @@ protected function applyRule($item, $rule, $address, $couponCode)
* @param \Magento\SalesRule\Model\Rule $rule
* @return \Magento\SalesRule\Model\Rule\Action\Discount\Data
*/
- protected function getDiscountData($item, $rule)
+ protected function getDiscountData($item, $rule, $address)
{
$qty = $this->validatorUtility->getItemQty($item, $rule);
$discountCalculator = $this->calculatorFactory->create($rule->getSimpleAction());
$qty = $discountCalculator->fixQuantity($qty, $rule);
$discountData = $discountCalculator->calculate($rule, $item, $qty);
-
+ $this->setDiscountBreakdown($discountData, $item, $rule, $address);
$this->eventFix($discountData, $item, $rule, $qty);
$this->validatorUtility->deltaRoundingFix($discountData, $item);
/**
* We can't use row total here because row total not include tax
* Discount can be applied on price included tax
+ *
*/
$this->validatorUtility->minFix($discountData, $item, $qty);
@@ -179,6 +180,27 @@ protected function getDiscountData($item, $rule)
return $discountData;
}
+ /**
+ * Set Discount Breakdown
+ *
+ * @param \Magento\SalesRule\Model\Rule\Action\Discount\Data $discountData
+ * @param \Magento\Quote\Model\Quote\Item\AbstractItem $item
+ * @param \Magento\SalesRule\Model\Rule $rule
+ * @param Address $address
+ * @return $this
+ */
+ protected function setDiscountBreakdown($discountData, $item, $rule, $address)
+ {
+ $discount = $discountData->getAmount();
+ $discountBreakdown = $item->getDiscountBreakdown() ?? [];
+ $ruleLabel = $rule->getStoreLabel($address->getQuote()->getStore());
+ if ($ruleLabel) {
+ $discountBreakdown[$ruleLabel] = $discount;
+ }
+ $item->setDiscountBreakdown($discountBreakdown);
+ return $this;
+ }
+
/**
* @param \Magento\SalesRule\Model\Rule\Action\Discount\Data $discountData
* @param \Magento\Quote\Model\Quote\Item\AbstractItem $item
From 30e0bbb215208e6063fcb820e1168c0681db9f87 Mon Sep 17 00:00:00 2001
From: Vitalii Zabaznov
Date: Thu, 5 Sep 2019 16:38:36 -0500
Subject: [PATCH 152/937] MC-18719: private cookie version increments each post
request
---
.../Customer/Block/SectionsNameProvider.php | 36 +++++++++++++++++++
.../Customer/view/frontend/layout/default.xml | 6 +++-
.../frontend/templates/js/customer-data.phtml | 3 +-
.../view/frontend/web/js/customer-data.js | 2 +-
4 files changed, 44 insertions(+), 3 deletions(-)
create mode 100644 app/code/Magento/Customer/Block/SectionsNameProvider.php
diff --git a/app/code/Magento/Customer/Block/SectionsNameProvider.php b/app/code/Magento/Customer/Block/SectionsNameProvider.php
new file mode 100644
index 0000000000000..e2cd94f3df0ab
--- /dev/null
+++ b/app/code/Magento/Customer/Block/SectionsNameProvider.php
@@ -0,0 +1,36 @@
+sectionPool = $sectionPool;
+ }
+
+ /**
+ * Return array of section names.
+ *
+ * @return array
+ */
+ public function getSectionsName()
+ {
+ return array_keys($this->sectionPool->getSectionsData());
+ }
+}
diff --git a/app/code/Magento/Customer/view/frontend/layout/default.xml b/app/code/Magento/Customer/view/frontend/layout/default.xml
index 94e46fda194b0..e0126e2d071ca 100644
--- a/app/code/Magento/Customer/view/frontend/layout/default.xml
+++ b/app/code/Magento/Customer/view/frontend/layout/default.xml
@@ -44,7 +44,11 @@
template="Magento_Customer::js/section-config.phtml"/>
+ template="Magento_Customer::js/customer-data.phtml">
+
+ Magento\Customer\Block\SectionsNameProvider
+
+
diff --git a/app/code/Magento/Customer/view/frontend/templates/js/customer-data.phtml b/app/code/Magento/Customer/view/frontend/templates/js/customer-data.phtml
index a1a784076bac3..1e067a6134a9b 100644
--- a/app/code/Magento/Customer/view/frontend/templates/js/customer-data.phtml
+++ b/app/code/Magento/Customer/view/frontend/templates/js/customer-data.phtml
@@ -14,7 +14,8 @@
"expirableSectionLifetime": = (int)$block->getExpirableSectionLifetime() ?>,
"expirableSectionNames": = /* @noEscape */ $this->helper(\Magento\Framework\Json\Helper\Data::class)->jsonEncode($block->getExpirableSectionNames()) ?>,
"cookieLifeTime": "= $block->escapeJs($block->getCookieLifeTime()) ?>",
- "updateSessionUrl": "= $block->escapeJs($block->escapeUrl($block->getCustomerDataUrl('customer/account/updateSession'))) ?>"
+ "updateSessionUrl": "= $block->escapeJs($block->escapeUrl($block->getCustomerDataUrl('customer/account/updateSession'))) ?>",
+ "sectionsName": = $this->helper(\Magento\Framework\Json\Helper\Data::class)->jsonEncode($block->getData('sectionsNameProvider')->getSectionsName()) ?>
}
}
}
diff --git a/app/code/Magento/Customer/view/frontend/web/js/customer-data.js b/app/code/Magento/Customer/view/frontend/web/js/customer-data.js
index 9df8d75e43172..5360c2d9119c7 100644
--- a/app/code/Magento/Customer/view/frontend/web/js/customer-data.js
+++ b/app/code/Magento/Customer/view/frontend/web/js/customer-data.js
@@ -320,7 +320,7 @@ define([
var sectionDataIds,
sectionsNamesForInvalidation;
- sectionsNamesForInvalidation = _.contains(sectionNames, '*') ? buffer.keys() : sectionNames;
+ sectionsNamesForInvalidation = _.contains(sectionNames, '*') ? options.sectionsName : sectionNames;
$(document).trigger('customer-data-invalidate', [sectionsNamesForInvalidation]);
buffer.remove(sectionsNamesForInvalidation);
sectionDataIds = $.cookieStorage.get('section_data_ids') || {};
From 945a1a73705c2aeb768d9e6e3374264358f424eb Mon Sep 17 00:00:00 2001
From: Vaha
Date: Fri, 6 Sep 2019 08:55:36 +0300
Subject: [PATCH 153/937] magento/graphql-ce#893 return null if no selected
shipping method
---
.../SelectedShippingMethod.php | 70 ++++++++-----------
.../GetSelectedShippingMethodTest.php | 27 +------
.../Guest/GetSelectedShippingMethodTest.php | 27 +------
3 files changed, 33 insertions(+), 91 deletions(-)
diff --git a/app/code/Magento/QuoteGraphQl/Model/Resolver/ShippingAddress/SelectedShippingMethod.php b/app/code/Magento/QuoteGraphQl/Model/Resolver/ShippingAddress/SelectedShippingMethod.php
index 86a61a313b79f..6062d85396ea2 100644
--- a/app/code/Magento/QuoteGraphQl/Model/Resolver/ShippingAddress/SelectedShippingMethod.php
+++ b/app/code/Magento/QuoteGraphQl/Model/Resolver/ShippingAddress/SelectedShippingMethod.php
@@ -34,51 +34,39 @@ public function resolve(Field $field, $context, ResolveInfo $info, array $value
$carrierTitle = '';
$methodTitle = '';
- if (count($rates) > 0 && !empty($address->getShippingMethod())) {
- list($carrierCode, $methodCode) = explode('_', $address->getShippingMethod(), 2);
+ if (!count($rates) || empty($address->getShippingMethod())) {
+ return null;
+ }
+
+ list($carrierCode, $methodCode) = explode('_', $address->getShippingMethod(), 2);
- /** @var Rate $rate */
- foreach ($rates as $rate) {
- if ($rate->getCode() == $address->getShippingMethod()) {
- $carrierTitle = $rate->getCarrierTitle();
- $methodTitle = $rate->getMethodTitle();
- break;
- }
+ /** @var Rate $rate */
+ foreach ($rates as $rate) {
+ if ($rate->getCode() == $address->getShippingMethod()) {
+ $carrierTitle = $rate->getCarrierTitle();
+ $methodTitle = $rate->getMethodTitle();
+ break;
}
+ }
- /** @var Currency $currency */
- $currency = $context->getExtensionAttributes()->getStore()->getBaseCurrency();
+ /** @var Currency $currency */
+ $currency = $context->getExtensionAttributes()->getStore()->getBaseCurrency();
+
+ $data = [
+ 'carrier_code' => $carrierCode,
+ 'method_code' => $methodCode,
+ 'carrier_title' => $carrierTitle,
+ 'method_title' => $methodTitle,
+ 'amount' => [
+ 'value' => $address->getShippingAmount(),
+ 'currency' => $address->getQuote()->getQuoteCurrencyCode(),
+ ],
+ 'base_amount' => [
+ 'value' => $address->getBaseShippingAmount(),
+ 'currency' => $currency->getCode(),
+ ],
+ ];
- $data = [
- 'carrier_code' => $carrierCode,
- 'method_code' => $methodCode,
- 'carrier_title' => $carrierTitle,
- 'method_title' => $methodTitle,
- 'amount' => [
- 'value' => $address->getShippingAmount(),
- 'currency' => $address->getQuote()->getQuoteCurrencyCode(),
- ],
- 'base_amount' => [
- 'value' => $address->getBaseShippingAmount(),
- 'currency' => $currency->getCode(),
- ],
- ];
- } else {
- $data = [
- 'carrier_code' => '',
- 'method_code' => '',
- 'carrier_title' => $carrierTitle,
- 'method_title' => $methodTitle,
- 'amount' => [
- 'value' => null,
- 'currency' => null,
- ],
- 'base_amount' => [
- 'value' => null,
- 'currency' => null,
- ],
- ];
- }
return $data;
}
}
diff --git a/dev/tests/api-functional/testsuite/Magento/GraphQl/Quote/Customer/GetSelectedShippingMethodTest.php b/dev/tests/api-functional/testsuite/Magento/GraphQl/Quote/Customer/GetSelectedShippingMethodTest.php
index e42f675455eed..90107ad2220da 100644
--- a/dev/tests/api-functional/testsuite/Magento/GraphQl/Quote/Customer/GetSelectedShippingMethodTest.php
+++ b/dev/tests/api-functional/testsuite/Magento/GraphQl/Quote/Customer/GetSelectedShippingMethodTest.php
@@ -108,18 +108,7 @@ public function testGetSelectedShippingMethodBeforeSet()
$shippingAddress = current($response['cart']['shipping_addresses']);
self::assertArrayHasKey('selected_shipping_method', $shippingAddress);
-
- self::assertArrayHasKey('carrier_code', $shippingAddress['selected_shipping_method']);
- self::assertEmpty($shippingAddress['selected_shipping_method']['carrier_code']);
-
- self::assertArrayHasKey('method_code', $shippingAddress['selected_shipping_method']);
- self::assertEmpty($shippingAddress['selected_shipping_method']['method_code']);
-
- self::assertArrayHasKey('carrier_title', $shippingAddress['selected_shipping_method']);
- self::assertEmpty($shippingAddress['selected_shipping_method']['carrier_title']);
-
- self::assertArrayHasKey('method_title', $shippingAddress['selected_shipping_method']);
- self::assertEmpty($shippingAddress['selected_shipping_method']['method_title']);
+ self::assertNull($shippingAddress['selected_shipping_method']);
}
/**
@@ -182,19 +171,7 @@ public function testGetGetSelectedShippingMethodIfShippingMethodIsNotSet()
$shippingAddress = current($response['cart']['shipping_addresses']);
self::assertArrayHasKey('selected_shipping_method', $shippingAddress);
-
- self::assertEmpty($shippingAddress['selected_shipping_method']['carrier_code']);
- self::assertEmpty($shippingAddress['selected_shipping_method']['method_code']);
- self::assertEmpty($shippingAddress['selected_shipping_method']['carrier_title']);
- self::assertEmpty($shippingAddress['selected_shipping_method']['method_title']);
-
- self::assertArrayHasKey('amount', $shippingAddress['selected_shipping_method']);
- self::assertNull($shippingAddress['selected_shipping_method']['amount']['value']);
- self::assertNull($shippingAddress['selected_shipping_method']['amount']['currency']);
-
- self::assertArrayHasKey('base_amount', $shippingAddress['selected_shipping_method']);
- self::assertNull($shippingAddress['selected_shipping_method']['base_amount']['value']);
- self::assertNull($shippingAddress['selected_shipping_method']['base_amount']['currency']);
+ self::assertNull($shippingAddress['selected_shipping_method']);
}
/**
diff --git a/dev/tests/api-functional/testsuite/Magento/GraphQl/Quote/Guest/GetSelectedShippingMethodTest.php b/dev/tests/api-functional/testsuite/Magento/GraphQl/Quote/Guest/GetSelectedShippingMethodTest.php
index eaab4b16a8530..ce2f1868d48b4 100644
--- a/dev/tests/api-functional/testsuite/Magento/GraphQl/Quote/Guest/GetSelectedShippingMethodTest.php
+++ b/dev/tests/api-functional/testsuite/Magento/GraphQl/Quote/Guest/GetSelectedShippingMethodTest.php
@@ -99,18 +99,7 @@ public function testGetSelectedShippingMethodBeforeSet()
$shippingAddress = current($response['cart']['shipping_addresses']);
self::assertArrayHasKey('selected_shipping_method', $shippingAddress);
-
- self::assertArrayHasKey('carrier_code', $shippingAddress['selected_shipping_method']);
- self::assertEmpty($shippingAddress['selected_shipping_method']['carrier_code']);
-
- self::assertArrayHasKey('method_code', $shippingAddress['selected_shipping_method']);
- self::assertEmpty($shippingAddress['selected_shipping_method']['method_code']);
-
- self::assertArrayHasKey('carrier_title', $shippingAddress['selected_shipping_method']);
- self::assertEmpty($shippingAddress['selected_shipping_method']['carrier_title']);
-
- self::assertArrayHasKey('method_title', $shippingAddress['selected_shipping_method']);
- self::assertEmpty($shippingAddress['selected_shipping_method']['method_title']);
+ self::assertNull($shippingAddress['selected_shipping_method']);
}
/**
@@ -152,19 +141,7 @@ public function testGetGetSelectedShippingMethodIfShippingMethodIsNotSet()
$shippingAddress = current($response['cart']['shipping_addresses']);
self::assertArrayHasKey('selected_shipping_method', $shippingAddress);
-
- self::assertEmpty($shippingAddress['selected_shipping_method']['carrier_code']);
- self::assertEmpty($shippingAddress['selected_shipping_method']['method_code']);
- self::assertEmpty($shippingAddress['selected_shipping_method']['carrier_title']);
- self::assertEmpty($shippingAddress['selected_shipping_method']['method_title']);
-
- self::assertArrayHasKey('amount', $shippingAddress['selected_shipping_method']);
- self::assertNull($shippingAddress['selected_shipping_method']['amount']['value']);
- self::assertNull($shippingAddress['selected_shipping_method']['amount']['currency']);
-
- self::assertArrayHasKey('base_amount', $shippingAddress['selected_shipping_method']);
- self::assertNull($shippingAddress['selected_shipping_method']['base_amount']['value']);
- self::assertNull($shippingAddress['selected_shipping_method']['base_amount']['currency']);
+ self::assertNull($shippingAddress['selected_shipping_method']);
}
/**
From 6cce7520875f84313a74136d5fd3e3cf8e5bc65a Mon Sep 17 00:00:00 2001
From: Lusine Papyan
Date: Fri, 6 Sep 2019 14:12:38 +0400
Subject: [PATCH 154/937] MC-18823: Increase test coverage for Framework and
Performance functional areas
- Automation test for MC-11158
---
.../Test/Mftf/Suite/AppConfigDumpSuite.xml | 0
.../Section/AdminShippingMethodDHLSection.xml | 0
...utFieldsDisabledAfterAppConfigDumpTest.xml | 47 +++++
.../AdminShippingMethodFedExSection.xml | 0
...utFieldsDisabledAfterAppConfigDumpTest.xml | 53 ++++++
.../Section/AdminShippingMethodUPSSection.xml | 39 ----
...utFieldsDisabledAfterAppConfigDumpTest.xml | 170 +-----------------
.../AdminShippingMethodsUpsSection.xml | 25 +++
...utFieldsDisabledAfterAppConfigDumpTest.xml | 67 +++++++
.../AdminShippingMethodUSPSSection.xml | 0
...utFieldsDisabledAfterAppConfigDumpTest.xml | 55 ++++++
11 files changed, 249 insertions(+), 207 deletions(-)
rename app/code/Magento/{Shipping => Config}/Test/Mftf/Suite/AppConfigDumpSuite.xml (100%)
rename app/code/Magento/{Shipping => Dhl}/Test/Mftf/Section/AdminShippingMethodDHLSection.xml (100%)
create mode 100644 app/code/Magento/Dhl/Test/Mftf/Test/AdminCheckInputFieldsDisabledAfterAppConfigDumpTest.xml
rename app/code/Magento/{Shipping => Fedex}/Test/Mftf/Section/AdminShippingMethodFedExSection.xml (100%)
create mode 100644 app/code/Magento/Fedex/Test/Mftf/Test/AdminCheckInputFieldsDisabledAfterAppConfigDumpTest.xml
delete mode 100644 app/code/Magento/Shipping/Test/Mftf/Section/AdminShippingMethodUPSSection.xml
create mode 100644 app/code/Magento/Ups/Test/Mftf/Test/AdminCheckInputFieldsDisabledAfterAppConfigDumpTest.xml
rename app/code/Magento/{Shipping => Usps}/Test/Mftf/Section/AdminShippingMethodUSPSSection.xml (100%)
create mode 100644 app/code/Magento/Usps/Test/Mftf/Test/AdminCheckInputFieldsDisabledAfterAppConfigDumpTest.xml
diff --git a/app/code/Magento/Shipping/Test/Mftf/Suite/AppConfigDumpSuite.xml b/app/code/Magento/Config/Test/Mftf/Suite/AppConfigDumpSuite.xml
similarity index 100%
rename from app/code/Magento/Shipping/Test/Mftf/Suite/AppConfigDumpSuite.xml
rename to app/code/Magento/Config/Test/Mftf/Suite/AppConfigDumpSuite.xml
diff --git a/app/code/Magento/Shipping/Test/Mftf/Section/AdminShippingMethodDHLSection.xml b/app/code/Magento/Dhl/Test/Mftf/Section/AdminShippingMethodDHLSection.xml
similarity index 100%
rename from app/code/Magento/Shipping/Test/Mftf/Section/AdminShippingMethodDHLSection.xml
rename to app/code/Magento/Dhl/Test/Mftf/Section/AdminShippingMethodDHLSection.xml
diff --git a/app/code/Magento/Dhl/Test/Mftf/Test/AdminCheckInputFieldsDisabledAfterAppConfigDumpTest.xml b/app/code/Magento/Dhl/Test/Mftf/Test/AdminCheckInputFieldsDisabledAfterAppConfigDumpTest.xml
new file mode 100644
index 0000000000000..df6841cb718f6
--- /dev/null
+++ b/app/code/Magento/Dhl/Test/Mftf/Test/AdminCheckInputFieldsDisabledAfterAppConfigDumpTest.xml
@@ -0,0 +1,47 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/app/code/Magento/Shipping/Test/Mftf/Section/AdminShippingMethodFedExSection.xml b/app/code/Magento/Fedex/Test/Mftf/Section/AdminShippingMethodFedExSection.xml
similarity index 100%
rename from app/code/Magento/Shipping/Test/Mftf/Section/AdminShippingMethodFedExSection.xml
rename to app/code/Magento/Fedex/Test/Mftf/Section/AdminShippingMethodFedExSection.xml
diff --git a/app/code/Magento/Fedex/Test/Mftf/Test/AdminCheckInputFieldsDisabledAfterAppConfigDumpTest.xml b/app/code/Magento/Fedex/Test/Mftf/Test/AdminCheckInputFieldsDisabledAfterAppConfigDumpTest.xml
new file mode 100644
index 0000000000000..c5cb75ae99755
--- /dev/null
+++ b/app/code/Magento/Fedex/Test/Mftf/Test/AdminCheckInputFieldsDisabledAfterAppConfigDumpTest.xml
@@ -0,0 +1,53 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/app/code/Magento/Shipping/Test/Mftf/Section/AdminShippingMethodUPSSection.xml b/app/code/Magento/Shipping/Test/Mftf/Section/AdminShippingMethodUPSSection.xml
deleted file mode 100644
index 3eda77a31b423..0000000000000
--- a/app/code/Magento/Shipping/Test/Mftf/Section/AdminShippingMethodUPSSection.xml
+++ /dev/null
@@ -1,39 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/app/code/Magento/Shipping/Test/Mftf/Test/AdminCheckInputFieldsDisabledAfterAppConfigDumpTest.xml b/app/code/Magento/Shipping/Test/Mftf/Test/AdminCheckInputFieldsDisabledAfterAppConfigDumpTest.xml
index c144d6f21b647..1739bcd01ec95 100644
--- a/app/code/Magento/Shipping/Test/Mftf/Test/AdminCheckInputFieldsDisabledAfterAppConfigDumpTest.xml
+++ b/app/code/Magento/Shipping/Test/Mftf/Test/AdminCheckInputFieldsDisabledAfterAppConfigDumpTest.xml
@@ -10,8 +10,8 @@
xsi:noNamespaceSchemaLocation="urn:magento:mftf:Test/etc/testSchema.xsd">
-
-
+
+
@@ -77,171 +77,5 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/app/code/Magento/Ups/Test/Mftf/Section/AdminShippingMethodsUpsSection.xml b/app/code/Magento/Ups/Test/Mftf/Section/AdminShippingMethodsUpsSection.xml
index 4107f17dbc18c..d68b6a77add64 100644
--- a/app/code/Magento/Ups/Test/Mftf/Section/AdminShippingMethodsUpsSection.xml
+++ b/app/code/Magento/Ups/Test/Mftf/Section/AdminShippingMethodsUpsSection.xml
@@ -12,5 +12,30 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/app/code/Magento/Ups/Test/Mftf/Test/AdminCheckInputFieldsDisabledAfterAppConfigDumpTest.xml b/app/code/Magento/Ups/Test/Mftf/Test/AdminCheckInputFieldsDisabledAfterAppConfigDumpTest.xml
new file mode 100644
index 0000000000000..9202476ef1832
--- /dev/null
+++ b/app/code/Magento/Ups/Test/Mftf/Test/AdminCheckInputFieldsDisabledAfterAppConfigDumpTest.xml
@@ -0,0 +1,67 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/app/code/Magento/Shipping/Test/Mftf/Section/AdminShippingMethodUSPSSection.xml b/app/code/Magento/Usps/Test/Mftf/Section/AdminShippingMethodUSPSSection.xml
similarity index 100%
rename from app/code/Magento/Shipping/Test/Mftf/Section/AdminShippingMethodUSPSSection.xml
rename to app/code/Magento/Usps/Test/Mftf/Section/AdminShippingMethodUSPSSection.xml
diff --git a/app/code/Magento/Usps/Test/Mftf/Test/AdminCheckInputFieldsDisabledAfterAppConfigDumpTest.xml b/app/code/Magento/Usps/Test/Mftf/Test/AdminCheckInputFieldsDisabledAfterAppConfigDumpTest.xml
new file mode 100644
index 0000000000000..003ccb8c3ef8c
--- /dev/null
+++ b/app/code/Magento/Usps/Test/Mftf/Test/AdminCheckInputFieldsDisabledAfterAppConfigDumpTest.xml
@@ -0,0 +1,55 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
From f463caf1b77575c89ddc15320043f12d97284499 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Torben=20Ho=CC=88hn?=
Date: Fri, 6 Sep 2019 14:20:54 +0200
Subject: [PATCH 155/937] rework
---
.../Block/Product/Renderer/Configurable.php | 60 +++++++++----------
1 file changed, 27 insertions(+), 33 deletions(-)
diff --git a/app/code/Magento/Swatches/Block/Product/Renderer/Configurable.php b/app/code/Magento/Swatches/Block/Product/Renderer/Configurable.php
index 35bf199681720..19d9340c4049c 100644
--- a/app/code/Magento/Swatches/Block/Product/Renderer/Configurable.php
+++ b/app/code/Magento/Swatches/Block/Product/Renderer/Configurable.php
@@ -61,12 +61,12 @@ class Configurable extends \Magento\ConfigurableProduct\Block\Product\View\Type\
/**
* Config path which contains number of swatches per product
*/
- const XML_PATH_SWATCHES_PER_PRODUCT = 'catalog/frontend/swatches_per_product';
+ private const XML_PATH_SWATCHES_PER_PRODUCT = 'catalog/frontend/swatches_per_product';
/**
* Config path if swatch tooltips are enabled
*/
- const XML_PATH_SHOW_SWATCH_TOOLTIP = 'catalog/frontend/show_swatch_tooltip';
+ private const XML_PATH_SHOW_SWATCH_TOOLTIP = 'catalog/frontend/show_swatch_tooltip';
/**
* @var Product
@@ -104,19 +104,19 @@ class Configurable extends \Magento\ConfigurableProduct\Block\Product\View\Type\
/**
* @SuppressWarnings(PHPMD.ExcessiveParameterList)
- * @param Context $context
- * @param ArrayUtils $arrayUtils
- * @param EncoderInterface $jsonEncoder
- * @param Data $helper
- * @param CatalogProduct $catalogProduct
- * @param CurrentCustomer $currentCustomer
- * @param PriceCurrencyInterface $priceCurrency
- * @param ConfigurableAttributeData $configurableAttributeData
- * @param SwatchData $swatchHelper
- * @param Media $swatchMediaHelper
- * @param array $data
+ * @param Context $context
+ * @param ArrayUtils $arrayUtils
+ * @param EncoderInterface $jsonEncoder
+ * @param Data $helper
+ * @param CatalogProduct $catalogProduct
+ * @param CurrentCustomer $currentCustomer
+ * @param PriceCurrencyInterface $priceCurrency
+ * @param ConfigurableAttributeData $configurableAttributeData
+ * @param SwatchData $swatchHelper
+ * @param Media $swatchMediaHelper
+ * @param array $data
* @param SwatchAttributesProvider|null $swatchAttributesProvider
- * @param UrlBuilder|null $imageUrlBuilder
+ * @param UrlBuilder|null $imageUrlBuilder
*/
public function __construct(
Context $context,
@@ -183,6 +183,7 @@ public function getJsonSwatchConfig()
$attributesData = $this->getSwatchAttributesData();
$allOptionIds = $this->getConfigurableOptionsIds($attributesData);
$swatchesData = $this->swatchHelper->getSwatchesByOptionsId($allOptionIds);
+
$config = [];
foreach ($attributesData as $attributeId => $attributeDataArray) {
if (isset($attributeDataArray['options'])) {
@@ -232,13 +233,11 @@ public function getShowSwatchTooltip()
* Set product to block
*
* @param Product $product
- *
* @return $this
*/
public function setProduct(Product $product)
{
$this->product = $product;
-
return $this;
}
@@ -269,10 +268,10 @@ protected function getSwatchAttributesData()
/**
* Init isProductHasSwatchAttribute.
*
- * @return void
* @deprecated 100.1.5 Method isProductHasSwatchAttribute() is used instead of this.
*
* @codeCoverageIgnore
+ * @return void
*/
protected function initIsProductHasSwatchAttribute()
{
@@ -288,7 +287,6 @@ protected function initIsProductHasSwatchAttribute()
protected function isProductHasSwatchAttribute()
{
$swatchAttributes = $this->swatchAttributesProvider->provide($this->getProduct());
-
return count($swatchAttributes) > 0;
}
@@ -298,7 +296,6 @@ protected function isProductHasSwatchAttribute()
* @param array $options
* @param array $swatchesCollectionArray
* @param array $attributeDataArray
- *
* @return array
*/
protected function addSwatchDataForAttribute(
@@ -321,10 +318,9 @@ protected function addSwatchDataForAttribute(
/**
* Add media from variation
*
- * @param array $swatch
+ * @param array $swatch
* @param integer $optionId
- * @param array $attributeDataArray
- *
+ * @param array $attributeDataArray
* @return array
*/
protected function addAdditionalMediaData(array $swatch, $optionId, array $attributeDataArray)
@@ -333,12 +329,11 @@ protected function addAdditionalMediaData(array $swatch, $optionId, array $attri
&& $attributeDataArray['use_product_image_for_swatch']
) {
$variationMedia = $this->getVariationMedia($attributeDataArray['attribute_code'], $optionId);
- if (!empty($variationMedia)) {
+ if (! empty($variationMedia)) {
$swatch['type'] = Swatch::SWATCH_TYPE_VISUAL_IMAGE;
$swatch = array_merge($swatch, $variationMedia);
}
}
-
return $swatch;
}
@@ -346,12 +341,12 @@ protected function addAdditionalMediaData(array $swatch, $optionId, array $attri
* Retrieve Swatch data for config
*
* @param array $swatchDataArray
- *
* @return array
*/
protected function extractNecessarySwatchData(array $swatchDataArray)
{
$result['type'] = $swatchDataArray['type'];
+
if ($result['type'] == Swatch::SWATCH_TYPE_VISUAL_IMAGE && !empty($swatchDataArray['value'])) {
$result['value'] = $this->swatchMediaHelper->getSwatchAttributeImage(
Swatch::SWATCH_IMAGE_NAME,
@@ -371,9 +366,8 @@ protected function extractNecessarySwatchData(array $swatchDataArray)
/**
* Generate Product Media array
*
- * @param string $attributeCode
+ * @param string $attributeCode
* @param integer $optionId
- *
* @return array
*/
protected function getVariationMedia($attributeCode, $optionId)
@@ -382,12 +376,14 @@ protected function getVariationMedia($attributeCode, $optionId)
$this->getProduct(),
[$attributeCode => $optionId]
);
+
if (!$variationProduct) {
$variationProduct = $this->swatchHelper->loadFirstVariationWithImage(
$this->getProduct(),
[$attributeCode => $optionId]
);
}
+
$variationMediaArray = [];
if ($variationProduct) {
$variationMediaArray = [
@@ -403,8 +399,7 @@ protected function getVariationMedia($attributeCode, $optionId)
* Get swatch product image.
*
* @param Product $childProduct
- * @param string $imageType
- *
+ * @param string $imageType
* @return string
*/
protected function getSwatchProductImage(Product $childProduct, $imageType)
@@ -416,6 +411,7 @@ protected function getSwatchProductImage(Product $childProduct, $imageType)
$swatchImageId = $imageType == Swatch::SWATCH_IMAGE_NAME ? 'swatch_image_base' : 'swatch_thumb_base';
$imageAttributes = ['type' => 'image'];
}
+
if (!empty($swatchImageId) && !empty($imageAttributes['type'])) {
return $this->imageUrlBuilder->getUrl($childProduct->getData($imageAttributes['type']), $swatchImageId);
}
@@ -425,8 +421,7 @@ protected function getSwatchProductImage(Product $childProduct, $imageType)
* Check if product have image.
*
* @param Product $product
- * @param string $imageType
- *
+ * @param string $imageType
* @return bool
*/
protected function isProductHasImage(Product $product, $imageType)
@@ -438,7 +433,6 @@ protected function isProductHasImage(Product $product, $imageType)
* Get configurable options ids.
*
* @param array $attributeData
- *
* @return array
* @since 100.0.3
*/
@@ -455,7 +449,6 @@ protected function getConfigurableOptionsIds(array $attributeData)
}
}
}
-
return array_keys($ids);
}
@@ -540,6 +533,7 @@ public function getJsonSwatchSizeConfig()
{
$imageConfig = $this->swatchMediaHelper->getImageConfig();
$sizeConfig = [];
+
$sizeConfig[self::SWATCH_IMAGE_NAME]['width'] = $imageConfig[Swatch::SWATCH_IMAGE_NAME]['width'];
$sizeConfig[self::SWATCH_IMAGE_NAME]['height'] = $imageConfig[Swatch::SWATCH_IMAGE_NAME]['height'];
$sizeConfig[self::SWATCH_THUMBNAIL_NAME]['height'] = $imageConfig[Swatch::SWATCH_THUMBNAIL_NAME]['height'];
From 2ea7a99f9684597d36cc7422d5d0f6ebf3ea4f4f Mon Sep 17 00:00:00 2001
From: Yuliya Labudova
Date: Fri, 6 Sep 2019 11:47:56 +0300
Subject: [PATCH 156/937] MAGETWO-94565: Catalog product collection filters
produce errors and cause inconsistent behaviour
- Fix CR comments.
---
app/code/Magento/Catalog/Model/ResourceModel/Category.php | 6 +++++-
.../Catalog/Model/ResourceModel/Product/Collection.php | 4 ++++
.../Catalog/Model/ResourceModel/Product/CollectionTest.php | 7 +++++--
3 files changed, 14 insertions(+), 3 deletions(-)
diff --git a/app/code/Magento/Catalog/Model/ResourceModel/Category.php b/app/code/Magento/Catalog/Model/ResourceModel/Category.php
index fb8c089ed9f9a..797ce72ae9b7a 100644
--- a/app/code/Magento/Catalog/Model/ResourceModel/Category.php
+++ b/app/code/Magento/Catalog/Model/ResourceModel/Category.php
@@ -1155,6 +1155,10 @@ public function getCategoryWithChildren(int $categoryId): array
)->where('entity_type_id = ?', CategorySetup::CATEGORY_ENTITY_TYPE_ID)
->where('attribute_code = ?', 'is_anchor')
->limit(1);
+ $isAnchorAttributeCode = $connection->fetchOne($selectAttributeCode);
+ if (empty($isAnchorAttributeCode) || (int)$isAnchorAttributeCode <= 0) {
+ return [];
+ }
$select = $connection->select()
->from(
@@ -1166,7 +1170,7 @@ public function getCategoryWithChildren(int $categoryId): array
['is_anchor' => 'cce_int.value']
)->where(
'cce_int.attribute_id = ?',
- $connection->fetchOne($selectAttributeCode)
+ $isAnchorAttributeCode
)->where(
"cce.path LIKE '%/{$categoryId}' OR cce.path LIKE '%/{$categoryId}/%'"
)->order('path');
diff --git a/app/code/Magento/Catalog/Model/ResourceModel/Product/Collection.php b/app/code/Magento/Catalog/Model/ResourceModel/Product/Collection.php
index 71b03620b342b..42d55892b6ec6 100644
--- a/app/code/Magento/Catalog/Model/ResourceModel/Product/Collection.php
+++ b/app/code/Magento/Catalog/Model/ResourceModel/Product/Collection.php
@@ -2107,6 +2107,10 @@ private function getChildrenCategories(int $categoryId): array
$anchorCategory = [];
$categories = $this->categoryResourceModel->getCategoryWithChildren($categoryId);
+ if (empty($categories)) {
+ return $categoryIds;
+ }
+
$firstCategory = array_shift($categories);
if ($firstCategory['is_anchor'] == 1) {
$anchorCategory[] = (int)$firstCategory['entity_id'];
diff --git a/dev/tests/integration/testsuite/Magento/Catalog/Model/ResourceModel/Product/CollectionTest.php b/dev/tests/integration/testsuite/Magento/Catalog/Model/ResourceModel/Product/CollectionTest.php
index 80d700c7e54ff..d3970ad403ffd 100644
--- a/dev/tests/integration/testsuite/Magento/Catalog/Model/ResourceModel/Product/CollectionTest.php
+++ b/dev/tests/integration/testsuite/Magento/Catalog/Model/ResourceModel/Product/CollectionTest.php
@@ -99,6 +99,7 @@ public function testAddPriceDataOnSchedule()
/**
* @magentoDataFixture Magento/Catalog/_files/products.php
+ * @magentoAppIsolation enabled
* @magentoDbIsolation disabled
*/
public function testSetVisibility()
@@ -116,6 +117,7 @@ public function testSetVisibility()
/**
* @magentoDataFixture Magento/Catalog/_files/category_product.php
+ * @magentoAppIsolation enabled
* @magentoDbIsolation disabled
*/
public function testSetCategoryWithStoreFilter()
@@ -131,8 +133,8 @@ public function testSetCategoryWithStoreFilter()
$this->collection->load();
$collectionStoreFilterAfter = Bootstrap::getObjectManager()->create(
- \Magento\Catalog\Model\ResourceModel\Product\Collection::class
- );
+ \Magento\Catalog\Model\ResourceModel\Product\CollectionFactory::class
+ )->create();
$collectionStoreFilterAfter->addStoreFilter(1)->addCategoryFilter($category);
$collectionStoreFilterAfter->load();
$this->assertEquals($this->collection->getItems(), $collectionStoreFilterAfter->getItems());
@@ -141,6 +143,7 @@ public function testSetCategoryWithStoreFilter()
/**
* @magentoDataFixture Magento/Catalog/_files/categories.php
+ * @magentoAppIsolation enabled
* @magentoDbIsolation disabled
*/
public function testSetCategoryFilter()
From ddcbb93cf8b897891f543a72ec709d34c2893df4 Mon Sep 17 00:00:00 2001
From: Dmytro Poperechnyy
Date: Fri, 6 Sep 2019 09:41:10 -0500
Subject: [PATCH 157/937] MC-19247: Broken translations with advanced bundling
- Fix embedded translation strategy;
---
.../Magento/Translation/Model/FileManager.php | 20 -----------------
.../Translation/ViewModel/Dictionary.php | 22 +++++++++----------
.../view/base/templates/dictionary.phtml | 11 ++++++++++
.../view/base/templates/translate.phtml | 2 ++
4 files changed, 23 insertions(+), 32 deletions(-)
diff --git a/app/code/Magento/Translation/Model/FileManager.php b/app/code/Magento/Translation/Model/FileManager.php
index 43bd357c50691..387173f6de0ba 100644
--- a/app/code/Magento/Translation/Model/FileManager.php
+++ b/app/code/Magento/Translation/Model/FileManager.php
@@ -8,8 +8,6 @@
use Magento\Framework\App\Filesystem\DirectoryList;
use Magento\Framework\App\ObjectManager;
use Magento\Translation\Model\Inline\File as TranslationFile;
-use Magento\Framework\View\Asset\File\FallbackContext as FileFallbackContext;
-use Magento\Framework\View\Asset\File;
/**
* A service for handling Translation config files
@@ -41,11 +39,6 @@ class FileManager
*/
private $translationFile;
- /**
- * @var FileFallbackContext
- */
- private $staticContext;
-
/**
* @param \Magento\Framework\View\Asset\Repository $assetRepo
* @param \Magento\Framework\App\Filesystem\DirectoryList $directoryList
@@ -62,7 +55,6 @@ public function __construct(
$this->directoryList = $directoryList;
$this->driverFile = $driverFile;
$this->translationFile = $translationFile ?: ObjectManager::getInstance()->get(TranslationFile::class);
- $this->staticContext = $assetRepo->getStaticViewFileContext();
}
/**
@@ -145,16 +137,4 @@ public function getTranslationFileVersion()
return sha1($translationFileHash . $this->getTranslationFilePath());
}
-
- /**
- * Create a view asset for translate dictionary config.
- *
- * @param string $fileName
- * @return File
- */
- public function createTranslateDictionaryConfigAsset(string $fileName): File
- {
- $relPath = $this->staticContext->getConfigPath() . '/' . $fileName;
- return $this->assetRepo->createArbitrary($relPath, '');
- }
}
diff --git a/app/code/Magento/Translation/ViewModel/Dictionary.php b/app/code/Magento/Translation/ViewModel/Dictionary.php
index c7bb972980e3d..ced632fd7e6b2 100644
--- a/app/code/Magento/Translation/ViewModel/Dictionary.php
+++ b/app/code/Magento/Translation/ViewModel/Dictionary.php
@@ -6,8 +6,8 @@
namespace Magento\Translation\ViewModel;
+use Magento\Framework\View\Asset\Repository as AssetRepository;
use Magento\Framework\View\Element\Block\ArgumentInterface;
-use Magento\Translation\Model\FileManager;
use Magento\Translation\Model\Js\Config as JsConfig;
/**
@@ -16,24 +16,24 @@
class Dictionary implements ArgumentInterface
{
/**
- * @var FileManager
+ * @var JsConfig
*/
- private $fileManager;
+ private $config;
/**
- * @var JsConfig
+ * @var AssetRepository
*/
- private $config;
+ private $assetRepo;
/**
- * @param FileManager $fileManager
+ * @param AssetRepository $assetRepo
* @param JsConfig $config
*/
public function __construct(
- FileManager $fileManager,
+ AssetRepository $assetRepo,
JsConfig $config
) {
- $this->fileManager = $fileManager;
+ $this->assetRepo = $assetRepo;
$this->config = $config;
}
@@ -44,13 +44,11 @@ public function __construct(
*/
public function getTranslationDictionaryFile(): string
{
- $translateDictionaryConfig = $this->fileManager->createTranslateDictionaryConfigAsset(JsConfig::DICTIONARY_FILE_NAME);
-
- return $translateDictionaryConfig->getUrl();
+ return $this->assetRepo->getUrl(JsConfig::DICTIONARY_FILE_NAME);
}
/**
- * Is js translation set to dictionary mode
+ * Is js translation set to dictionary mode.
*
* @return bool
*/
diff --git a/app/code/Magento/Translation/view/base/templates/dictionary.phtml b/app/code/Magento/Translation/view/base/templates/dictionary.phtml
index f8d30149cf4fb..87318ef437418 100644
--- a/app/code/Magento/Translation/view/base/templates/dictionary.phtml
+++ b/app/code/Magento/Translation/view/base/templates/dictionary.phtml
@@ -18,4 +18,15 @@ $viewModel = $block->getData('dictionary_view_model');
}
});
+
+
+
diff --git a/app/code/Magento/Translation/view/base/templates/translate.phtml b/app/code/Magento/Translation/view/base/templates/translate.phtml
index 445c3e88830a6..c4592e02eff88 100644
--- a/app/code/Magento/Translation/view/base/templates/translate.phtml
+++ b/app/code/Magento/Translation/view/base/templates/translate.phtml
@@ -6,6 +6,8 @@
/** @var \Magento\Translation\Block\Js $block */
?>
+
+
dictionaryEnabled()) : ?>
-
-
-
-
-
+
diff --git a/lib/web/mage/translate.js b/lib/web/mage/translate.js
index 261d680c9ffab..4a4a46e9a3e82 100644
--- a/lib/web/mage/translate.js
+++ b/lib/web/mage/translate.js
@@ -6,9 +6,8 @@
define([
'jquery',
'mage/mage',
- 'text!dictionary'
-], function ($, mage, d) {
- var dictionary = JSON.parse(d);
+ 'dictionary'
+], function ($, mage, dictionary) {
$.extend(true, $, {
mage: {
translate: (function () {
From 57cf55a26da38edcf0dbd76b4d5b06242a321cd8 Mon Sep 17 00:00:00 2001
From: Dmytro Poperechnyy
Date: Tue, 10 Sep 2019 16:38:44 -0500
Subject: [PATCH 183/937] MC-19247: Broken translations with advanced bundling
---
.../Magento/Translation/view/base/templates/dictionary.phtml | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/app/code/Magento/Translation/view/base/templates/dictionary.phtml b/app/code/Magento/Translation/view/base/templates/dictionary.phtml
index d2244ca317108..8c517e3b3ea23 100644
--- a/app/code/Magento/Translation/view/base/templates/dictionary.phtml
+++ b/app/code/Magento/Translation/view/base/templates/dictionary.phtml
@@ -9,6 +9,6 @@ $viewModel = $block->getData('dictionary_view_model');
?>
From c1b7ba0b1fa7e1737a94d9307a9a40d115f42e09 Mon Sep 17 00:00:00 2001
From: Roman Lytvynenko
Date: Tue, 10 Sep 2019 17:22:50 -0500
Subject: [PATCH 184/937] MC-19661: Export Products bug. I can't exclude
attributes from CSV file.
---
.../Controller/Adminhtml/Export/Export.php | 13 +++++---
.../Model/Export/Entity/ExportInfo.php | 19 ++++++++++--
.../Model/Export/Entity/ExportInfoFactory.php | 10 ++++--
.../Entity/ExtendedExportInfoInterface.php | 31 +++++++++++++++++++
.../ImportExport/etc/communication.xml | 2 +-
app/code/Magento/ImportExport/etc/di.xml | 1 +
6 files changed, 65 insertions(+), 11 deletions(-)
create mode 100644 app/code/Magento/ImportExport/Model/Export/Entity/ExtendedExportInfoInterface.php
diff --git a/app/code/Magento/ImportExport/Controller/Adminhtml/Export/Export.php b/app/code/Magento/ImportExport/Controller/Adminhtml/Export/Export.php
index 13c22a976e798..c5885f72474f9 100644
--- a/app/code/Magento/ImportExport/Controller/Adminhtml/Export/Export.php
+++ b/app/code/Magento/ImportExport/Controller/Adminhtml/Export/Export.php
@@ -5,13 +5,13 @@
*/
namespace Magento\ImportExport\Controller\Adminhtml\Export;
+use Magento\Backend\App\Action\Context;
use Magento\Framework\App\Action\HttpPostActionInterface as HttpPostActionInterface;
+use Magento\Framework\App\Response\Http\FileFactory;
use Magento\Framework\Controller\ResultFactory;
+use Magento\Framework\MessageQueue\PublisherInterface;
use Magento\ImportExport\Controller\Adminhtml\Export as ExportController;
-use Magento\Backend\App\Action\Context;
-use Magento\Framework\App\Response\Http\FileFactory;
use Magento\ImportExport\Model\Export as ExportModel;
-use Magento\Framework\MessageQueue\PublisherInterface;
use Magento\ImportExport\Model\Export\Entity\ExportInfoFactory;
/**
@@ -76,11 +76,16 @@ public function execute()
try {
$params = $this->getRequest()->getParams();
+ if (!array_key_exists('skip_attr', $params)) {
+ $params['skip_attr'] = [];
+ }
+
/** @var ExportInfoFactory $dataObject */
$dataObject = $this->exportInfoFactory->create(
$params['file_format'],
$params['entity'],
- $params['export_filter']
+ $params['export_filter'],
+ $params['skip_attr']
);
$this->messagePublisher->publish('import_export.export', $dataObject);
diff --git a/app/code/Magento/ImportExport/Model/Export/Entity/ExportInfo.php b/app/code/Magento/ImportExport/Model/Export/Entity/ExportInfo.php
index 6dffc1827cfd0..afe10614ded7f 100644
--- a/app/code/Magento/ImportExport/Model/Export/Entity/ExportInfo.php
+++ b/app/code/Magento/ImportExport/Model/Export/Entity/ExportInfo.php
@@ -7,12 +7,10 @@
namespace Magento\ImportExport\Model\Export\Entity;
-use \Magento\ImportExport\Api\Data\ExportInfoInterface;
-
/**
* Class ExportInfo implementation for ExportInfoInterface.
*/
-class ExportInfo implements ExportInfoInterface
+class ExportInfo implements ExtendedExportInfoInterface
{
/**
* @var string
@@ -39,6 +37,11 @@ class ExportInfo implements ExportInfoInterface
*/
private $exportFilter;
+ /**
+ * @var mixed
+ */
+ private $skipAttr;
+
/**
* @inheritdoc
*/
@@ -118,4 +121,14 @@ public function setExportFilter($exportFilter)
{
$this->exportFilter = $exportFilter;
}
+
+ public function getSkipAttr()
+ {
+ return $this->skipAttr;
+ }
+
+ public function setSkipAttr($skipAttr)
+ {
+ $this->skipAttr = $skipAttr;
+ }
}
diff --git a/app/code/Magento/ImportExport/Model/Export/Entity/ExportInfoFactory.php b/app/code/Magento/ImportExport/Model/Export/Entity/ExportInfoFactory.php
index e3cbd162aa5af..a8f4b08e459b5 100644
--- a/app/code/Magento/ImportExport/Model/Export/Entity/ExportInfoFactory.php
+++ b/app/code/Magento/ImportExport/Model/Export/Entity/ExportInfoFactory.php
@@ -84,17 +84,19 @@ public function __construct(
* @param string $fileFormat
* @param string $entity
* @param string $exportFilter
+ * @param array $skipAttr
* @return ExportInfoInterface
* @throws \Magento\Framework\Exception\LocalizedException
*/
- public function create($fileFormat, $entity, $exportFilter)
+ public function create($fileFormat, $entity, $exportFilter, $skipAttr)
{
$writer = $this->getWriter($fileFormat);
- $entityAdapter = $this->getEntityAdapter($entity, $fileFormat, $exportFilter, $writer->getContentType());
+ $entityAdapter = $this->getEntityAdapter($entity, $fileFormat, $exportFilter, $skipAttr, $writer->getContentType());
$fileName = $this->generateFileName($entity, $entityAdapter, $writer->getFileExtension());
/** @var ExportInfoInterface $exportInfo */
$exportInfo = $this->objectManager->create(ExportInfoInterface::class);
$exportInfo->setExportFilter($this->serializer->serialize($exportFilter));
+ $exportInfo->setSkipAttr($skipAttr);
$exportInfo->setFileName($fileName);
$exportInfo->setEntity($entity);
$exportInfo->setFileFormat($fileFormat);
@@ -130,11 +132,12 @@ private function generateFileName($entity, $entityAdapter, $fileExtensions)
* @param string $entity
* @param string $fileFormat
* @param string $exportFilter
+ * @param array $skipAttr
* @param string $contentType
* @return \Magento\ImportExport\Model\Export\AbstractEntity|AbstractEntity
* @throws \Magento\Framework\Exception\LocalizedException
*/
- private function getEntityAdapter($entity, $fileFormat, $exportFilter, $contentType)
+ private function getEntityAdapter($entity, $fileFormat, $exportFilter, $skipAttr, $contentType)
{
$entities = $this->exportConfig->getEntities();
if (isset($entities[$entity])) {
@@ -170,6 +173,7 @@ private function getEntityAdapter($entity, $fileFormat, $exportFilter, $contentT
'fileFormat' => $fileFormat,
'entity' => $entity,
'exportFilter' => $exportFilter,
+ 'skipAttr' => $skipAttr,
'contentType' => $contentType,
]);
return $entityAdapter;
diff --git a/app/code/Magento/ImportExport/Model/Export/Entity/ExtendedExportInfoInterface.php b/app/code/Magento/ImportExport/Model/Export/Entity/ExtendedExportInfoInterface.php
new file mode 100644
index 0000000000000..3d59b213f12b6
--- /dev/null
+++ b/app/code/Magento/ImportExport/Model/Export/Entity/ExtendedExportInfoInterface.php
@@ -0,0 +1,31 @@
+
-
+
diff --git a/app/code/Magento/ImportExport/etc/di.xml b/app/code/Magento/ImportExport/etc/di.xml
index 909b526e4790c..bf90b434ea260 100644
--- a/app/code/Magento/ImportExport/etc/di.xml
+++ b/app/code/Magento/ImportExport/etc/di.xml
@@ -11,6 +11,7 @@
+
From b8d6ad053b1c11fbabc2ee6d091a0fcc5264aa91 Mon Sep 17 00:00:00 2001
From: Ravi Chandra
Date: Wed, 11 Sep 2019 10:43:22 +0530
Subject: [PATCH 185/937] Add digits validation for Bulk Actions,Full Page
Cache(TTL), Environment Update Time system configuration
---
app/code/Magento/AsynchronousOperations/etc/adminhtml/system.xml | 1 +
app/code/Magento/MediaStorage/etc/adminhtml/system.xml | 1 +
app/code/Magento/PageCache/etc/adminhtml/system.xml | 1 +
3 files changed, 3 insertions(+)
diff --git a/app/code/Magento/AsynchronousOperations/etc/adminhtml/system.xml b/app/code/Magento/AsynchronousOperations/etc/adminhtml/system.xml
index 7190b80750357..e373a4fc78b13 100644
--- a/app/code/Magento/AsynchronousOperations/etc/adminhtml/system.xml
+++ b/app/code/Magento/AsynchronousOperations/etc/adminhtml/system.xml
@@ -13,6 +13,7 @@
Bulk Actions
Days Saved in Log
+ validate-zero-or-greater validate-digits
diff --git a/app/code/Magento/MediaStorage/etc/adminhtml/system.xml b/app/code/Magento/MediaStorage/etc/adminhtml/system.xml
index 0f6e7f93aea11..2c7219fe8afaa 100644
--- a/app/code/Magento/MediaStorage/etc/adminhtml/system.xml
+++ b/app/code/Magento/MediaStorage/etc/adminhtml/system.xml
@@ -28,6 +28,7 @@
Environment Update Time
+ validate-zero-or-greater validate-digits
diff --git a/app/code/Magento/PageCache/etc/adminhtml/system.xml b/app/code/Magento/PageCache/etc/adminhtml/system.xml
index 8013ad40ef5aa..234e3e48a95d8 100644
--- a/app/code/Magento/PageCache/etc/adminhtml/system.xml
+++ b/app/code/Magento/PageCache/etc/adminhtml/system.xml
@@ -74,6 +74,7 @@
TTL for public content
+ validate-zero-or-greater validate-digits
Public content cache lifetime in seconds. If field is empty default value 86400 will be saved.
Magento\PageCache\Model\System\Config\Backend\Ttl
From bb4a4fe3b2b9cafc6af4830238241566567b7860 Mon Sep 17 00:00:00 2001
From: Yuliya Labudova
Date: Wed, 11 Sep 2019 11:20:05 +0300
Subject: [PATCH 186/937] MC-15507: Shipping address is dropped after zip code
in new billing address form is filled
- Delete unnecessary file.
---
.../SelectShippingAddressPopupSection.xml | 16 ----------------
1 file changed, 16 deletions(-)
delete mode 100644 app/code/Magento/Checkout/Test/Mftf/Section/SelectShippingAddressPopupSection.xml
diff --git a/app/code/Magento/Checkout/Test/Mftf/Section/SelectShippingAddressPopupSection.xml b/app/code/Magento/Checkout/Test/Mftf/Section/SelectShippingAddressPopupSection.xml
deleted file mode 100644
index 965ee4f4b10d8..0000000000000
--- a/app/code/Magento/Checkout/Test/Mftf/Section/SelectShippingAddressPopupSection.xml
+++ /dev/null
@@ -1,16 +0,0 @@
-
-
-
-
-
-
From 93e93deb70e397b1a4e21a0714d9905a99ea127d Mon Sep 17 00:00:00 2001
From: Serhiy Yelahin
Date: Wed, 11 Sep 2019 12:16:03 +0300
Subject: [PATCH 187/937] MC-19701: Country code for Taiwan (Province of China)
---
lib/internal/Magento/Framework/Locale/TranslatedLists.php | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/lib/internal/Magento/Framework/Locale/TranslatedLists.php b/lib/internal/Magento/Framework/Locale/TranslatedLists.php
index 2087564dcec20..1724198f15b9f 100644
--- a/lib/internal/Magento/Framework/Locale/TranslatedLists.php
+++ b/lib/internal/Magento/Framework/Locale/TranslatedLists.php
@@ -10,6 +10,7 @@
use Magento\Framework\Locale\Bundle\DataBundle;
use Magento\Framework\Locale\Bundle\LanguageBundle;
use Magento\Framework\Locale\Bundle\RegionBundle;
+use Magento\Framework\Validator\Locale;
/**
* Translated lists.
@@ -207,7 +208,11 @@ public function getCountryTranslation($value, $locale = null)
$locale = $this->localeResolver->getLocale();
}
+ $language = \Locale::getPrimaryLanguage($locale);
$translation = (new RegionBundle())->get($locale)['Countries'][$value];
+ if ($value == 'TW' && $language == 'en') {
+ $translation .= ", Province of China";
+ }
return $translation ? (string)__($translation) : $translation;
}
From c771fb976b8ce7480723e6555e529bb9394c4428 Mon Sep 17 00:00:00 2001
From: Serhiy Yelahin
Date: Wed, 11 Sep 2019 14:04:20 +0300
Subject: [PATCH 188/937] MC-19701: Country code for Taiwan (Province of China)
---
lib/internal/Magento/Framework/Locale/TranslatedLists.php | 1 -
1 file changed, 1 deletion(-)
diff --git a/lib/internal/Magento/Framework/Locale/TranslatedLists.php b/lib/internal/Magento/Framework/Locale/TranslatedLists.php
index 1724198f15b9f..5ed552d8219ae 100644
--- a/lib/internal/Magento/Framework/Locale/TranslatedLists.php
+++ b/lib/internal/Magento/Framework/Locale/TranslatedLists.php
@@ -10,7 +10,6 @@
use Magento\Framework\Locale\Bundle\DataBundle;
use Magento\Framework\Locale\Bundle\LanguageBundle;
use Magento\Framework\Locale\Bundle\RegionBundle;
-use Magento\Framework\Validator\Locale;
/**
* Translated lists.
From e01d260bb49313b3cc2ecbc993c4a16dd29e3856 Mon Sep 17 00:00:00 2001
From: Roman Lytvynenko
Date: Wed, 11 Sep 2019 07:55:09 -0500
Subject: [PATCH 189/937] MC-19661: Export Products bug. I can't exclude
attributes from CSV file.
---
.../Model/Export/Entity/ExportInfo.php | 6 +++++
.../Model/Export/Entity/ExportInfoFactory.php | 24 ++++++++++++-------
2 files changed, 22 insertions(+), 8 deletions(-)
diff --git a/app/code/Magento/ImportExport/Model/Export/Entity/ExportInfo.php b/app/code/Magento/ImportExport/Model/Export/Entity/ExportInfo.php
index afe10614ded7f..ef84f50919b52 100644
--- a/app/code/Magento/ImportExport/Model/Export/Entity/ExportInfo.php
+++ b/app/code/Magento/ImportExport/Model/Export/Entity/ExportInfo.php
@@ -122,11 +122,17 @@ public function setExportFilter($exportFilter)
$this->exportFilter = $exportFilter;
}
+ /**
+ * @inheritdoc
+ */
public function getSkipAttr()
{
return $this->skipAttr;
}
+ /**
+ * @inheritdoc
+ */
public function setSkipAttr($skipAttr)
{
$this->skipAttr = $skipAttr;
diff --git a/app/code/Magento/ImportExport/Model/Export/Entity/ExportInfoFactory.php b/app/code/Magento/ImportExport/Model/Export/Entity/ExportInfoFactory.php
index a8f4b08e459b5..32c989acb661c 100644
--- a/app/code/Magento/ImportExport/Model/Export/Entity/ExportInfoFactory.php
+++ b/app/code/Magento/ImportExport/Model/Export/Entity/ExportInfoFactory.php
@@ -91,7 +91,13 @@ public function __construct(
public function create($fileFormat, $entity, $exportFilter, $skipAttr)
{
$writer = $this->getWriter($fileFormat);
- $entityAdapter = $this->getEntityAdapter($entity, $fileFormat, $exportFilter, $skipAttr, $writer->getContentType());
+ $entityAdapter = $this->getEntityAdapter(
+ $entity,
+ $fileFormat,
+ $exportFilter,
+ $skipAttr,
+ $writer->getContentType()
+ );
$fileName = $this->generateFileName($entity, $entityAdapter, $writer->getFileExtension());
/** @var ExportInfoInterface $exportInfo */
$exportInfo = $this->objectManager->create(ExportInfoInterface::class);
@@ -169,13 +175,15 @@ private function getEntityAdapter($entity, $fileFormat, $exportFilter, $skipAttr
} else {
throw new \Magento\Framework\Exception\LocalizedException(__('Please enter a correct entity.'));
}
- $entityAdapter->setParameters([
- 'fileFormat' => $fileFormat,
- 'entity' => $entity,
- 'exportFilter' => $exportFilter,
- 'skipAttr' => $skipAttr,
- 'contentType' => $contentType,
- ]);
+ $entityAdapter->setParameters(
+ [
+ 'fileFormat' => $fileFormat,
+ 'entity' => $entity,
+ 'exportFilter' => $exportFilter,
+ 'skipAttr' => $skipAttr,
+ 'contentType' => $contentType,
+ ]
+ );
return $entityAdapter;
}
From cc70abdc388b62ca5ca58c3c41afa2b40e34ab0a Mon Sep 17 00:00:00 2001
From: Aliaksei_Manenak
Date: Wed, 11 Sep 2019 18:36:09 +0300
Subject: [PATCH 190/937] MC-17493: Cart/catalog rules grid missing
- Updated automated test script
---
.../Test/Mftf/ActionGroup/CatalogPriceRuleActionGroup.xml | 6 +-----
.../ActionGroup/AdminCreateCartPriceRuleActionGroup.xml | 3 ---
2 files changed, 1 insertion(+), 8 deletions(-)
diff --git a/app/code/Magento/CatalogRule/Test/Mftf/ActionGroup/CatalogPriceRuleActionGroup.xml b/app/code/Magento/CatalogRule/Test/Mftf/ActionGroup/CatalogPriceRuleActionGroup.xml
index f2ee5dc30591b..e4aecfab549ac 100644
--- a/app/code/Magento/CatalogRule/Test/Mftf/ActionGroup/CatalogPriceRuleActionGroup.xml
+++ b/app/code/Magento/CatalogRule/Test/Mftf/ActionGroup/CatalogPriceRuleActionGroup.xml
@@ -58,12 +58,8 @@
-
-
-
-
-
+
diff --git a/app/code/Magento/SalesRule/Test/Mftf/ActionGroup/AdminCreateCartPriceRuleActionGroup.xml b/app/code/Magento/SalesRule/Test/Mftf/ActionGroup/AdminCreateCartPriceRuleActionGroup.xml
index 16a19de670af3..8d71b8501a411 100644
--- a/app/code/Magento/SalesRule/Test/Mftf/ActionGroup/AdminCreateCartPriceRuleActionGroup.xml
+++ b/app/code/Magento/SalesRule/Test/Mftf/ActionGroup/AdminCreateCartPriceRuleActionGroup.xml
@@ -113,13 +113,10 @@
-
-
-
From 5d259e509c8b2a678bc9914a21578909fb481055 Mon Sep 17 00:00:00 2001
From: Dmytro Poperechnyy
Date: Wed, 11 Sep 2019 10:46:38 -0500
Subject: [PATCH 191/937] MC-19247: Broken translations with advanced bundling
- Test to find degradation;
---
app/code/Magento/Translation/ViewModel/Dictionary.php | 1 +
1 file changed, 1 insertion(+)
diff --git a/app/code/Magento/Translation/ViewModel/Dictionary.php b/app/code/Magento/Translation/ViewModel/Dictionary.php
index 20ecef1d0eedc..bb5244d50a7f2 100644
--- a/app/code/Magento/Translation/ViewModel/Dictionary.php
+++ b/app/code/Magento/Translation/ViewModel/Dictionary.php
@@ -38,6 +38,7 @@ public function __construct(
*/
public function getTranslationDictionary(): string
{
+ return '[]';
try {
$asset = $this->assetRepo->createAsset(JsConfig::DICTIONARY_FILE_NAME);
$content = $asset->getContent();
From a16f08be22a8b1b0376ef9ddee66c7b43c0895a3 Mon Sep 17 00:00:00 2001
From: Roman Lytvynenko
Date: Wed, 11 Sep 2019 10:51:43 -0500
Subject: [PATCH 192/937] MC-19661: Export Products bug. I can't exclude
attributes from CSV file.
---
.../Entity => Api/Data}/ExtendedExportInfoInterface.php | 4 +---
.../Magento/ImportExport/Model/Export/Entity/ExportInfo.php | 2 ++
app/code/Magento/ImportExport/etc/communication.xml | 2 +-
app/code/Magento/ImportExport/etc/di.xml | 2 +-
4 files changed, 5 insertions(+), 5 deletions(-)
rename app/code/Magento/ImportExport/{Model/Export/Entity => Api/Data}/ExtendedExportInfoInterface.php (83%)
diff --git a/app/code/Magento/ImportExport/Model/Export/Entity/ExtendedExportInfoInterface.php b/app/code/Magento/ImportExport/Api/Data/ExtendedExportInfoInterface.php
similarity index 83%
rename from app/code/Magento/ImportExport/Model/Export/Entity/ExtendedExportInfoInterface.php
rename to app/code/Magento/ImportExport/Api/Data/ExtendedExportInfoInterface.php
index 3d59b213f12b6..4e3e1647e9d27 100644
--- a/app/code/Magento/ImportExport/Model/Export/Entity/ExtendedExportInfoInterface.php
+++ b/app/code/Magento/ImportExport/Api/Data/ExtendedExportInfoInterface.php
@@ -5,9 +5,7 @@
*/
declare(strict_types=1);
-namespace Magento\ImportExport\Model\Export\Entity;
-
-use Magento\ImportExport\Api\Data\ExportInfoInterface;
+namespace Magento\ImportExport\Api\Data;
/**
* Basic interface with data needed for export operation.
diff --git a/app/code/Magento/ImportExport/Model/Export/Entity/ExportInfo.php b/app/code/Magento/ImportExport/Model/Export/Entity/ExportInfo.php
index ef84f50919b52..a5d5d63e4f8da 100644
--- a/app/code/Magento/ImportExport/Model/Export/Entity/ExportInfo.php
+++ b/app/code/Magento/ImportExport/Model/Export/Entity/ExportInfo.php
@@ -7,6 +7,8 @@
namespace Magento\ImportExport\Model\Export\Entity;
+use Magento\ImportExport\Api\Data\ExtendedExportInfoInterface;
+
/**
* Class ExportInfo implementation for ExportInfoInterface.
*/
diff --git a/app/code/Magento/ImportExport/etc/communication.xml b/app/code/Magento/ImportExport/etc/communication.xml
index 64f35b3484964..3f87eef1ddbd4 100644
--- a/app/code/Magento/ImportExport/etc/communication.xml
+++ b/app/code/Magento/ImportExport/etc/communication.xml
@@ -6,7 +6,7 @@
*/
-->
-
+
diff --git a/app/code/Magento/ImportExport/etc/di.xml b/app/code/Magento/ImportExport/etc/di.xml
index bf90b434ea260..2a9e1d388754f 100644
--- a/app/code/Magento/ImportExport/etc/di.xml
+++ b/app/code/Magento/ImportExport/etc/di.xml
@@ -11,7 +11,7 @@
-
+
From cd05c5a96b7e397f7f18d08bb431e902747227c4 Mon Sep 17 00:00:00 2001
From: Roman Lytvynenko
Date: Wed, 11 Sep 2019 14:21:20 -0500
Subject: [PATCH 193/937] MC-19661: Export Products bug. I can't exclude
attributes from CSV file.
---
.../ImportExport/Api/Data/ExtendedExportInfoInterface.php | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/app/code/Magento/ImportExport/Api/Data/ExtendedExportInfoInterface.php b/app/code/Magento/ImportExport/Api/Data/ExtendedExportInfoInterface.php
index 4e3e1647e9d27..aa14d562d9cf7 100644
--- a/app/code/Magento/ImportExport/Api/Data/ExtendedExportInfoInterface.php
+++ b/app/code/Magento/ImportExport/Api/Data/ExtendedExportInfoInterface.php
@@ -8,7 +8,7 @@
namespace Magento\ImportExport\Api\Data;
/**
- * Basic interface with data needed for export operation.
+ * Extended export interface for implementation of Skipped Attributes which are missing from the basic interface
*/
interface ExtendedExportInfoInterface extends ExportInfoInterface
{
From 2a4a2228de30da83ca6e9bac410ebc37b677086a Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Torben=20Ho=CC=88hn?=
Date: Wed, 11 Sep 2019 21:46:43 +0200
Subject: [PATCH 194/937] add view model
---
.../Block/Product/Renderer/Configurable.php | 18 -------
.../Product/Renderer/Configurable.php | 50 +++++++++++++++++++
.../frontend/layout/catalog_category_view.xml | 13 ++++-
...catalog_product_view_type_configurable.xml | 11 +++-
.../layout/catalog_widget_product_list.xml | 15 ++++--
.../layout/catalogsearch_advanced_result.xml | 13 ++++-
.../layout/catalogsearch_result_index.xml | 13 ++++-
...list_index_configure_type_configurable.xml | 11 +++-
.../templates/product/listing/renderer.phtml | 4 +-
.../templates/product/view/renderer.phtml | 8 ++-
10 files changed, 122 insertions(+), 34 deletions(-)
create mode 100644 app/code/Magento/Swatches/ViewModel/Product/Renderer/Configurable.php
diff --git a/app/code/Magento/Swatches/Block/Product/Renderer/Configurable.php b/app/code/Magento/Swatches/Block/Product/Renderer/Configurable.php
index 19d9340c4049c..a2cae7f7b5a20 100644
--- a/app/code/Magento/Swatches/Block/Product/Renderer/Configurable.php
+++ b/app/code/Magento/Swatches/Block/Product/Renderer/Configurable.php
@@ -63,11 +63,6 @@ class Configurable extends \Magento\ConfigurableProduct\Block\Product\View\Type\
*/
private const XML_PATH_SWATCHES_PER_PRODUCT = 'catalog/frontend/swatches_per_product';
- /**
- * Config path if swatch tooltips are enabled
- */
- private const XML_PATH_SHOW_SWATCH_TOOLTIP = 'catalog/frontend/show_swatch_tooltip';
-
/**
* @var Product
*/
@@ -216,19 +211,6 @@ public function getNumberSwatchesPerProduct()
);
}
- /**
- * Get config if swatch tooltips should be rendered.
- *
- * @return string
- */
- public function getShowSwatchTooltip()
- {
- return $this->_scopeConfig->getValue(
- self::XML_PATH_SHOW_SWATCH_TOOLTIP,
- ScopeInterface::SCOPE_STORE
- );
- }
-
/**
* Set product to block
*
diff --git a/app/code/Magento/Swatches/ViewModel/Product/Renderer/Configurable.php b/app/code/Magento/Swatches/ViewModel/Product/Renderer/Configurable.php
new file mode 100644
index 0000000000000..849d79cc58d92
--- /dev/null
+++ b/app/code/Magento/Swatches/ViewModel/Product/Renderer/Configurable.php
@@ -0,0 +1,50 @@
+scopeConfig = $scopeConfig;
+ }
+
+ /**
+ * Get config if swatch tooltips should be rendered.
+ *
+ * @return string
+ */
+ public function getShowSwatchTooltip()
+ {
+ return $this->scopeConfig->getValue(
+ self::XML_PATH_SHOW_SWATCH_TOOLTIP,
+ ScopeInterface::SCOPE_STORE
+ );
+ }
+}
diff --git a/app/code/Magento/Swatches/view/frontend/layout/catalog_category_view.xml b/app/code/Magento/Swatches/view/frontend/layout/catalog_category_view.xml
index c2dc36e83950c..86031a189d798 100644
--- a/app/code/Magento/Swatches/view/frontend/layout/catalog_category_view.xml
+++ b/app/code/Magento/Swatches/view/frontend/layout/catalog_category_view.xml
@@ -5,10 +5,19 @@
* See COPYING.txt for license details.
*/
-->
-
+
-
+
+
+ Magento\Swatches\ViewModel\Product\Renderer\Configurable
+
+
diff --git a/app/code/Magento/Swatches/view/frontend/layout/catalog_product_view_type_configurable.xml b/app/code/Magento/Swatches/view/frontend/layout/catalog_product_view_type_configurable.xml
index 6188f3957a11d..98346d6ae7e67 100644
--- a/app/code/Magento/Swatches/view/frontend/layout/catalog_product_view_type_configurable.xml
+++ b/app/code/Magento/Swatches/view/frontend/layout/catalog_product_view_type_configurable.xml
@@ -5,11 +5,18 @@
* See COPYING.txt for license details.
*/
-->
-
+
-
+
+
+ Magento\Swatches\ViewModel\Product\Renderer\Configurable
+
+
diff --git a/app/code/Magento/Swatches/view/frontend/layout/catalog_widget_product_list.xml b/app/code/Magento/Swatches/view/frontend/layout/catalog_widget_product_list.xml
index 91798cbd9947f..ce31f588c6c8c 100644
--- a/app/code/Magento/Swatches/view/frontend/layout/catalog_widget_product_list.xml
+++ b/app/code/Magento/Swatches/view/frontend/layout/catalog_widget_product_list.xml
@@ -3,10 +3,19 @@
~ See COPYING.txt for license details.
-->
-
+
-
+
+
+ Magento\Swatches\ViewModel\Product\Renderer\Configurable
+
+
-
\ No newline at end of file
+
diff --git a/app/code/Magento/Swatches/view/frontend/layout/catalogsearch_advanced_result.xml b/app/code/Magento/Swatches/view/frontend/layout/catalogsearch_advanced_result.xml
index c2dc36e83950c..86031a189d798 100644
--- a/app/code/Magento/Swatches/view/frontend/layout/catalogsearch_advanced_result.xml
+++ b/app/code/Magento/Swatches/view/frontend/layout/catalogsearch_advanced_result.xml
@@ -5,10 +5,19 @@
* See COPYING.txt for license details.
*/
-->
-
+
-
+
+
+ Magento\Swatches\ViewModel\Product\Renderer\Configurable
+
+
diff --git a/app/code/Magento/Swatches/view/frontend/layout/catalogsearch_result_index.xml b/app/code/Magento/Swatches/view/frontend/layout/catalogsearch_result_index.xml
index 9285d34efcd4c..86031a189d798 100644
--- a/app/code/Magento/Swatches/view/frontend/layout/catalogsearch_result_index.xml
+++ b/app/code/Magento/Swatches/view/frontend/layout/catalogsearch_result_index.xml
@@ -5,10 +5,19 @@
* See COPYING.txt for license details.
*/
-->
-
+
-
+
+
+ Magento\Swatches\ViewModel\Product\Renderer\Configurable
+
+
diff --git a/app/code/Magento/Swatches/view/frontend/layout/wishlist_index_configure_type_configurable.xml b/app/code/Magento/Swatches/view/frontend/layout/wishlist_index_configure_type_configurable.xml
index 9982eb98d84da..c8159f1a43fe3 100644
--- a/app/code/Magento/Swatches/view/frontend/layout/wishlist_index_configure_type_configurable.xml
+++ b/app/code/Magento/Swatches/view/frontend/layout/wishlist_index_configure_type_configurable.xml
@@ -5,11 +5,18 @@
* See COPYING.txt for license details.
*/
-->
-
+
-
+
+
+ Magento\Swatches\ViewModel\Product\Renderer\Configurable
+
+
diff --git a/app/code/Magento/Swatches/view/frontend/templates/product/listing/renderer.phtml b/app/code/Magento/Swatches/view/frontend/templates/product/listing/renderer.phtml
index 3c2f15dea0ab4..5838ba9625c6a 100644
--- a/app/code/Magento/Swatches/view/frontend/templates/product/listing/renderer.phtml
+++ b/app/code/Magento/Swatches/view/frontend/templates/product/listing/renderer.phtml
@@ -7,6 +7,8 @@
getProduct()->getId();
+/** @var \Magento\Swatches\ViewModel\Product\Renderer\Configurable $configurableViewModel */
+$configurableViewModel = $block->getConfigurableViewModel()
?>
@@ -23,7 +25,7 @@ $productId = $block->getProduct()->getId();
"jsonSwatchConfig": = /* @noEscape */ $block->getJsonSwatchConfig() ?>,
"mediaCallback": "= $block->escapeJs($block->escapeUrl($block->getMediaCallback())) ?>",
"jsonSwatchImageSizeConfig": = /* @noEscape */ $block->getJsonSwatchSizeConfig() ?>,
- "showTooltip": = $block->escapeJs($block->getShowSwatchTooltip()) ?>
+ "showTooltip": = $block->escapeJs($configurableViewModel->getShowSwatchTooltip()) ?>
}
}
}
diff --git a/app/code/Magento/Swatches/view/frontend/templates/product/view/renderer.phtml b/app/code/Magento/Swatches/view/frontend/templates/product/view/renderer.phtml
index 46666e880bb03..bfabd5f3ab38f 100644
--- a/app/code/Magento/Swatches/view/frontend/templates/product/view/renderer.phtml
+++ b/app/code/Magento/Swatches/view/frontend/templates/product/view/renderer.phtml
@@ -4,7 +4,11 @@
* See COPYING.txt for license details.
*/
?>
-
+getConfigurableViewModel()
+?>
diff --git a/app/code/Magento/Customer/view/frontend/web/js/validation.js b/app/code/Magento/Customer/view/frontend/web/js/validation.js
new file mode 100644
index 0000000000000..840134d64422e
--- /dev/null
+++ b/app/code/Magento/Customer/view/frontend/web/js/validation.js
@@ -0,0 +1,19 @@
+require([
+ 'jquery',
+ 'moment',
+ 'jquery/ui',
+ 'jquery/validate',
+ 'mage/translate',
+], function($, moment) {
+ 'use strict';
+ $.validator.addMethod(
+ "validate-dob",
+ function (value) {
+ if (value === '') {
+ return true;
+ }
+ return moment(value).isBefore(moment());
+ },
+ $.mage.__('The Date of Birth should not be greater than today.')
+ );
+});
From 4122c40e193813e568b44953d6e12392cfed27cc Mon Sep 17 00:00:00 2001
From: Lucas Calazans
Date: Sat, 14 Sep 2019 15:16:25 -0300
Subject: [PATCH 258/937] Cleaning inputs value before the checks
---
.../Checkout/view/frontend/web/js/region-updater.js | 10 +++-------
1 file changed, 3 insertions(+), 7 deletions(-)
diff --git a/app/code/Magento/Checkout/view/frontend/web/js/region-updater.js b/app/code/Magento/Checkout/view/frontend/web/js/region-updater.js
index 175b6ca32068d..669e477770bef 100644
--- a/app/code/Magento/Checkout/view/frontend/web/js/region-updater.js
+++ b/app/code/Magento/Checkout/view/frontend/web/js/region-updater.js
@@ -164,6 +164,7 @@ define([
// Populate state/province dropdown list if available or use input box
if (this.options.regionJson[country]) {
+ $(regionList).find('option:selected').removeAttr("selected");
this._removeSelectOptions(regionList);
$.each(this.options.regionJson[country], $.proxy(function (key, value) {
this._renderSelectOption(regionList, key, value);
@@ -198,6 +199,7 @@ define([
regionInput.hide();
label.attr('for', regionList.attr('id'));
} else {
+ regionInput.val('');
this._removeSelectOptions(regionList);
if (this.options.isRegionRequired) {
@@ -224,13 +226,7 @@ define([
postcode.addClass('required-entry').closest('.field').addClass('required');
}
- if (!this.options.defaultRegion) {
- regionList.val('');
- regionInput.val('');
- } else {
- // Add defaultvalue attribute to state/province select element
- regionList.attr('defaultvalue', this.options.defaultRegion);
- }
+ regionList.attr('defaultvalue', this.options.defaultRegion);
},
/**
From 60d1ce2cea38f9c7327067b92a0af21739bdbd39 Mon Sep 17 00:00:00 2001
From: Vinicius Dziuba
Date: Sat, 14 Sep 2019 15:39:10 -0300
Subject: [PATCH 259/937] magento/magento2#24512:Click "What 's this" link
scroll to the top of page
- changed the tag for the strong tag and took the href
---
.../Persistent/view/frontend/templates/remember_me.phtml | 4 +++-
.../Persistent/view/frontend/web/template/remember-me.html | 2 +-
2 files changed, 4 insertions(+), 2 deletions(-)
diff --git a/app/code/Magento/Persistent/view/frontend/templates/remember_me.phtml b/app/code/Magento/Persistent/view/frontend/templates/remember_me.phtml
index afa52e4111051..c0f1332d3d0e7 100644
--- a/app/code/Magento/Persistent/view/frontend/templates/remember_me.phtml
+++ b/app/code/Magento/Persistent/view/frontend/templates/remember_me.phtml
@@ -17,7 +17,9 @@
isRememberMeChecked()) : ?> checked="checked" title="= $block->escapeHtmlAttr(__('Remember Me')) ?>" />
= $block->escapeHtml(__('Remember Me')) ?>
- = $block->escapeHtml(__('What\'s this?')) ?>
+
+ = $block->escapeHtml(__('What\'s this?')) ?>
+
= $block->escapeHtml(__('Check "Remember Me" to access your shopping cart on this computer even if you are not signed in.')) ?>
diff --git a/app/code/Magento/Persistent/view/frontend/web/template/remember-me.html b/app/code/Magento/Persistent/view/frontend/web/template/remember-me.html
index ba0d51d7d3d7c..ac83d6767d4e0 100644
--- a/app/code/Magento/Persistent/view/frontend/web/template/remember-me.html
+++ b/app/code/Magento/Persistent/view/frontend/web/template/remember-me.html
@@ -10,7 +10,7 @@
data-bind="checked: isRememberMeCheckboxChecked, attr: {title: $t('Remember Me'), 'data-scope': dataScope}" />
-
+
From 01e5ab549a999c5b3d87e0d90a648a4f10876076 Mon Sep 17 00:00:00 2001
From: Jonathan Willian
Date: Sat, 14 Sep 2019 16:19:39 -0300
Subject: [PATCH 260/937] Added a deprecated anotation to the graphql schema
and changed the model of the GraphQL to only return null value.
---
app/code/Magento/CustomerGraphQl/Model/Customer/GetCustomer.php | 2 +-
app/code/Magento/CustomerGraphQl/etc/schema.graphqls | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/app/code/Magento/CustomerGraphQl/Model/Customer/GetCustomer.php b/app/code/Magento/CustomerGraphQl/Model/Customer/GetCustomer.php
index 63f42ea1825af..d0d8a4731884e 100644
--- a/app/code/Magento/CustomerGraphQl/Model/Customer/GetCustomer.php
+++ b/app/code/Magento/CustomerGraphQl/Model/Customer/GetCustomer.php
@@ -92,6 +92,6 @@ public function execute(ContextInterface $context): CustomerInterface
if ($confirmationStatus === AccountManagementInterface::ACCOUNT_CONFIRMATION_REQUIRED) {
throw new GraphQlAuthenticationException(__("This account isn't confirmed. Verify and try again."));
}
- return $customer;
+ return $customer->setGroupId(null);
}
}
diff --git a/app/code/Magento/CustomerGraphQl/etc/schema.graphqls b/app/code/Magento/CustomerGraphQl/etc/schema.graphqls
index d27debdc39c64..b068835516beb 100644
--- a/app/code/Magento/CustomerGraphQl/etc/schema.graphqls
+++ b/app/code/Magento/CustomerGraphQl/etc/schema.graphqls
@@ -78,7 +78,7 @@ type RevokeCustomerTokenOutput {
type Customer @doc(description: "Customer defines the customer name and address and other details") {
created_at: String @doc(description: "Timestamp indicating when the account was created")
- group_id: Int @doc(description: "The group assigned to the user. Default values are 0 (Not logged in), 1 (General), 2 (Wholesale), and 3 (Retailer)")
+ group_id: Int @doc(description: "The group assigned to the user. Default values are 0 (Not logged in), 1 (General), 2 (Wholesale), and 3 (Retailer)") @deprecated(reason: "Customer group should not be exposed in the storefront scenarios.")
prefix: String @doc(description: "An honorific, such as Dr., Mr., or Mrs.")
firstname: String @doc(description: "The customer's first name")
middlename: String @doc(description: "The customer's middle name")
From 140d59162047b25b9d413e3e597e383b41090616 Mon Sep 17 00:00:00 2001
From: Lucas Calazans
Date: Sat, 14 Sep 2019 16:25:36 -0300
Subject: [PATCH 261/937] Fixing static tests
---
.../Magento/Checkout/view/frontend/web/js/region-updater.js | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/app/code/Magento/Checkout/view/frontend/web/js/region-updater.js b/app/code/Magento/Checkout/view/frontend/web/js/region-updater.js
index 669e477770bef..4f9b4c44db615 100644
--- a/app/code/Magento/Checkout/view/frontend/web/js/region-updater.js
+++ b/app/code/Magento/Checkout/view/frontend/web/js/region-updater.js
@@ -164,7 +164,7 @@ define([
// Populate state/province dropdown list if available or use input box
if (this.options.regionJson[country]) {
- $(regionList).find('option:selected').removeAttr("selected");
+ $(regionList).find('option:selected').removeAttr('selected');
this._removeSelectOptions(regionList);
$.each(this.options.regionJson[country], $.proxy(function (key, value) {
this._renderSelectOption(regionList, key, value);
From 6ab019b21eb90d9ebe119d8777a111a4b88bfad8 Mon Sep 17 00:00:00 2001
From: Krzysztof Daniel
Date: Sun, 15 Sep 2019 15:54:05 +0200
Subject: [PATCH 262/937] Fizes problem with wrong image URL in sitemap
Problem was caused by wrong context of generation. It was adminhtml
and for this area URL for selected image sizes are not defined (as
those sizes are not defined).
Fixed by using Emulation.
---
.../Magento/Sitemap/Controller/Adminhtml/Sitemap/Generate.php | 2 ++
1 file changed, 2 insertions(+)
diff --git a/app/code/Magento/Sitemap/Controller/Adminhtml/Sitemap/Generate.php b/app/code/Magento/Sitemap/Controller/Adminhtml/Sitemap/Generate.php
index 8eeeb5bf6bc12..d5e1984bf3204 100644
--- a/app/code/Magento/Sitemap/Controller/Adminhtml/Sitemap/Generate.php
+++ b/app/code/Magento/Sitemap/Controller/Adminhtml/Sitemap/Generate.php
@@ -49,7 +49,9 @@ public function execute()
// if sitemap record exists
if ($sitemap->getId()) {
try {
+ $this->appEmulation->startEnvironmentEmulation($sitemap->getStoreId(),\Magento\Framework\App\Area::AREA_FRONTEND, true);
$sitemap->generateXml();
+ $this->appEmulation->stopEnvironmentEmulation();
$this->messageManager->addSuccessMessage(
__('The sitemap "%1" has been generated.', $sitemap->getSitemapFilename())
);
From b7059a615b59b673690f0f3d8187f684213fc72d Mon Sep 17 00:00:00 2001
From: Krzysztof Daniel
Date: Sun, 15 Sep 2019 16:31:16 +0200
Subject: [PATCH 263/937] Fix Code style
---
.../Magento/Sitemap/Controller/Adminhtml/Sitemap/Generate.php | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/app/code/Magento/Sitemap/Controller/Adminhtml/Sitemap/Generate.php b/app/code/Magento/Sitemap/Controller/Adminhtml/Sitemap/Generate.php
index d5e1984bf3204..bf3fa8d95b211 100644
--- a/app/code/Magento/Sitemap/Controller/Adminhtml/Sitemap/Generate.php
+++ b/app/code/Magento/Sitemap/Controller/Adminhtml/Sitemap/Generate.php
@@ -49,7 +49,8 @@ public function execute()
// if sitemap record exists
if ($sitemap->getId()) {
try {
- $this->appEmulation->startEnvironmentEmulation($sitemap->getStoreId(),\Magento\Framework\App\Area::AREA_FRONTEND, true);
+ $this->appEmulation->startEnvironmentEmulation($sitemap->getStoreId(),
+ \Magento\Framework\App\Area::AREA_FRONTEND, true);
$sitemap->generateXml();
$this->appEmulation->stopEnvironmentEmulation();
$this->messageManager->addSuccessMessage(
From 861e9f9401dd7845a77e63fb6cddd5359064c027 Mon Sep 17 00:00:00 2001
From: Krzysztof Daniel
Date: Sun, 15 Sep 2019 17:04:03 +0200
Subject: [PATCH 264/937] Fix Code style
---
.../Sitemap/Controller/Adminhtml/Sitemap/Generate.php | 7 +++++--
1 file changed, 5 insertions(+), 2 deletions(-)
diff --git a/app/code/Magento/Sitemap/Controller/Adminhtml/Sitemap/Generate.php b/app/code/Magento/Sitemap/Controller/Adminhtml/Sitemap/Generate.php
index bf3fa8d95b211..5cfc7349888f3 100644
--- a/app/code/Magento/Sitemap/Controller/Adminhtml/Sitemap/Generate.php
+++ b/app/code/Magento/Sitemap/Controller/Adminhtml/Sitemap/Generate.php
@@ -49,8 +49,11 @@ public function execute()
// if sitemap record exists
if ($sitemap->getId()) {
try {
- $this->appEmulation->startEnvironmentEmulation($sitemap->getStoreId(),
- \Magento\Framework\App\Area::AREA_FRONTEND, true);
+ $this->appEmulation->startEnvironmentEmulation(
+ $sitemap->getStoreId(),
+ \Magento\Framework\App\Area::AREA_FRONTEND,
+ true
+ );
$sitemap->generateXml();
$this->appEmulation->stopEnvironmentEmulation();
$this->messageManager->addSuccessMessage(
From 0c45902eeeddb660ecdeaeabda2d0a06e514c316 Mon Sep 17 00:00:00 2001
From: Raul E Watson
Date: Sun, 15 Sep 2019 22:49:37 +0100
Subject: [PATCH 265/937] remove confusing lines from Magento_Analytics ReadMe
---
app/code/Magento/Analytics/README.md | 1 -
1 file changed, 1 deletion(-)
diff --git a/app/code/Magento/Analytics/README.md b/app/code/Magento/Analytics/README.md
index e0f1c818c7a94..7ec30c6dd484b 100644
--- a/app/code/Magento/Analytics/README.md
+++ b/app/code/Magento/Analytics/README.md
@@ -5,7 +5,6 @@ The Magento_Analytics module integrates your Magento instance with the [Magento
The module implements the following functionality:
- Enabling subscription to Magento Business Intelligence (MBI) and automatic re-subscription
-- Changing the base URL with the same MBI account remained
- Declaring the configuration schemas for report data collection
- Collecting the Magento instance data as reports for MBI
- Introducing API that provides the collected data
From 7ec7d6526bda78791301f16ff6cb6a215dbfff77 Mon Sep 17 00:00:00 2001
From: Max Souza
Date: Sun, 15 Sep 2019 19:41:40 -0300
Subject: [PATCH 266/937] Fix brackets
---
app/code/Magento/SalesRule/Model/RulesApplier.php | 6 ++----
1 file changed, 2 insertions(+), 4 deletions(-)
diff --git a/app/code/Magento/SalesRule/Model/RulesApplier.php b/app/code/Magento/SalesRule/Model/RulesApplier.php
index 6eb536f2d67d5..302138b736bce 100644
--- a/app/code/Magento/SalesRule/Model/RulesApplier.php
+++ b/app/code/Magento/SalesRule/Model/RulesApplier.php
@@ -51,8 +51,7 @@ public function __construct(
\Magento\Framework\Event\ManagerInterface $eventManager,
\Magento\SalesRule\Model\Utility $utility,
ChildrenValidationLocator $childrenValidationLocator = null
- )
- {
+ ) {
$this->calculatorFactory = $calculatorFactory;
$this->validatorUtility = $utility;
$this->_eventManager = $eventManager;
@@ -236,8 +235,7 @@ protected function eventFix(
\Magento\Quote\Model\Quote\Item\AbstractItem $item,
\Magento\SalesRule\Model\Rule $rule,
$qty
- )
- {
+ ) {
$quote = $item->getQuote();
$address = $item->getAddress();
From 08a77d7625c9cc8c7d674031d938c5c6573d94e9 Mon Sep 17 00:00:00 2001
From: Raul E Watson
Date: Sun, 15 Sep 2019 23:49:46 +0100
Subject: [PATCH 267/937] Update Magento_Backend module ReadMe
---
app/code/Magento/Backend/README.md | 115 ++++++++++++++++++++++++++++-
1 file changed, 112 insertions(+), 3 deletions(-)
diff --git a/app/code/Magento/Backend/README.md b/app/code/Magento/Backend/README.md
index 03c7d86516b92..205051809328a 100644
--- a/app/code/Magento/Backend/README.md
+++ b/app/code/Magento/Backend/README.md
@@ -1,3 +1,112 @@
-The Backend module contains common infrastructure and assets for other modules to be defined and used in their
-administration user interface (UI). It does not contain anything specific to other modules. Among many things it
-handles the logic of authenticating and authorizing users.
+# Magento_Backend module
+
+The Magento_Backend module contains common infrastructure and assets for other modules to be defined and used in their
+administration user interface (UI).
+
+The Magento_Backend module does not contain anything specific to other modules. Among many things it handles the logic of authenticating and authorizing users.
+
+## Installation details
+
+Before disabling or uninstalling this module, note that the following modules depends on this module:
+
+- Magento_Analytics
+- Magento_Authorization
+- Magento_NewRelicReporting
+- Magento_ProductVideo
+- Magento_ReleaseNotification
+- Magento_Search
+- Magento_Security
+- Magento_Signifyd
+- Magento_Swatches
+- Magento_Ui
+- Magento_User
+- Magento_Webapi
+
+For information about module installation in Magento 2, see [Enable or disable modules](https://devdocs.magento.com/guides/v2.3/install-gde/install/cli/install-cli-subcommands-enable.html).
+
+## Structure
+
+Beyond the [usual module file structure](https://devdocs.magento.com/guides/v2.3/architecture/archi_perspectives/components/modules/mod_intro.html) the module contains a directory `Service/V1`.
+
+`Service/V1` - contains logic to provide a list of modules installed in Magento.
+
+For information about typical file structure of a module in Magento 2, see [Module file structure](https://devdocs.magento.com/guides/v2.3/extension-dev-guide/build/module-file-structure.html#module-file-structure).
+
+## Extensibility
+
+Extension developers can interact with the Magento_Backend module. For more information about the Magento extension mechanism, see [Magento plug-ins](https://devdocs.magento.com/guides/v2.3/extension-dev-guide/plugins.html).
+
+[The Magento dependency injection mechanism](https://devdocs.magento.com/guides/v2.3/extension-dev-guide/depend-inj.html) enables you to override the functionality of the Magento_Backend module.
+
+### Events
+
+The module dispatches the following events:
+
+ - `adminhtml_block_html_before` event in the `\Magento\Backend\Block\Template::_toHtml()` method. Parameters:
+ - `block` is the backend block template (this) (`\Magento\Backend\Block\Template` class).
+ - `adminhtml_store_edit_form_prepare_form` event in the `\Magento\Backend\Block\System\Store\Edit\AbstractForm::_prepareForm()` method. Parameters:
+ - `block` is the AbstractForm block (this) (`\Magento\Backend\Block\System\Store\Edit\AbstractForm` class).
+ - `backend_block_widget_grid_prepare_grid_before` event in the `\Magento\Backend\Block\Widget\Grid::_prepareGrid()` method. Parameters:
+ - `grid` is the widget grid block (this) (`\Magento\Backend\Block\Widget\Grid` class)
+ - `collection` is the grid collection (`\Magento\Framework\Data\Collection` class).
+ - `adminhtml_cache_flush_system` event in the `\Magento\Backend\Console\Command\CacheCleanCommand::performAction()` method.
+ - `adminhtml_cache_flush_all` event in the `\Magento\Backend\Console\Command\CacheFlushCommand::performAction()` method.
+ - `clean_catalog_images_cache_after` event in the `\Magento\Backend\Controller\Adminhtml\Cache\CleanImages::execute()` method.
+ - `clean_media_cache_after` event in the `\Magento\Backend\Controller\Adminhtml\Cache\CleanMedia::execute()` method.
+ - `clean_static_files_cache_after` event in the `\Magento\Backend\Controller\Adminhtml\Cache\CleanStaticFiles::execute()` method.
+ - `adminhtml_cache_flush_all` event in the `\Magento\Backend\Controller\Adminhtml\Cache\FlushAll::execute()` method.
+ - `adminhtml_cache_flush_system` event in the `\Magento\Backend\Controller\Adminhtml\Cache\FlushSystem::execute()` method.
+ - `theme_save_after` event in the `\Magento\Backend\Controller\Adminhtml\System\Design\Save::execute()` method.
+ - `backend_auth_user_login_success` event in the `\Magento\Backend\Model\Auth::login()` method. Parameters:
+ - `user` is the credential storage object (`null | \Magento\Backend\Model\Auth\Credential\StorageInterface`)
+ - `backend_auth_user_login_failed` event in the `\Magento\Backend\Model\Auth::login()` method. Parameters:
+ - `user_name` is username extracted from the credential storage object (`null | \Magento\Backend\Model\Auth\Credential\StorageInterface`)
+ - `exception` any exception generated (`\Magento\Framework\Exception\LocalizedException | \Magento\Framework\Exception\Plugin\AuthenticationException`)
+
+For information about an event in Magento 2, see [Events and observers](https://devdocs.magento.com/guides/v2.3/extension-dev-guide/events-and-observers.html#events).
+
+### Layouts
+
+This module introduces the following layouts and layout handles in the `view/adminhtml/layout` directory:
+
+- `admin_login`
+- `adminhtml_auth_login`
+- `adminhtml_cache_block`
+- `adminhtml_cache_index`
+- `adminhtml_dashboard_customersmost`
+- `adminhtml_dashboard_customersnewest`
+- `adminhtml_dashboard_index`
+- `adminhtml_dashboard_productsviewed`
+- `adminhtml_denied`
+- `adminhtml_noroute`
+- `adminhtml_system_account_index`
+- `adminhtml_system_design_edit`
+- `adminhtml_system_design_grid`
+- `adminhtml_system_design_grid_block`
+- `adminhtml_system_design_index`
+- `adminhtml_system_store_deletestore`
+- `adminhtml_system_store_editstore`
+- `adminhtml_system_store_grid_block`
+- `adminhtml_system_store_index`
+- `default`
+- `editor`
+- `empty`
+- `formkey`
+- `overlay_popup`
+- `popup`
+
+
+For more information about layouts in Magento 2, see the [Layout documentation](https://devdocs.magento.com/guides/v2.3/frontend-dev-guide/layouts/layout-overview.html).
+
+### UI components
+
+You can extend Magento_Backend module using the following configuration files:
+
+- `view/adminhtml/ui_component/design_config_form.xml`
+- `view/adminhtml/ui_component/design_config_listing.xml`
+
+For information about UI components in Magento 2, see [Overview of UI components](https://devdocs.magento.com/guides/v2.3/ui_comp_guide/bk-ui_comps.html).
+
+## Additional information
+
+For information about significant changes in patch releases, see [2.3.x Release information](https://devdocs.magento.com/guides/v2.3/release-notes/bk-release-notes.html).
From d17996f7f49dcc16a23554617a7bce87f1bc277b Mon Sep 17 00:00:00 2001
From: Raul E Watson
Date: Mon, 16 Sep 2019 00:05:10 +0100
Subject: [PATCH 268/937] Update Magento_Backup module ReadMe
---
app/code/Magento/Backup/README.md | 29 +++++++++++++++++++++++++++--
1 file changed, 27 insertions(+), 2 deletions(-)
diff --git a/app/code/Magento/Backup/README.md b/app/code/Magento/Backup/README.md
index 59688ea3e716e..fe5a34d84d0c0 100644
--- a/app/code/Magento/Backup/README.md
+++ b/app/code/Magento/Backup/README.md
@@ -1,3 +1,28 @@
-The Backup module allows administrators to perform backups and rollbacks. Types of backups include system, database and media backups. This module relies on the Cron module to schedule backups.
+# Magento_Backup module
-This module does not affect the storefront.
+The Magento_Backup allows administrators to perform backups and rollbacks. Types of backups include system, database and media backups. This module relies on the Cron module to schedule backups.
+
+The Magento_Backup does not affect the storefront.
+
+For more information about this module, see [Magento Backups](https://docs.magento.com/m2/ce/user_guide/system/backups.html)
+
+## Extensibility
+
+Extension developers can interact with the Magento_Backup module. For more information about the Magento extension mechanism, see [Magento plug-ins](https://devdocs.magento.com/guides/v2.3/extension-dev-guide/plugins.html).
+
+[The Magento dependency injection mechanism](https://devdocs.magento.com/guides/v2.3/extension-dev-guide/depend-inj.html) enables you to override the functionality of the Magento_Backup module.
+
+### Layouts
+
+This module introduces the following layouts and layout handles in the `view/adminhtml/layout` directory:
+
+`backup_index_block`
+`backup_index_disabled`
+`backup_index_grid`
+`backup_index_index`
+
+For more information about layouts in Magento 2, see the [Layout documentation](https://devdocs.magento.com/guides/v2.3/frontend-dev-guide/layouts/layout-overview.html).
+
+## Additional information
+
+For information about significant changes in patch releases, see [2.3.x Release information](https://devdocs.magento.com/guides/v2.3/release-notes/bk-release-notes.html).
From b97290e5ebba09eb9193b2bcc897aba983f6480a Mon Sep 17 00:00:00 2001
From: Viktor Sevch
Date: Mon, 16 Sep 2019 08:28:03 +0300
Subject: [PATCH 269/937] MC-20069: Fix Skipped MFTF Tests From MC-17140:
MAGETWO-72277, MAGETWO-84682, MAGETWO-94854
---
.../Test/Mftf/Test/AdminAddWidgetToWYSIWYGNewsletterTest.xml | 3 ---
1 file changed, 3 deletions(-)
diff --git a/app/code/Magento/Newsletter/Test/Mftf/Test/AdminAddWidgetToWYSIWYGNewsletterTest.xml b/app/code/Magento/Newsletter/Test/Mftf/Test/AdminAddWidgetToWYSIWYGNewsletterTest.xml
index a7ac9e38d4b07..9c961f9da751a 100644
--- a/app/code/Magento/Newsletter/Test/Mftf/Test/AdminAddWidgetToWYSIWYGNewsletterTest.xml
+++ b/app/code/Magento/Newsletter/Test/Mftf/Test/AdminAddWidgetToWYSIWYGNewsletterTest.xml
@@ -16,9 +16,6 @@
-
-
-
From 9bddf12fbbe2138c1484e5ed3e095e7f6dd7f735 Mon Sep 17 00:00:00 2001
From: Yuliya Labudova
Date: Mon, 16 Sep 2019 10:54:17 +0300
Subject: [PATCH 270/937] MC-15507: Shipping address is dropped after zip code
in new billing address form is filled
- Fix for automation test.
---
.../GuestCheckoutFillNewBillingAddressActionGroup.xml | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/app/code/Magento/Checkout/Test/Mftf/ActionGroup/GuestCheckoutFillNewBillingAddressActionGroup.xml b/app/code/Magento/Checkout/Test/Mftf/ActionGroup/GuestCheckoutFillNewBillingAddressActionGroup.xml
index 6d92ca79000eb..a1137308e8e6c 100644
--- a/app/code/Magento/Checkout/Test/Mftf/ActionGroup/GuestCheckoutFillNewBillingAddressActionGroup.xml
+++ b/app/code/Magento/Checkout/Test/Mftf/ActionGroup/GuestCheckoutFillNewBillingAddressActionGroup.xml
@@ -24,7 +24,7 @@
-
+
From 49f569551d4902fa737cb4158818d8ea8cca8f60 Mon Sep 17 00:00:00 2001
From: DmytroPaidych
Date: Mon, 16 Sep 2019 11:34:32 +0300
Subject: [PATCH 271/937] MC-6353: Product in the shopping cart could be
reached by admin during order creation with multi website config
---
.../StorefrontOpenCustomerAccountCreatePageActionGroup.xml | 1 -
1 file changed, 1 deletion(-)
diff --git a/app/code/Magento/Customer/Test/Mftf/ActionGroup/StorefrontOpenCustomerAccountCreatePageActionGroup.xml b/app/code/Magento/Customer/Test/Mftf/ActionGroup/StorefrontOpenCustomerAccountCreatePageActionGroup.xml
index 155c0423bb7e3..31a988ac9da0d 100644
--- a/app/code/Magento/Customer/Test/Mftf/ActionGroup/StorefrontOpenCustomerAccountCreatePageActionGroup.xml
+++ b/app/code/Magento/Customer/Test/Mftf/ActionGroup/StorefrontOpenCustomerAccountCreatePageActionGroup.xml
@@ -26,6 +26,5 @@
-
From 35e98f5fd33b4bdaa44dd4f3e982cbe7b30e3565 Mon Sep 17 00:00:00 2001
From: RomanKis
Date: Mon, 16 Sep 2019 11:40:17 +0300
Subject: [PATCH 272/937] graphQl-509: `save_in_address_book` has no impact on
Address Book
---
.../SaveQuoteAddressToCustomerAddressBook.php | 1 -
.../Model/Cart/SetShippingAddressesOnCart.php | 20 ++++++++++++++++++-
2 files changed, 19 insertions(+), 2 deletions(-)
diff --git a/app/code/Magento/QuoteGraphQl/Model/Cart/Address/SaveQuoteAddressToCustomerAddressBook.php b/app/code/Magento/QuoteGraphQl/Model/Cart/Address/SaveQuoteAddressToCustomerAddressBook.php
index e9aa4ba745b9f..543fe96ddec8b 100644
--- a/app/code/Magento/QuoteGraphQl/Model/Cart/Address/SaveQuoteAddressToCustomerAddressBook.php
+++ b/app/code/Magento/QuoteGraphQl/Model/Cart/Address/SaveQuoteAddressToCustomerAddressBook.php
@@ -52,7 +52,6 @@ public function __construct(
}
/**
- *
* @param QuoteAddress $quoteAddress
* @param int $customerId
*
diff --git a/app/code/Magento/QuoteGraphQl/Model/Cart/SetShippingAddressesOnCart.php b/app/code/Magento/QuoteGraphQl/Model/Cart/SetShippingAddressesOnCart.php
index 1b735aadc1101..f2e639f74cc20 100644
--- a/app/code/Magento/QuoteGraphQl/Model/Cart/SetShippingAddressesOnCart.php
+++ b/app/code/Magento/QuoteGraphQl/Model/Cart/SetShippingAddressesOnCart.php
@@ -78,6 +78,24 @@ public function execute(ContextInterface $context, CartInterface $cart, array $s
);
}
+ $shippingAddress = $this->createShippingAddress($context, $customerAddressId, $addressInput);
+
+ $this->assignShippingAddressToCart->execute($cart, $shippingAddress);
+ }
+
+ /**
+ * @param ContextInterface $context
+ * @param int|null $customerAddressId
+ * @param array|null $addressInput
+ *
+ * @return \Magento\Quote\Model\Quote\Address
+ * @throws GraphQlAuthorizationException
+ */
+ private function createShippingAddress(
+ ContextInterface $context,
+ ?int $customerAddressId,
+ ?array $addressInput
+ ) {
$customerId = $context->getUserId();
if (null === $customerAddressId) {
@@ -98,6 +116,6 @@ public function execute(ContextInterface $context, CartInterface $cart, array $s
);
}
- $this->assignShippingAddressToCart->execute($cart, $shippingAddress);
+ return $shippingAddress;
}
}
From 5b77eb849dd4b94cf49cfd6060d9ebe2856b7f8a Mon Sep 17 00:00:00 2001
From: Serhii Balko
Date: Mon, 16 Sep 2019 13:18:45 +0300
Subject: [PATCH 273/937] MC-20139: Wishlist Items of customers not displaying
on admin for secondary store
---
.../ResourceModel/Item/Collection/Grid.php | 94 ++++++++++++-------
.../ResourceModel/Item/Collection/Grid.php | 76 +++++++++++++++
.../_files/wishlist_on_second_website.php | 27 ++++++
.../wishlist_on_second_website_rollback.php | 9 ++
4 files changed, 171 insertions(+), 35 deletions(-)
create mode 100644 dev/tests/integration/testsuite/Magento/Wishlist/Model/ResourceModel/Item/Collection/Grid.php
create mode 100644 dev/tests/integration/testsuite/Magento/Wishlist/_files/wishlist_on_second_website.php
create mode 100644 dev/tests/integration/testsuite/Magento/Wishlist/_files/wishlist_on_second_website_rollback.php
diff --git a/app/code/Magento/Wishlist/Model/ResourceModel/Item/Collection/Grid.php b/app/code/Magento/Wishlist/Model/ResourceModel/Item/Collection/Grid.php
index fb6b647811abb..5d2ab2db3fc77 100644
--- a/app/code/Magento/Wishlist/Model/ResourceModel/Item/Collection/Grid.php
+++ b/app/code/Magento/Wishlist/Model/ResourceModel/Item/Collection/Grid.php
@@ -6,15 +6,25 @@
namespace Magento\Wishlist\Model\ResourceModel\Item\Collection;
-use Magento\Customer\Controller\RegistryConstants as RegistryConstants;
+use Magento\Catalog\Model\ResourceModel\Product\Collection as ProductCollection;
+use Magento\Customer\Controller\RegistryConstants;
+use Magento\Wishlist\Model\Item;
/**
- * Wishlist item collection grouped by customer id
+ * Wishlist item collection for grid grouped by customer id
*
* @SuppressWarnings(PHPMD.CouplingBetweenObjects)
*/
class Grid extends \Magento\Wishlist\Model\ResourceModel\Item\Collection
{
+ /**
+ * Load product attributes to present in grid
+ */
+ private const PRODUCT_ATTRIBUTES_TO_GRID = [
+ 'name',
+ 'price',
+ ];
+
/**
* @var \Magento\Framework\Registry
*/
@@ -88,30 +98,48 @@ public function __construct(
}
/**
- * Initialize db select
- *
- * @return $this
+ * @inheritdoc
*/
protected function _initSelect()
{
parent::_initSelect();
- $this->addCustomerIdFilter(
- $this->_registryManager->registry(RegistryConstants::CURRENT_CUSTOMER_ID)
- )
- ->resetSortOrder()
- ->addDaysInWishlist()
+
+ $customerId = $this->_registryManager->registry(RegistryConstants::CURRENT_CUSTOMER_ID);
+ $this->addDaysInWishlist()
->addStoreData()
- ->setVisibilityFilter()
- ->setInStockFilter();
+ ->addCustomerIdFilter($customerId)
+ ->resetSortOrder();
+
return $this;
}
/**
- * Add select order
- *
- * @param string $field
- * @param string $direction
- * @return \Magento\Framework\Data\Collection\AbstractDb
+ * @inheritdoc
+ */
+ protected function _assignProducts()
+ {
+ /** @var ProductCollection $productCollection */
+ $productCollection = $this->_productCollectionFactory->create()
+ ->addAttributeToSelect(self::PRODUCT_ATTRIBUTES_TO_GRID)
+ ->addIdFilter($this->_productIds);
+
+ /** @var Item $item */
+ foreach ($this as $item) {
+ $product = $productCollection->getItemById($item->getProductId());
+ if ($product) {
+ $product->setCustomOptions([]);
+ $item->setProduct($product);
+ $item->setProductName($product->getName());
+ $item->setName($product->getName());
+ $item->setPrice($product->getPrice());
+ }
+ }
+
+ return $this;
+ }
+
+ /**
+ * @inheritdoc
*/
public function setOrder($field, $direction = self::SORT_ORDER_DESC)
{
@@ -127,24 +155,7 @@ public function setOrder($field, $direction = self::SORT_ORDER_DESC)
}
/**
- * Add quantity to filter
- *
- * @param string $field
- * @param array $condition
- * @return \Magento\Wishlist\Model\ResourceModel\Item\Collection
- */
- private function addQtyFilter(string $field, array $condition)
- {
- return parent::addFieldToFilter('main_table.' . $field, $condition);
- }
-
- /**
- * Add field filter to collection
- *
- * @param string|array $field
- * @param null|string|array $condition
- * @see self::_getConditionSql for $condition
- * @return \Magento\Framework\Data\Collection\AbstractDb
+ * @inheritdoc
*/
public function addFieldToFilter($field, $condition = null)
{
@@ -168,6 +179,19 @@ public function addFieldToFilter($field, $condition = null)
return $this->addQtyFilter($field, $condition);
}
}
+
return parent::addFieldToFilter($field, $condition);
}
+
+ /**
+ * Add quantity to filter
+ *
+ * @param string $field
+ * @param array $condition
+ * @return \Magento\Wishlist\Model\ResourceModel\Item\Collection
+ */
+ private function addQtyFilter(string $field, array $condition)
+ {
+ return parent::addFieldToFilter('main_table.' . $field, $condition);
+ }
}
diff --git a/dev/tests/integration/testsuite/Magento/Wishlist/Model/ResourceModel/Item/Collection/Grid.php b/dev/tests/integration/testsuite/Magento/Wishlist/Model/ResourceModel/Item/Collection/Grid.php
new file mode 100644
index 0000000000000..f7d7199134013
--- /dev/null
+++ b/dev/tests/integration/testsuite/Magento/Wishlist/Model/ResourceModel/Item/Collection/Grid.php
@@ -0,0 +1,76 @@
+objectManager = ObjectManager::getInstance();
+ $this->registryManager = $this->objectManager->get(Registry::class);
+ }
+
+ /**
+ * Test to load wishlist collection by customer on second website
+ *
+ * @magentoDbIsolation disabled
+ * @magentoDataFixture Magento/Wishlist/_files/wishlist_on_second_website.php
+ */
+ public function testLoadOnSecondWebsite()
+ {
+ $customer = $this->loadCustomer();
+ $this->registryManager->register(RegistryConstants::CURRENT_CUSTOMER_ID, $customer->getId());
+
+ $gridCollection = $this->objectManager->get(Grid::class);
+ $this->assertNotEmpty($gridCollection->getItems());
+ }
+
+ /**
+ * Load customer in second website
+ *
+ * @return Customer
+ */
+ private function loadCustomer(): Customer
+ {
+ /** @var $website Website */
+ $website = $this->objectManager->get(Website::class);
+ $website->load('newwebsite', 'code');
+
+ /** @var Customer $customer */
+ $customer = $this->objectManager->get(Customer::class);
+ $customer->setWebsiteId($website->getId());
+ $customer->loadByEmail('customer2@example.com');
+
+ return $customer;
+ }
+}
diff --git a/dev/tests/integration/testsuite/Magento/Wishlist/_files/wishlist_on_second_website.php b/dev/tests/integration/testsuite/Magento/Wishlist/_files/wishlist_on_second_website.php
new file mode 100644
index 0000000000000..6d8051cf060f6
--- /dev/null
+++ b/dev/tests/integration/testsuite/Magento/Wishlist/_files/wishlist_on_second_website.php
@@ -0,0 +1,27 @@
+get(ProductRepositoryInterface::class);
+$simpleProduct = $productRepository->get('simple-2');
+
+/* @var $wishlist Wishlist */
+$wishlist = Bootstrap::getObjectManager()->create(Wishlist::class);
+$wishlist->loadByCustomerId($customer->getId(), true);
+$wishlist->addNewItem($simpleProduct);
+$wishlist->setSharingCode('fixture_unique_code')
+ ->setShared(1)
+ ->save();
diff --git a/dev/tests/integration/testsuite/Magento/Wishlist/_files/wishlist_on_second_website_rollback.php b/dev/tests/integration/testsuite/Magento/Wishlist/_files/wishlist_on_second_website_rollback.php
new file mode 100644
index 0000000000000..49b3e120f7354
--- /dev/null
+++ b/dev/tests/integration/testsuite/Magento/Wishlist/_files/wishlist_on_second_website_rollback.php
@@ -0,0 +1,9 @@
+
Date: Mon, 16 Sep 2019 14:29:10 +0300
Subject: [PATCH 274/937] MC-20139: Wishlist Items of customers not displaying
on admin for secondary store
---
.../ResourceModel/Item/Collection/{Grid.php => GridTest.php} | 0
1 file changed, 0 insertions(+), 0 deletions(-)
rename dev/tests/integration/testsuite/Magento/Wishlist/Model/ResourceModel/Item/Collection/{Grid.php => GridTest.php} (100%)
diff --git a/dev/tests/integration/testsuite/Magento/Wishlist/Model/ResourceModel/Item/Collection/Grid.php b/dev/tests/integration/testsuite/Magento/Wishlist/Model/ResourceModel/Item/Collection/GridTest.php
similarity index 100%
rename from dev/tests/integration/testsuite/Magento/Wishlist/Model/ResourceModel/Item/Collection/Grid.php
rename to dev/tests/integration/testsuite/Magento/Wishlist/Model/ResourceModel/Item/Collection/GridTest.php
From 6f4df9be6a8f2a43b08b3831821d01fe6f1e4c2f Mon Sep 17 00:00:00 2001
From: Mastiuhin Olexandr
Date: Mon, 16 Sep 2019 14:30:39 +0300
Subject: [PATCH 275/937] MC-19872: Out-of-Stock Threshold can not be negative
when Backorders are allowed
---
.../Initialization/StockDataFilter.php | 28 +-
...inBackorderAllowedAddProductToCartTest.xml | 2 -
.../Initialization/StockDataFilterTest.php | 57 ++-
.../Model/ResourceModel/Stock/Item.php | 43 +-
.../Model/StockStateProvider.php | 33 +-
.../Model/System/Config/Backend/Minqty.php | 21 +-
.../Unit/Model/StockStateProviderTest.php | 223 +++++++++++
.../Model/ResourceModel/Stock/ItemTest.php | 376 ++++++++++++++++++
.../System/Config/Backend/MinqtyTest.php | 67 ++++
9 files changed, 812 insertions(+), 38 deletions(-)
create mode 100644 app/code/Magento/CatalogInventory/Test/Unit/Model/StockStateProviderTest.php
create mode 100644 dev/tests/integration/testsuite/Magento/CatalogInventory/Model/ResourceModel/Stock/ItemTest.php
create mode 100644 dev/tests/integration/testsuite/Magento/CatalogInventory/Model/System/Config/Backend/MinqtyTest.php
diff --git a/app/code/Magento/Catalog/Controller/Adminhtml/Product/Initialization/StockDataFilter.php b/app/code/Magento/Catalog/Controller/Adminhtml/Product/Initialization/StockDataFilter.php
index f7e69bc72ea18..47324c5b70908 100644
--- a/app/code/Magento/Catalog/Controller/Adminhtml/Product/Initialization/StockDataFilter.php
+++ b/app/code/Magento/Catalog/Controller/Adminhtml/Product/Initialization/StockDataFilter.php
@@ -7,6 +7,7 @@
use Magento\CatalogInventory\Api\StockConfigurationInterface;
use Magento\Framework\App\Config\ScopeConfigInterface;
+use Magento\CatalogInventory\Model\Stock;
/**
* Class StockDataFilter
@@ -60,8 +61,8 @@ public function filter(array $stockData)
$stockData['qty'] = self::MAX_QTY_VALUE;
}
- if (isset($stockData['min_qty']) && (int)$stockData['min_qty'] < 0) {
- $stockData['min_qty'] = 0;
+ if (isset($stockData['min_qty'])) {
+ $stockData['min_qty'] = $this->purifyMinQty($stockData['min_qty'], $stockData['backorders']);
}
if (!isset($stockData['is_decimal_divided']) || $stockData['is_qty_decimal'] == 0) {
@@ -70,4 +71,27 @@ public function filter(array $stockData)
return $stockData;
}
+
+ /**
+ * Purifies min_qty.
+ *
+ * @param int $minQty
+ * @param int $backOrders
+ * @return float
+ */
+ private function purifyMinQty(int $minQty, int $backOrders): float
+ {
+ /**
+ * As described in the documentation if the Backorders Option is disabled
+ * it is recommended to set the Out Of Stock Threshold to a positive number.
+ * That's why to clarify the logic to the end user the code below prevent him to set a negative number so such
+ * a number will turn to zero.
+ * @see https://docs.magento.com/m2/ce/user_guide/catalog/inventory-backorders.html
+ */
+ if ($backOrders === Stock::BACKORDERS_NO && $minQty < 0) {
+ $minQty = 0;
+ }
+
+ return (float)$minQty;
+ }
}
diff --git a/app/code/Magento/Catalog/Test/Mftf/Test/AdminBackorderAllowedAddProductToCartTest.xml b/app/code/Magento/Catalog/Test/Mftf/Test/AdminBackorderAllowedAddProductToCartTest.xml
index 88c524eff387c..679cab4159ebd 100644
--- a/app/code/Magento/Catalog/Test/Mftf/Test/AdminBackorderAllowedAddProductToCartTest.xml
+++ b/app/code/Magento/Catalog/Test/Mftf/Test/AdminBackorderAllowedAddProductToCartTest.xml
@@ -23,13 +23,11 @@
-
-
diff --git a/app/code/Magento/Catalog/Test/Unit/Controller/Adminhtml/Product/Initialization/StockDataFilterTest.php b/app/code/Magento/Catalog/Test/Unit/Controller/Adminhtml/Product/Initialization/StockDataFilterTest.php
index 0214de8120bae..cb23d0c0a9a24 100644
--- a/app/code/Magento/Catalog/Test/Unit/Controller/Adminhtml/Product/Initialization/StockDataFilterTest.php
+++ b/app/code/Magento/Catalog/Test/Unit/Controller/Adminhtml/Product/Initialization/StockDataFilterTest.php
@@ -6,11 +6,15 @@
namespace Magento\Catalog\Test\Unit\Controller\Adminhtml\Product\Initialization;
use Magento\Catalog\Controller\Adminhtml\Product\Initialization\StockDataFilter;
+use Magento\CatalogInventory\Model\Stock;
+use Magento\Framework\App\Config\ScopeConfigInterface;
+use Magento\CatalogInventory\Model\Configuration;
+use PHPUnit\Framework\TestCase;
/**
- * Class StockDataFilterTest
+ * StockDataFilter test.
*/
-class StockDataFilterTest extends \PHPUnit\Framework\TestCase
+class StockDataFilterTest extends TestCase
{
/**
* @var \PHPUnit_Framework_MockObject_MockObject
@@ -27,17 +31,23 @@ class StockDataFilterTest extends \PHPUnit\Framework\TestCase
*/
protected $stockDataFilter;
- /** @var \PHPUnit_Framework_MockObject_MockObject */
+ /**
+ * @var \PHPUnit_Framework_MockObject_MockObject
+ */
protected $stockConfiguration;
+ /**
+ * @inheritdoc
+ */
protected function setUp()
{
- $this->scopeConfigMock = $this->createMock(\Magento\Framework\App\Config\ScopeConfigInterface::class);
+ $this->scopeConfigMock = $this->createMock(ScopeConfigInterface::class);
- $this->scopeConfigMock->expects($this->any())->method('getValue')->will($this->returnValue(1));
+ $this->scopeConfigMock->method('getValue')
+ ->will($this->returnValue(1));
$this->stockConfiguration = $this->createPartialMock(
- \Magento\CatalogInventory\Model\Configuration::class,
+ Configuration::class,
['getManageStock']
);
@@ -45,8 +55,11 @@ protected function setUp()
}
/**
+ * Tests filter method.
+ *
* @param array $inputStockData
* @param array $outputStockData
+ * @return void
*
* @covers \Magento\Catalog\Controller\Adminhtml\Product\Initialization\StockDataFilter::filter
* @dataProvider filterDataProvider
@@ -54,8 +67,7 @@ protected function setUp()
public function testFilter(array $inputStockData, array $outputStockData)
{
if (isset($inputStockData['use_config_manage_stock']) && $inputStockData['use_config_manage_stock'] === 1) {
- $this->stockConfiguration->expects($this->once())
- ->method('getManageStock')
+ $this->stockConfiguration->method('getManageStock')
->will($this->returnValue($outputStockData['manage_stock']));
}
@@ -93,8 +105,13 @@ public function filterDataProvider()
],
],
'case4' => [
- 'inputStockData' => ['min_qty' => -1],
- 'outputStockData' => ['min_qty' => 0, 'is_decimal_divided' => 0, 'use_config_manage_stock' => 0],
+ 'inputStockData' => ['min_qty' => -1, 'backorders' => Stock::BACKORDERS_NO],
+ 'outputStockData' => [
+ 'min_qty' => 0,
+ 'is_decimal_divided' => 0,
+ 'use_config_manage_stock' => 0,
+ 'backorders' => Stock::BACKORDERS_NO,
+ ],
],
'case5' => [
'inputStockData' => ['is_qty_decimal' => 0],
@@ -103,7 +120,25 @@ public function filterDataProvider()
'is_decimal_divided' => 0,
'use_config_manage_stock' => 0,
],
- ]
+ ],
+ 'case6' => [
+ 'inputStockData' => ['min_qty' => -1, 'backorders' => Stock::BACKORDERS_YES_NONOTIFY],
+ 'outputStockData' => [
+ 'min_qty' => -1,
+ 'is_decimal_divided' => 0,
+ 'use_config_manage_stock' => 0,
+ 'backorders' => Stock::BACKORDERS_YES_NONOTIFY,
+ ],
+ ],
+ 'case7' => [
+ 'inputStockData' => ['min_qty' => -1, 'backorders' => Stock::BACKORDERS_YES_NOTIFY],
+ 'outputStockData' => [
+ 'min_qty' => -1,
+ 'is_decimal_divided' => 0,
+ 'use_config_manage_stock' => 0,
+ 'backorders' => Stock::BACKORDERS_YES_NOTIFY,
+ ],
+ ],
];
}
}
diff --git a/app/code/Magento/CatalogInventory/Model/ResourceModel/Stock/Item.php b/app/code/Magento/CatalogInventory/Model/ResourceModel/Stock/Item.php
index edccad60231ec..3a214bd8cd7cb 100644
--- a/app/code/Magento/CatalogInventory/Model/ResourceModel/Stock/Item.php
+++ b/app/code/Magento/CatalogInventory/Model/ResourceModel/Stock/Item.php
@@ -14,6 +14,7 @@
use Magento\Framework\DB\Select;
use Magento\Framework\App\ObjectManager;
use Magento\Framework\Stdlib\DateTime\DateTime;
+use Zend_Db_Expr;
/**
* Stock item resource model
@@ -183,16 +184,12 @@ public function updateSetOutOfStock(int $websiteId)
'is_in_stock = ' . Stock::STOCK_IN_STOCK,
'(use_config_manage_stock = 1 AND 1 = ' . $this->stockConfiguration->getManageStock() . ')'
. ' OR (use_config_manage_stock = 0 AND manage_stock = 1)',
- '(use_config_min_qty = 1 AND qty <= ' . $this->stockConfiguration->getMinQty() . ')'
- . ' OR (use_config_min_qty = 0 AND qty <= min_qty)',
+ '(' . $this->getBackordersExpr() .' = 0 AND qty <= ' . $this->getMinQtyExpr() . ')'
+ . ' OR (' . $this->getBackordersExpr() .' != 0 AND '
+ . $this->getMinQtyExpr() . ' != 0 AND qty <= ' . $this->getMinQtyExpr() . ')',
'product_id IN (' . $select->assemble() . ')',
];
- $backordersWhere = '(use_config_backorders = 0 AND backorders = ' . Stock::BACKORDERS_NO . ')';
- if (Stock::BACKORDERS_NO == $this->stockConfiguration->getBackorders()) {
- $where[] = $backordersWhere . ' OR use_config_backorders = 1';
- } else {
- $where[] = $backordersWhere;
- }
+
$connection->update($this->getMainTable(), $values, $where);
$this->stockIndexerProcessor->markIndexerAsInvalid();
@@ -215,8 +212,8 @@ public function updateSetInStock(int $websiteId)
$where = [
'website_id = ' . $websiteId,
'stock_status_changed_auto = 1',
- '(use_config_min_qty = 1 AND qty > ' . $this->stockConfiguration->getMinQty() . ')'
- . ' OR (use_config_min_qty = 0 AND qty > min_qty)',
+ '(qty > ' . $this->getMinQtyExpr() . ')'
+ . ' OR (' . $this->getBackordersExpr() . ' != 0 AND ' . $this->getMinQtyExpr() . ' = 0)', // If infinite
'product_id IN (' . $select->assemble() . ')',
];
$manageStockWhere = '(use_config_manage_stock = 0 AND manage_stock = 1)';
@@ -304,12 +301,12 @@ public function getBackordersExpr(string $tableAlias = ''): \Zend_Db_Expr
}
/**
- * Get Minimum Sale Quantity Expression
+ * Get Minimum Sale Quantity Expression.
*
* @param string $tableAlias
- * @return \Zend_Db_Expr
+ * @return Zend_Db_Expr
*/
- public function getMinSaleQtyExpr(string $tableAlias = ''): \Zend_Db_Expr
+ public function getMinSaleQtyExpr(string $tableAlias = ''): Zend_Db_Expr
{
if ($tableAlias) {
$tableAlias .= '.';
@@ -323,6 +320,26 @@ public function getMinSaleQtyExpr(string $tableAlias = ''): \Zend_Db_Expr
return $itemMinSaleQty;
}
+ /**
+ * Get Min Qty Expression
+ *
+ * @param string $tableAlias
+ * @return Zend_Db_Expr
+ */
+ public function getMinQtyExpr(string $tableAlias = ''): Zend_Db_Expr
+ {
+ if ($tableAlias) {
+ $tableAlias .= '.';
+ }
+ $itemBackorders = $this->getConnection()->getCheckSql(
+ $tableAlias . 'use_config_min_qty = 1',
+ $this->stockConfiguration->getMinQty(),
+ $tableAlias . 'min_qty'
+ );
+
+ return $itemBackorders;
+ }
+
/**
* Build select for products with types from config
*
diff --git a/app/code/Magento/CatalogInventory/Model/StockStateProvider.php b/app/code/Magento/CatalogInventory/Model/StockStateProvider.php
index 6851b05aa56a6..74271cdd97bf8 100644
--- a/app/code/Magento/CatalogInventory/Model/StockStateProvider.php
+++ b/app/code/Magento/CatalogInventory/Model/StockStateProvider.php
@@ -72,14 +72,31 @@ public function __construct(
*/
public function verifyStock(StockItemInterface $stockItem)
{
+ // Manage stock, but qty is null
if ($stockItem->getQty() === null && $stockItem->getManageStock()) {
return false;
}
+
+ // Backorders are not allowed and qty reached min qty
if ($stockItem->getBackorders() == StockItemInterface::BACKORDERS_NO
&& $stockItem->getQty() <= $stockItem->getMinQty()
) {
return false;
}
+
+ $backordersAllowed = [Stock::BACKORDERS_YES_NONOTIFY, Stock::BACKORDERS_YES_NOTIFY];
+ if (in_array($stockItem->getBackorders(), $backordersAllowed)) {
+ // Infinite - let it be In stock
+ if ($stockItem->getMinQty() == 0) {
+ return true;
+ }
+
+ // qty reached min qty - let it stand Out Of Stock
+ if ($stockItem->getQty() <= $stockItem->getMinQty()) {
+ return false;
+ }
+ }
+
return true;
}
@@ -245,15 +262,17 @@ public function checkQty(StockItemInterface $stockItem, $qty)
if (!$stockItem->getManageStock()) {
return true;
}
+
+ $backordersAllowed = [Stock::BACKORDERS_YES_NONOTIFY, Stock::BACKORDERS_YES_NOTIFY];
+ // Infinite check
+ if ($stockItem->getMinQty() == 0 && in_array($stockItem->getBackorders(), $backordersAllowed)) {
+ return true;
+ }
+
if ($stockItem->getQty() - $stockItem->getMinQty() - $qty < 0) {
- switch ($stockItem->getBackorders()) {
- case \Magento\CatalogInventory\Model\Stock::BACKORDERS_YES_NONOTIFY:
- case \Magento\CatalogInventory\Model\Stock::BACKORDERS_YES_NOTIFY:
- break;
- default:
- return false;
- }
+ return false;
}
+
return true;
}
diff --git a/app/code/Magento/CatalogInventory/Model/System/Config/Backend/Minqty.php b/app/code/Magento/CatalogInventory/Model/System/Config/Backend/Minqty.php
index f49d41b5dd656..268f1846161d4 100644
--- a/app/code/Magento/CatalogInventory/Model/System/Config/Backend/Minqty.php
+++ b/app/code/Magento/CatalogInventory/Model/System/Config/Backend/Minqty.php
@@ -6,21 +6,36 @@
namespace Magento\CatalogInventory\Model\System\Config\Backend;
+use Magento\CatalogInventory\Model\Stock;
+
/**
- * Minimum product qty backend model
+ * Minimum product qty backend model.
*/
class Minqty extends \Magento\Framework\App\Config\Value
{
/**
- * Validate minimum product qty value
+ * Validate minimum product qty value.
*
* @return $this
*/
public function beforeSave()
{
parent::beforeSave();
- $minQty = (int) $this->getValue() >= 0 ? (int) $this->getValue() : (int) $this->getOldValue();
+ $minQty = (float)$this->getValue();
+
+ /**
+ * As described in the documentation if the Backorders Option is disabled
+ * it is recommended to set the Out Of Stock Threshold to a positive number.
+ * That's why to clarify the logic to the end user the code below prevent him to set a negative number so such
+ * a number will turn to zero.
+ * @see https://docs.magento.com/m2/ce/user_guide/catalog/inventory-backorders.html
+ */
+ if ($this->getFieldsetDataValue("backorders") == Stock::BACKORDERS_NO && $minQty < 0) {
+ $minQty = 0;
+ }
+
$this->setValue((string) $minQty);
+
return $this;
}
}
diff --git a/app/code/Magento/CatalogInventory/Test/Unit/Model/StockStateProviderTest.php b/app/code/Magento/CatalogInventory/Test/Unit/Model/StockStateProviderTest.php
new file mode 100644
index 0000000000000..942d77063a8e3
--- /dev/null
+++ b/app/code/Magento/CatalogInventory/Test/Unit/Model/StockStateProviderTest.php
@@ -0,0 +1,223 @@
+objectManager = new ObjectManager($this);
+
+ $this->stockItem = $this->getMockBuilder(StockItemInterface::class)
+ ->getMock();
+
+ $this->model = $this->objectManager->getObject(StockStateProvider::class);
+ }
+
+ /**
+ * Tests verifyStock method.
+ *
+ * @param int $qty
+ * @param int $backOrders
+ * @param int $minQty
+ * @param int $manageStock
+ * @param int $expected
+ *
+ * @return void
+ *
+ * @dataProvider stockItemDataProvider
+ * @covers \Magento\CatalogInventory\Model\StockStateProvider::verifyStock
+ */
+ public function testVerifyStock(
+ ?int $qty,
+ ?int $backOrders,
+ ?int $minQty,
+ ?int $manageStock,
+ bool $expected
+ ): void {
+ $this->stockItem->method('getQty')
+ ->willReturn($qty);
+ $this->stockItem->method('getBackOrders')
+ ->willReturn($backOrders);
+ $this->stockItem->method('getMinQty')
+ ->willReturn($minQty);
+ $this->stockItem->method('getManageStock')
+ ->willReturn($manageStock);
+
+ $result = $this->model->verifyStock($this->stockItem);
+
+ self::assertEquals($expected, $result);
+ }
+
+ /**
+ * StockItem data provider.
+ *
+ * @return array
+ */
+ public function stockItemDataProvider(): array
+ {
+ return [
+ 'qty_is_null_manage_stock_on' => [
+ 'qty' => null,
+ 'backorders' => null,
+ 'min_qty' => null,
+ 'manage_stock' => 1,
+ 'expected' => false,
+ ],
+ 'qty_reached_threshold_without_backorders' => [
+ 'qty' => 3,
+ 'backorders' => Stock::BACKORDERS_NO,
+ 'min_qty' => 3,
+ 'manage_stock' => 1,
+ 'expected' => false,
+ ],
+ 'backorders_are_ininite' => [
+ 'qty' => -100,
+ 'backorders' => Stock::BACKORDERS_YES_NONOTIFY,
+ 'min_qty' => 0,
+ 'manage_stock' => 1,
+ 'expected' => true,
+ ],
+ 'limited_backorders_and_qty_reached_threshold' => [
+ 'qty' => -100,
+ 'backorders' => Stock::BACKORDERS_YES_NONOTIFY,
+ 'min_qty' => -100,
+ 'manage_stock' => 1,
+ 'expected' => false,
+ ],
+ 'qty_not_yet_reached_threshold_1' => [
+ 'qty' => -99,
+ 'backorders' => Stock::BACKORDERS_YES_NONOTIFY,
+ 'min_qty' => -100,
+ 'manage_stock' => 1,
+ 'expected' => true,
+ ],
+ 'qty_not_yet_reached_threshold_2' => [
+ 'qty' => 1,
+ 'backorders' => Stock::BACKORDERS_NO,
+ 'min_qty' => 0,
+ 'manage_stock' => 1,
+ 'expected' => true,
+ ],
+ ];
+ }
+
+ /**
+ * Tests checkQty method.
+ *
+ * @return void
+ *
+ * @dataProvider stockItemAndQtyDataProvider
+ * @covers \Magento\CatalogInventory\Model\StockStateProvider::verifyStock
+ */
+ public function testCheckQty(
+ bool $manageStock,
+ int $qty,
+ int $minQty,
+ int $backOrders,
+ int $orderQty,
+ bool $expected
+ ): void {
+ $this->stockItem->method('getManageStock')
+ ->willReturn($manageStock);
+ $this->stockItem->method('getQty')
+ ->willReturn($qty);
+ $this->stockItem->method('getMinQty')
+ ->willReturn($minQty);
+ $this->stockItem->method('getBackOrders')
+ ->willReturn($backOrders);
+
+ $result = $this->model->checkQty($this->stockItem, $orderQty);
+
+ self::assertEquals($expected, $result);
+ }
+
+ /**
+ * StockItem and qty data provider.
+ *
+ * @return array
+ */
+ public function stockItemAndQtyDataProvider(): array
+ {
+ return [
+ 'disabled_manage_stock' => [
+ 'manage_stock' => false,
+ 'qty' => 0,
+ 'min_qty' => 0,
+ 'backorders' => 0,
+ 'order_qty' => 0,
+ 'expected' => true,
+ ],
+ 'infinite_backorders' => [
+ 'manage_stock' => true,
+ 'qty' => -100,
+ 'min_qty' => 0,
+ 'backorders' => Stock::BACKORDERS_YES_NONOTIFY,
+ 'order_qty' => 100,
+ 'expected' => true,
+ ],
+ 'qty_reached_threshold' => [
+ 'manage_stock' => true,
+ 'qty' => -100,
+ 'min_qty' => -100,
+ 'backorders' => Stock::BACKORDERS_YES_NOTIFY,
+ 'order_qty' => 1,
+ 'expected' => false,
+ ],
+ 'qty_yet_not_reached_threshold' => [
+ 'manage_stock' => true,
+ 'qty' => -100,
+ 'min_qty' => -100,
+ 'backorders' => Stock::BACKORDERS_YES_NOTIFY,
+ 'order_qty' => 1,
+ 'expected' => false,
+ ]
+ ];
+ }
+
+ /**
+ * Tests checkQty method when check is not applicable.
+ *
+ * @return void
+ */
+ public function testCheckQtyWhenCheckIsNotApplicable(): void
+ {
+ $model = $this->objectManager->getObject(StockStateProvider::class, ['qtyCheckApplicable' => false]);
+
+ $result = $model->checkQty($this->stockItem, 3);
+
+ self::assertTrue($result);
+ }
+}
diff --git a/dev/tests/integration/testsuite/Magento/CatalogInventory/Model/ResourceModel/Stock/ItemTest.php b/dev/tests/integration/testsuite/Magento/CatalogInventory/Model/ResourceModel/Stock/ItemTest.php
new file mode 100644
index 0000000000000..460f43d816e35
--- /dev/null
+++ b/dev/tests/integration/testsuite/Magento/CatalogInventory/Model/ResourceModel/Stock/ItemTest.php
@@ -0,0 +1,376 @@
+objectManager = Bootstrap::getObjectManager();
+
+ $this->stockItemResourceModel = $this->objectManager->get(Item::class);
+ $this->productRepository = $this->objectManager->get(ProductRepositoryInterface::class);
+ $this->stockItemRepository = $this->objectManager->get(StockItemRepositoryInterface::class);
+ $this->stockItemCriteriaFactory = $this->objectManager->get(StockItemCriteriaInterfaceFactory::class);
+ $this->stockConfiguration = $this->objectManager->get(StockConfigurationInterface::class);
+ $this->config = $this->objectManager->get(Config::class);
+
+ $this->storeSystemConfig();
+ }
+
+ /**
+ * @inheritdoc
+ */
+ protected function tearDown()
+ {
+ $this->restoreSystemConfig();
+ }
+
+ /**
+ * Tests updateSetOutOfStock method.
+ *
+ * @return void
+ *
+ * @magentoDataFixture Magento/Catalog/_files/product_simple.php
+ */
+ public function testUpdateSetOutOfStock(): void
+ {
+ $stockItem = $this->getStockItem(1);
+ $this->saveStockItemData($stockItem);
+ $this->storeSystemConfig();
+
+ foreach ($this->stockStatusVariations() as $variation) {
+ /**
+ * Check when Stock Item use it's own configuration of backorders.
+ */
+ $this->configureStockItem($stockItem, $variation);
+ $this->stockItemResourceModel->updateSetOutOfStock($this->stockConfiguration->getDefaultScopeId());
+ $stockItem = $this->getStockItem(1);
+
+ self::assertEquals($variation['is_in_stock'], $stockItem->getIsInStock(), $variation['message']);
+ $stockItem = $this->resetStockItem($stockItem);
+
+ /**
+ * Check when Stock Item use system configuration of backorders.
+ */
+ $this->configureStockItemWithSystemConfig($stockItem, $variation);
+ $this->stockItemResourceModel->updateSetOutOfStock($this->stockConfiguration->getDefaultScopeId());
+ $stockItem = $this->getStockItem(1);
+
+ self::assertEquals($variation['is_in_stock'], $stockItem->getIsInStock(), $variation['message']);
+ $stockItem = $this->resetStockItem($stockItem);
+ $this->restoreSystemConfig();
+ }
+ }
+
+ /**
+ * Tests updateSetInOfStock method.
+ *
+ * @return void
+ *
+ * @magentoDataFixture Magento/Catalog/_files/product_simple_out_of_stock.php
+ */
+ public function testUpdateSetInStock(): void
+ {
+ $product = $this->productRepository->get('simple-out-of-stock');
+ $stockItem = $this->getStockItem((int)$product->getId());
+ $this->saveStockItemData($stockItem);
+ $this->storeSystemConfig();
+
+ foreach ($this->stockStatusVariations() as $variation) {
+ /**
+ * Check when Stock Item use it's own configuration of backorders.
+ */
+ $stockItem->setStockStatusChangedAutomaticallyFlag(true);
+ $this->configureStockItem($stockItem, $variation);
+ $this->stockItemResourceModel->updateSetInStock($this->stockConfiguration->getDefaultScopeId());
+ $stockItem = $this->getStockItem((int)$product->getId());
+
+ self::assertEquals($variation['is_in_stock'], $stockItem->getIsInStock(), $variation['message']);
+ $stockItem = $this->resetStockItem($stockItem);
+
+ /**
+ * Check when Stock Item use the system configuration of backorders.
+ */
+ $stockItem->setStockStatusChangedAuto(1);
+ $this->configureStockItemWithSystemConfig($stockItem, $variation);
+ $this->stockItemResourceModel->updateSetInStock($this->stockConfiguration->getDefaultScopeId());
+ $stockItem = $this->getStockItem((int)$product->getId());
+
+ self::assertEquals($variation['is_in_stock'], $stockItem->getIsInStock(), $variation['message']);
+ $stockItem = $this->resetStockItem($stockItem);
+ $this->restoreSystemConfig();
+ }
+ }
+
+ /**
+ * Configure backorders feature for Stock Item.
+ *
+ * @param StockItemInterface $stockItem
+ * @param array $config
+ * @return void
+ */
+ private function configureStockItem(StockItemInterface $stockItem, array $config): void
+ {
+ /**
+ * Configuring Stock Item to use it's own configuration.
+ */
+ $stockItem->setUseConfigBackorders(0);
+ $stockItem->setUseConfigMinQty(0);
+ $stockItem->setQty($config['qty']);
+ $stockItem->setMinQty($config['min_qty']);
+ $stockItem->setBackorders($config['backorders']);
+
+ $this->stockItemRepository->save($stockItem);
+ }
+
+ /**
+ * Configure backorders feature using the system configuration for Stock Item.
+ *
+ * @param StockItemInterface $stockItem
+ * @param array $config
+ * @return void
+ */
+ private function configureStockItemWithSystemConfig(StockItemInterface $stockItem, array $config): void
+ {
+ /**
+ * Configuring Stock Item to use the system configuration.
+ */
+ $stockItem->setUseConfigBackorders(1);
+ $stockItem->setUseConfigMinQty(1);
+
+ $this->config->setValue(
+ Configuration::XML_PATH_BACKORDERS,
+ $config['backorders'],
+ ScopeInterface::SCOPE_STORE
+ );
+ $this->config->setValue(
+ Configuration::XML_PATH_MIN_QTY,
+ $config['min_qty'],
+ ScopeInterface::SCOPE_STORE
+ );
+
+ $stockItem->setQty($config['qty']);
+
+ $this->stockItemRepository->save($stockItem);
+ }
+
+ /**
+ * Stock status variations.
+ *
+ * @return array
+ */
+ private function stockStatusVariations(): array
+ {
+ return [
+ // Quantity has not reached Threshold
+ [
+ 'qty' => 3,
+ 'min_qty' => 2,
+ 'backorders' => Stock::BACKORDERS_NO,
+ 'is_in_stock' => true,
+ 'message' => "Stock status should be In Stock - v.1",
+ ],
+ // Quantity has reached Threshold
+ [
+ 'qty' => 3,
+ 'min_qty' => 3,
+ 'backorders' => Stock::BACKORDERS_NO,
+ 'is_in_stock' => false,
+ 'message' => "Stock status should be Out of Stock - v.2",
+ ],
+ // Infinite backorders
+ [
+ 'qty' => -100,
+ 'min_qty' => 0,
+ 'backorders' => Stock::BACKORDERS_YES_NOTIFY,
+ 'is_in_stock' => true,
+ 'message' => "Stock status should be In Stock for infinite backorders - v.3",
+ ],
+ // Quantity has not reached Threshold's negative value
+ [
+ 'qty' => -99,
+ 'min_qty' => -100,
+ 'backorders' => Stock::BACKORDERS_YES_NOTIFY,
+ 'is_in_stock' => true,
+ 'message' => "Stock status should be In Stock - v.4",
+ ],
+ // Quantity has reached Threshold's negative value
+ [
+ 'qty' => -100,
+ 'min_qty' => -99,
+ 'backorders' => Stock::BACKORDERS_YES_NOTIFY,
+ 'is_in_stock' => false,
+ 'message' => "Stock status should be Out of Stock - v.5",
+ ],
+ ];
+ }
+
+ /**
+ * Stores Stock Item values.
+ *
+ * @param StockItemInterface $stockItem
+ * @return void
+ */
+ private function saveStockItemData(StockItemInterface $stockItem): void
+ {
+ $this->stockStatusData = $stockItem->getData();
+ }
+
+ /**
+ * Resets Stock Item to previous saved values and prepare for new test variation.
+ *
+ * @param StockItemInterface $stockItem
+ * @return StockItemInterface
+ */
+ private function resetStockItem(StockItemInterface $stockItem): StockItemInterface
+ {
+ $stockItem->setData($this->stockStatusData);
+
+ return $this->stockItemRepository->save($stockItem);
+ }
+
+ /**
+ * Get Stock Item by product id.
+ *
+ * @param int $productId
+ * @param int|null $scope
+ * @return StockItemInterface
+ * @throws NoSuchEntityException
+ */
+ private function getStockItem(int $productId, ?int $scope = null): StockItemInterface
+ {
+ $scope = $scope ?? $this->stockConfiguration->getDefaultScopeId();
+ $stockItemCriteria = $this->stockItemCriteriaFactory->create();
+ $stockItemCriteria->setScopeFilter($scope);
+ $stockItemCriteria->setProductsFilter([$productId]);
+ $stockItems = $this->stockItemRepository->getList($stockItemCriteria);
+ $stockItems = $stockItems->getItems();
+
+ if (empty($stockItems)) {
+ throw new NoSuchEntityException();
+ }
+
+ $stockItem = reset($stockItems);
+
+ return $stockItem;
+ }
+
+ /**
+ * Stores system configuration.
+ *
+ * @return void
+ */
+ private function storeSystemConfig(): void
+ {
+ /**
+ * Save system configuration data.
+ */
+ $backorders = $this->config->getValue(
+ Configuration::XML_PATH_BACKORDERS,
+ ScopeInterface::SCOPE_STORE
+ );
+ $minQty = $this->config->getValue(Configuration::XML_PATH_MIN_QTY, ScopeInterface::SCOPE_STORE);
+ $this->configData = [
+ 'backorders' => $backorders,
+ 'min_qty' => $minQty,
+ ];
+ }
+
+ /**
+ * Restores system configuration.
+ *
+ * @return void
+ */
+ private function restoreSystemConfig(): void
+ {
+ /**
+ * Turn back system configuration.
+ */
+ $this->config->setValue(
+ Configuration::XML_PATH_BACKORDERS,
+ $this->configData['backorders'],
+ ScopeInterface::SCOPE_STORE
+ );
+ $this->config->setValue(
+ Configuration::XML_PATH_MIN_QTY,
+ $this->configData['min_qty'],
+ ScopeInterface::SCOPE_STORE
+ );
+ }
+}
diff --git a/dev/tests/integration/testsuite/Magento/CatalogInventory/Model/System/Config/Backend/MinqtyTest.php b/dev/tests/integration/testsuite/Magento/CatalogInventory/Model/System/Config/Backend/MinqtyTest.php
new file mode 100644
index 0000000000000..c053d38fea1ff
--- /dev/null
+++ b/dev/tests/integration/testsuite/Magento/CatalogInventory/Model/System/Config/Backend/MinqtyTest.php
@@ -0,0 +1,67 @@
+minQtyConfig = $objectManager->create(Minqty::class);
+ $this->minQtyConfig->setPath('cataloginventory/item_options/min_qty');
+ }
+
+ /**
+ * Tests beforeSave method.
+ *
+ * @param string $value
+ * @param array $fieldSetData
+ * @param string $expected
+ * @return void
+ *
+ * @dataProvider minQtyConfigDataProvider
+ */
+ public function testBeforeSave(string $value, array $fieldSetData, string $expected): void
+ {
+ $this->minQtyConfig->setData('fieldset_data', $fieldSetData);
+ $this->minQtyConfig->setValue($value);
+ $this->minQtyConfig->beforeSave();
+ $this->assertEquals($expected, $this->minQtyConfig->getValue());
+ }
+
+ /**
+ * Minqty config data provider.
+ *
+ * @return array
+ */
+ public function minQtyConfigDataProvider(): array
+ {
+ return [
+ 'straight' => ['3', ['backorders' => Stock::BACKORDERS_NO], '3'],
+ 'straight2' => ['3.5', ['backorders' => Stock::BACKORDERS_NO], '3.5'],
+ 'negative_value_disabled_backorders' => ['-3', ['backorders' => Stock::BACKORDERS_NO], '0'],
+ 'negative_value_enabled_backorders' => ['-3', ['backorders' => Stock::BACKORDERS_YES_NOTIFY], '-3'],
+ 'negative_value_enabled_backorders2' => ['-3.05', ['backorders' => Stock::BACKORDERS_YES_NOTIFY], '-3.05'],
+ ];
+ }
+}
From cbbf6127b68e3c5b68b0e06d81e4614e58f1210a Mon Sep 17 00:00:00 2001
From: Lusine Papyan
Date: Mon, 16 Sep 2019 15:42:13 +0400
Subject: [PATCH 276/937] MC-18821: Increase test coverage for Account
functional area
- Automation test for MC-11531
---
.../Test/Mftf/Section/StorefrontCategorySidebarSection.xml | 4 ++--
.../ActionGroup/AdminConfigurableProductActionGroup.xml | 4 ----
.../StorefrontImageColorWhenFilterByColorFilterTest.xml | 7 ++-----
3 files changed, 4 insertions(+), 11 deletions(-)
diff --git a/app/code/Magento/Catalog/Test/Mftf/Section/StorefrontCategorySidebarSection.xml b/app/code/Magento/Catalog/Test/Mftf/Section/StorefrontCategorySidebarSection.xml
index 2c73941a92b42..136a8ceadb89e 100644
--- a/app/code/Magento/Catalog/Test/Mftf/Section/StorefrontCategorySidebarSection.xml
+++ b/app/code/Magento/Catalog/Test/Mftf/Section/StorefrontCategorySidebarSection.xml
@@ -12,8 +12,8 @@
-
-
+
+
diff --git a/app/code/Magento/ConfigurableProduct/Test/Mftf/ActionGroup/AdminConfigurableProductActionGroup.xml b/app/code/Magento/ConfigurableProduct/Test/Mftf/ActionGroup/AdminConfigurableProductActionGroup.xml
index 1561fa5e2702d..a0a3a551c3d93 100644
--- a/app/code/Magento/ConfigurableProduct/Test/Mftf/ActionGroup/AdminConfigurableProductActionGroup.xml
+++ b/app/code/Magento/ConfigurableProduct/Test/Mftf/ActionGroup/AdminConfigurableProductActionGroup.xml
@@ -220,10 +220,6 @@
-
-
-
-
diff --git a/app/code/Magento/Swatches/Test/Mftf/Test/StorefrontImageColorWhenFilterByColorFilterTest.xml b/app/code/Magento/Swatches/Test/Mftf/Test/StorefrontImageColorWhenFilterByColorFilterTest.xml
index 428915ab8ae6a..033778635ddbd 100644
--- a/app/code/Magento/Swatches/Test/Mftf/Test/StorefrontImageColorWhenFilterByColorFilterTest.xml
+++ b/app/code/Magento/Swatches/Test/Mftf/Test/StorefrontImageColorWhenFilterByColorFilterTest.xml
@@ -21,7 +21,6 @@
-
@@ -45,7 +44,6 @@
-
@@ -56,7 +54,6 @@
-
@@ -67,10 +64,10 @@
-
+
+
-
From f2627308caa7595d1e0da148f431dffcc132f120 Mon Sep 17 00:00:00 2001
From: Serhii Voloshkov
Date: Mon, 16 Sep 2019 15:17:59 +0300
Subject: [PATCH 277/937] MC-20075: Fix Skipped MFTF Tests From MC-17140:
MC-14536, MC-14538, MC-14720
---
...yWhenMoreItemsAddedToTheCartThanDefaultDisplayLimitTest.xml | 3 ---
1 file changed, 3 deletions(-)
diff --git a/app/code/Magento/Checkout/Test/Mftf/Test/StorefrontCheckCartItemDisplayWhenMoreItemsAddedToTheCartThanDefaultDisplayLimitTest.xml b/app/code/Magento/Checkout/Test/Mftf/Test/StorefrontCheckCartItemDisplayWhenMoreItemsAddedToTheCartThanDefaultDisplayLimitTest.xml
index 09a5ce4c70373..a0aec77ad419f 100644
--- a/app/code/Magento/Checkout/Test/Mftf/Test/StorefrontCheckCartItemDisplayWhenMoreItemsAddedToTheCartThanDefaultDisplayLimitTest.xml
+++ b/app/code/Magento/Checkout/Test/Mftf/Test/StorefrontCheckCartItemDisplayWhenMoreItemsAddedToTheCartThanDefaultDisplayLimitTest.xml
@@ -15,9 +15,6 @@
-
-
-
From 5d440c5f5acb7092d6ca27212d249b313aa700ce Mon Sep 17 00:00:00 2001
From: Lucas Calazans
Date: Mon, 16 Sep 2019 09:23:26 -0300
Subject: [PATCH 278/937] Cleaning values before populate
---
.../Magento/Checkout/view/frontend/web/js/region-updater.js | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/app/code/Magento/Checkout/view/frontend/web/js/region-updater.js b/app/code/Magento/Checkout/view/frontend/web/js/region-updater.js
index 4f9b4c44db615..6a40e882a6bfc 100644
--- a/app/code/Magento/Checkout/view/frontend/web/js/region-updater.js
+++ b/app/code/Magento/Checkout/view/frontend/web/js/region-updater.js
@@ -162,9 +162,11 @@ define([
this._clearError();
this._checkRegionRequired(country);
+ $(regionList).find('option:selected').removeAttr('selected');
+ regionInput.val('');
+
// Populate state/province dropdown list if available or use input box
if (this.options.regionJson[country]) {
- $(regionList).find('option:selected').removeAttr('selected');
this._removeSelectOptions(regionList);
$.each(this.options.regionJson[country], $.proxy(function (key, value) {
this._renderSelectOption(regionList, key, value);
@@ -199,7 +201,6 @@ define([
regionInput.hide();
label.attr('for', regionList.attr('id'));
} else {
- regionInput.val('');
this._removeSelectOptions(regionList);
if (this.options.isRegionRequired) {
From f51fd0b5f105966aa8bed720581e89c9e140424d Mon Sep 17 00:00:00 2001
From: Lucas Calazans
Date: Mon, 16 Sep 2019 09:24:41 -0300
Subject: [PATCH 279/937] Reverting removed comment
---
app/code/Magento/Checkout/view/frontend/web/js/region-updater.js | 1 +
1 file changed, 1 insertion(+)
diff --git a/app/code/Magento/Checkout/view/frontend/web/js/region-updater.js b/app/code/Magento/Checkout/view/frontend/web/js/region-updater.js
index 6a40e882a6bfc..6d54f607484b4 100644
--- a/app/code/Magento/Checkout/view/frontend/web/js/region-updater.js
+++ b/app/code/Magento/Checkout/view/frontend/web/js/region-updater.js
@@ -227,6 +227,7 @@ define([
postcode.addClass('required-entry').closest('.field').addClass('required');
}
+ // Add defaultvalue attribute to state/province select element
regionList.attr('defaultvalue', this.options.defaultRegion);
},
From 966e4a071d97ebeac5266cd1cd735d2d7c3f0caf Mon Sep 17 00:00:00 2001
From: Lusine Papyan
Date: Mon, 16 Sep 2019 16:30:57 +0400
Subject: [PATCH 280/937] MC-18821: Increase test coverage for Catalog
functional area
- Automation test for MC-13641
---
.../Test/Mftf/Suite/MagentoDeveloperModeTestSuite.xml | 2 +-
...inSaveConfProductWithCustomProductAttributeTest.xml | 10 ++--------
2 files changed, 3 insertions(+), 9 deletions(-)
diff --git a/app/code/Magento/Deploy/Test/Mftf/Suite/MagentoDeveloperModeTestSuite.xml b/app/code/Magento/Deploy/Test/Mftf/Suite/MagentoDeveloperModeTestSuite.xml
index 750f7233342b8..76dd6995c751b 100644
--- a/app/code/Magento/Deploy/Test/Mftf/Suite/MagentoDeveloperModeTestSuite.xml
+++ b/app/code/Magento/Deploy/Test/Mftf/Suite/MagentoDeveloperModeTestSuite.xml
@@ -14,7 +14,7 @@
-
+
diff --git a/app/code/Magento/Swatches/Test/Mftf/Test/AdminSaveConfProductWithCustomProductAttributeTest.xml b/app/code/Magento/Swatches/Test/Mftf/Test/AdminSaveConfProductWithCustomProductAttributeTest.xml
index a7e1d5cad65ea..084dceb004b40 100644
--- a/app/code/Magento/Swatches/Test/Mftf/Test/AdminSaveConfProductWithCustomProductAttributeTest.xml
+++ b/app/code/Magento/Swatches/Test/Mftf/Test/AdminSaveConfProductWithCustomProductAttributeTest.xml
@@ -11,18 +11,17 @@
-
+
-
+
-
@@ -30,7 +29,6 @@
-
@@ -41,14 +39,12 @@
-
-
@@ -60,7 +56,6 @@
-
@@ -76,7 +71,6 @@
-
From 42edfafe9f3dc32d65a201a39c8df96d1e6db23e Mon Sep 17 00:00:00 2001
From: Max Souza
Date: Mon, 16 Sep 2019 09:43:11 -0300
Subject: [PATCH 281/937] Fixing phpcs and phpcbf
---
.../Magento/SalesRule/Model/RulesApplier.php | 68 ++++++++++---------
1 file changed, 37 insertions(+), 31 deletions(-)
diff --git a/app/code/Magento/SalesRule/Model/RulesApplier.php b/app/code/Magento/SalesRule/Model/RulesApplier.php
index 302138b736bce..0b454d49add8a 100644
--- a/app/code/Magento/SalesRule/Model/RulesApplier.php
+++ b/app/code/Magento/SalesRule/Model/RulesApplier.php
@@ -7,8 +7,10 @@
namespace Magento\SalesRule\Model;
use Magento\Quote\Model\Quote\Address;
+use Magento\Quote\Model\Quote\Item\AbstractItem;
use Magento\SalesRule\Model\Quote\ChildrenValidationLocator;
use Magento\Framework\App\ObjectManager;
+use Magento\SalesRule\Model\ResourceModel\Rule\Collection;
use Magento\SalesRule\Model\Rule\Action\Discount\CalculatorFactory;
/**
@@ -42,9 +44,9 @@ class RulesApplier
/**
* @param \Magento\SalesRule\Model\Rule\Action\Discount\CalculatorFactory $calculatorFactory
- * @param \Magento\Framework\Event\ManagerInterface $eventManager
- * @param \Magento\SalesRule\Model\Utility $utility
- * @param ChildrenValidationLocator|null $childrenValidationLocator
+ * @param \Magento\Framework\Event\ManagerInterface $eventManager
+ * @param \Magento\SalesRule\Model\Utility $utility
+ * @param ChildrenValidationLocator|null $childrenValidationLocator
*/
public function __construct(
\Magento\SalesRule\Model\Rule\Action\Discount\CalculatorFactory $calculatorFactory,
@@ -62,18 +64,18 @@ public function __construct(
/**
* Apply rules to current order item
*
- * @param \Magento\Quote\Model\Quote\Item\AbstractItem $item
- * @param \Magento\SalesRule\Model\ResourceModel\Rule\Collection $rules
- * @param bool $skipValidation
- * @param mixed $couponCode
- * @return array
+ * @param AbstractItem $item
+ * @param Collection $rules
+ * @param bool $skipValidation
+ * @param mixed $couponCode
+ * @return array
* @SuppressWarnings(PHPMD.CyclomaticComplexity)
*/
public function applyRules($item, $rules, $skipValidation, $couponCode)
{
$address = $item->getAddress();
$appliedRuleIds = [];
- /* @var $rule \Magento\SalesRule\Model\Rule */
+ /* @var $rule Rule */
foreach ($rules as $rule) {
if (!$this->validatorUtility->canProcessRule($rule, $address)) {
continue;
@@ -111,8 +113,8 @@ public function applyRules($item, $rules, $skipValidation, $couponCode)
/**
* Add rule discount description label to address object
*
- * @param Address $address
- * @param \Magento\SalesRule\Model\Rule $rule
+ * @param Address $address
+ * @param Rule $rule
* @return $this
*/
public function addDiscountDescription($address, $rule)
@@ -142,10 +144,12 @@ public function addDiscountDescription($address, $rule)
}
/**
- * @param \Magento\Quote\Model\Quote\Item\AbstractItem $item
- * @param \Magento\SalesRule\Model\Rule $rule
- * @param \Magento\Quote\Model\Quote\Address $address
- * @param mixed $couponCode
+ * Apply Rule
+ *
+ * @param AbstractItem $item
+ * @param Rule $rule
+ * @param \Magento\Quote\Model\Quote\Address $address
+ * @param mixed $couponCode
* @return $this
*/
protected function applyRule($item, $rule, $address, $couponCode)
@@ -160,8 +164,10 @@ protected function applyRule($item, $rule, $address, $couponCode)
}
/**
- * @param \Magento\Quote\Model\Quote\Item\AbstractItem $item
- * @param \Magento\SalesRule\Model\Rule $rule
+ * Get discount Data
+ *
+ * @param AbstractItem $item
+ * @param Rule $rule
* @return \Magento\SalesRule\Model\Rule\Action\Discount\Data
*/
protected function getDiscountData($item, $rule)
@@ -187,7 +193,7 @@ protected function getDiscountData($item, $rule)
/**
* @param \Magento\SalesRule\Model\Rule\Action\Discount\Data $discountData
- * @param \Magento\Quote\Model\Quote\Item\AbstractItem $item
+ * @param AbstractItem $item
* @return $this
*/
protected function setDiscountData($discountData, $item)
@@ -203,9 +209,9 @@ protected function setDiscountData($discountData, $item)
/**
* Set coupon code to address if $rule contains validated coupon
*
- * @param Address $address
- * @param \Magento\SalesRule\Model\Rule $rule
- * @param mixed $couponCode
+ * @param Address $address
+ * @param Rule $rule
+ * @param mixed $couponCode
* @return $this
*/
public function maintainAddressCouponCode($address, $rule, $couponCode)
@@ -214,7 +220,7 @@ public function maintainAddressCouponCode($address, $rule, $couponCode)
Rule is a part of rules collection, which includes only rules with 'No Coupon' type or with validated coupon.
As a result, if rule uses coupon code(s) ('Specific' or 'Auto' Coupon Type), it always contains validated coupon
*/
- if ($rule->getCouponType() != \Magento\SalesRule\Model\Rule::COUPON_TYPE_NO_COUPON) {
+ if ($rule->getCouponType() != Rule::COUPON_TYPE_NO_COUPON) {
$address->setCouponCode($couponCode);
}
@@ -224,16 +230,16 @@ public function maintainAddressCouponCode($address, $rule, $couponCode)
/**
* Fire event to allow overwriting of discount amounts
*
- * @param \Magento\SalesRule\Model\Rule\Action\Discount\Data $discountData
- * @param \Magento\Quote\Model\Quote\Item\AbstractItem $item
- * @param \Magento\SalesRule\Model\Rule $rule
- * @param float $qty
+ * @param \Magento\SalesRule\Model\Rule\Action\Discount\Data $discountData
+ * @param AbstractItem $item
+ * @param Rule $rule
+ * @param float $qty
* @return $this
*/
protected function eventFix(
\Magento\SalesRule\Model\Rule\Action\Discount\Data $discountData,
- \Magento\Quote\Model\Quote\Item\AbstractItem $item,
- \Magento\SalesRule\Model\Rule $rule,
+ AbstractItem $item,
+ Rule $rule,
$qty
) {
$quote = $item->getQuote();
@@ -255,11 +261,11 @@ protected function eventFix(
}
/**
- * @param \Magento\Quote\Model\Quote\Item\AbstractItem $item
- * @param int[] $appliedRuleIds
+ * @param AbstractItem $item
+ * @param int[] $appliedRuleIds
* @return $this
*/
- public function setAppliedRuleIds(\Magento\Quote\Model\Quote\Item\AbstractItem $item, array $appliedRuleIds)
+ public function setAppliedRuleIds(AbstractItem $item, array $appliedRuleIds)
{
$address = $item->getAddress();
$quote = $item->getQuote();
From 96bb2dcd61861ecd53cc1f1c1e0aadc52b645fef Mon Sep 17 00:00:00 2001
From: Stas Puga
Date: Mon, 16 Sep 2019 15:56:29 +0300
Subject: [PATCH 282/937] MC-12735: [Inline Translation] Buttons inline
translation
---
.../Test/StorefrontButtonsInlineTranslationTest.xml | 13 ++++++++-----
1 file changed, 8 insertions(+), 5 deletions(-)
diff --git a/app/code/Magento/Translation/Test/Mftf/Test/StorefrontButtonsInlineTranslationTest.xml b/app/code/Magento/Translation/Test/Mftf/Test/StorefrontButtonsInlineTranslationTest.xml
index 6baec16b0f55d..a4b769fca3900 100644
--- a/app/code/Magento/Translation/Test/Mftf/Test/StorefrontButtonsInlineTranslationTest.xml
+++ b/app/code/Magento/Translation/Test/Mftf/Test/StorefrontButtonsInlineTranslationTest.xml
@@ -10,6 +10,7 @@
xsi:noNamespaceSchemaLocation="urn:magento:mftf:Test/etc/testSchema.xsd">
+
@@ -36,29 +37,31 @@
+
+
+
-
+
-
-
+
-
+
-
+
From ebb48f81424e3cc414492e99bdde856e0a166db3 Mon Sep 17 00:00:00 2001
From: Lusine Papyan
Date: Mon, 16 Sep 2019 13:53:45 +0300
Subject: [PATCH 283/937] MC-18709: [WYSIWYG]Spinner is Always Displayed on
Media Gallery popup
- Updated automated test script
---
.../AdminCMSBlockContentActionGroup.xml | 22 +++++++++----------
.../CmsNewBlockBlockActionsSection.xml | 14 +-----------
2 files changed, 11 insertions(+), 25 deletions(-)
diff --git a/app/code/Magento/Cms/Test/Mftf/ActionGroup/AdminCMSBlockContentActionGroup.xml b/app/code/Magento/Cms/Test/Mftf/ActionGroup/AdminCMSBlockContentActionGroup.xml
index f350865fbf3da..a7dc5ab96890b 100644
--- a/app/code/Magento/Cms/Test/Mftf/ActionGroup/AdminCMSBlockContentActionGroup.xml
+++ b/app/code/Magento/Cms/Test/Mftf/ActionGroup/AdminCMSBlockContentActionGroup.xml
@@ -11,18 +11,16 @@
-
-
-
-
-
+
+
+
+
+
-
-
-
-
-
-
-
+
+
+
+
+
diff --git a/app/code/Magento/Cms/Test/Mftf/Section/CmsNewBlockBlockActionsSection.xml b/app/code/Magento/Cms/Test/Mftf/Section/CmsNewBlockBlockActionsSection.xml
index e7ad1b617ec44..445279a8b1403 100644
--- a/app/code/Magento/Cms/Test/Mftf/Section/CmsNewBlockBlockActionsSection.xml
+++ b/app/code/Magento/Cms/Test/Mftf/Section/CmsNewBlockBlockActionsSection.xml
@@ -24,23 +24,11 @@
-
-
-
From f97b59dfeb84c65ba22fab01e02299fc06dc8720 Mon Sep 17 00:00:00 2001
From: vital_sery
Date: Mon, 16 Sep 2019 15:59:57 +0300
Subject: [PATCH 284/937] MC-18709: [WYSIWYG]Spinner is Always Displayed on
Media Gallery popup
---
lib/web/mage/loader.js | 5 +----
lib/web/mage/loader_old.js | 5 +----
2 files changed, 2 insertions(+), 8 deletions(-)
diff --git a/lib/web/mage/loader.js b/lib/web/mage/loader.js
index 29034f93e8ba9..83299efba422b 100644
--- a/lib/web/mage/loader.js
+++ b/lib/web/mage/loader.js
@@ -69,10 +69,7 @@ define([
show: function (e, ctx) {
this._render();
this.loaderStarted++;
-
- if (this.loaderStarted === 1) {
- this.spinner.show();
- }
+ this.spinner.show();
if (ctx) {
this.spinner
diff --git a/lib/web/mage/loader_old.js b/lib/web/mage/loader_old.js
index e008beb12d134..f759758acd12a 100644
--- a/lib/web/mage/loader_old.js
+++ b/lib/web/mage/loader_old.js
@@ -81,10 +81,7 @@
show: function (e, ctx) {
this._render();
this.loaderStarted++;
-
- if (this.loaderStarted === 1) {
- this.spinner.show();
- }
+ this.spinner.show();
if (ctx) {
this.spinner
From d72ba99f208d593e1adc83f597e8fb09bba28bbd Mon Sep 17 00:00:00 2001
From: Yuliya Labudova
Date: Mon, 16 Sep 2019 16:24:36 +0300
Subject: [PATCH 285/937] MC-17493: Cart/catalog rules grid missing
- Fix for automation test.
---
.../ActionGroup/CatalogPriceRuleActionGroup.xml | 2 +-
.../AdminCreateCartPriceRuleActionGroup.xml | 17 ++++++++---------
2 files changed, 9 insertions(+), 10 deletions(-)
diff --git a/app/code/Magento/CatalogRule/Test/Mftf/ActionGroup/CatalogPriceRuleActionGroup.xml b/app/code/Magento/CatalogRule/Test/Mftf/ActionGroup/CatalogPriceRuleActionGroup.xml
index e4aecfab549ac..39f509c68c6e4 100644
--- a/app/code/Magento/CatalogRule/Test/Mftf/ActionGroup/CatalogPriceRuleActionGroup.xml
+++ b/app/code/Magento/CatalogRule/Test/Mftf/ActionGroup/CatalogPriceRuleActionGroup.xml
@@ -57,7 +57,7 @@
-
+
diff --git a/app/code/Magento/SalesRule/Test/Mftf/ActionGroup/AdminCreateCartPriceRuleActionGroup.xml b/app/code/Magento/SalesRule/Test/Mftf/ActionGroup/AdminCreateCartPriceRuleActionGroup.xml
index 8d71b8501a411..537fc3fbc55ee 100644
--- a/app/code/Magento/SalesRule/Test/Mftf/ActionGroup/AdminCreateCartPriceRuleActionGroup.xml
+++ b/app/code/Magento/SalesRule/Test/Mftf/ActionGroup/AdminCreateCartPriceRuleActionGroup.xml
@@ -105,18 +105,17 @@
-
+
+
+ EXTENDS: AdminCreateCartPriceRuleActionGroup. Removes 'clickSaveButton' for the next data changing. Assign cart price rule to 2 websites instead of 1.
+
-
-
-
-
-
-
-
-
+
+
+
+
From c7e6fc893f29e1dbcf197b121c8ea55ca09269e5 Mon Sep 17 00:00:00 2001
From: Stas Puga
Date: Mon, 16 Sep 2019 16:36:09 +0300
Subject: [PATCH 286/937] MC-12735: [Inline Translation] Buttons inline
translation
---
.../Test/Mftf/Test/StorefrontButtonsInlineTranslationTest.xml | 1 -
1 file changed, 1 deletion(-)
diff --git a/app/code/Magento/Translation/Test/Mftf/Test/StorefrontButtonsInlineTranslationTest.xml b/app/code/Magento/Translation/Test/Mftf/Test/StorefrontButtonsInlineTranslationTest.xml
index a4b769fca3900..155e174310ea9 100644
--- a/app/code/Magento/Translation/Test/Mftf/Test/StorefrontButtonsInlineTranslationTest.xml
+++ b/app/code/Magento/Translation/Test/Mftf/Test/StorefrontButtonsInlineTranslationTest.xml
@@ -53,7 +53,6 @@
-
From a33cd0c6b07de42c694b2489845df680c2538fb8 Mon Sep 17 00:00:00 2001
From: Stsiapan Korf
Date: Fri, 13 Sep 2019 15:10:17 +0300
Subject: [PATCH 287/937] MAGETWO-98748: Incorrect behavior in the category
menu on the Storefront
- PR stabilization
---
app/code/Magento/Catalog/Plugin/Block/Topmenu.php | 10 +++++++---
1 file changed, 7 insertions(+), 3 deletions(-)
diff --git a/app/code/Magento/Catalog/Plugin/Block/Topmenu.php b/app/code/Magento/Catalog/Plugin/Block/Topmenu.php
index d788525356fab..b4aa5bd960b01 100644
--- a/app/code/Magento/Catalog/Plugin/Block/Topmenu.php
+++ b/app/code/Magento/Catalog/Plugin/Block/Topmenu.php
@@ -3,6 +3,8 @@
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
+declare(strict_types=1);
+
namespace Magento\Catalog\Plugin\Block;
use Magento\Catalog\Model\Category;
@@ -156,12 +158,13 @@ private function getCurrentCategory()
*/
private function getCategoryAsArray($category, $currentCategory, $isParentActive)
{
+ $categoryId = $category->getId();
return [
'name' => $category->getName(),
- 'id' => 'category-node-' . $category->getId(),
+ 'id' => 'category-node-' . $categoryId,
'url' => $this->catalogCategory->getCategoryUrl($category),
- 'has_active' => in_array((string)$category->getId(), explode('/', $currentCategory->getPath()), true),
- 'is_active' => $category->getId() == $currentCategory->getId(),
+ 'has_active' => in_array((string)$categoryId, explode('/', (string)$currentCategory->getPath()), true),
+ 'is_active' => $categoryId == $currentCategory->getId(),
'is_category' => true,
'is_parent_active' => $isParentActive
];
@@ -200,6 +203,7 @@ protected function getCategoryTree($storeId, $rootId)
* @param \Magento\Theme\Block\Html\Topmenu $subject
* @param string[] $result
* @return string[]
+ * @SuppressWarnings(PHPMD.UnusedFormalParameter)
*/
public function afterGetCacheKeyInfo(\Magento\Theme\Block\Html\Topmenu $subject, array $result)
{
From 81c3ae3a075507c9e449f70d6d92adbfaca69fd3 Mon Sep 17 00:00:00 2001
From: Nikita Chubukov
Date: Mon, 16 Sep 2019 16:38:31 +0300
Subject: [PATCH 288/937] MC-15256: Exported customer without modification can
not be imported
- Fix static test
---
app/code/Magento/CustomerImportExport/Model/Import/Customer.php | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/app/code/Magento/CustomerImportExport/Model/Import/Customer.php b/app/code/Magento/CustomerImportExport/Model/Import/Customer.php
index 563bd2cd7f2b9..f86ebaea69730 100644
--- a/app/code/Magento/CustomerImportExport/Model/Import/Customer.php
+++ b/app/code/Magento/CustomerImportExport/Model/Import/Customer.php
@@ -23,7 +23,7 @@
class Customer extends AbstractCustomer
{
/**
- * Attribute collection name
+ * Collection name attribute
*/
const ATTRIBUTE_COLLECTION_NAME = \Magento\Customer\Model\ResourceModel\Attribute\Collection::class;
From 2f6332ca6be7eeb9a7abae0ab7ffd83fff725ee7 Mon Sep 17 00:00:00 2001
From: Pavel Bystritsky
Date: Mon, 16 Sep 2019 16:40:27 +0300
Subject: [PATCH 289/937] magento/magento2#24580: Added MFTF test.
---
...leProductWithSeparateLinksFromCartTest.xml | 104 ++++++++++++++++++
1 file changed, 104 insertions(+)
create mode 100644 app/code/Magento/Downloadable/Test/Mftf/Test/EditDownloadableProductWithSeparateLinksFromCartTest.xml
diff --git a/app/code/Magento/Downloadable/Test/Mftf/Test/EditDownloadableProductWithSeparateLinksFromCartTest.xml b/app/code/Magento/Downloadable/Test/Mftf/Test/EditDownloadableProductWithSeparateLinksFromCartTest.xml
new file mode 100644
index 0000000000000..0b905964fd2d9
--- /dev/null
+++ b/app/code/Magento/Downloadable/Test/Mftf/Test/EditDownloadableProductWithSeparateLinksFromCartTest.xml
@@ -0,0 +1,104 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
From 3e03eec3c0e831c9536be75248b5c5503f481514 Mon Sep 17 00:00:00 2001
From: RomanKis
Date: Mon, 16 Sep 2019 16:49:04 +0300
Subject: [PATCH 290/937] graphQl-907: [Customer] Deprecate customer_id in
CustomerAddress
---
.../Model/Customer/Address/ExtractCustomerAddressData.php | 2 ++
.../CustomerGraphQl/Model/Customer/ExtractCustomerData.php | 2 ++
app/code/Magento/CustomerGraphQl/etc/schema.graphqls | 4 ++--
.../Magento/GraphQl/Customer/CreateCustomerAddressTest.php | 4 ++--
.../Magento/GraphQl/Customer/CreateCustomerTest.php | 1 +
.../testsuite/Magento/GraphQl/Customer/GetAddressesTest.php | 6 +++---
.../testsuite/Magento/GraphQl/Customer/GetCustomerTest.php | 2 ++
.../Magento/GraphQl/Customer/UpdateCustomerAddressTest.php | 3 +--
8 files changed, 15 insertions(+), 9 deletions(-)
diff --git a/app/code/Magento/CustomerGraphQl/Model/Customer/Address/ExtractCustomerAddressData.php b/app/code/Magento/CustomerGraphQl/Model/Customer/Address/ExtractCustomerAddressData.php
index a4649bccc02e8..8741bff7aa88d 100644
--- a/app/code/Magento/CustomerGraphQl/Model/Customer/Address/ExtractCustomerAddressData.php
+++ b/app/code/Magento/CustomerGraphQl/Model/Customer/Address/ExtractCustomerAddressData.php
@@ -125,6 +125,8 @@ public function execute(AddressInterface $address): array
}
$addressData = array_merge($addressData, $customAttributes);
+ $addressData['customer_id'] = null;
+
return $addressData;
}
}
diff --git a/app/code/Magento/CustomerGraphQl/Model/Customer/ExtractCustomerData.php b/app/code/Magento/CustomerGraphQl/Model/Customer/ExtractCustomerData.php
index de37482aca056..34359cf9a9e66 100644
--- a/app/code/Magento/CustomerGraphQl/Model/Customer/ExtractCustomerData.php
+++ b/app/code/Magento/CustomerGraphQl/Model/Customer/ExtractCustomerData.php
@@ -103,6 +103,8 @@ public function execute(CustomerInterface $customer): array
$customerData = array_merge($customerData, $customAttributes);
$customerData['model'] = $customer;
+ $customerData['id'] = null;
+
return $customerData;
}
}
diff --git a/app/code/Magento/CustomerGraphQl/etc/schema.graphqls b/app/code/Magento/CustomerGraphQl/etc/schema.graphqls
index d27debdc39c64..4fd7ed7a80349 100644
--- a/app/code/Magento/CustomerGraphQl/etc/schema.graphqls
+++ b/app/code/Magento/CustomerGraphQl/etc/schema.graphqls
@@ -89,7 +89,7 @@ type Customer @doc(description: "Customer defines the customer name and address
default_shipping: String @doc(description: "The ID assigned to the shipping address")
dob: String @doc(description: "The customer's date of birth")
taxvat: String @doc(description: "The customer's Tax/VAT number (for corporate customers)")
- id: Int @doc(description: "The ID assigned to the customer")
+ id: Int @doc(description: "The ID assigned to the customer") @deprecated(reason: "id is not needed as part of Customer because on server side it can be identified based on customer token used for authentication. There is no need to know customer ID on the client side.")
is_subscribed: Boolean @doc(description: "Indicates whether the customer is subscribed to the company's newsletter") @resolver(class: "\\Magento\\CustomerGraphQl\\Model\\Resolver\\IsSubscribed")
addresses: [CustomerAddress] @doc(description: "An array containing the customer's shipping and billing addresses") @resolver(class: "\\Magento\\CustomerGraphQl\\Model\\Resolver\\CustomerAddresses")
gender: Int @doc(description: "The customer's gender(Male - 1, Female - 2)")
@@ -97,7 +97,7 @@ type Customer @doc(description: "Customer defines the customer name and address
type CustomerAddress @doc(description: "CustomerAddress contains detailed information about a customer's billing and shipping addresses"){
id: Int @doc(description: "The ID assigned to the address object")
- customer_id: Int @doc(description: "The customer ID")
+ customer_id: Int @doc(description: "The customer ID") @deprecated(reason: "customer_id is not needed as part of CustomerAddress, address ID (id) is unique identifier for the addresses.")
region: CustomerAddressRegion @doc(description: "An object containing the region name, region code, and region ID")
region_id: Int @doc(description: "A number that uniquely identifies the state, province, or other area")
country_id: String @doc(description: "The customer's country")
diff --git a/dev/tests/api-functional/testsuite/Magento/GraphQl/Customer/CreateCustomerAddressTest.php b/dev/tests/api-functional/testsuite/Magento/GraphQl/Customer/CreateCustomerAddressTest.php
index 203e9b5cb42e5..04fb304305250 100644
--- a/dev/tests/api-functional/testsuite/Magento/GraphQl/Customer/CreateCustomerAddressTest.php
+++ b/dev/tests/api-functional/testsuite/Magento/GraphQl/Customer/CreateCustomerAddressTest.php
@@ -43,7 +43,6 @@ protected function setUp()
*/
public function testCreateCustomerAddress()
{
- $customerId = 1;
$newAddress = [
'region' => [
'region' => 'Arizona',
@@ -124,11 +123,12 @@ public function testCreateCustomerAddress()
$response = $this->graphQlMutation($mutation, [], '', $this->getCustomerAuthHeaders($userName, $password));
$this->assertArrayHasKey('createCustomerAddress', $response);
$this->assertArrayHasKey('customer_id', $response['createCustomerAddress']);
- $this->assertEquals($customerId, $response['createCustomerAddress']['customer_id']);
+ $this->assertEquals(null, $response['createCustomerAddress']['customer_id']);
$this->assertArrayHasKey('id', $response['createCustomerAddress']);
$address = $this->addressRepository->getById($response['createCustomerAddress']['id']);
$this->assertEquals($address->getId(), $response['createCustomerAddress']['id']);
+ $address->setCustomerId(null);
$this->assertCustomerAddressesFields($address, $response['createCustomerAddress']);
$this->assertCustomerAddressesFields($address, $newAddress);
}
diff --git a/dev/tests/api-functional/testsuite/Magento/GraphQl/Customer/CreateCustomerTest.php b/dev/tests/api-functional/testsuite/Magento/GraphQl/Customer/CreateCustomerTest.php
index c5714012f38c9..5b3ff041d481b 100644
--- a/dev/tests/api-functional/testsuite/Magento/GraphQl/Customer/CreateCustomerTest.php
+++ b/dev/tests/api-functional/testsuite/Magento/GraphQl/Customer/CreateCustomerTest.php
@@ -68,6 +68,7 @@ public function testCreateCustomerAccountWithPassword()
QUERY;
$response = $this->graphQlMutation($query);
+ $this->assertEquals(null, $response['createCustomer']['customer']['id']);
$this->assertEquals($newFirstname, $response['createCustomer']['customer']['firstname']);
$this->assertEquals($newLastname, $response['createCustomer']['customer']['lastname']);
$this->assertEquals($newEmail, $response['createCustomer']['customer']['email']);
diff --git a/dev/tests/api-functional/testsuite/Magento/GraphQl/Customer/GetAddressesTest.php b/dev/tests/api-functional/testsuite/Magento/GraphQl/Customer/GetAddressesTest.php
index e0c6841b2ea2b..c1573d7dbd8af 100644
--- a/dev/tests/api-functional/testsuite/Magento/GraphQl/Customer/GetAddressesTest.php
+++ b/dev/tests/api-functional/testsuite/Magento/GraphQl/Customer/GetAddressesTest.php
@@ -62,7 +62,7 @@ public function testGetCustomerWithAddresses()
is_array([$response['customer']['addresses']]),
" Addresses field must be of an array type."
);
- self::assertEquals($customer->getId(), $response['customer']['id']);
+ self::assertEquals(null, $response['customer']['id']);
$this->assertCustomerAddressesFields($customer, $response);
}
@@ -105,7 +105,7 @@ public function testGetCustomerAddressIfUserIsNotAuthorized()
* @param CustomerInterface $customer
* @param array $actualResponse
*/
- public function assertCustomerAddressesFields($customer, $actualResponse)
+ private function assertCustomerAddressesFields($customer, $actualResponse)
{
/** @var AddressInterface $addresses */
$addresses = $customer->getAddresses();
@@ -113,7 +113,7 @@ public function assertCustomerAddressesFields($customer, $actualResponse)
$this->assertNotEmpty($addressValue);
$assertionMap = [
['response_field' => 'id', 'expected_value' => $addresses[$addressKey]->getId()],
- ['response_field' => 'customer_id', 'expected_value' => $addresses[$addressKey]->getCustomerId()],
+ ['response_field' => 'customer_id', 'expected_value' => 0],
['response_field' => 'region_id', 'expected_value' => $addresses[$addressKey]->getRegionId()],
['response_field' => 'country_id', 'expected_value' => $addresses[$addressKey]->getCountryId()],
['response_field' => 'telephone', 'expected_value' => $addresses[$addressKey]->getTelephone()],
diff --git a/dev/tests/api-functional/testsuite/Magento/GraphQl/Customer/GetCustomerTest.php b/dev/tests/api-functional/testsuite/Magento/GraphQl/Customer/GetCustomerTest.php
index 928a263e8531b..b15a799ae7521 100644
--- a/dev/tests/api-functional/testsuite/Magento/GraphQl/Customer/GetCustomerTest.php
+++ b/dev/tests/api-functional/testsuite/Magento/GraphQl/Customer/GetCustomerTest.php
@@ -50,6 +50,7 @@ public function testGetCustomer()
$query = <<graphQlQuery($query, [], '', $this->getCustomerAuthHeaders($currentEmail, $currentPassword));
+ $this->assertEquals(null, $response['customer']['id']);
$this->assertEquals('John', $response['customer']['firstname']);
$this->assertEquals('Smith', $response['customer']['lastname']);
$this->assertEquals($currentEmail, $response['customer']['email']);
diff --git a/dev/tests/api-functional/testsuite/Magento/GraphQl/Customer/UpdateCustomerAddressTest.php b/dev/tests/api-functional/testsuite/Magento/GraphQl/Customer/UpdateCustomerAddressTest.php
index 9840236dc9896..625d027f58d24 100644
--- a/dev/tests/api-functional/testsuite/Magento/GraphQl/Customer/UpdateCustomerAddressTest.php
+++ b/dev/tests/api-functional/testsuite/Magento/GraphQl/Customer/UpdateCustomerAddressTest.php
@@ -59,7 +59,6 @@ public function testUpdateCustomerAddress()
{
$userName = 'customer@example.com';
$password = 'password';
- $customerId = 1;
$addressId = 1;
$mutation = $this->getMutation($addressId);
@@ -67,7 +66,7 @@ public function testUpdateCustomerAddress()
$response = $this->graphQlMutation($mutation, [], '', $this->getCustomerAuthHeaders($userName, $password));
$this->assertArrayHasKey('updateCustomerAddress', $response);
$this->assertArrayHasKey('customer_id', $response['updateCustomerAddress']);
- $this->assertEquals($customerId, $response['updateCustomerAddress']['customer_id']);
+ $this->assertEquals(null, $response['updateCustomerAddress']['customer_id']);
$this->assertArrayHasKey('id', $response['updateCustomerAddress']);
$address = $this->addressRepository->getById($addressId);
From 232fd1d64d4d6168a3111d509f868f79ee020f67 Mon Sep 17 00:00:00 2001
From: Dmytro Poperechnyy
Date: Mon, 16 Sep 2019 09:18:11 -0500
Subject: [PATCH 291/937] MC-19247: Broken translations with advanced bundling
- Define dictionary as a text;
---
.../Magento/Translation/view/base/templates/dictionary.phtml | 4 ++--
lib/web/mage/translate.js | 2 +-
2 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/app/code/Magento/Translation/view/base/templates/dictionary.phtml b/app/code/Magento/Translation/view/base/templates/dictionary.phtml
index fb082439b1c39..efd13e927cbd2 100644
--- a/app/code/Magento/Translation/view/base/templates/dictionary.phtml
+++ b/app/code/Magento/Translation/view/base/templates/dictionary.phtml
@@ -8,7 +8,7 @@
$viewModel = $block->getData('dictionary_view_model');
?>
diff --git a/lib/web/mage/translate.js b/lib/web/mage/translate.js
index db341807364e8..c4e7e53cea8ae 100644
--- a/lib/web/mage/translate.js
+++ b/lib/web/mage/translate.js
@@ -6,7 +6,7 @@
define([
'jquery',
'mage/mage',
- 'dictionary'
+ 'text!dictionary'
], function ($, mage, dictionary) {
'use strict';
From 94f2c18f51554c6b2296012e0c294e1c890f82e3 Mon Sep 17 00:00:00 2001
From: utietze
Date: Mon, 16 Sep 2019 16:40:15 +0200
Subject: [PATCH 292/937] Use InvalidArgumentException from plain PHP
Update Patch
---
.../Magento/Framework/MessageQueue/MessageValidator.php | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/lib/internal/Magento/Framework/MessageQueue/MessageValidator.php b/lib/internal/Magento/Framework/MessageQueue/MessageValidator.php
index a40bb9af1e0c4..abb2918d459ae 100644
--- a/lib/internal/Magento/Framework/MessageQueue/MessageValidator.php
+++ b/lib/internal/Magento/Framework/MessageQueue/MessageValidator.php
@@ -5,7 +5,7 @@
*/
namespace Magento\Framework\MessageQueue;
-use Doctrine\Instantiator\Exception\InvalidArgumentException;
+use InvalidArgumentException;
use Magento\Framework\Exception\LocalizedException;
use Magento\Framework\Phrase;
use Magento\Framework\Communication\ConfigInterface as CommunicationConfig;
@@ -58,6 +58,7 @@ protected function getTopicSchema($topic, $requestType)
* @param bool $requestType
* @return void
* @throws InvalidArgumentException
+ * @throws LocalizedException
*/
public function validate($topic, $message, $requestType = true)
{
From 6fc366c5a743b08eb61f817ca35035cf37c9a9a5 Mon Sep 17 00:00:00 2001
From: utietze
Date: Mon, 16 Sep 2019 16:43:48 +0200
Subject: [PATCH 293/937] No need for extra doctrine dependency
---
lib/internal/Magento/Framework/MessageQueue/composer.json | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/lib/internal/Magento/Framework/MessageQueue/composer.json b/lib/internal/Magento/Framework/MessageQueue/composer.json
index f1397fb91afe8..56644e428e5cb 100644
--- a/lib/internal/Magento/Framework/MessageQueue/composer.json
+++ b/lib/internal/Magento/Framework/MessageQueue/composer.json
@@ -11,8 +11,7 @@
],
"require": {
"magento/framework": "*",
- "php": "~7.1.3||~7.2.0||~7.3.0",
- "doctrine/instantiator": "^1.0"
+ "php": "~7.1.3||~7.2.0||~7.3.0"
},
"autoload": {
"psr-4": {
From e39b03a4a597fdc6badbcde3ecaed022b713a67c Mon Sep 17 00:00:00 2001
From: Anton Siniorg
Date: Mon, 16 Sep 2019 17:33:08 +0300
Subject: [PATCH 294/937] fix for the #24618
Magento_Braintree/js/view/payment/method-renderer/paypal.js accessing
undefined variables
---
.../view/frontend/web/js/view/payment/method-renderer/paypal.js | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/app/code/Magento/Braintree/view/frontend/web/js/view/payment/method-renderer/paypal.js b/app/code/Magento/Braintree/view/frontend/web/js/view/payment/method-renderer/paypal.js
index ae9f69c405c2b..edb2064d87aa4 100644
--- a/app/code/Magento/Braintree/view/frontend/web/js/view/payment/method-renderer/paypal.js
+++ b/app/code/Magento/Braintree/view/frontend/web/js/view/payment/method-renderer/paypal.js
@@ -334,7 +334,7 @@ define([
}
return {
- line1: address.street[0],
+ line1: (_.isUndefined(address.street) || _.isUndefined(address.street[0]) ? '' : address.street[0],
city: address.city,
state: address.regionCode,
postalCode: address.postcode,
From 6b9f71a89ceef01050cbe9446891a15d3ab56d23 Mon Sep 17 00:00:00 2001
From: Dmytro Poperechnyy
Date: Mon, 16 Sep 2019 10:08:46 -0500
Subject: [PATCH 295/937] MC-19247: Broken translations with advanced bundling
- Update comment;
---
.../Magento/Translation/view/base/templates/translate.phtml | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/app/code/Magento/Translation/view/base/templates/translate.phtml b/app/code/Magento/Translation/view/base/templates/translate.phtml
index c4592e02eff88..844b16024f15b 100644
--- a/app/code/Magento/Translation/view/base/templates/translate.phtml
+++ b/app/code/Magento/Translation/view/base/templates/translate.phtml
@@ -6,8 +6,7 @@
/** @var \Magento\Translation\Block\Js $block */
?>
-
-
+
dictionaryEnabled()) : ?>
diff --git a/dev/tests/js/jasmine/require.conf.js b/dev/tests/js/jasmine/require.conf.js
index cd5d6fe836da4..43ea596007f00 100644
--- a/dev/tests/js/jasmine/require.conf.js
+++ b/dev/tests/js/jasmine/require.conf.js
@@ -19,6 +19,11 @@ require.config({
'tests': '../../../../../../dev/tests/js/jasmine',
'squire': '../../../../../../node_modules/squirejs/src/Squire'
},
+ map: {
+ '*': {
+ dictionary: '../../../../../../dev/tests/js/jasmine/tests/lib/mage/fake-dictionary'
+ }
+ },
shim: {
squire: {
exports: 'squire'
diff --git a/dev/tests/js/jasmine/tests/lib/mage/fake-dictionary.js b/dev/tests/js/jasmine/tests/lib/mage/fake-dictionary.js
new file mode 100644
index 0000000000000..a40bd15c77bd5
--- /dev/null
+++ b/dev/tests/js/jasmine/tests/lib/mage/fake-dictionary.js
@@ -0,0 +1,8 @@
+/**
+ * Copyright © Magento, Inc. All rights reserved.
+ * See COPYING.txt for license details.
+ */
+// Fake dictionary for js unit tests as real dictionary is defined is template and cannot be initialized by requirejs
+define([], function () {
+ return {};
+});
diff --git a/dev/tests/js/jasmine/tests/lib/mage/translate.test.js b/dev/tests/js/jasmine/tests/lib/mage/translate.test.js
index c87cfa227c1aa..22be0fbbaa32f 100644
--- a/dev/tests/js/jasmine/tests/lib/mage/translate.test.js
+++ b/dev/tests/js/jasmine/tests/lib/mage/translate.test.js
@@ -14,6 +14,10 @@ define([
$.mage.translate.add('Hello World!');
expect('Hello World!').toEqual($.mage.translate.translate('Hello World!'));
});
+ it('works with translation alias __', function () {
+ $.mage.translate.add('Hello World!');
+ expect('Hello World!').toEqual($.mage.__('Hello World!'));
+ });
it('works with one array as parameter', function () {
$.mage.translate.add(['Hello World!', 'Bonjour tout le monde!']);
expect('Hello World!').toEqual($.mage.translate.translate('Hello World!'));
@@ -40,10 +44,6 @@ define([
$.mage.translate.add('Hello World!', 'Bonjour tout le monde!');
expect('Bonjour tout le monde!').toEqual($.mage.translate.translate('Hello World!'));
});
- it('works with translation alias __', function () {
- $.mage.translate.add('Hello World!');
- expect('Hello World!').toEqual($.mage.__('Hello World!'));
- });
});
});
diff --git a/lib/web/mage/translate.js b/lib/web/mage/translate.js
index c4e7e53cea8ae..db341807364e8 100644
--- a/lib/web/mage/translate.js
+++ b/lib/web/mage/translate.js
@@ -6,7 +6,7 @@
define([
'jquery',
'mage/mage',
- 'text!dictionary'
+ 'dictionary'
], function ($, mage, dictionary) {
'use strict';
From 900a707c9980c760137d573fa10b45eaf1414ee1 Mon Sep 17 00:00:00 2001
From: Roman Lytvynenko
Date: Mon, 16 Sep 2019 14:56:14 -0500
Subject: [PATCH 301/937] MC-19661: Export Products bug. I can't exclude
attributes from CSV file.
---
.../Model/Export/Product.php | 20 ++++++++++++++++++-
1 file changed, 19 insertions(+), 1 deletion(-)
diff --git a/app/code/Magento/CatalogImportExport/Model/Export/Product.php b/app/code/Magento/CatalogImportExport/Model/Export/Product.php
index b675e9211acde..2a7113518d750 100644
--- a/app/code/Magento/CatalogImportExport/Model/Export/Product.php
+++ b/app/code/Magento/CatalogImportExport/Model/Export/Product.php
@@ -712,6 +712,21 @@ public function _getHeaderColumns()
return $this->_customHeadersMapping($this->rowCustomizer->addHeaderColumns($this->_headerColumns));
}
+ /**
+ * Return non-system attributes
+
+ * @return array
+ */
+ private function getNonSystemAttributes()
+ {
+ $attrKeys = [];
+ foreach ($this->filterAttributeCollection($this->getAttributeCollection()) as $attribute) {
+ $attrKeys []= $attribute->getAttributeCode();
+ }
+
+ return array_diff($this->_getExportMainAttrCodes(), $this->_customHeadersMapping($attrKeys));
+ }
+
/**
* Set headers columns
*
@@ -729,7 +744,10 @@ protected function setHeaderColumns($customOptionsData, $stockItemRows)
) ?
array_intersect(
$this->_getExportMainAttrCodes(),
- $this->_customHeadersMapping($this->_getExportAttrCodes())
+ array_merge(
+ $this->_customHeadersMapping($this->_getExportAttrCodes()),
+ $this->getNonSystemAttributes()
+ )
) :
$this->_getExportMainAttrCodes();
From 992602f6237b6f8b50ce61f6b8d69eb708971b29 Mon Sep 17 00:00:00 2001
From: Stanislav Idolov
Date: Mon, 16 Sep 2019 17:09:30 -0300
Subject: [PATCH 302/937] Removed api annotation
---
app/code/Magento/Config/Model/Config/Backend/File/Pdf.php | 2 --
1 file changed, 2 deletions(-)
diff --git a/app/code/Magento/Config/Model/Config/Backend/File/Pdf.php b/app/code/Magento/Config/Model/Config/Backend/File/Pdf.php
index 9e3a5ec507a4b..8716fe5a23ad3 100644
--- a/app/code/Magento/Config/Model/Config/Backend/File/Pdf.php
+++ b/app/code/Magento/Config/Model/Config/Backend/File/Pdf.php
@@ -8,8 +8,6 @@
/**
* System config PDF field backend model.
- *
- * @api
*/
class Pdf extends \Magento\Config\Model\Config\Backend\File
{
From 2e97e8fc03ff286b4b5eac3b0ec92192a17efb5b Mon Sep 17 00:00:00 2001
From: Stanislav Idolov
Date: Mon, 16 Sep 2019 17:10:03 -0300
Subject: [PATCH 303/937] Removed deprecated tag
---
app/code/Magento/Config/Model/Config/Backend/Image/Pdf.php | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/app/code/Magento/Config/Model/Config/Backend/Image/Pdf.php b/app/code/Magento/Config/Model/Config/Backend/Image/Pdf.php
index bde392547a7f9..4ddc848784551 100644
--- a/app/code/Magento/Config/Model/Config/Backend/Image/Pdf.php
+++ b/app/code/Magento/Config/Model/Config/Backend/Image/Pdf.php
@@ -10,7 +10,7 @@
* System config PDF field backend model.
*
* @api
- * @deprecated The wrong file type extensions are returned.
+ * @since 100.0.2
* @see \Magento\Config\Model\Config\Backend\File\Pdf
*/
class Pdf extends \Magento\Config\Model\Config\Backend\Image
From 2bfc6fdb5ba20d44560a8eaa7268cf015ecba584 Mon Sep 17 00:00:00 2001
From: Vitalii Zabaznov
Date: Mon, 16 Sep 2019 15:12:39 -0500
Subject: [PATCH 304/937] MC-18719: private cookie version increments each post
request
---
.../Mftf/Test/StorefrontGuestCheckoutDisabledProductTest.xml | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/app/code/Magento/Quote/Test/Mftf/Test/StorefrontGuestCheckoutDisabledProductTest.xml b/app/code/Magento/Quote/Test/Mftf/Test/StorefrontGuestCheckoutDisabledProductTest.xml
index 4ec608a18a686..7e3af5e402ac9 100644
--- a/app/code/Magento/Quote/Test/Mftf/Test/StorefrontGuestCheckoutDisabledProductTest.xml
+++ b/app/code/Magento/Quote/Test/Mftf/Test/StorefrontGuestCheckoutDisabledProductTest.xml
@@ -73,6 +73,9 @@
+
+
@@ -119,6 +122,7 @@
+
@@ -146,6 +150,7 @@
+
From d3cbe273595d204422c3ee9a79c4e9a79a6ead28 Mon Sep 17 00:00:00 2001
From: Sergey Dovbenko
Date: Tue, 17 Sep 2019 00:13:19 +0300
Subject: [PATCH 305/937] Update
app/code/Magento/BraintreeGraphQl/etc/schema.graphqls
Updated is_active_payment_token_enabler
Co-Authored-By: Lena Orobei
---
app/code/Magento/BraintreeGraphQl/etc/schema.graphqls | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/app/code/Magento/BraintreeGraphQl/etc/schema.graphqls b/app/code/Magento/BraintreeGraphQl/etc/schema.graphqls
index e9a203d041f29..a822468c562f0 100644
--- a/app/code/Magento/BraintreeGraphQl/etc/schema.graphqls
+++ b/app/code/Magento/BraintreeGraphQl/etc/schema.graphqls
@@ -12,7 +12,7 @@ input PaymentMethodInput {
input BraintreeInput {
payment_method_nonce: String! @doc(description:"The one-time payment token generated by Braintree payment gateway based on card details. Required field to make sale transaction.")
- is_active_payment_token_enabler: Boolean! @doc(description:"This field states whether an entered by a customer credit/debit card should be tokenized for later usage. Required only if Vault is enabled for Braintree payment integration.")
+ is_active_payment_token_enabler: Boolean! @doc(description:"States whether an entered by a customer credit/debit card should be tokenized for later usage. Required only if Vault is enabled for Braintree payment integration.")
device_data: String @doc(description:"This field contains a fingerprint provided by Braintree JS SDK and should be sent with sale transaction details to the Braintree payment gateway. The device_data will be presented only in a case if Kount (advanced fraud protection) is enabled for Braintree payment integration.")
}
From 2ff66af1e9c6163c6543e082292737cc62079e4b Mon Sep 17 00:00:00 2001
From: Sergey Dovbenko
Date: Tue, 17 Sep 2019 00:13:50 +0300
Subject: [PATCH 306/937] Update
app/code/Magento/BraintreeGraphQl/etc/schema.graphqls
Updated device_data
Co-Authored-By: Lena Orobei
---
app/code/Magento/BraintreeGraphQl/etc/schema.graphqls | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/app/code/Magento/BraintreeGraphQl/etc/schema.graphqls b/app/code/Magento/BraintreeGraphQl/etc/schema.graphqls
index a822468c562f0..0f8e06a201152 100644
--- a/app/code/Magento/BraintreeGraphQl/etc/schema.graphqls
+++ b/app/code/Magento/BraintreeGraphQl/etc/schema.graphqls
@@ -13,7 +13,7 @@ input PaymentMethodInput {
input BraintreeInput {
payment_method_nonce: String! @doc(description:"The one-time payment token generated by Braintree payment gateway based on card details. Required field to make sale transaction.")
is_active_payment_token_enabler: Boolean! @doc(description:"States whether an entered by a customer credit/debit card should be tokenized for later usage. Required only if Vault is enabled for Braintree payment integration.")
- device_data: String @doc(description:"This field contains a fingerprint provided by Braintree JS SDK and should be sent with sale transaction details to the Braintree payment gateway. The device_data will be presented only in a case if Kount (advanced fraud protection) is enabled for Braintree payment integration.")
+ device_data: String @doc(description:"Contains a fingerprint provided by Braintree JS SDK and should be sent with sale transaction details to the Braintree payment gateway. Should be specified only in a case if Kount (advanced fraud protection) is enabled for Braintree payment integration.")
}
input BraintreeCcVaultInput {
From 8beac86721bfce31f5d6951c83006c42dbc00cef Mon Sep 17 00:00:00 2001
From: Oleksandr Dubovyk
Date: Mon, 16 Sep 2019 16:45:30 -0500
Subject: [PATCH 307/937] MC-20112: [OnPrem] - Import CSV - Can't import empty
value __EMPTY__VALUE__ at store view level
- modified test
---
.../Import/Product/Type/AbstractTypeTest.php | 21 +++++++++++++++----
1 file changed, 17 insertions(+), 4 deletions(-)
diff --git a/app/code/Magento/CatalogImportExport/Test/Unit/Model/Import/Product/Type/AbstractTypeTest.php b/app/code/Magento/CatalogImportExport/Test/Unit/Model/Import/Product/Type/AbstractTypeTest.php
index bd2fe896b8c0a..b183f4ebceb14 100644
--- a/app/code/Magento/CatalogImportExport/Test/Unit/Model/Import/Product/Type/AbstractTypeTest.php
+++ b/app/code/Magento/CatalogImportExport/Test/Unit/Model/Import/Product/Type/AbstractTypeTest.php
@@ -107,6 +107,7 @@ protected function setUp()
];
$attribute1 = clone $attribute;
$attribute2 = clone $attribute;
+ $attribute3 = clone $attribute;
$attribute1->expects($this->any())->method('getId')->willReturn('1');
$attribute1->expects($this->any())->method('getAttributeCode')->willReturn('attr_code');
@@ -118,6 +119,11 @@ protected function setUp()
$attribute2->expects($this->any())->method('getFrontendInput')->willReturn('boolean');
$attribute2->expects($this->any())->method('isStatic')->willReturn(false);
+ $attribute3->expects($this->any())->method('getId')->willReturn('3');
+ $attribute3->expects($this->any())->method('getAttributeCode')->willReturn('text_attribute');
+ $attribute3->expects($this->any())->method('getFrontendInput')->willReturn('text');
+ $attribute3->expects($this->any())->method('isStatic')->willReturn(false);
+
$this->entityModel->expects($this->any())->method('getEntityTypeId')->willReturn(3);
$this->entityModel->expects($this->any())->method('getAttributeOptions')->willReturnOnConsecutiveCalls(
['option1', 'option2'],
@@ -126,7 +132,9 @@ protected function setUp()
$attrSetColFactory->expects($this->any())->method('create')->willReturn($attrSetCollection);
$attrSetCollection->expects($this->any())->method('setEntityTypeFilter')->willReturn([$attributeSet]);
$attrColFactory->expects($this->any())->method('create')->willReturn($attrCollection);
- $attrCollection->expects($this->any())->method('setAttributeSetFilter')->willReturn([$attribute1, $attribute2]);
+ $attrCollection->expects($this->any())
+ ->method('setAttributeSetFilter')
+ ->willReturn([$attribute1, $attribute2, $attribute3]);
$attributeSet->expects($this->any())->method('getId')->willReturn(1);
$attributeSet->expects($this->any())->method('getAttributeSetName')->willReturn('attribute_set_name');
@@ -157,7 +165,7 @@ protected function setUp()
],
]
)
- ->willReturn([$attribute1, $attribute2]);
+ ->willReturn([$attribute1, $attribute2, $attribute3]);
$this->connection = $this->createPartialMock(\Magento\Framework\DB\Adapter\Pdo\Mysql::class, [
'select',
@@ -364,9 +372,14 @@ public function testPrepareAttributesWithDefaultValueForSave()
{
$rowData = [
'_attribute_set' => 'attributeSetName',
- 'boolean_attribute' => 'Yes'
+ 'boolean_attribute' => 'Yes',
+ ];
+
+ $expected = [
+ 'boolean_attribute' => 1,
+ 'text_attribute' => 'default_value'
];
$result = $this->simpleType->prepareAttributesWithDefaultValueForSave($rowData);
- $this->assertEquals(['boolean_attribute' => 1], $result);
+ $this->assertEquals($expected, $result);
}
}
From e0d4d0da36713cf74e0ae202a759da292d9c0f6c Mon Sep 17 00:00:00 2001
From: Vitalii Zabaznov
Date: Mon, 16 Sep 2019 16:47:21 -0500
Subject: [PATCH 308/937] MC-18719: private cookie version increments each post
request
---
.../Mftf/Test/StorefrontGuestCheckoutDisabledProductTest.xml | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/app/code/Magento/Quote/Test/Mftf/Test/StorefrontGuestCheckoutDisabledProductTest.xml b/app/code/Magento/Quote/Test/Mftf/Test/StorefrontGuestCheckoutDisabledProductTest.xml
index 7e3af5e402ac9..f7a4fda4f67d8 100644
--- a/app/code/Magento/Quote/Test/Mftf/Test/StorefrontGuestCheckoutDisabledProductTest.xml
+++ b/app/code/Magento/Quote/Test/Mftf/Test/StorefrontGuestCheckoutDisabledProductTest.xml
@@ -119,10 +119,10 @@
+
-
@@ -147,10 +147,10 @@
+
-
From af587486d8aa30956c08eb99fdc09873fa7cbb17 Mon Sep 17 00:00:00 2001
From: Dmytro Poperechnyy
Date: Mon, 16 Sep 2019 16:50:16 -0500
Subject: [PATCH 309/937] MC-19247: Broken translations with advanced bundling
- Add strict type to js unit test;
- Eliminate preference for file system driver;
---
.../Translation/ViewModel/Dictionary.php | 25 +++++++------------
app/code/Magento/Translation/etc/di.xml | 6 ++++-
.../jasmine/tests/lib/mage/fake-dictionary.js | 2 ++
3 files changed, 16 insertions(+), 17 deletions(-)
diff --git a/app/code/Magento/Translation/ViewModel/Dictionary.php b/app/code/Magento/Translation/ViewModel/Dictionary.php
index 41a5faf097da0..011501fc219ae 100644
--- a/app/code/Magento/Translation/ViewModel/Dictionary.php
+++ b/app/code/Magento/Translation/ViewModel/Dictionary.php
@@ -10,7 +10,6 @@
use Magento\Framework\Exception\FileSystemException;
use Magento\Framework\Exception\LocalizedException;
use Magento\Framework\Filesystem;
-use Magento\Framework\View\Asset\File\NotFoundException;
use Magento\Framework\View\Asset\Repository as AssetRepository;
use Magento\Framework\View\Element\Block\ArgumentInterface;
use Magento\Translation\Model\Js\Config as JsConfig;
@@ -64,26 +63,20 @@ public function __construct(
* Get translation dictionary file content.
*
* @return string
+ * @throws FileSystemException
+ * @throws LocalizedException
*/
public function getTranslationDictionary(): string
{
if ($this->appState->getMode() === AppState::MODE_PRODUCTION) {
- try {
- $asset = $this->assetRepo->createAsset(JsConfig::DICTIONARY_FILE_NAME);
- $staticViewFilePath = $this->filesystem->getDirectoryRead(
- DirectoryList::STATIC_VIEW
- )->getAbsolutePath();
- $content = $this->filesystemDriver->fileGetContents($staticViewFilePath . $asset->getPath());
- } catch (LocalizedException | FileSystemException $e) {
- $content = '';
- }
+ $asset = $this->assetRepo->createAsset(JsConfig::DICTIONARY_FILE_NAME);
+ $staticViewFilePath = $this->filesystem->getDirectoryRead(
+ DirectoryList::STATIC_VIEW
+ )->getAbsolutePath();
+ $content = $this->filesystemDriver->fileGetContents($staticViewFilePath . $asset->getPath());
} else {
- try {
- $asset = $this->assetRepo->createAsset(JsConfig::DICTIONARY_FILE_NAME);
- $content = $asset->getContent();
- } catch (LocalizedException | NotFoundException $e) {
- $content = '';
- }
+ $asset = $this->assetRepo->createAsset(JsConfig::DICTIONARY_FILE_NAME);
+ $content = $asset->getContent();
}
return $content;
diff --git a/app/code/Magento/Translation/etc/di.xml b/app/code/Magento/Translation/etc/di.xml
index 3ba249d601277..acb24bcd0a71e 100644
--- a/app/code/Magento/Translation/etc/di.xml
+++ b/app/code/Magento/Translation/etc/di.xml
@@ -15,7 +15,11 @@
-
+
+
+ Magento\Framework\Filesystem\Driver\File
+
+
Magento_Translation::translate_inline.phtml
diff --git a/dev/tests/js/jasmine/tests/lib/mage/fake-dictionary.js b/dev/tests/js/jasmine/tests/lib/mage/fake-dictionary.js
index a40bd15c77bd5..bdaf66991a30b 100644
--- a/dev/tests/js/jasmine/tests/lib/mage/fake-dictionary.js
+++ b/dev/tests/js/jasmine/tests/lib/mage/fake-dictionary.js
@@ -4,5 +4,7 @@
*/
// Fake dictionary for js unit tests as real dictionary is defined is template and cannot be initialized by requirejs
define([], function () {
+ 'use strict';
+
return {};
});
From 82c8402f7acc2e017c5e391026fc4989b780cd44 Mon Sep 17 00:00:00 2001
From: Oleksandr Dubovyk
Date: Mon, 16 Sep 2019 18:28:52 -0500
Subject: [PATCH 310/937] MC-20112: [OnPrem] - Import CSV - Can't import empty
value __EMPTY__VALUE__ at store view level
- static test fixed
---
.../Import/Product/Type/AbstractType.php | 1 +
.../Import/Product/Type/AbstractTypeTest.php | 54 +++++++++++++------
2 files changed, 38 insertions(+), 17 deletions(-)
diff --git a/app/code/Magento/CatalogImportExport/Model/Import/Product/Type/AbstractType.php b/app/code/Magento/CatalogImportExport/Model/Import/Product/Type/AbstractType.php
index dc3fa119a7abe..d87c3d8477556 100644
--- a/app/code/Magento/CatalogImportExport/Model/Import/Product/Type/AbstractType.php
+++ b/app/code/Magento/CatalogImportExport/Model/Import/Product/Type/AbstractType.php
@@ -13,6 +13,7 @@
/**
* Import entity abstract product type model
*
+ * phpcs:disable Magento2.Classes.AbstractApi
* @api
*
* @SuppressWarnings(PHPMD.TooManyFields)
diff --git a/app/code/Magento/CatalogImportExport/Test/Unit/Model/Import/Product/Type/AbstractTypeTest.php b/app/code/Magento/CatalogImportExport/Test/Unit/Model/Import/Product/Type/AbstractTypeTest.php
index b183f4ebceb14..371d75bc922f3 100644
--- a/app/code/Magento/CatalogImportExport/Test/Unit/Model/Import/Product/Type/AbstractTypeTest.php
+++ b/app/code/Magento/CatalogImportExport/Test/Unit/Model/Import/Product/Type/AbstractTypeTest.php
@@ -72,7 +72,9 @@ protected function setUp()
'setAttributeSetFilter'
]
);
- $attribute = $this->createPartialMock(\Magento\Eav\Model\Entity\Attribute::class, [
+ $attribute = $this->createPartialMock(
+ \Magento\Eav\Model\Entity\Attribute::class,
+ [
'getAttributeCode',
'getId',
'getIsVisible',
@@ -85,7 +87,8 @@ protected function setUp()
'getDefaultValue',
'usesSource',
'getFrontendInput',
- ]);
+ ]
+ );
$attribute->expects($this->any())->method('getIsVisible')->willReturn(true);
$attribute->expects($this->any())->method('getIsGlobal')->willReturn(true);
$attribute->expects($this->any())->method('getIsRequired')->willReturn(true);
@@ -167,7 +170,9 @@ protected function setUp()
)
->willReturn([$attribute1, $attribute2, $attribute3]);
- $this->connection = $this->createPartialMock(\Magento\Framework\DB\Adapter\Pdo\Mysql::class, [
+ $this->connection = $this->createPartialMock(
+ \Magento\Framework\DB\Adapter\Pdo\Mysql::class,
+ [
'select',
'fetchAll',
'fetchPairs',
@@ -175,13 +180,17 @@ protected function setUp()
'insertOnDuplicate',
'delete',
'quoteInto'
- ]);
- $this->select = $this->createPartialMock(\Magento\Framework\DB\Select::class, [
+ ]
+ );
+ $this->select = $this->createPartialMock(
+ \Magento\Framework\DB\Select::class,
+ [
'from',
'where',
'joinLeft',
'getConnection',
- ]);
+ ]
+ );
$this->select->expects($this->any())->method('from')->will($this->returnSelf());
$this->select->expects($this->any())->method('where')->will($this->returnSelf());
$this->select->expects($this->any())->method('joinLeft')->will($this->returnSelf());
@@ -197,10 +206,13 @@ protected function setUp()
->method('fetchAll')
->will($this->returnValue($entityAttributes));
- $this->resource = $this->createPartialMock(\Magento\Framework\App\ResourceConnection::class, [
+ $this->resource = $this->createPartialMock(
+ \Magento\Framework\App\ResourceConnection::class,
+ [
'getConnection',
'getTableName',
- ]);
+ ]
+ );
$this->resource->expects($this->any())->method('getConnection')->will(
$this->returnValue($this->connection)
);
@@ -265,9 +277,13 @@ public function testIsRowValidSuccess()
$rowNum = 1;
$this->entityModel->expects($this->any())->method('getRowScope')->willReturn(null);
$this->entityModel->expects($this->never())->method('addRowError');
- $this->setPropertyValue($this->simpleType, '_attributes', [
- $rowData[\Magento\CatalogImportExport\Model\Import\Product::COL_ATTR_SET] => [],
- ]);
+ $this->setPropertyValue(
+ $this->simpleType,
+ '_attributes',
+ [
+ $rowData[\Magento\CatalogImportExport\Model\Import\Product::COL_ATTR_SET] => [],
+ ]
+ );
$this->assertTrue($this->simpleType->isRowValid($rowData, $rowNum));
}
@@ -286,13 +302,17 @@ public function testIsRowValidError()
'attr_code'
)
->willReturnSelf();
- $this->setPropertyValue($this->simpleType, '_attributes', [
- $rowData[\Magento\CatalogImportExport\Model\Import\Product::COL_ATTR_SET] => [
- 'attr_code' => [
- 'is_required' => true,
+ $this->setPropertyValue(
+ $this->simpleType,
+ '_attributes',
+ [
+ $rowData[\Magento\CatalogImportExport\Model\Import\Product::COL_ATTR_SET] => [
+ 'attr_code' => [
+ 'is_required' => true,
+ ],
],
- ],
- ]);
+ ]
+ );
$this->assertFalse($this->simpleType->isRowValid($rowData, $rowNum));
}
From 8c2760f4b09ff63188c25ae131265c5dae60075b Mon Sep 17 00:00:00 2001
From: vital_pantsialeyeu
Date: Mon, 16 Sep 2019 22:23:43 +0300
Subject: [PATCH 311/937] MAGETWO-99490: gift messaging options are not saved
with multi-address checkout
- Check gift massage ID in quote and quote items.
- Added functional test.
---
.../Message/Multishipping/Plugin/ItemsBox.php | 9 ++
.../Mftf/Section/AdminOrderGiftSection.xml | 15 +++
.../StorefrontCheckoutCartGiftSection.xml | 16 +++
.../Section/StorefrontOrderGiftSection.xml | 15 +++
...eckingWithMultipleAddressesActionGroup.xml | 12 +++
.../SelectShippingInfoActionGroup.xml | 4 +
.../Mftf/Section/MultishippingSection.xml | 2 +
...frontCheckoutWithMultipleAddressesTest.xml | 97 +++++++++++++++++++
8 files changed, 170 insertions(+)
create mode 100644 app/code/Magento/GiftMessage/Test/Mftf/Section/AdminOrderGiftSection.xml
create mode 100644 app/code/Magento/GiftMessage/Test/Mftf/Section/StorefrontCheckoutCartGiftSection.xml
create mode 100644 app/code/Magento/GiftMessage/Test/Mftf/Section/StorefrontOrderGiftSection.xml
create mode 100644 app/code/Magento/Multishipping/Test/Mftf/Test/StorefrontCheckoutWithMultipleAddressesTest.xml
diff --git a/app/code/Magento/GiftMessage/Block/Message/Multishipping/Plugin/ItemsBox.php b/app/code/Magento/GiftMessage/Block/Message/Multishipping/Plugin/ItemsBox.php
index e02401c1a865d..59ad900c491b6 100644
--- a/app/code/Magento/GiftMessage/Block/Message/Multishipping/Plugin/ItemsBox.php
+++ b/app/code/Magento/GiftMessage/Block/Message/Multishipping/Plugin/ItemsBox.php
@@ -43,6 +43,15 @@ public function __construct(MessageHelper $helper)
*/
public function afterGetItemsBoxTextAfter(ShippingBlock $subject, $itemsBoxText, DataObject $addressEntity)
{
+ if ($addressEntity->getGiftMessageId() === null) {
+ $addressEntity->setGiftMessageId($addressEntity->getQuote()->getGiftMessageId());
+ }
+ foreach ($addressEntity->getAllItems() as $item) {
+ if ($item->getGiftMessageId() === null) {
+ $item->setGiftMessageId($item->getQuoteItem()->getGiftMessageId());
+ }
+ }
+
return $itemsBoxText . $this->helper->getInline('multishipping_address', $addressEntity);
}
}
diff --git a/app/code/Magento/GiftMessage/Test/Mftf/Section/AdminOrderGiftSection.xml b/app/code/Magento/GiftMessage/Test/Mftf/Section/AdminOrderGiftSection.xml
new file mode 100644
index 0000000000000..dc6d0b79a8367
--- /dev/null
+++ b/app/code/Magento/GiftMessage/Test/Mftf/Section/AdminOrderGiftSection.xml
@@ -0,0 +1,15 @@
+
+
+
+
+
+
diff --git a/app/code/Magento/GiftMessage/Test/Mftf/Section/StorefrontCheckoutCartGiftSection.xml b/app/code/Magento/GiftMessage/Test/Mftf/Section/StorefrontCheckoutCartGiftSection.xml
new file mode 100644
index 0000000000000..e39279de228f9
--- /dev/null
+++ b/app/code/Magento/GiftMessage/Test/Mftf/Section/StorefrontCheckoutCartGiftSection.xml
@@ -0,0 +1,16 @@
+
+
+
+
+
+
diff --git a/app/code/Magento/GiftMessage/Test/Mftf/Section/StorefrontOrderGiftSection.xml b/app/code/Magento/GiftMessage/Test/Mftf/Section/StorefrontOrderGiftSection.xml
new file mode 100644
index 0000000000000..3017675611661
--- /dev/null
+++ b/app/code/Magento/GiftMessage/Test/Mftf/Section/StorefrontOrderGiftSection.xml
@@ -0,0 +1,15 @@
+
+
+
+
+
+
diff --git a/app/code/Magento/Multishipping/Test/Mftf/ActionGroup/CheckingWithMultipleAddressesActionGroup.xml b/app/code/Magento/Multishipping/Test/Mftf/ActionGroup/CheckingWithMultipleAddressesActionGroup.xml
index 333c2aec6c28e..c5d04c6ab7301 100644
--- a/app/code/Magento/Multishipping/Test/Mftf/ActionGroup/CheckingWithMultipleAddressesActionGroup.xml
+++ b/app/code/Magento/Multishipping/Test/Mftf/ActionGroup/CheckingWithMultipleAddressesActionGroup.xml
@@ -23,5 +23,17 @@
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/app/code/Magento/Multishipping/Test/Mftf/ActionGroup/SelectShippingInfoActionGroup.xml b/app/code/Magento/Multishipping/Test/Mftf/ActionGroup/SelectShippingInfoActionGroup.xml
index af0b2467862ba..29d90c9083e8d 100644
--- a/app/code/Magento/Multishipping/Test/Mftf/ActionGroup/SelectShippingInfoActionGroup.xml
+++ b/app/code/Magento/Multishipping/Test/Mftf/ActionGroup/SelectShippingInfoActionGroup.xml
@@ -29,5 +29,9 @@
+
+
+
+
diff --git a/app/code/Magento/Multishipping/Test/Mftf/Section/MultishippingSection.xml b/app/code/Magento/Multishipping/Test/Mftf/Section/MultishippingSection.xml
index 45fafc3105c38..e182cb3c68c0f 100644
--- a/app/code/Magento/Multishipping/Test/Mftf/Section/MultishippingSection.xml
+++ b/app/code/Magento/Multishipping/Test/Mftf/Section/MultishippingSection.xml
@@ -20,5 +20,7 @@
+
+
diff --git a/app/code/Magento/Multishipping/Test/Mftf/Test/StorefrontCheckoutWithMultipleAddressesTest.xml b/app/code/Magento/Multishipping/Test/Mftf/Test/StorefrontCheckoutWithMultipleAddressesTest.xml
new file mode 100644
index 0000000000000..c454655989594
--- /dev/null
+++ b/app/code/Magento/Multishipping/Test/Mftf/Test/StorefrontCheckoutWithMultipleAddressesTest.xml
@@ -0,0 +1,97 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
From 1024f53d39890aed965301807c7df4dac344b285 Mon Sep 17 00:00:00 2001
From: natalia
Date: Tue, 17 Sep 2019 08:17:55 +0300
Subject: [PATCH 312/937] MC-16333: Admin user with permission for 1 store can
manage product quantity
---
.../AdminAssertDisabledQtyActionGroup.xml | 19 ++++++++++++++
.../Form/Modifier/AdvancedInventory.php | 7 +++---
.../Product/Form/Modifier/ConfigurableQty.php | 25 ++++++++++++++++---
.../Block/Adminhtml/Product/ProductForm.xml | 2 +-
4 files changed, 45 insertions(+), 8 deletions(-)
create mode 100644 app/code/Magento/CatalogInventory/Test/Mftf/ActionGroup/AdminAssertDisabledQtyActionGroup.xml
diff --git a/app/code/Magento/CatalogInventory/Test/Mftf/ActionGroup/AdminAssertDisabledQtyActionGroup.xml b/app/code/Magento/CatalogInventory/Test/Mftf/ActionGroup/AdminAssertDisabledQtyActionGroup.xml
new file mode 100644
index 0000000000000..27c4a93577a07
--- /dev/null
+++ b/app/code/Magento/CatalogInventory/Test/Mftf/ActionGroup/AdminAssertDisabledQtyActionGroup.xml
@@ -0,0 +1,19 @@
+
+
+
+
+
+
+ Goes to the 'Quantity' field and assert disabled attribute.
+
+
+
+
+
+
diff --git a/app/code/Magento/CatalogInventory/Ui/DataProvider/Product/Form/Modifier/AdvancedInventory.php b/app/code/Magento/CatalogInventory/Ui/DataProvider/Product/Form/Modifier/AdvancedInventory.php
index da465f5bdd3dc..789befcfec8b7 100644
--- a/app/code/Magento/CatalogInventory/Ui/DataProvider/Product/Form/Modifier/AdvancedInventory.php
+++ b/app/code/Magento/CatalogInventory/Ui/DataProvider/Product/Form/Modifier/AdvancedInventory.php
@@ -1,11 +1,10 @@
meta = $this->arrayManager->merge(
$fieldsetPath . '/children',
$this->meta,
- ['container_quantity_and_stock_status_qty' => $container]
+ ['quantity_and_stock_status_qty' => $container]
);
}
}
diff --git a/app/code/Magento/ConfigurableProduct/Ui/DataProvider/Product/Form/Modifier/ConfigurableQty.php b/app/code/Magento/ConfigurableProduct/Ui/DataProvider/Product/Form/Modifier/ConfigurableQty.php
index 7d337c57d7e77..055891ff79c69 100644
--- a/app/code/Magento/ConfigurableProduct/Ui/DataProvider/Product/Form/Modifier/ConfigurableQty.php
+++ b/app/code/Magento/ConfigurableProduct/Ui/DataProvider/Product/Form/Modifier/ConfigurableQty.php
@@ -3,9 +3,12 @@
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
+declare(strict_types=1);
+
namespace Magento\ConfigurableProduct\Ui\DataProvider\Product\Form\Modifier;
use Magento\Catalog\Ui\DataProvider\Product\Form\Modifier\AbstractModifier;
+use Magento\Catalog\Model\Locator\LocatorInterface;
/**
* Data provider for quantity in the Configurable products
@@ -16,7 +19,22 @@ class ConfigurableQty extends AbstractModifier
const CODE_QTY_CONTAINER = 'quantity_and_stock_status_qty';
/**
- * {@inheritdoc}
+ * @var LocatorInterface
+ */
+ private $locator;
+
+ /**
+ * ConfigurableQty constructor
+ *
+ * @param LocatorInterface $locator
+ */
+ public function __construct(LocatorInterface $locator)
+ {
+ $this->locator = $locator;
+ }
+
+ /**
+ * @inheritdoc
*/
public function modifyData(array $data)
{
@@ -24,13 +42,14 @@ public function modifyData(array $data)
}
/**
- * {@inheritdoc}
+ * @inheritdoc
*/
public function modifyMeta(array $meta)
{
if ($groupCode = $this->getGroupCodeByField($meta, self::CODE_QTY_CONTAINER)) {
$parentChildren = &$meta[$groupCode]['children'];
- if (!empty($parentChildren[self::CODE_QTY_CONTAINER])) {
+ $isConfigurable = $this->locator->getProduct()->getTypeId() === 'configurable';
+ if (!empty($parentChildren[self::CODE_QTY_CONTAINER]) && $isConfigurable) {
$parentChildren[self::CODE_QTY_CONTAINER] = array_replace_recursive(
$parentChildren[self::CODE_QTY_CONTAINER],
[
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 525e6b47374a0..028dfc6d109ea 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
@@ -31,7 +31,7 @@
- fieldset[data-index="container_quantity_and_stock_status_qty"] [name="product[quantity_and_stock_status][qty]"]
+ fieldset[data-index="quantity_and_stock_status_qty"] [name="product[quantity_and_stock_status][qty]"]
[data-index="quantity_and_stock_status"] [name="product[quantity_and_stock_status][is_in_stock]"]
From 25b9454d1ac3d9635c0779249cf466f83e04e74a Mon Sep 17 00:00:00 2001
From: Hailong Zhao
Date: Mon, 9 Sep 2019 10:50:12 -0400
Subject: [PATCH 313/937] Fix the comparison of directory path.
---
.../Filesystem/Directory/PathValidator.php | 2 +-
.../Test/Unit/Directory/PathValidatorTest.php | 80 +++++++++++++++++++
2 files changed, 81 insertions(+), 1 deletion(-)
create mode 100644 lib/internal/Magento/Framework/Filesystem/Test/Unit/Directory/PathValidatorTest.php
diff --git a/lib/internal/Magento/Framework/Filesystem/Directory/PathValidator.php b/lib/internal/Magento/Framework/Filesystem/Directory/PathValidator.php
index fe0e6b37666b7..74e6cac7d77b3 100644
--- a/lib/internal/Magento/Framework/Filesystem/Directory/PathValidator.php
+++ b/lib/internal/Magento/Framework/Filesystem/Directory/PathValidator.php
@@ -58,7 +58,7 @@ public function validate(
}
if (mb_strpos($actualPath, $realDirectoryPath) !== 0
- && $path .DIRECTORY_SEPARATOR !== $realDirectoryPath
+ && rtrim($path, DIRECTORY_SEPARATOR) . DIRECTORY_SEPARATOR !== $realDirectoryPath
) {
throw new ValidatorException(
new Phrase(
diff --git a/lib/internal/Magento/Framework/Filesystem/Test/Unit/Directory/PathValidatorTest.php b/lib/internal/Magento/Framework/Filesystem/Test/Unit/Directory/PathValidatorTest.php
new file mode 100644
index 0000000000000..1fe4596759ebd
--- /dev/null
+++ b/lib/internal/Magento/Framework/Filesystem/Test/Unit/Directory/PathValidatorTest.php
@@ -0,0 +1,80 @@
+driver = $this->createMock(\Magento\Framework\Filesystem\Driver\File::class);
+ $this->pathValidator = new \Magento\Framework\Filesystem\Directory\PathValidator(
+ $this->driver
+ );
+ }
+
+ /**
+ * Tear down
+ */
+ protected function tearDown()
+ {
+ $this->pathValidator = null;
+ }
+
+ /**
+ * @param string $directoryPath
+ * @param string $path
+ * @param string $scheme
+ * @param bool $absolutePath
+ * @param string $prefix
+ * @dataProvider validateDataProvider
+ */
+ public function testValidate($directoryPath, $path, $scheme, $absolutePath, $prefix)
+ {
+ $this->driver->expects($this->exactly(2))
+ ->method('getRealPathSafety')
+ ->willReturnMap(
+ [
+ [$directoryPath, $directoryPath],
+ [null, $prefix . $directoryPath . ltrim($path, '/')],
+ ]
+ );
+
+ $this->assertNull(
+ $this->pathValidator->validate($directoryPath, $path, $scheme, $absolutePath)
+ );
+ }
+
+ /**
+ * @return array
+ */
+ public function validateDataProvider()
+ {
+ return [
+ ['/directory/path/', '/directory/path/', '/', false, '/://'],
+ ['/directory/path/', '/var/.regenerate', null, false, ''],
+ ];
+ }
+}
From 7e30a189028ecd77872989df5648ba033a55dd5f Mon Sep 17 00:00:00 2001
From: "al.kravchuk"
Date: Tue, 17 Sep 2019 09:27:52 +0300
Subject: [PATCH 314/937] magento/magento2#24626: Webapi Swager schema
generation fail in case when Get endpoint has param with Extension Attributes
[Case#2]. Fix warnings for empty objects in Get endpoints.
---
app/code/Magento/Webapi/Model/Rest/Swagger/Generator.php | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/app/code/Magento/Webapi/Model/Rest/Swagger/Generator.php b/app/code/Magento/Webapi/Model/Rest/Swagger/Generator.php
index 3ddb2e441ef91..f17e4792422cd 100644
--- a/app/code/Magento/Webapi/Model/Rest/Swagger/Generator.php
+++ b/app/code/Magento/Webapi/Model/Rest/Swagger/Generator.php
@@ -759,7 +759,8 @@ private function handleComplex($name, $type, $prefix, $isArray)
$subPrefix
);
}
- return array_merge(...$queryNames);
+
+ return empty($queryNames) ? [] : array_merge(...$queryNames);
}
/**
From ebb71f8736c735b53157a5c368bf7625b7a6504e Mon Sep 17 00:00:00 2001
From: Yuliya Labudova
Date: Tue, 17 Sep 2019 10:28:29 +0300
Subject: [PATCH 315/937] MC-17493: Cart/catalog rules grid missing
- Fix actionGroup's name.
---
.../Mftf/ActionGroup/AdminCreateCartPriceRuleActionGroup.xml | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/app/code/Magento/SalesRule/Test/Mftf/ActionGroup/AdminCreateCartPriceRuleActionGroup.xml b/app/code/Magento/SalesRule/Test/Mftf/ActionGroup/AdminCreateCartPriceRuleActionGroup.xml
index 537fc3fbc55ee..c840162f0d162 100644
--- a/app/code/Magento/SalesRule/Test/Mftf/ActionGroup/AdminCreateCartPriceRuleActionGroup.xml
+++ b/app/code/Magento/SalesRule/Test/Mftf/ActionGroup/AdminCreateCartPriceRuleActionGroup.xml
@@ -105,7 +105,7 @@
-
+
EXTENDS: AdminCreateCartPriceRuleActionGroup. Removes 'clickSaveButton' for the next data changing. Assign cart price rule to 2 websites instead of 1.
From c25ce099be1473d211e19cfdab90886fc1244608 Mon Sep 17 00:00:00 2001
From: Serhii Voloshkov
Date: Tue, 17 Sep 2019 11:55:17 +0300
Subject: [PATCH 316/937] MC-20075: Fix Skipped MFTF Tests From MC-17140:
MC-14536, MC-14538, MC-14720
---
.../AssertStorefrontMiniCartItemsActionGroup.xml | 16 +++++++++++++++-
...AddedToTheCartThanDefaultDisplayLimitTest.xml | 6 ++++--
2 files changed, 19 insertions(+), 3 deletions(-)
diff --git a/app/code/Magento/Checkout/Test/Mftf/ActionGroup/AssertStorefrontMiniCartItemsActionGroup.xml b/app/code/Magento/Checkout/Test/Mftf/ActionGroup/AssertStorefrontMiniCartItemsActionGroup.xml
index 176eebed142c8..55ccf9539d43d 100644
--- a/app/code/Magento/Checkout/Test/Mftf/ActionGroup/AssertStorefrontMiniCartItemsActionGroup.xml
+++ b/app/code/Magento/Checkout/Test/Mftf/ActionGroup/AssertStorefrontMiniCartItemsActionGroup.xml
@@ -18,7 +18,7 @@
-
+
@@ -26,4 +26,18 @@
+
+
+
+ Validates that the provided Product details (Name, Price) are
+ not present in the Storefront Mini Shopping Cart.
+
+
+
+
+
+
+
+
+
diff --git a/app/code/Magento/Checkout/Test/Mftf/Test/StorefrontCheckCartItemDisplayWhenMoreItemsAddedToTheCartThanDefaultDisplayLimitTest.xml b/app/code/Magento/Checkout/Test/Mftf/Test/StorefrontCheckCartItemDisplayWhenMoreItemsAddedToTheCartThanDefaultDisplayLimitTest.xml
index a0aec77ad419f..8b8aed3ac6204 100644
--- a/app/code/Magento/Checkout/Test/Mftf/Test/StorefrontCheckCartItemDisplayWhenMoreItemsAddedToTheCartThanDefaultDisplayLimitTest.xml
+++ b/app/code/Magento/Checkout/Test/Mftf/Test/StorefrontCheckCartItemDisplayWhenMoreItemsAddedToTheCartThanDefaultDisplayLimitTest.xml
@@ -277,7 +277,9 @@
-
-
+
+
+
+
From 9cd6e22de237acb09cd1afaba5d2b95704ff0988 Mon Sep 17 00:00:00 2001
From: Lusine Papyan
Date: Tue, 17 Sep 2019 13:35:04 +0400
Subject: [PATCH 317/937] MC-18826: Increase test coverage for Cart & Checkout
and Order Processing functional areas
- Automation test for MC-6411
---
.../AdminOrderSelectShippingMethodActionGroup.xml | 8 ++++----
.../Section/AdminInvoicePaymentShippingSection.xml | 2 +-
...eOrderCustomStoreShippingMethodTableRatesTest.xml | 12 ++----------
3 files changed, 7 insertions(+), 15 deletions(-)
diff --git a/app/code/Magento/Sales/Test/Mftf/ActionGroup/AdminOrderSelectShippingMethodActionGroup.xml b/app/code/Magento/Sales/Test/Mftf/ActionGroup/AdminOrderSelectShippingMethodActionGroup.xml
index 87f0c4d7e470e..cfed144184e40 100644
--- a/app/code/Magento/Sales/Test/Mftf/ActionGroup/AdminOrderSelectShippingMethodActionGroup.xml
+++ b/app/code/Magento/Sales/Test/Mftf/ActionGroup/AdminOrderSelectShippingMethodActionGroup.xml
@@ -10,14 +10,14 @@
xsi:noNamespaceSchemaLocation="urn:magento:mftf:Test/etc/actionGroupSchema.xsd">
-
-
+
+
-
-
+
+
diff --git a/app/code/Magento/Sales/Test/Mftf/Section/AdminInvoicePaymentShippingSection.xml b/app/code/Magento/Sales/Test/Mftf/Section/AdminInvoicePaymentShippingSection.xml
index a0b93c66f3a59..32e987bea919b 100644
--- a/app/code/Magento/Sales/Test/Mftf/Section/AdminInvoicePaymentShippingSection.xml
+++ b/app/code/Magento/Sales/Test/Mftf/Section/AdminInvoicePaymentShippingSection.xml
@@ -17,7 +17,7 @@
-
+
diff --git a/app/code/Magento/Shipping/Test/Mftf/Test/AdminCreateOrderCustomStoreShippingMethodTableRatesTest.xml b/app/code/Magento/Shipping/Test/Mftf/Test/AdminCreateOrderCustomStoreShippingMethodTableRatesTest.xml
index bfb94c4293135..67885ccfc99d8 100644
--- a/app/code/Magento/Shipping/Test/Mftf/Test/AdminCreateOrderCustomStoreShippingMethodTableRatesTest.xml
+++ b/app/code/Magento/Shipping/Test/Mftf/Test/AdminCreateOrderCustomStoreShippingMethodTableRatesTest.xml
@@ -21,12 +21,10 @@
-
-
@@ -41,7 +39,6 @@
-
@@ -64,7 +61,6 @@
-
@@ -76,7 +72,6 @@
-
@@ -87,7 +82,6 @@
-
@@ -96,7 +90,6 @@
-
@@ -109,10 +102,9 @@
-
-
-
+
+
From d8534d2430f540373262dd3d47a8500f2c752d3e Mon Sep 17 00:00:00 2001
From: Anton Siniorg
Date: Mon, 16 Sep 2019 17:33:08 +0300
Subject: [PATCH 318/937] fix for the #24618
Magento_Braintree/js/view/payment/method-renderer/paypal.js accessing
undefined variables
---
.../view/frontend/web/js/view/payment/method-renderer/paypal.js | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/app/code/Magento/Braintree/view/frontend/web/js/view/payment/method-renderer/paypal.js b/app/code/Magento/Braintree/view/frontend/web/js/view/payment/method-renderer/paypal.js
index ae9f69c405c2b..e49ddbfb7a246 100644
--- a/app/code/Magento/Braintree/view/frontend/web/js/view/payment/method-renderer/paypal.js
+++ b/app/code/Magento/Braintree/view/frontend/web/js/view/payment/method-renderer/paypal.js
@@ -334,7 +334,7 @@ define([
}
return {
- line1: address.street[0],
+ line1: _.isUndefined(address.street) || _.isUndefined(address.street[0]) ? '' : address.street[0],
city: address.city,
state: address.regionCode,
postalCode: address.postcode,
From e9879d142bac70dbe5ffc9e90578a88152fccf5f Mon Sep 17 00:00:00 2001
From: Ievgenii Gryshkun
Date: Tue, 17 Sep 2019 12:49:29 +0300
Subject: [PATCH 319/937] [Customer] Rename dob to date_of_birth #911
---
.../testsuite/Magento/GraphQl/Customer/UpdateCustomerTest.php | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/dev/tests/api-functional/testsuite/Magento/GraphQl/Customer/UpdateCustomerTest.php b/dev/tests/api-functional/testsuite/Magento/GraphQl/Customer/UpdateCustomerTest.php
index d1c6638e8d5ff..c57b456cf9e35 100644
--- a/dev/tests/api-functional/testsuite/Magento/GraphQl/Customer/UpdateCustomerTest.php
+++ b/dev/tests/api-functional/testsuite/Magento/GraphQl/Customer/UpdateCustomerTest.php
@@ -102,7 +102,7 @@ public function testUpdateCustomer()
$this->assertEquals($newMiddlename, $response['updateCustomer']['customer']['middlename']);
$this->assertEquals($newLastname, $response['updateCustomer']['customer']['lastname']);
$this->assertEquals($newSuffix, $response['updateCustomer']['customer']['suffix']);
- $this->assertEquals($newDob, $response['updateCustomer']['customer']['date_of_birth']);
+ $this->assertEquals($newDob, $response['updateCustomer']['customer']['dob']);
$this->assertEquals($newTaxVat, $response['updateCustomer']['customer']['taxvat']);
$this->assertEquals($newEmail, $response['updateCustomer']['customer']['email']);
$this->assertEquals($newGender, $response['updateCustomer']['customer']['gender']);
From 9bbbf045dc2931a55952f3b9b356b1a2a72ef341 Mon Sep 17 00:00:00 2001
From: "al.kravchuk"
Date: Tue, 17 Sep 2019 14:02:55 +0300
Subject: [PATCH 320/937] magento/magento2#24626: Webapi Swager schema
generation fail in case when Get endpoint has param with Extension Attributes
[Case#2]. Add unit tests coverage.
---
.../Unit/Model/Rest/Swagger/GeneratorTest.php | 131 +++++++++++++++---
1 file changed, 114 insertions(+), 17 deletions(-)
diff --git a/app/code/Magento/Webapi/Test/Unit/Model/Rest/Swagger/GeneratorTest.php b/app/code/Magento/Webapi/Test/Unit/Model/Rest/Swagger/GeneratorTest.php
index 172db875c6c49..67e361bb019d0 100644
--- a/app/code/Magento/Webapi/Test/Unit/Model/Rest/Swagger/GeneratorTest.php
+++ b/app/code/Magento/Webapi/Test/Unit/Model/Rest/Swagger/GeneratorTest.php
@@ -3,6 +3,7 @@
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
+
namespace Magento\Webapi\Test\Unit\Model\Rest\Swagger;
/**
@@ -137,11 +138,7 @@ public function testGenerate($serviceMetadata, $typeData, $schema)
->willReturn($serviceMetadata);
$this->typeProcessorMock->expects($this->any())
->method('getTypeData')
- ->willReturnMap(
- [
- ['TestModule5V2EntityAllSoapAndRest', $typeData],
- ]
- );
+ ->willReturnMap($typeData);
$this->typeProcessorMock->expects($this->any())
->method('isTypeSimple')
@@ -169,6 +166,96 @@ public function testGenerate($serviceMetadata, $typeData, $schema)
public function generateDataProvider()
{
return [
+ [
+ [
+ 'methods' => [
+ 'execute' => [
+ 'method' => 'execute',
+ 'inputRequired' => false,
+ 'isSecure' => false,
+ 'resources' => [
+ "anonymous"
+ ],
+ 'methodAlias' => 'execute',
+ 'parameters' => [],
+ 'documentation' => 'Do Magic!',
+ 'interface' => [
+ 'in' => [
+ 'parameters' => [
+ 'searchRequest' => [
+ 'type' => 'DreamVendorDreamModuleApiDataSearchRequestInterface',
+ 'required' => true,
+ 'documentation' => ""
+ ]
+ ]
+ ],
+ 'out' => [
+ 'parameters' => [
+ 'result' => [
+ 'type' => 'DreamVendorDreamModuleApiDataSearchResultInterface',
+ 'documentation' => null,
+ 'required' => true
+ ]
+ ]
+ ]
+ ]
+ ]
+ ],
+ 'class' => 'DreamVendor\DreamModule\Api\ExecuteStuff',
+ 'description' => '',
+ 'routes' => [
+ '/V1/dream-vendor/dream-module/execute-stuff' => [
+ 'GET' => [
+ 'method' => 'execute',
+ 'parameters' => []
+ ]
+ ]
+ ]
+ ],
+ [
+ [
+ 'DreamVendorDreamModuleApiDataSearchRequestInterface',
+ [
+ 'documentation' => '',
+ 'parameters' => [
+ 'stuff' => [
+ 'type' => 'DreamVendorDreamModuleApiDataStuffInterface',
+ 'required' => true,
+ 'documentation' => 'Empty Extension Point'
+ ]
+ ]
+ ]
+ ],
+ [
+ 'DreamVendorDreamModuleApiDataSearchResultInterface',
+ [
+ 'documentation' => '',
+ 'parameters' => [
+ 'totalCount' => [
+ 'type' => 'int',
+ 'required' => true,
+ 'documentation' => 'Processed count.'
+ ],
+ 'stuff' => [
+ 'type' => 'DreamVendorDreamModuleApiDataStuffInterface',
+ 'required' => true,
+ 'documentation' => 'Empty Extension Point'
+ ]
+ ]
+ ]
+ ],
+ [
+ 'DreamVendorDreamModuleApiDataStuffInterface',
+ [
+ 'documentation' => '',
+ 'parameters' => []
+ ]
+ ]
+ ],
+ // @codingStandardsIgnoreStart
+ '{"swagger":"2.0","info":{"version":"","title":""},"host":"magento.host","basePath":"/rest/default","schemes":["http://"],"tags":[{"name":"testModule5AllSoapAndRestV2","description":""}],"paths":{"/V1/dream-vendor/dream-module/execute-stuff":{"get":{"tags":["testModule5AllSoapAndRestV2"],"description":"Do Magic!","operationId":"operationNameGet","consumes":["application/json","application/xml"],"produces":["application/json","application/xml"],"responses":{"200":{"description":"200 Success.","schema":{"$ref":"#/definitions/dream-vendor-dream-module-api-data-search-result-interface"}},"default":{"description":"Unexpected error","schema":{"$ref":"#/definitions/error-response"}}}}}},"definitions":{"error-response":{"type":"object","properties":{"message":{"type":"string","description":"Error message"},"errors":{"$ref":"#/definitions/error-errors"},"code":{"type":"integer","description":"Error code"},"parameters":{"$ref":"#/definitions/error-parameters"},"trace":{"type":"string","description":"Stack trace"}},"required":["message"]},"error-errors":{"type":"array","description":"Errors list","items":{"$ref":"#/definitions/error-errors-item"}},"error-errors-item":{"type":"object","description":"Error details","properties":{"message":{"type":"string","description":"Error message"},"parameters":{"$ref":"#/definitions/error-parameters"}}},"error-parameters":{"type":"array","description":"Error parameters list","items":{"$ref":"#/definitions/error-parameters-item"}},"error-parameters-item":{"type":"object","description":"Error parameters item","properties":{"resources":{"type":"string","description":"ACL resource"},"fieldName":{"type":"string","description":"Missing or invalid field name"},"fieldValue":{"type":"string","description":"Incorrect field value"}}},"dream-vendor-dream-module-api-data-search-result-interface":{"type":"object","description":"","properties":{"total_count":{"type":"integer","description":"Processed count."},"stuff":{"$ref":"#/definitions/dream-vendor-dream-module-api-data-stuff-interface"}},"required":["total_count","stuff"]},"dream-vendor-dream-module-api-data-stuff-interface":{"type":"object","description":""}}}'
+ // @codingStandardsIgnoreEnd
+ ],
[
[
'methods' => [
@@ -213,12 +300,17 @@ public function generateDataProvider()
],
],
[
- 'documentation' => 'Some Data Object',
- 'parameters' => [
- 'price' => [
- 'type' => 'int',
- 'required' => true,
- 'documentation' => ""
+ [
+ 'TestModule5V2EntityAllSoapAndRest',
+ [
+ 'documentation' => 'Some Data Object',
+ 'parameters' => [
+ 'price' => [
+ 'type' => 'int',
+ 'required' => true,
+ 'documentation' => ""
+ ]
+ ]
]
]
],
@@ -261,12 +353,17 @@ public function generateDataProvider()
],
],
[
- 'documentation' => 'Some Data Object',
- 'parameters' => [
- 'price' => [
- 'type' => 'int',
- 'required' => true,
- 'documentation' => ""
+ [
+ 'TestModule5V2EntityAllSoapAndRest',
+ [
+ 'documentation' => 'Some Data Object',
+ 'parameters' => [
+ 'price' => [
+ 'type' => 'int',
+ 'required' => true,
+ 'documentation' => ""
+ ]
+ ]
]
]
],
From 8dd87681d490a5958d1ea1435df9d6a2adc98ce6 Mon Sep 17 00:00:00 2001
From: "al.kravchuk"
Date: Tue, 17 Sep 2019 14:03:17 +0300
Subject: [PATCH 321/937] magento/magento2#24626: Webapi Swager schema
generation fail in case when Get endpoint has param with Extension Attributes
[Case#2]. Try to fix static tests.
---
app/code/Magento/Webapi/Model/Rest/Swagger/Generator.php | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/app/code/Magento/Webapi/Model/Rest/Swagger/Generator.php b/app/code/Magento/Webapi/Model/Rest/Swagger/Generator.php
index f17e4792422cd..ebc716b3e2f46 100644
--- a/app/code/Magento/Webapi/Model/Rest/Swagger/Generator.php
+++ b/app/code/Magento/Webapi/Model/Rest/Swagger/Generator.php
@@ -38,7 +38,9 @@ class Generator extends AbstractSchemaGenerator
*/
const UNAUTHORIZED_DESCRIPTION = '401 Unauthorized';
- /** Array signifier */
+ /**
+ * Array signifier
+ */
const ARRAY_SIGNIFIER = '[0]';
/**
From da62bd1da9804056882b08f3c3dcb2ae6d69dc3b Mon Sep 17 00:00:00 2001
From: Ievgenii Gryshkun
Date: Tue, 17 Sep 2019 14:05:56 +0300
Subject: [PATCH 322/937] [Customer] Rename dob to date_of_birth #911
---
.../testsuite/Magento/GraphQl/Customer/UpdateCustomerTest.php | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/dev/tests/api-functional/testsuite/Magento/GraphQl/Customer/UpdateCustomerTest.php b/dev/tests/api-functional/testsuite/Magento/GraphQl/Customer/UpdateCustomerTest.php
index c57b456cf9e35..64f9afff81d16 100644
--- a/dev/tests/api-functional/testsuite/Magento/GraphQl/Customer/UpdateCustomerTest.php
+++ b/dev/tests/api-functional/testsuite/Magento/GraphQl/Customer/UpdateCustomerTest.php
@@ -82,7 +82,7 @@ public function testUpdateCustomer()
middlename
lastname
suffix
- date_of_birth
+ dob
taxvat
email
gender
From 80c2b7a16bdc47b88dc1512f28e9c7bbe15df1ad Mon Sep 17 00:00:00 2001
From: Evgeny Petrov
Date: Tue, 17 Sep 2019 14:24:57 +0300
Subject: [PATCH 323/937] MC-17469: Fatal error is displayed during
multishipping checkout when open Cart page in another window
---
.../Magento/Multishipping/Model/Cart/Controller/CartPlugin.php | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/app/code/Magento/Multishipping/Model/Cart/Controller/CartPlugin.php b/app/code/Magento/Multishipping/Model/Cart/Controller/CartPlugin.php
index 40b6f0fa4d8fb..b450232395b88 100644
--- a/app/code/Magento/Multishipping/Model/Cart/Controller/CartPlugin.php
+++ b/app/code/Magento/Multishipping/Model/Cart/Controller/CartPlugin.php
@@ -84,7 +84,7 @@ public function beforeDispatch(Cart $subject, RequestInterface $request)
*
* @return bool
*/
- private function isCheckoutComplete()
+ private function isCheckoutComplete() : bool
{
return (bool) ($this->checkoutSession->getStepData(State::STEP_SHIPPING)['is_complete'] ?? true);
}
From f5e8efa71e4756392de160ab1cbd99eb7fef1210 Mon Sep 17 00:00:00 2001
From: Lusine Papyan
Date: Tue, 17 Sep 2019 15:31:45 +0400
Subject: [PATCH 324/937] MAGETWO-70803: [GITHUB] Inconsistent CSV file Import
error: #7495
- Updated automated test script
---
.../AdminImportProductsActionGroup.xml | 19 +++++++++++++------
...ImportCSVFileCorrectDifferentFilesTest.xml | 10 ++--------
2 files changed, 15 insertions(+), 14 deletions(-)
diff --git a/app/code/Magento/ImportExport/Test/Mftf/ActionGroup/AdminImportProductsActionGroup.xml b/app/code/Magento/ImportExport/Test/Mftf/ActionGroup/AdminImportProductsActionGroup.xml
index 0ba1cd520b48a..9063916e9f502 100644
--- a/app/code/Magento/ImportExport/Test/Mftf/ActionGroup/AdminImportProductsActionGroup.xml
+++ b/app/code/Magento/ImportExport/Test/Mftf/ActionGroup/AdminImportProductsActionGroup.xml
@@ -46,11 +46,18 @@
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/app/code/Magento/ImportExport/Test/Mftf/Test/AdminProductImportCSVFileCorrectDifferentFilesTest.xml b/app/code/Magento/ImportExport/Test/Mftf/Test/AdminProductImportCSVFileCorrectDifferentFilesTest.xml
index 349d3415af06e..eb84929ec8d93 100644
--- a/app/code/Magento/ImportExport/Test/Mftf/Test/AdminProductImportCSVFileCorrectDifferentFilesTest.xml
+++ b/app/code/Magento/ImportExport/Test/Mftf/Test/AdminProductImportCSVFileCorrectDifferentFilesTest.xml
@@ -20,27 +20,21 @@
-
-
-
-
+
-
-
+
-
-
From f1eb7a33bb28ff046c0ae3422084376331cb22d0 Mon Sep 17 00:00:00 2001
From: "al.kravchuk"
Date: Tue, 17 Sep 2019 14:38:17 +0300
Subject: [PATCH 325/937] magento/magento2#24626: Webapi Swager schema
generation fail in case when Get endpoint has param with Extension Attributes
[Case#2]. Try to fix static tests.
---
app/code/Magento/Webapi/Model/Rest/Swagger/Generator.php | 8 ++------
1 file changed, 2 insertions(+), 6 deletions(-)
diff --git a/app/code/Magento/Webapi/Model/Rest/Swagger/Generator.php b/app/code/Magento/Webapi/Model/Rest/Swagger/Generator.php
index ebc716b3e2f46..f38c0f0978536 100644
--- a/app/code/Magento/Webapi/Model/Rest/Swagger/Generator.php
+++ b/app/code/Magento/Webapi/Model/Rest/Swagger/Generator.php
@@ -33,14 +33,10 @@ class Generator extends AbstractSchemaGenerator
*/
const ERROR_SCHEMA = '#/definitions/error-response';
- /**
- * Unauthorized description
- */
+ /** Unauthorized description */
const UNAUTHORIZED_DESCRIPTION = '401 Unauthorized';
- /**
- * Array signifier
- */
+ /** Array signifier */
const ARRAY_SIGNIFIER = '[0]';
/**
From fb5c663bcf3e1564da47e05294d540df17943b7a Mon Sep 17 00:00:00 2001
From: Max Souza
Date: Tue, 17 Sep 2019 09:12:21 -0300
Subject: [PATCH 326/937] Remove tabs and added short description
---
.../Magento/SalesRule/Model/RulesApplier.php | 55 ++++++++++---------
1 file changed, 29 insertions(+), 26 deletions(-)
diff --git a/app/code/Magento/SalesRule/Model/RulesApplier.php b/app/code/Magento/SalesRule/Model/RulesApplier.php
index 0b454d49add8a..a7ec98d24eaf9 100644
--- a/app/code/Magento/SalesRule/Model/RulesApplier.php
+++ b/app/code/Magento/SalesRule/Model/RulesApplier.php
@@ -3,7 +3,6 @@
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
-
namespace Magento\SalesRule\Model;
use Magento\Quote\Model\Quote\Address;
@@ -44,9 +43,9 @@ class RulesApplier
/**
* @param \Magento\SalesRule\Model\Rule\Action\Discount\CalculatorFactory $calculatorFactory
- * @param \Magento\Framework\Event\ManagerInterface $eventManager
- * @param \Magento\SalesRule\Model\Utility $utility
- * @param ChildrenValidationLocator|null $childrenValidationLocator
+ * @param \Magento\Framework\Event\ManagerInterface $eventManager
+ * @param \Magento\SalesRule\Model\Utility $utility
+ * @param ChildrenValidationLocator|null $childrenValidationLocator
*/
public function __construct(
\Magento\SalesRule\Model\Rule\Action\Discount\CalculatorFactory $calculatorFactory,
@@ -64,11 +63,11 @@ public function __construct(
/**
* Apply rules to current order item
*
- * @param AbstractItem $item
- * @param Collection $rules
- * @param bool $skipValidation
- * @param mixed $couponCode
- * @return array
+ * @param AbstractItem $item
+ * @param Collection $rules
+ * @param bool $skipValidation
+ * @param mixed $couponCode
+ * @return array
* @SuppressWarnings(PHPMD.CyclomaticComplexity)
*/
public function applyRules($item, $rules, $skipValidation, $couponCode)
@@ -113,8 +112,8 @@ public function applyRules($item, $rules, $skipValidation, $couponCode)
/**
* Add rule discount description label to address object
*
- * @param Address $address
- * @param Rule $rule
+ * @param Address $address
+ * @param Rule $rule
* @return $this
*/
public function addDiscountDescription($address, $rule)
@@ -146,10 +145,10 @@ public function addDiscountDescription($address, $rule)
/**
* Apply Rule
*
- * @param AbstractItem $item
- * @param Rule $rule
- * @param \Magento\Quote\Model\Quote\Address $address
- * @param mixed $couponCode
+ * @param AbstractItem $item
+ * @param Rule $rule
+ * @param \Magento\Quote\Model\Quote\Address $address
+ * @param mixed $couponCode
* @return $this
*/
protected function applyRule($item, $rule, $address, $couponCode)
@@ -166,8 +165,8 @@ protected function applyRule($item, $rule, $address, $couponCode)
/**
* Get discount Data
*
- * @param AbstractItem $item
- * @param Rule $rule
+ * @param AbstractItem $item
+ * @param Rule $rule
* @return \Magento\SalesRule\Model\Rule\Action\Discount\Data
*/
protected function getDiscountData($item, $rule)
@@ -192,8 +191,10 @@ protected function getDiscountData($item, $rule)
}
/**
+ * Set discount
+ *
* @param \Magento\SalesRule\Model\Rule\Action\Discount\Data $discountData
- * @param AbstractItem $item
+ * @param AbstractItem $item
* @return $this
*/
protected function setDiscountData($discountData, $item)
@@ -209,9 +210,9 @@ protected function setDiscountData($discountData, $item)
/**
* Set coupon code to address if $rule contains validated coupon
*
- * @param Address $address
- * @param Rule $rule
- * @param mixed $couponCode
+ * @param Address $address
+ * @param Rule $rule
+ * @param mixed $couponCode
* @return $this
*/
public function maintainAddressCouponCode($address, $rule, $couponCode)
@@ -230,10 +231,10 @@ public function maintainAddressCouponCode($address, $rule, $couponCode)
/**
* Fire event to allow overwriting of discount amounts
*
- * @param \Magento\SalesRule\Model\Rule\Action\Discount\Data $discountData
- * @param AbstractItem $item
- * @param Rule $rule
- * @param float $qty
+ * @param \Magento\SalesRule\Model\Rule\Action\Discount\Data $discountData
+ * @param AbstractItem $item
+ * @param Rule $rule
+ * @param float $qty
* @return $this
*/
protected function eventFix(
@@ -261,8 +262,10 @@ protected function eventFix(
}
/**
+ * Set Applied Rule Ids
+ *
* @param AbstractItem $item
- * @param int[] $appliedRuleIds
+ * @param int[] $appliedRuleIds
* @return $this
*/
public function setAppliedRuleIds(AbstractItem $item, array $appliedRuleIds)
From 6ddd1d10edbd542a88b526fe25b8010adb568bf9 Mon Sep 17 00:00:00 2001
From: Serhii Balko
Date: Tue, 17 Sep 2019 15:46:51 +0300
Subject: [PATCH 327/937] MC-20118: Arabic Date Selector shows date in
incorrect format
---
.../Magento/Customer/Block/Widget/Dob.php | 6 +++-
.../Test/Unit/Block/Widget/DobTest.php | 31 ++++++++++++++-----
2 files changed, 28 insertions(+), 9 deletions(-)
diff --git a/app/code/Magento/Customer/Block/Widget/Dob.php b/app/code/Magento/Customer/Block/Widget/Dob.php
index d874729d9132e..d822be853f184 100644
--- a/app/code/Magento/Customer/Block/Widget/Dob.php
+++ b/app/code/Magento/Customer/Block/Widget/Dob.php
@@ -277,7 +277,11 @@ public function getHtmlExtraParams()
*/
public function getDateFormat()
{
- return $this->_localeDate->getDateFormatWithLongYear();
+ $dateFormat = $this->_localeDate->getDateFormatWithLongYear();
+ /** Escape RTL characters which are present in some locales and corrupt formatting */
+ $escapedDateFormat = preg_replace('/[^MmDdYy\/\.\-]/', '', $dateFormat);
+
+ return $escapedDateFormat;
}
/**
diff --git a/app/code/Magento/Customer/Test/Unit/Block/Widget/DobTest.php b/app/code/Magento/Customer/Test/Unit/Block/Widget/DobTest.php
index 8bfddac3cef8f..2e8ee7af37cef 100644
--- a/app/code/Magento/Customer/Test/Unit/Block/Widget/DobTest.php
+++ b/app/code/Magento/Customer/Test/Unit/Block/Widget/DobTest.php
@@ -23,7 +23,7 @@
use Magento\Framework\View\Element\Html\Date;
use Magento\Framework\View\Element\Template\Context;
use PHPUnit\Framework\TestCase;
-use PHPUnit_Framework_MockObject_MockObject;
+use PHPUnit\Framework\MockObject\MockObject;
use Zend_Cache_Backend_BlackHole;
use Zend_Cache_Core;
@@ -60,17 +60,17 @@ class DobTest extends TestCase
const YEAR_HTML =
'yy
';
- /** @var PHPUnit_Framework_MockObject_MockObject|AttributeMetadataInterface */
+ /** @var MockObject|AttributeMetadataInterface */
protected $attribute;
/** @var Dob */
protected $_block;
- /** @var PHPUnit_Framework_MockObject_MockObject|CustomerMetadataInterface */
+ /** @var MockObject|CustomerMetadataInterface */
protected $customerMetadata;
/**
- * @var FilterFactory|PHPUnit_Framework_MockObject_MockObject
+ * @var FilterFactory|MockObject
*/
protected $filterFactory;
@@ -336,12 +336,27 @@ public function getYearDataProvider()
}
/**
- * is used to derive the Locale that is used to determine the
- * value of Dob::getDateFormat() for that Locale.
+ * Is used to derive the Locale that is used to determine the value of Dob::getDateFormat() for that Locale
+ *
+ * @param string $locale
+ * @param string $expectedFormat
+ * @dataProvider getDateFormatDataProvider
*/
- public function testGetDateFormat()
+ public function testGetDateFormat(string $locale, string $expectedFormat)
{
- $this->assertEquals(self::DATE_FORMAT, $this->_block->getDateFormat());
+ $this->_locale = $locale;
+ $this->assertEquals($expectedFormat, $this->_block->getDateFormat());
+ }
+
+ /**
+ * @return array
+ */
+ public function getDateFormatDataProvider(): array
+ {
+ return [
+ ['ar_SA', 'd/M/y'],
+ [Resolver::DEFAULT_LOCALE, self::DATE_FORMAT],
+ ];
}
/**
From eabb8a3bdbaa62bf54a2e763d016e6212f84f55b Mon Sep 17 00:00:00 2001
From: Aliaksei_Manenak
Date: Tue, 17 Sep 2019 16:31:54 +0300
Subject: [PATCH 328/937] MC-18819: Increase test coverage for Account
functional area
- Integration test for MC-11209
---
.../Cart/Item/Renderer/ConfigurableTest.php | 68 +++++++++++++++++++
1 file changed, 68 insertions(+)
create mode 100644 dev/tests/integration/testsuite/Magento/ConfigurableProduct/Block/Cart/Item/Renderer/ConfigurableTest.php
diff --git a/dev/tests/integration/testsuite/Magento/ConfigurableProduct/Block/Cart/Item/Renderer/ConfigurableTest.php b/dev/tests/integration/testsuite/Magento/ConfigurableProduct/Block/Cart/Item/Renderer/ConfigurableTest.php
new file mode 100644
index 0000000000000..aba813148512c
--- /dev/null
+++ b/dev/tests/integration/testsuite/Magento/ConfigurableProduct/Block/Cart/Item/Renderer/ConfigurableTest.php
@@ -0,0 +1,68 @@
+objectManager = \Magento\TestFramework\Helper\Bootstrap::getObjectManager();
+ $this->block = $this->objectManager->get(LayoutInterface::class)
+ ->createBlock(ConfigurableRenderer::class);
+ }
+
+ /**
+ * @magentoDbIsolation enabled
+ * @magentoAppIsolation enabled
+ * @magentoDataFixture Magento/ConfigurableProduct/_files/quote_with_configurable_product.php
+ */
+ public function testGetProductPriceHtml()
+ {
+ $productRepository = $this->objectManager->get(ProductRepositoryInterface::class);
+ $configurableProduct = $productRepository->getById(1);
+
+ $layout = $this->objectManager->get(LayoutInterface::class);
+ $layout->createBlock(
+ \Magento\Framework\Pricing\Render::class,
+ 'product.price.render.default',
+ [
+ 'data' => [
+ 'price_render_handle' => 'catalog_product_prices',
+ 'use_link_for_as_low_as' => true
+ ]
+ ]
+ );
+
+ $this->block->setItem(
+ $this->block->getCheckoutSession()->getQuote()->getAllVisibleItems()[0]
+ );
+ $html = $this->block->getProductPriceHtml($configurableProduct);
+ $this->assertContains('$10.00 ', $html);
+ }
+}
From 3e890e6b38574383f45114097ec99d14169bebb4 Mon Sep 17 00:00:00 2001
From: vital_sery
Date: Tue, 17 Sep 2019 16:50:38 +0300
Subject: [PATCH 329/937] MC-18826: Increase test coverage for Cart & Checkout
and Order Processing functional areas
- Integration test for MC-11299
---
.../Sales/Model/Order/ShipmentTest.php | 27 +++++++++++-
.../testsuite/Magento/Sales/_files/order.php | 41 +++++++++++++++++++
2 files changed, 66 insertions(+), 2 deletions(-)
diff --git a/dev/tests/integration/testsuite/Magento/Sales/Model/Order/ShipmentTest.php b/dev/tests/integration/testsuite/Magento/Sales/Model/Order/ShipmentTest.php
index 9c0024480d164..5b5c2365bfac4 100644
--- a/dev/tests/integration/testsuite/Magento/Sales/Model/Order/ShipmentTest.php
+++ b/dev/tests/integration/testsuite/Magento/Sales/Model/Order/ShipmentTest.php
@@ -173,7 +173,30 @@ public function testGetTracksCollection()
$shipment->addTrack($track);
$this->shipmentRepository->save($shipment);
- $saved = $shipment->getTracksCollection();
- self::assertTrue(in_array($track->getId(), $saved->getColumnValues('id')));
+
+ $secondOrder = $this->getOrder('100000002');
+ $secondOrderItems = [];
+ foreach ($secondOrder->getItems() as $item) {
+ $secondOrderItems[$item->getId()] = $item->getQtyOrdered();
+ }
+ /** @var \Magento\Sales\Model\Order\Shipment $secondOrderShipment */
+ $secondOrderShipment = $this->objectManager->get(ShipmentFactory::class)
+ ->create($secondOrder, $secondOrderItems);
+
+ /** @var ShipmentTrackInterface $secondShipmentTrack */
+ $secondShipmentTrack = $this->objectManager->create(ShipmentTrackInterface::class);
+ $secondShipmentTrack->setNumber('Test Number2')
+ ->setTitle('Test Title2')
+ ->setCarrierCode('Test CODE2');
+
+ $secondOrderShipment->addTrack($secondShipmentTrack);
+ $this->shipmentRepository->save($secondOrderShipment);
+
+ self::assertEmpty(
+ array_intersect(
+ $shipment->getTracksCollection()->getColumnValues('id'),
+ $secondOrderShipment->getTracksCollection()->getColumnValues('id')
+ )
+ );
}
}
diff --git a/dev/tests/integration/testsuite/Magento/Sales/_files/order.php b/dev/tests/integration/testsuite/Magento/Sales/_files/order.php
index 9ea85aae56cbb..8d2132dadd69b 100644
--- a/dev/tests/integration/testsuite/Magento/Sales/_files/order.php
+++ b/dev/tests/integration/testsuite/Magento/Sales/_files/order.php
@@ -68,3 +68,44 @@
/** @var OrderRepositoryInterface $orderRepository */
$orderRepository = $objectManager->create(OrderRepositoryInterface::class);
$orderRepository->save($order);
+
+/** @var Payment $payment */
+$payment2 = $objectManager->create(Payment::class);
+$payment2->setMethod('checkmo')
+ ->setAdditionalInformation('last_trans_id', '11122')
+ ->setAdditionalInformation(
+ 'metadata',
+ [
+ 'type' => 'free',
+ 'fraudulent' => false,
+ ]
+ );
+
+/** @var OrderItem $orderItem */
+$orderItem2 = $objectManager->create(OrderItem::class);
+$orderItem2->setProductId($product->getId())
+ ->setQtyOrdered(2)
+ ->setBasePrice($product->getPrice())
+ ->setPrice($product->getPrice())
+ ->setRowTotal($product->getPrice())
+ ->setProductType('simple')
+ ->setName($product->getName())
+ ->setSku($product->getSku());
+
+/** @var Order $order */
+$order2 = $objectManager->create(Order::class);
+$order2->setIncrementId('100000002')
+ ->setState(Order::STATE_PROCESSING)
+ ->setStatus($order2->getConfig()->getStateDefaultStatus(Order::STATE_PROCESSING))
+ ->setSubtotal(100)
+ ->setGrandTotal(100)
+ ->setBaseSubtotal(100)
+ ->setBaseGrandTotal(100)
+ ->setCustomerIsGuest(true)
+ ->setCustomerEmail('customer@null.com')
+ ->setBillingAddress($billingAddress)
+ ->setShippingAddress($shippingAddress)
+ ->setStoreId($objectManager->get(StoreManagerInterface::class)->getStore()->getId())
+ ->addItem($orderItem2)
+ ->setPayment($payment2);
+$orderRepository->save($order2);
From 9623f9a0a6e1a1fd92846585a149e291d0ffd6e8 Mon Sep 17 00:00:00 2001
From: Oleksandr Burianyk
Date: Tue, 17 Sep 2019 17:14:54 +0300
Subject: [PATCH 330/937] MC-6463: Product custom URL Key is preserved when
assigned to a Category (with custom URL Key) alongside with another Product
without custom URL Key
---
...dminProductFormUpdateUrlKeyActionGroup.xml | 23 ++++
.../StorefrontCheckProductUrlActionGroup.xml | 21 ++++
...CreateUrlRewriteForCustomStoreViewTest.xml | 109 ++++++++++++++++++
3 files changed, 153 insertions(+)
create mode 100644 app/code/Magento/UrlRewrite/Test/Mftf/ActionGroup/AdminProductFormUpdateUrlKeyActionGroup.xml
create mode 100644 app/code/Magento/UrlRewrite/Test/Mftf/ActionGroup/StorefrontCheckProductUrlActionGroup.xml
create mode 100644 app/code/Magento/UrlRewrite/Test/Mftf/Test/AdminProductCreateUrlRewriteForCustomStoreViewTest.xml
diff --git a/app/code/Magento/UrlRewrite/Test/Mftf/ActionGroup/AdminProductFormUpdateUrlKeyActionGroup.xml b/app/code/Magento/UrlRewrite/Test/Mftf/ActionGroup/AdminProductFormUpdateUrlKeyActionGroup.xml
new file mode 100644
index 0000000000000..967aa4be7cdc8
--- /dev/null
+++ b/app/code/Magento/UrlRewrite/Test/Mftf/ActionGroup/AdminProductFormUpdateUrlKeyActionGroup.xml
@@ -0,0 +1,23 @@
+
+
+
+
+
+
+ Update UrlKey for Product on Custom Store View.
+
+
+
+
+
+
+
+
+
+
diff --git a/app/code/Magento/UrlRewrite/Test/Mftf/ActionGroup/StorefrontCheckProductUrlActionGroup.xml b/app/code/Magento/UrlRewrite/Test/Mftf/ActionGroup/StorefrontCheckProductUrlActionGroup.xml
new file mode 100644
index 0000000000000..c97a6d9bb8f24
--- /dev/null
+++ b/app/code/Magento/UrlRewrite/Test/Mftf/ActionGroup/StorefrontCheckProductUrlActionGroup.xml
@@ -0,0 +1,21 @@
+
+
+
+
+
+
+
+ Validates that the provided Simple Product Url is correct.
+
+
+
+
+
+
+
diff --git a/app/code/Magento/UrlRewrite/Test/Mftf/Test/AdminProductCreateUrlRewriteForCustomStoreViewTest.xml b/app/code/Magento/UrlRewrite/Test/Mftf/Test/AdminProductCreateUrlRewriteForCustomStoreViewTest.xml
new file mode 100644
index 0000000000000..e77e956fc4d60
--- /dev/null
+++ b/app/code/Magento/UrlRewrite/Test/Mftf/Test/AdminProductCreateUrlRewriteForCustomStoreViewTest.xml
@@ -0,0 +1,109 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
From b2e78e3a65d568e48c12bc989685e3066985f826 Mon Sep 17 00:00:00 2001
From: Pavel Bystritsky
Date: Tue, 17 Sep 2019 17:23:10 +0300
Subject: [PATCH 331/937] magento/magento2#24089: MFTF test added.
---
.../Test/Mftf/Page/AdminEditCustomerPage.xml | 2 +
.../Mftf/Section/AdminCustomerCartSection.xml | 14 ++++
.../AdminCustomerInformationSection.xml | 22 ++++++
...ectNavigateFromCustomerViewCartProduct.xml | 74 +++++++++++++++++++
4 files changed, 112 insertions(+)
create mode 100644 app/code/Magento/Customer/Test/Mftf/Section/AdminCustomerCartSection.xml
create mode 100644 app/code/Magento/Customer/Test/Mftf/Section/AdminCustomerInformationSection.xml
create mode 100644 app/code/Magento/Customer/Test/Mftf/Test/AdminProductBackRedirectNavigateFromCustomerViewCartProduct.xml
diff --git a/app/code/Magento/Customer/Test/Mftf/Page/AdminEditCustomerPage.xml b/app/code/Magento/Customer/Test/Mftf/Page/AdminEditCustomerPage.xml
index 9bd382da8eb92..79fb18afaad53 100644
--- a/app/code/Magento/Customer/Test/Mftf/Page/AdminEditCustomerPage.xml
+++ b/app/code/Magento/Customer/Test/Mftf/Page/AdminEditCustomerPage.xml
@@ -12,6 +12,8 @@
+
+
diff --git a/app/code/Magento/Customer/Test/Mftf/Section/AdminCustomerCartSection.xml b/app/code/Magento/Customer/Test/Mftf/Section/AdminCustomerCartSection.xml
new file mode 100644
index 0000000000000..5c8b8907db43a
--- /dev/null
+++ b/app/code/Magento/Customer/Test/Mftf/Section/AdminCustomerCartSection.xml
@@ -0,0 +1,14 @@
+
+
+
+
+
+
diff --git a/app/code/Magento/Customer/Test/Mftf/Section/AdminCustomerInformationSection.xml b/app/code/Magento/Customer/Test/Mftf/Section/AdminCustomerInformationSection.xml
new file mode 100644
index 0000000000000..d680015230b9d
--- /dev/null
+++ b/app/code/Magento/Customer/Test/Mftf/Section/AdminCustomerInformationSection.xml
@@ -0,0 +1,22 @@
+
+
+
+
+
+
diff --git a/app/code/Magento/Customer/Test/Mftf/Test/AdminProductBackRedirectNavigateFromCustomerViewCartProduct.xml b/app/code/Magento/Customer/Test/Mftf/Test/AdminProductBackRedirectNavigateFromCustomerViewCartProduct.xml
new file mode 100644
index 0000000000000..9de2339f2e217
--- /dev/null
+++ b/app/code/Magento/Customer/Test/Mftf/Test/AdminProductBackRedirectNavigateFromCustomerViewCartProduct.xml
@@ -0,0 +1,74 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
From 3c5d4a716ec7f10ec1d06f656992aec1bb51f5ba Mon Sep 17 00:00:00 2001
From: Lusine Papyan
Date: Tue, 17 Sep 2019 15:32:20 +0300
Subject: [PATCH 332/937] MC-18709: [WYSIWYG]Spinner is Always Displayed on
Media Gallery popup
- Updated automated test script
---
.../Test/Mftf/ActionGroup/AdminCMSBlockContentActionGroup.xml | 3 +++
1 file changed, 3 insertions(+)
diff --git a/app/code/Magento/Cms/Test/Mftf/ActionGroup/AdminCMSBlockContentActionGroup.xml b/app/code/Magento/Cms/Test/Mftf/ActionGroup/AdminCMSBlockContentActionGroup.xml
index a7dc5ab96890b..711a8af38efe3 100644
--- a/app/code/Magento/Cms/Test/Mftf/ActionGroup/AdminCMSBlockContentActionGroup.xml
+++ b/app/code/Magento/Cms/Test/Mftf/ActionGroup/AdminCMSBlockContentActionGroup.xml
@@ -15,12 +15,15 @@
+
+
+
From 3c4607344e44dcebc864ca6e9dc0309f26b0b1ee Mon Sep 17 00:00:00 2001
From: Lilit Sargsyan
Date: Tue, 17 Sep 2019 18:09:27 +0400
Subject: [PATCH 333/937] MC-17653: Cannot schedule update for catalog price
rule for date attribute
- Updated automated test script.
---
.../Catalog/Test/Mftf/Section/AdminProductFormSection.xml | 1 +
1 file changed, 1 insertion(+)
diff --git a/app/code/Magento/Catalog/Test/Mftf/Section/AdminProductFormSection.xml b/app/code/Magento/Catalog/Test/Mftf/Section/AdminProductFormSection.xml
index 80b4159167453..b2992a20814e8 100644
--- a/app/code/Magento/Catalog/Test/Mftf/Section/AdminProductFormSection.xml
+++ b/app/code/Magento/Catalog/Test/Mftf/Section/AdminProductFormSection.xml
@@ -8,6 +8,7 @@
+
From 9f67e9f00b6ee5b77009b3ffac3b96ad090495b4 Mon Sep 17 00:00:00 2001
From: Deepty Thampy
Date: Tue, 17 Sep 2019 09:54:53 -0500
Subject: [PATCH 334/937] MC-19255: API functional tests to cover cart
promotions
- added test coverage
---
.../GraphQl/Quote/CartPromotionsTest.php | 295 ++++++++++++++++++
...e_10_percent_off_qty_more_than_2_items.php | 70 +++++
...ent_off_qty_more_than_2_items_rollback.php | 9 +
.../SalesRule/_files/rules_category.php | 8 +-
4 files changed, 381 insertions(+), 1 deletion(-)
create mode 100644 dev/tests/api-functional/testsuite/Magento/GraphQl/Quote/CartPromotionsTest.php
create mode 100644 dev/tests/integration/testsuite/Magento/SalesRule/_files/cart_rule_10_percent_off_qty_more_than_2_items.php
create mode 100644 dev/tests/integration/testsuite/Magento/SalesRule/_files/cart_rule_10_percent_off_qty_more_than_2_items_rollback.php
diff --git a/dev/tests/api-functional/testsuite/Magento/GraphQl/Quote/CartPromotionsTest.php b/dev/tests/api-functional/testsuite/Magento/GraphQl/Quote/CartPromotionsTest.php
new file mode 100644
index 0000000000000..ccfdfc9f741f4
--- /dev/null
+++ b/dev/tests/api-functional/testsuite/Magento/GraphQl/Quote/CartPromotionsTest.php
@@ -0,0 +1,295 @@
+get(ProductRepositoryInterface::class);
+ /** @var Product $prod2 */
+ $prod1 = $productRepository->get('simple1');
+ $prod2 = $productRepository->get('simple2');
+ $productsInCart = [$prod1, $prod2];
+ $prod2->setVisibility(Visibility::VISIBILITY_BOTH);
+ $productRepository->save($prod2);
+ $skus =['simple1', 'simple2'];
+ $categoryId = 66;
+ /** @var \Magento\Catalog\Api\CategoryLinkManagementInterface $categoryLinkManagement */
+ $categoryLinkManagement = $objectManager->create(CategoryLinkManagementInterface::class);
+ foreach ($skus as $sku) {
+ $categoryLinkManagement->assignProductToCategories(
+ $sku,
+ [$categoryId]
+ );
+ }
+ /** @var Collection $ruleCollection */
+ $ruleCollection = $objectManager->get(Collection::class);
+ $ruleLabels = [];
+ /** @var Rule $rule */
+ foreach ($ruleCollection as $rule) {
+ $ruleLabels = $rule->getStoreLabels();
+ }
+
+ $qty = 2;
+ $cartId = $this->createEmptyCart();
+ $this->addMultipleSimpleProductsToCart($cartId, $qty, $skus[0], $skus[1]);
+ $query = $this->getCartItemPricesQuery($cartId);
+ $response = $this->graphQlMutation($query);
+ $this->assertCount(2, $response['cart']['items']);
+ //validating the line item prices, quantity and discount
+ $productsInResponse = array_map(null, $response['cart']['items'], $productsInCart);
+ $count = count($productsInCart);
+ for ($itemIndex = 0; $itemIndex < $count; $itemIndex++) {
+ $this->assertNotEmpty($productsInResponse[$itemIndex]);
+ $this->assertResponseFields(
+ $productsInResponse[$itemIndex][0],
+ [
+ 'quantity' => $qty,
+ 'prices' => [
+ 'row_total' => ['value' => $productsInCart[$itemIndex]->getSpecialPrice()*$qty],
+ 'row_total_including_tax' => ['value' => $productsInCart[$itemIndex]->getSpecialPrice()*$qty],
+ 'discount' => ['value' => $productsInCart[$itemIndex]->getSpecialPrice()*$qty*0.5],
+ 'discounts' => [
+ 0 =>[
+ 'amount' =>
+ ['value' => $productsInCart[$itemIndex]->getSpecialPrice()*$qty*0.5],
+ 'label' => $ruleLabels[0]
+ ]
+ ]
+ ],
+ ]
+ );
+ }
+
+ /** @var Collection $ruleCollection */
+ // $ruleCollection = $objectManager->get(Collection::class);
+ /** @var RuleRepositoryInterface $ruleRepository */
+ // $ruleRepository = $objectManager->get(RuleRepositoryInterface::class);
+
+ /** @var Rule $rule */
+// foreach ($ruleCollection as $rule) {
+// $ruleName = $rule->getName();
+// if($ruleName === '50% Off on Large Orders'){
+// $ruleId = $rule->getRuleId();
+ /** @var \Magento\SalesRule\Model\Data\Rule $salesRule */
+// $salesRule = $ruleRepository->getById($ruleId);
+// $salesRule->setStoreLabels(['store_labels' => 'Test Label']);
+
+// $salesRule->setStoreLabels([
+// 'store_labels' => [
+// [
+// 'store_id' => 0,
+// 'store_label' => 'TestRule_Label',
+// ]
+// ]
+//
+// ]
+// );
+ // $ruleRepository->save($salesRule);
+ // $salesRule->save();
+ /** @var Rule $salesRule */
+ // $salesRule = $objectManager->get(Rule::class);
+// $salesRule->setData
+// ([
+// 'store_labels' => [0 => '50% discount for products in category']
+// ]
+// );
+// $salesRule->save();
+
+
+ }
+
+ /**
+ * Test adding multiple cart rules to multiple products in a cart
+ *
+ * @magentoApiDataFixture Magento/Catalog/_files/multiple_products.php
+ * @magentoApiDataFixture Magento/SalesRule/_files/rules_category.php
+ * @magentoApiDataFixture Magento/SalesRule/_files/cart_rule_10_percent_off_qty_more_than_2_items.php
+ */
+ public function testCartPromotionsMultipleCartRules()
+ {
+ $objectManager = Bootstrap::getObjectManager();
+ /** @var ProductRepositoryInterface $productRepository */
+ $productRepository = $objectManager->get(ProductRepositoryInterface::class);
+ /** @var Product $prod2 */
+ $prod1 = $productRepository->get('simple1');
+ $prod2 = $productRepository->get('simple2');
+ $productsInCart = [$prod1, $prod2];
+ $prod2->setVisibility(Visibility::VISIBILITY_BOTH);
+ $productRepository->save($prod2);
+ $skus =['simple1', 'simple2'];
+ $categoryId = 66;
+ /** @var \Magento\Catalog\Api\CategoryLinkManagementInterface $categoryLinkManagement */
+ $categoryLinkManagement = $objectManager->create(CategoryLinkManagementInterface::class);
+ foreach ($skus as $sku) {
+ $categoryLinkManagement->assignProductToCategories(
+ $sku,
+ [$categoryId]
+ );
+ }
+ /** @var Collection $ruleCollection */
+ $ruleCollection = $objectManager->get(Collection::class);
+ $ruleLabels = [];
+ /** @var Rule $rule */
+ foreach ($ruleCollection as $rule) {
+ $ruleLabels[] = $rule->getStoreLabels();
+ }
+ $qty = 2;
+ $cartId = $this->createEmptyCart();
+ $this->addMultipleSimpleProductsToCart($cartId, $qty, $skus[0], $skus[1]);
+ $query = $this->getCartItemPricesQuery($cartId);
+ $response = $this->graphQlMutation($query);
+ $this->assertCount(2, $response['cart']['items']);
+
+ //validating the individual discounts per product and aggregate discount per product
+ $productsInResponse = array_map(null, $response['cart']['items'], $productsInCart);
+ $count = count($productsInCart);
+ for ($itemIndex = 0; $itemIndex < $count; $itemIndex++) {
+ $this->assertNotEmpty($productsInResponse[$itemIndex]);
+ $lineItemDiscount = $productsInResponse[$itemIndex][0]['prices']['discounts'];
+ $expectedTotalDiscountValue = ($productsInCart[$itemIndex]->getSpecialPrice()*$qty*0.5)+($productsInCart[$itemIndex]->getSpecialPrice()*$qty*0.5*0.1);
+ $this->assertEquals($productsInCart[$itemIndex]->getSpecialPrice()*$qty*0.5, current($lineItemDiscount)['amount']['value']);
+ $this->assertEquals('TestRule_Label', current($lineItemDiscount)['label']);
+
+ $lineItemDiscountValue = next($lineItemDiscount)['amount']['value'];
+ $this->assertEquals(round($productsInCart[$itemIndex]->getSpecialPrice()*$qty*0.5)*0.1, $lineItemDiscountValue );
+ $this->assertEquals('10% off with two items_Label', end($lineItemDiscount)['label']);
+ $actualTotalDiscountValue = $lineItemDiscount[0]['amount']['value'] + $lineItemDiscount[1]['amount']['value'];
+ $this->assertEquals(round($expectedTotalDiscountValue,2), $actualTotalDiscountValue);
+
+ //removing the elements from the response so that the rest of the response values can be compared
+ unset($productsInResponse[$itemIndex][0]['prices']['discounts']);
+ unset($productsInResponse[$itemIndex][0]['prices']['discount']);
+ $this->assertResponseFields(
+ $productsInResponse[$itemIndex][0],
+ [
+ 'quantity' => $qty,
+ 'prices' => [
+ 'row_total' => ['value' => $productsInCart[$itemIndex]->getSpecialPrice()*$qty],
+ 'row_total_including_tax' => ['value' => $productsInCart[$itemIndex]->getSpecialPrice()*$qty]
+ ],
+ ]
+ );
+ }
+ }
+
+ /**
+ * @param string $cartId
+ * @return string
+ */
+ private function getCartItemPricesQuery(string $cartId): string
+ {
+ return <<graphQlMutation($query);
+ $cartId = $response['createEmptyCart'];
+ return $cartId;
+ }
+
+ /**
+ * @param string $cartId
+ * @param int $sku1
+ * @param int $qty
+ * @param string $sku2
+ */
+ private function addMultipleSimpleProductsToCart(string $cartId, int $qty, string $sku1, string $sku2): void
+ {
+ $query = <<graphQlMutation($query);
+
+ self::assertArrayHasKey('cart', $response['addSimpleProductsToCart']);
+ self::assertEquals($qty, $response['addSimpleProductsToCart']['cart']['items'][0]['quantity']);
+ self::assertEquals($sku1, $response['addSimpleProductsToCart']['cart']['items'][0]['product']['sku']);
+ self::assertEquals($qty, $response['addSimpleProductsToCart']['cart']['items'][1]['quantity']);
+ self::assertEquals($sku2, $response['addSimpleProductsToCart']['cart']['items'][1]['product']['sku']);
+ }
+}
diff --git a/dev/tests/integration/testsuite/Magento/SalesRule/_files/cart_rule_10_percent_off_qty_more_than_2_items.php b/dev/tests/integration/testsuite/Magento/SalesRule/_files/cart_rule_10_percent_off_qty_more_than_2_items.php
new file mode 100644
index 0000000000000..c652791a8fe7c
--- /dev/null
+++ b/dev/tests/integration/testsuite/Magento/SalesRule/_files/cart_rule_10_percent_off_qty_more_than_2_items.php
@@ -0,0 +1,70 @@
+get(StoreManagerInterface::class)
+ ->getWebsite()
+ ->getId();
+
+/** @var Rule $salesRule */
+$salesRule = $objectManager->create(Rule::class);
+$salesRule->setData(
+ [
+ 'name' => '10% Off on orders with two items',
+ 'is_active' => 1,
+ 'customer_group_ids' => [GroupManagement::NOT_LOGGED_IN_ID],
+ 'coupon_type' => Rule::COUPON_TYPE_NO_COUPON,
+ 'simple_action' => 'by_percent',
+ 'discount_amount' => 10,
+ 'discount_step' => 0,
+ 'stop_rules_processing' => 1,
+ 'website_ids' => [$websiteId],
+ 'store_labels' => [
+
+ 'store_id' => 0,
+ 'store_label' => '10% off with two items_Label',
+
+ ]
+ ]
+);
+
+$salesRule->getConditions()->loadArray([
+ 'type' => \Magento\SalesRule\Model\Rule\Condition\Combine::class,
+ 'attribute' => null,
+ 'operator' => null,
+ 'value' => '1',
+ 'is_value_processed' => null,
+ 'aggregator' => 'all',
+ 'conditions' =>
+ [
+ [
+ 'type' => \Magento\SalesRule\Model\Rule\Condition\Product\Found::class,
+ 'attribute' => null,
+ 'operator' => null,
+ 'value' => '1',
+ 'is_value_processed' => null,
+ 'aggregator' => 'all',
+ 'conditions' =>
+ [
+ [
+ 'type' => \Magento\SalesRule\Model\Rule\Condition\Product::class,
+ 'attribute' => 'quote_item_qty',
+ 'operator' => '>=',
+ 'value' => '2',
+ 'is_value_processed' => false,
+ ],
+ ],
+ ],
+ ],
+]);
+
+$salesRule->save();
diff --git a/dev/tests/integration/testsuite/Magento/SalesRule/_files/cart_rule_10_percent_off_qty_more_than_2_items_rollback.php b/dev/tests/integration/testsuite/Magento/SalesRule/_files/cart_rule_10_percent_off_qty_more_than_2_items_rollback.php
new file mode 100644
index 0000000000000..54f09a29e4a2e
--- /dev/null
+++ b/dev/tests/integration/testsuite/Magento/SalesRule/_files/cart_rule_10_percent_off_qty_more_than_2_items_rollback.php
@@ -0,0 +1,9 @@
+ 'by_percent',
'discount_amount' => 50,
'discount_step' => 0,
- 'stop_rules_processing' => 1,
+ 'stop_rules_processing' => 0,
'website_ids' => [
\Magento\TestFramework\Helper\Bootstrap::getObjectManager()->get(
\Magento\Store\Model\StoreManagerInterface::class
)->getWebsite()->getId()
+ ],
+ 'store_labels' => [
+
+ 'store_id' => 0,
+ 'store_label' => 'TestRule_Label',
+
]
]
);
From 8632e6df4f4146e230bbb5b13432d8af797eeb9a Mon Sep 17 00:00:00 2001
From: Roman Lytvynenko
Date: Tue, 17 Sep 2019 09:58:15 -0500
Subject: [PATCH 335/937] MC-19661: Export Products bug. I can't exclude
attributes from CSV file.
---
app/code/Magento/CatalogImportExport/Model/Export/Product.php | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/app/code/Magento/CatalogImportExport/Model/Export/Product.php b/app/code/Magento/CatalogImportExport/Model/Export/Product.php
index 2a7113518d750..5baa4b4274be5 100644
--- a/app/code/Magento/CatalogImportExport/Model/Export/Product.php
+++ b/app/code/Magento/CatalogImportExport/Model/Export/Product.php
@@ -717,11 +717,11 @@ public function _getHeaderColumns()
* @return array
*/
- private function getNonSystemAttributes()
+ private function getNonSystemAttributes(): array
{
$attrKeys = [];
foreach ($this->filterAttributeCollection($this->getAttributeCollection()) as $attribute) {
- $attrKeys []= $attribute->getAttributeCode();
+ $attrKeys[] = $attribute->getAttributeCode();
}
return array_diff($this->_getExportMainAttrCodes(), $this->_customHeadersMapping($attrKeys));
From 4d160b184214d4e564a4e154acd832fe90a0e8f7 Mon Sep 17 00:00:00 2001
From: Prabhu Ram
Date: Tue, 17 Sep 2019 11:42:42 -0500
Subject: [PATCH 336/937] MC-19254: Implement the schema changes - Review fixes
for Bic/ Added new resolver for cart discounts
---
.../Quote/Model/Quote/Address/Total.php | 2 -
.../Quote/Model/Quote/Item/AbstractItem.php | 2 -
.../Model/Cart/DiscountAggregator.php | 76 ++++++++++++++++++
.../Model/Resolver/CartItemPrices.php | 5 +-
.../Model/Resolver/CartPrices.php | 30 --------
.../QuoteGraphQl/Model/Resolver/Discounts.php | 77 +++++++++++++++++++
.../Magento/QuoteGraphQl/etc/schema.graphqls | 2 +-
.../SalesRule/Model/Quote/Discount.php | 61 +--------------
.../Magento/SalesRule/Model/RulesApplier.php | 6 +-
.../Test/Unit/Model/RulesApplierTest.php | 41 ++++++++--
.../SalesRule/etc/extension_attributes.xml | 12 +++
11 files changed, 208 insertions(+), 106 deletions(-)
create mode 100644 app/code/Magento/QuoteGraphQl/Model/Cart/DiscountAggregator.php
create mode 100644 app/code/Magento/QuoteGraphQl/Model/Resolver/Discounts.php
create mode 100644 app/code/Magento/SalesRule/etc/extension_attributes.xml
diff --git a/app/code/Magento/Quote/Model/Quote/Address/Total.php b/app/code/Magento/Quote/Model/Quote/Address/Total.php
index 8cbcdc4cc25ed..d8dd0953407d4 100644
--- a/app/code/Magento/Quote/Model/Quote/Address/Total.php
+++ b/app/code/Magento/Quote/Model/Quote/Address/Total.php
@@ -11,8 +11,6 @@
* @method string getCode()
*
* @api
- * @method array getDiscounts()
- * @method Total setDiscounts(array $value)
* @since 100.0.2
*/
class Total extends \Magento\Framework\DataObject
diff --git a/app/code/Magento/Quote/Model/Quote/Item/AbstractItem.php b/app/code/Magento/Quote/Model/Quote/Item/AbstractItem.php
index 562b7f71a272b..d12fd00756c9a 100644
--- a/app/code/Magento/Quote/Model/Quote/Item/AbstractItem.php
+++ b/app/code/Magento/Quote/Model/Quote/Item/AbstractItem.php
@@ -35,8 +35,6 @@
* @method \Magento\Quote\Model\Quote\Item\AbstractItem setBaseDiscountCalculationPrice($price)
* @method int[] getAppliedRuleIds()
* @method \Magento\Quote\Model\Quote\Item\AbstractItem setAppliedRuleIds(array $ruleIds)
- * @method array getDiscountBreakdown()
- * @method \Magento\Quote\Model\Quote\Item\AbstractItem setDiscountBreakdown(array $data)
* @method float getBaseTaxAmount()
* @method float getBaseDiscountTaxCompensation()
* @method float getBaseRowTotal()
diff --git a/app/code/Magento/QuoteGraphQl/Model/Cart/DiscountAggregator.php b/app/code/Magento/QuoteGraphQl/Model/Cart/DiscountAggregator.php
new file mode 100644
index 0000000000000..46a5790908b8c
--- /dev/null
+++ b/app/code/Magento/QuoteGraphQl/Model/Cart/DiscountAggregator.php
@@ -0,0 +1,76 @@
+discountFactory = $discountDataFactory;
+ }
+
+ /**
+ * Aggregate Discount per rule
+ *
+ * @param Quote $quote
+ * @return array
+ */
+ public function aggregateDiscountPerRule(
+ Quote $quote
+ ) {
+ $items = $quote->getItems();
+ $discountPerRule = [];
+ foreach ($items as $item) {
+ $discountBreakdown = $item->getExtensionAttributes()->getDiscounts();
+ if ($discountBreakdown) {
+ foreach ($discountBreakdown as $key => $value) {
+ /* @var \Magento\SalesRule\Model\Rule\Action\Discount\Data $discount */
+ $discount = $value['discount'];
+ $rule = $value['rule'];
+ if (isset($discountPerRule[$key])) {
+ /* @var \Magento\SalesRule\Model\Rule\Action\Discount\Data $ruleDiscount */
+ $ruleDiscount = $this->discountFactory->create();
+ /* @var \Magento\SalesRule\Model\Rule\Action\Discount\Data $discountData */
+ $discountData = $discountPerRule[$key]['discount'];
+ $ruleDiscount->setAmount($discountData->getAmount()+$discount->getAmount());
+ $ruleDiscount->setBaseAmount($discountData->getBaseAmount()+$discount->getBaseAmount());
+ $ruleDiscount->setOriginalAmount(
+ $discountData->getOriginalAmount()+$discount->getOriginalAmount()
+ );
+ $ruleDiscount->setBaseOriginalAmount(
+ $discountData->getBaseOriginalAmount()+$discount->getBaseOriginalAmount()
+ );
+ $discountPerRule[$key]['discount'] = $ruleDiscount;
+ $discountPerRule[$key]['rule'] = $rule;
+ } else {
+ $discountPerRule[$key]['discount'] = $discount;
+ $discountPerRule[$key]['rule'] = $rule;
+ }
+ }
+ }
+ }
+ return $discountPerRule;
+ }
+}
diff --git a/app/code/Magento/QuoteGraphQl/Model/Resolver/CartItemPrices.php b/app/code/Magento/QuoteGraphQl/Model/Resolver/CartItemPrices.php
index ec756336ea9c0..4daa7927feadb 100644
--- a/app/code/Magento/QuoteGraphQl/Model/Resolver/CartItemPrices.php
+++ b/app/code/Magento/QuoteGraphQl/Model/Resolver/CartItemPrices.php
@@ -87,9 +87,10 @@ public function resolve(Field $field, $context, ResolveInfo $info, array $value
*/
private function getDiscountValues($cartItem, $currencyCode)
{
- if ($cartItem->getDiscountBreakdown()) {
+ $itemDiscounts = $cartItem->getExtensionAttributes()->getDiscounts();
+ if ($itemDiscounts) {
$discountValues=[];
- foreach ($cartItem->getDiscountBreakdown() as $value) {
+ foreach ($itemDiscounts as $value) {
$discount = [];
$amount = [];
/* @var \Magento\SalesRule\Model\Rule\Action\Discount\Data $discountData */
diff --git a/app/code/Magento/QuoteGraphQl/Model/Resolver/CartPrices.php b/app/code/Magento/QuoteGraphQl/Model/Resolver/CartPrices.php
index cd380e40652a7..6a57a7662af09 100644
--- a/app/code/Magento/QuoteGraphQl/Model/Resolver/CartPrices.php
+++ b/app/code/Magento/QuoteGraphQl/Model/Resolver/CartPrices.php
@@ -57,7 +57,6 @@ public function resolve(Field $field, $context, ResolveInfo $info, array $value
],
'applied_taxes' => $this->getAppliedTaxes($cartTotals, $currency),
'discount' => $this->getDiscount($cartTotals, $currency),
- 'discounts' => $this->getDiscountValues($cartTotals, $quote),
'model' => $quote
];
}
@@ -104,33 +103,4 @@ private function getDiscount(Total $total, string $currency)
'amount' => ['value' => $total->getDiscountAmount(), 'currency' => $currency]
];
}
-
- /**
- * Get Discount Values
- *
- * @param Total $total
- * @param Quote $quote
- * @return array
- */
- private function getDiscountValues(Total $total, Quote $quote)
- {
- $discountValues=[];
- if ($total->getDiscounts()) {
- foreach ($total->getDiscounts() as $value) {
- $discount = [];
- $amount = [];
- /* @var \Magento\SalesRule\Model\Rule\Action\Discount\Data $discountData */
- $discountData = $value['discount'];
- /* @var \Magento\SalesRule\Model\Rule $rule*/
- $rule = $value['rule'];
- $discount['label'] = $rule->getStoreLabel($quote->getStore()) ?: __('Discount');
- $amount['value'] = $discountData->getAmount();
- $amount['currency'] = $quote->getQuoteCurrencyCode();
- $discount['amount'] = $amount;
- $discountValues[] = $discount;
- }
- return $discountValues;
- }
- return null;
- }
}
diff --git a/app/code/Magento/QuoteGraphQl/Model/Resolver/Discounts.php b/app/code/Magento/QuoteGraphQl/Model/Resolver/Discounts.php
new file mode 100644
index 0000000000000..5b8ae6e6a07f6
--- /dev/null
+++ b/app/code/Magento/QuoteGraphQl/Model/Resolver/Discounts.php
@@ -0,0 +1,77 @@
+discountAggregator = $discountAggregator;
+ }
+
+ /**
+ * @inheritdoc
+ */
+ public function resolve(Field $field, $context, ResolveInfo $info, array $value = null, array $args = null)
+ {
+ if (!isset($value['model'])) {
+ throw new LocalizedException(__('"model" value should be specified'));
+ }
+ $quote = $value['model'];
+
+ return $this->getDiscountValues($quote);
+ }
+
+ /**
+ * Get Discount Values
+ *
+ * @param Quote $quote
+ * @return array
+ */
+ private function getDiscountValues(Quote $quote)
+ {
+ $discountValues=[];
+ $totalDiscounts = $this->discountAggregator->aggregateDiscountPerRule($quote);
+ if ($totalDiscounts) {
+ foreach ($totalDiscounts as $value) {
+ $discount = [];
+ $amount = [];
+ /* @var \Magento\SalesRule\Model\Rule\Action\Discount\Data $discountData */
+ $discountData = $value['discount'];
+ /* @var \Magento\SalesRule\Model\Rule $rule*/
+ $rule = $value['rule'];
+ $discount['label'] = $rule->getStoreLabel($quote->getStore()) ?: __('Discount');
+ $amount['value'] = $discountData->getAmount();
+ $amount['currency'] = $quote->getQuoteCurrencyCode();
+ $discount['amount'] = $amount;
+ $discountValues[] = $discount;
+ }
+ return $discountValues;
+ }
+ return null;
+ }
+}
diff --git a/app/code/Magento/QuoteGraphQl/etc/schema.graphqls b/app/code/Magento/QuoteGraphQl/etc/schema.graphqls
index dbf2ec5204470..a1d536b627803 100644
--- a/app/code/Magento/QuoteGraphQl/etc/schema.graphqls
+++ b/app/code/Magento/QuoteGraphQl/etc/schema.graphqls
@@ -153,7 +153,7 @@ type CartPrices {
discount: CartDiscount @deprecated(reason: "Use discounts instead ")
subtotal_with_discount_excluding_tax: Money
applied_taxes: [CartTaxItem]
- discounts: [Discount] @doc(description:"An array of applied discounts")
+ discounts: [Discount] @doc(description:"An array of applied discounts") @resolver(class: "\\Magento\\QuoteGraphQl\\Model\\Resolver\\Discounts")
}
type CartTaxItem {
diff --git a/app/code/Magento/SalesRule/Model/Quote/Discount.php b/app/code/Magento/SalesRule/Model/Quote/Discount.php
index f269d07859f63..315ce874513a3 100644
--- a/app/code/Magento/SalesRule/Model/Quote/Discount.php
+++ b/app/code/Magento/SalesRule/Model/Quote/Discount.php
@@ -5,9 +5,6 @@
*/
namespace Magento\SalesRule\Model\Quote;
-use Magento\SalesRule\Model\Rule\Action\Discount\DataFactory;
-use Magento\Framework\App\ObjectManager;
-
/**
* Discount totals calculation model.
*/
@@ -39,31 +36,23 @@ class Discount extends \Magento\Quote\Model\Quote\Address\Total\AbstractTotal
*/
protected $priceCurrency;
- /**
- * @var DataFactory
- */
- private $discountFactory;
-
/**
* @param \Magento\Framework\Event\ManagerInterface $eventManager
* @param \Magento\Store\Model\StoreManagerInterface $storeManager
* @param \Magento\SalesRule\Model\Validator $validator
* @param \Magento\Framework\Pricing\PriceCurrencyInterface $priceCurrency
- * @param DataFactory $discountDataFactory
*/
public function __construct(
\Magento\Framework\Event\ManagerInterface $eventManager,
\Magento\Store\Model\StoreManagerInterface $storeManager,
\Magento\SalesRule\Model\Validator $validator,
- \Magento\Framework\Pricing\PriceCurrencyInterface $priceCurrency,
- DataFactory $discountDataFactory
+ \Magento\Framework\Pricing\PriceCurrencyInterface $priceCurrency
) {
$this->setCode(self::COLLECTOR_TYPE_CODE);
$this->eventManager = $eventManager;
$this->calculator = $validator;
$this->storeManager = $storeManager;
$this->priceCurrency = $priceCurrency;
- $this->discountFactory = $discountDataFactory ?: ObjectManager::getInstance()->get(DataFactory::class);
}
/**
@@ -138,7 +127,6 @@ public function collect(
$this->calculator->process($item);
$this->aggregateItemDiscount($item, $total);
}
- $this->aggregateDiscountPerRule($item, $total);
}
$this->calculator->prepareDescription($address);
@@ -230,51 +218,4 @@ public function fetch(\Magento\Quote\Model\Quote $quote, \Magento\Quote\Model\Qu
}
return $result;
}
-
- /**
- * Aggregate Discount per rule
- *
- * @param \Magento\Quote\Model\Quote\Item\AbstractItem $item
- * @param \Magento\Quote\Model\Quote\Address\Total $total
- * @return $this
- */
- private function aggregateDiscountPerRule(
- \Magento\Quote\Model\Quote\Item\AbstractItem $item,
- \Magento\Quote\Model\Quote\Address\Total $total
- ) {
- $discountBreakdown = $item->getDiscountBreakdown();
- if ($discountBreakdown) {
- foreach ($discountBreakdown as $key => $value) {
- $discountPerRule = $total->getDiscounts() ?? [];
- /**
- * @var \Magento\SalesRule\Model\Rule\Action\Discount\Data $discount
- */
- $discount = $value['discount'];
- $rule = $value['rule'];
- if (isset($discountPerRule[$key])) {
- /**
- * @var \Magento\SalesRule\Model\Rule\Action\Discount\Data $ruleDiscount
- */
- $ruleDiscount = $this->discountFactory->create();
- /**
- * @var \Magento\SalesRule\Model\Rule\Action\Discount\Data $discountData
- */
- $discountData = $discountPerRule[$key]['discount'];
- $ruleDiscount->setAmount($discountData->getAmount()+$discount->getAmount());
- $ruleDiscount->setBaseAmount($discountData->getBaseAmount()+$discount->getBaseAmount());
- $ruleDiscount->setOriginalAmount($discountData->getOriginalAmount()+$discount->getOriginalAmount());
- $ruleDiscount->setBaseOriginalAmount(
- $discountData->getBaseOriginalAmount()+$discount->getBaseOriginalAmount()
- );
- $discountPerRule[$key]['discount'] = $ruleDiscount;
- $discountPerRule[$key]['rule'] = $rule;
- } else {
- $discountPerRule[$key]['discount'] = $discount;
- $discountPerRule[$key]['rule'] = $rule;
- }
- $total->setDiscounts($discountPerRule);
- }
- }
- return $this;
- }
}
diff --git a/app/code/Magento/SalesRule/Model/RulesApplier.php b/app/code/Magento/SalesRule/Model/RulesApplier.php
index 5aaec6eefec01..71376c113467a 100644
--- a/app/code/Magento/SalesRule/Model/RulesApplier.php
+++ b/app/code/Magento/SalesRule/Model/RulesApplier.php
@@ -49,8 +49,8 @@ class RulesApplier
* @param CalculatorFactory $calculatorFactory
* @param \Magento\Framework\Event\ManagerInterface $eventManager
* @param Utility $utility
- * @param DataFactory $discountDataFactory
* @param ChildrenValidationLocator|null $childrenValidationLocator
+ * @param DataFactory $discountDataFactory
*/
public function __construct(
\Magento\SalesRule\Model\Rule\Action\Discount\CalculatorFactory $calculatorFactory,
@@ -209,10 +209,10 @@ private function setDiscountBreakdown($discountData, $item, $rule)
$discount->setAmount($discountData->getAmount());
$discount->setBaseAmount($discountData->getBaseAmount());
$discount->setOriginalAmount($discountData->getOriginalAmount());
- $discountBreakdown = $item->getDiscountBreakdown() ?? [];
+ $discountBreakdown = $item->getExtensionAttributes()->getDiscounts() ?? [];
$discountBreakdown[$rule->getId()]['discount'] = $discount;
$discountBreakdown[$rule->getId()]['rule'] = $rule;
- $item->setDiscountBreakdown($discountBreakdown);
+ $item->getExtensionAttributes()->setDiscounts($discountBreakdown);
return $this;
}
diff --git a/app/code/Magento/SalesRule/Test/Unit/Model/RulesApplierTest.php b/app/code/Magento/SalesRule/Test/Unit/Model/RulesApplierTest.php
index 217a8dba273c4..969e22d6d0e77 100644
--- a/app/code/Magento/SalesRule/Test/Unit/Model/RulesApplierTest.php
+++ b/app/code/Magento/SalesRule/Test/Unit/Model/RulesApplierTest.php
@@ -21,6 +21,11 @@ class RulesApplierTest extends \PHPUnit\Framework\TestCase
*/
protected $calculatorFactory;
+ /**
+ * @var \Magento\SalesRule\Model\Rule\Action\Discount\DataFactory|\PHPUnit_Framework_MockObject_MockObject
+ */
+ protected $discountFactory;
+
/**
* @var \Magento\Framework\Event\Manager|\PHPUnit_Framework_MockObject_MockObject
*/
@@ -41,6 +46,10 @@ protected function setUp()
$this->calculatorFactory = $this->createMock(
\Magento\SalesRule\Model\Rule\Action\Discount\CalculatorFactory::class
);
+ $this->discountFactory = $this->createPartialMock(
+ \Magento\SalesRule\Model\Rule\Action\Discount\DataFactory::class,
+ ['create']
+ );
$this->eventManager = $this->createPartialMock(\Magento\Framework\Event\Manager::class, ['dispatch']);
$this->validatorUtility = $this->createPartialMock(
\Magento\SalesRule\Model\Utility::class,
@@ -54,7 +63,8 @@ protected function setUp()
$this->calculatorFactory,
$this->eventManager,
$this->validatorUtility,
- $this->childrenValidationLocator
+ $this->childrenValidationLocator,
+ $this->discountFactory
);
}
@@ -73,7 +83,20 @@ public function testApplyRulesWhenRuleWithStopRulesProcessingIsUsed($isChildren,
$ruleId = 1;
$appliedRuleIds = [$ruleId => $ruleId];
-
+ $discountData = $this->getMockBuilder(\Magento\SalesRule\Model\Rule\Action\Discount\Data::class)
+ ->setConstructorArgs(
+ [
+ 'amount' => 0,
+ 'baseAmount' => 0,
+ 'originalAmount' => 0,
+ 'baseOriginalAmount' => 0
+ ]
+ )
+ ->getMock();
+ $this->discountFactory->expects($this->any())
+ ->method('create')
+ ->with($this->anything())
+ ->will($this->returnValue($discountData));
/**
* @var \Magento\SalesRule\Model\Rule|\PHPUnit_Framework_MockObject_MockObject $ruleWithStopFurtherProcessing
*/
@@ -157,14 +180,19 @@ public function dataProviderChildren()
protected function getPreparedItem()
{
/** @var \Magento\Quote\Model\Quote\Address|\PHPUnit_Framework_MockObject_MockObject $address */
- $address = $this->createPartialMock(\Magento\Quote\Model\Quote\Address::class, [
+ $address = $this->createPartialMock(
+ \Magento\Quote\Model\Quote\Address::class,
+ [
'getQuote',
'setCouponCode',
'setAppliedRuleIds',
'__wakeup'
- ]);
+ ]
+ );
/** @var \Magento\Quote\Model\Quote\Item\AbstractItem|\PHPUnit_Framework_MockObject_MockObject $item */
- $item = $this->createPartialMock(\Magento\Quote\Model\Quote\Item::class, [
+ $item = $this->createPartialMock(
+ \Magento\Quote\Model\Quote\Item::class,
+ [
'setDiscountAmount',
'setBaseDiscountAmount',
'setDiscountPercent',
@@ -172,7 +200,8 @@ protected function getPreparedItem()
'setAppliedRuleIds',
'__wakeup',
'getChildren'
- ]);
+ ]
+ );
$quote = $this->createPartialMock(\Magento\Quote\Model\Quote::class, ['getStore', '__wakeUp']);
$item->expects($this->any())->method('getAddress')->will($this->returnValue($address));
$address->expects($this->any())
diff --git a/app/code/Magento/SalesRule/etc/extension_attributes.xml b/app/code/Magento/SalesRule/etc/extension_attributes.xml
new file mode 100644
index 0000000000000..5fba88c747fe1
--- /dev/null
+++ b/app/code/Magento/SalesRule/etc/extension_attributes.xml
@@ -0,0 +1,12 @@
+
+
+
+
+
+
+
From 397ce47c8d62b24ac6bdb0e7a2438d363312462c Mon Sep 17 00:00:00 2001
From: Vinicius Dziuba
Date: Tue, 17 Sep 2019 14:40:56 -0300
Subject: [PATCH 337/937] magento/magento2#24511:Click "What 's this" link
scroll to the top of page
- changed the tag for the strong tag and took the href.
---
.../Persistent/view/frontend/templates/remember_me.phtml | 8 ++------
.../view/frontend/web/template/remember-me.html | 7 ++-----
2 files changed, 4 insertions(+), 11 deletions(-)
diff --git a/app/code/Magento/Persistent/view/frontend/templates/remember_me.phtml b/app/code/Magento/Persistent/view/frontend/templates/remember_me.phtml
index c0f1332d3d0e7..ba55895453a09 100644
--- a/app/code/Magento/Persistent/view/frontend/templates/remember_me.phtml
+++ b/app/code/Magento/Persistent/view/frontend/templates/remember_me.phtml
@@ -17,11 +17,7 @@
isRememberMeChecked()) : ?> checked="checked" title="= $block->escapeHtmlAttr(__('Remember Me')) ?>" />
= $block->escapeHtml(__('Remember Me')) ?>
-
- = $block->escapeHtml(__('What\'s this?')) ?>
-
-
- = $block->escapeHtml(__('Check "Remember Me" to access your shopping cart on this computer even if you are not signed in.')) ?>
-
+ = $block->escapeHtml(__('What\'s this?')) ?>
+ = $block->escapeHtml(__('Check "Remember Me" to access your shopping cart on this computer even if you are not signed in.')) ?>
diff --git a/app/code/Magento/Persistent/view/frontend/web/template/remember-me.html b/app/code/Magento/Persistent/view/frontend/web/template/remember-me.html
index ac83d6767d4e0..427e6bdcd63ab 100644
--- a/app/code/Magento/Persistent/view/frontend/web/template/remember-me.html
+++ b/app/code/Magento/Persistent/view/frontend/web/template/remember-me.html
@@ -6,13 +6,10 @@
-->
-
+
-
-
+
From 02989b05b9ddbb5f2cfa199e59adc26ffe55b76d Mon Sep 17 00:00:00 2001
From: Cristian Partica
Date: Tue, 17 Sep 2019 12:57:05 -0500
Subject: [PATCH 338/937] MC-18996: GraphQl Url Resolver doesn't return any
results if the url_key doesn't have the extension
- add tests
---
.../UrlRewriteGraphQl/etc/schema.graphqls | 2 +-
.../CatalogUrlRewrite/UrlResolverTest.php | 391 ++++++++++++++++++
.../GraphQl/CmsUrlRewrite/UrlResolverTest.php | 101 +++++
.../GraphQl/UrlRewrite/UrlResolverTest.php | 374 +----------------
4 files changed, 494 insertions(+), 374 deletions(-)
create mode 100644 dev/tests/api-functional/testsuite/Magento/GraphQl/CatalogUrlRewrite/UrlResolverTest.php
create mode 100644 dev/tests/api-functional/testsuite/Magento/GraphQl/CmsUrlRewrite/UrlResolverTest.php
diff --git a/app/code/Magento/UrlRewriteGraphQl/etc/schema.graphqls b/app/code/Magento/UrlRewriteGraphQl/etc/schema.graphqls
index 92d237d3f01e1..e7291aae4b8e2 100644
--- a/app/code/Magento/UrlRewriteGraphQl/etc/schema.graphqls
+++ b/app/code/Magento/UrlRewriteGraphQl/etc/schema.graphqls
@@ -2,7 +2,7 @@
# See COPYING.txt for license details.
type Query {
- urlResolver(url: String!): EntityUrl @resolver(class: "Magento\\UrlRewriteGraphQl\\Model\\Resolver\\EntityUrl") @doc(description: "The urlResolver query returns the relative URL for a specified product, category or CMS page") @cache(cacheIdentity: "Magento\\UrlRewriteGraphQl\\Model\\Resolver\\UrlRewrite\\UrlResolverIdentity")
+ urlResolver(url: String!): EntityUrl @resolver(class: "Magento\\UrlRewriteGraphQl\\Model\\Resolver\\EntityUrl") @doc(description: "The urlResolver query returns the relative URL for a specified product, category or CMS page, using as input a url_key prepended by the url_suffix, if one exists") @cache(cacheIdentity: "Magento\\UrlRewriteGraphQl\\Model\\Resolver\\UrlRewrite\\UrlResolverIdentity")
}
type EntityUrl @doc(description: "EntityUrl is an output object containing the `id`, `relative_url`, and `type` attributes") {
diff --git a/dev/tests/api-functional/testsuite/Magento/GraphQl/CatalogUrlRewrite/UrlResolverTest.php b/dev/tests/api-functional/testsuite/Magento/GraphQl/CatalogUrlRewrite/UrlResolverTest.php
new file mode 100644
index 0000000000000..1b2776e66b7e7
--- /dev/null
+++ b/dev/tests/api-functional/testsuite/Magento/GraphQl/CatalogUrlRewrite/UrlResolverTest.php
@@ -0,0 +1,391 @@
+objectManager = \Magento\TestFramework\Helper\Bootstrap::getObjectManager();
+ }
+
+ /**
+ * Tests if target_path(relative_url) is resolved for Product entity
+ *
+ * @magentoApiDataFixture Magento/CatalogUrlRewrite/_files/product_with_category.php
+ */
+ public function testProductUrlResolver()
+ {
+ $productSku = 'p002';
+ /** @var ProductRepositoryInterface $productRepository */
+ $productRepository = $this->objectManager->get(ProductRepositoryInterface::class);
+ $product = $productRepository->get($productSku, false, null, true);
+ $storeId = $product->getStoreId();
+
+ $query
+ = <<graphQlQuery($query);
+ $urlPath = $response['products']['items'][0]['url_key'] . $response['products']['items'][0]['url_suffix'];
+
+ /** @var UrlFinderInterface $urlFinder */
+ $urlFinder = $this->objectManager->get(UrlFinderInterface::class);
+ $actualUrls = $urlFinder->findOneByData(
+ [
+ 'request_path' => $urlPath,
+ 'store_id' => $storeId
+ ]
+ );
+ $targetPath = $actualUrls->getTargetPath();
+ $expectedType = $actualUrls->getEntityType();
+
+ $query
+ = <<graphQlQuery($query);
+ $this->assertArrayHasKey('urlResolver', $response);
+ $this->assertEquals($product->getEntityId(), $response['urlResolver']['id']);
+ $this->assertEquals($targetPath, $response['urlResolver']['relative_url']);
+ $this->assertEquals(strtoupper($expectedType), $response['urlResolver']['type']);
+ }
+
+ /**
+ * Tests the use case where relative_url is provided as resolver input in the Query
+ *
+ * @magentoApiDataFixture Magento/CatalogUrlRewrite/_files/product_with_category.php
+ */
+ public function testProductUrlWithCanonicalUrlInput()
+ {
+ $productSku = 'p002';
+ /** @var ProductRepositoryInterface $productRepository */
+ $productRepository = $this->objectManager->get(ProductRepositoryInterface::class);
+ $product = $productRepository->get($productSku, false, null, true);
+ $storeId = $product->getStoreId();
+
+ $query
+ = <<graphQlQuery($query);
+ $urlPath = $response['products']['items'][0]['url_key'] . $response['products']['items'][0]['url_suffix'];
+
+ /** @var UrlFinderInterface $urlFinder */
+ $urlFinder = $this->objectManager->get(UrlFinderInterface::class);
+ $actualUrls = $urlFinder->findOneByData(
+ [
+ 'request_path' => $urlPath,
+ 'store_id' => $storeId
+ ]
+ );
+ $targetPath = $actualUrls->getTargetPath();
+ $expectedType = $actualUrls->getEntityType();
+ $canonicalPath = $actualUrls->getTargetPath();
+ $query
+ = <<graphQlQuery($query);
+ $this->assertArrayHasKey('urlResolver', $response);
+ $this->assertEquals($product->getEntityId(), $response['urlResolver']['id']);
+ $this->assertEquals($targetPath, $response['urlResolver']['relative_url']);
+ $this->assertEquals(strtoupper($expectedType), $response['urlResolver']['type']);
+ }
+
+ /**
+ * Test for category entity
+ *
+ * @magentoApiDataFixture Magento/CatalogUrlRewrite/_files/product_with_category.php
+ */
+ public function testCategoryUrlResolver()
+ {
+ $productSku = 'p002';
+ $categoryUrlPath = 'cat-1.html';
+ /** @var ProductRepositoryInterface $productRepository */
+ $productRepository = $this->objectManager->get(ProductRepositoryInterface::class);
+ $product = $productRepository->get($productSku, false, null, true);
+ $storeId = $product->getStoreId();
+
+ /** @var UrlFinderInterface $urlFinder */
+ $urlFinder = $this->objectManager->get(UrlFinderInterface::class);
+ $actualUrls = $urlFinder->findOneByData(
+ [
+ 'request_path' => $categoryUrlPath,
+ 'store_id' => $storeId
+ ]
+ );
+ $categoryId = $actualUrls->getEntityId();
+ $targetPath = $actualUrls->getTargetPath();
+ $expectedType = $actualUrls->getEntityType();
+
+ $query
+ = <<graphQlQuery($query);
+ $urlPath = $response['category']['url_key'] . $response['category']['url_suffix'];
+
+ $query
+ = <<graphQlQuery($query);
+ $this->assertArrayHasKey('urlResolver', $response);
+ $this->assertEquals($categoryId, $response['urlResolver']['id']);
+ $this->assertEquals($targetPath, $response['urlResolver']['relative_url']);
+ $this->assertEquals(strtoupper($expectedType), $response['urlResolver']['type']);
+ }
+
+ /**
+ * Tests the use case where the url_key of the existing product is changed
+ *
+ * @magentoApiDataFixture Magento/CatalogUrlRewrite/_files/product_with_category.php
+ */
+ public function testProductUrlRewriteResolver()
+ {
+ $productSku = 'p002';
+ /** @var ProductRepositoryInterface $productRepository */
+ $productRepository = $this->objectManager->get(ProductRepositoryInterface::class);
+ $product = $productRepository->get($productSku, false, null, true);
+ $storeId = $product->getStoreId();
+ $product->setUrlKey('p002-new')->save();
+
+ $query
+ = <<graphQlQuery($query);
+ $urlPath = $response['products']['items'][0]['url_key'] . $response['products']['items'][0]['url_suffix'];
+
+ $this->assertEquals($urlPath, 'p002-new' . $response['products']['items'][0]['url_suffix']);
+
+ /** @var UrlFinderInterface $urlFinder */
+ $urlFinder = $this->objectManager->get(UrlFinderInterface::class);
+ $actualUrls = $urlFinder->findOneByData(
+ [
+ 'request_path' => $urlPath,
+ 'store_id' => $storeId
+ ]
+ );
+ $targetPath = $actualUrls->getTargetPath();
+ $expectedType = $actualUrls->getEntityType();
+ $query
+ = <<graphQlQuery($query);
+ $this->assertArrayHasKey('urlResolver', $response);
+ $this->assertEquals($product->getEntityId(), $response['urlResolver']['id']);
+ $this->assertEquals($targetPath, $response['urlResolver']['relative_url']);
+ $this->assertEquals(strtoupper($expectedType), $response['urlResolver']['type']);
+ }
+
+ /**
+ * Tests if null is returned when an invalid request_path is provided as input to urlResolver
+ *
+ * @magentoApiDataFixture Magento/CatalogUrlRewrite/_files/product_with_category.php
+ */
+ public function testInvalidUrlResolverInput()
+ {
+ $productSku = 'p002';
+ $urlPath = 'p002';
+ /** @var ProductRepositoryInterface $productRepository */
+ $productRepository = $this->objectManager->get(ProductRepositoryInterface::class);
+ $product = $productRepository->get($productSku, false, null, true);
+ $storeId = $product->getStoreId();
+
+ /** @var UrlFinderInterface $urlFinder */
+ $urlFinder = $this->objectManager->get(UrlFinderInterface::class);
+ $urlFinder->findOneByData(
+ [
+ 'request_path' => $urlPath,
+ 'store_id' => $storeId
+ ]
+ );
+ $query
+ = <<graphQlQuery($query);
+ $this->assertArrayHasKey('urlResolver', $response);
+ $this->assertNull($response['urlResolver']);
+ }
+
+ /**
+ * Test for category entity with leading slash
+ *
+ * @magentoApiDataFixture Magento/CatalogUrlRewrite/_files/product_with_category.php
+ */
+ public function testCategoryUrlWithLeadingSlash()
+ {
+ $productSku = 'p002';
+ $categoryUrlPath = 'cat-1.html';
+ /** @var ProductRepositoryInterface $productRepository */
+ $productRepository = $this->objectManager->get(ProductRepositoryInterface::class);
+ $product = $productRepository->get($productSku, false, null, true);
+ $storeId = $product->getStoreId();
+
+ /** @var UrlFinderInterface $urlFinder */
+ $urlFinder = $this->objectManager->get(UrlFinderInterface::class);
+ $actualUrls = $urlFinder->findOneByData(
+ [
+ 'request_path' => $categoryUrlPath,
+ 'store_id' => $storeId
+ ]
+ );
+ $categoryId = $actualUrls->getEntityId();
+ $targetPath = $actualUrls->getTargetPath();
+ $expectedType = $actualUrls->getEntityType();
+
+ $query
+ = <<graphQlQuery($query);
+ $urlPath = $response['category']['url_key'] . $response['category']['url_suffix'];
+
+ $query = <<graphQlQuery($query);
+ $this->assertArrayHasKey('urlResolver', $response);
+ $this->assertEquals($categoryId, $response['urlResolver']['id']);
+ $this->assertEquals($targetPath, $response['urlResolver']['relative_url']);
+ $this->assertEquals(strtoupper($expectedType), $response['urlResolver']['type']);
+ }
+
+ /**
+ * Test for custom type which point to the valid product/category/cms page.
+ *
+ * @magentoApiDataFixture Magento/CatalogUrlRewrite/_files/product_with_category.php
+ */
+ public function testGetNonExistentUrlRewrite()
+ {
+ $urlPath = 'non-exist-product.html';
+ /** @var UrlRewrite $urlRewrite */
+ $urlRewrite = $this->objectManager->create(UrlRewrite::class);
+ $urlRewrite->load($urlPath, 'request_path');
+
+ /** @var UrlFinderInterface $urlFinder */
+ $urlFinder = $this->objectManager->get(UrlFinderInterface::class);
+ $actualUrls = $urlFinder->findOneByData(
+ [
+ 'request_path' => $urlPath,
+ 'store_id' => 1
+ ]
+ );
+ $targetPath = $actualUrls->getTargetPath();
+
+ $query = <<graphQlQuery($query);
+ $this->assertArrayHasKey('urlResolver', $response);
+ $this->assertEquals('PRODUCT', $response['urlResolver']['type']);
+ $this->assertEquals($targetPath, $response['urlResolver']['relative_url']);
+ }
+}
diff --git a/dev/tests/api-functional/testsuite/Magento/GraphQl/CmsUrlRewrite/UrlResolverTest.php b/dev/tests/api-functional/testsuite/Magento/GraphQl/CmsUrlRewrite/UrlResolverTest.php
new file mode 100644
index 0000000000000..ece421925a31c
--- /dev/null
+++ b/dev/tests/api-functional/testsuite/Magento/GraphQl/CmsUrlRewrite/UrlResolverTest.php
@@ -0,0 +1,101 @@
+objectManager = \Magento\TestFramework\Helper\Bootstrap::getObjectManager();
+ }
+
+ /**
+ * @magentoApiDataFixture Magento/Cms/_files/pages.php
+ */
+ public function testCMSPageUrlResolver()
+ {
+ /** @var \Magento\Cms\Model\Page $page */
+ $page = $this->objectManager->get(\Magento\Cms\Model\Page::class);
+ $page->load('page100');
+ $cmsPageId = $page->getId();
+ $requestPath = $page->getIdentifier();
+
+ /** @var \Magento\CmsUrlRewrite\Model\CmsPageUrlPathGenerator $urlPathGenerator */
+ $urlPathGenerator = $this->objectManager->get(\Magento\CmsUrlRewrite\Model\CmsPageUrlPathGenerator::class);
+
+ /** @param \Magento\Cms\Api\Data\PageInterface $page */
+ $targetPath = $urlPathGenerator->getCanonicalUrlPath($page);
+ $expectedEntityType = CmsPageUrlRewriteGenerator::ENTITY_TYPE;
+
+ $query
+ = <<graphQlQuery($query);
+ $this->assertEquals($cmsPageId, $response['urlResolver']['id']);
+ $this->assertEquals($targetPath, $response['urlResolver']['relative_url']);
+ $this->assertEquals(strtoupper(str_replace('-', '_', $expectedEntityType)), $response['urlResolver']['type']);
+ }
+
+ /**
+ * Test resolution of '/' path to home page
+ */
+ public function testResolveSlash()
+ {
+ /** @var \Magento\Framework\App\Config\ScopeConfigInterface $scopeConfigInterface */
+ $scopeConfigInterface = $this->objectManager->get(ScopeConfigInterface::class);
+ $homePageIdentifier = $scopeConfigInterface->getValue(
+ PageHelper::XML_PATH_HOME_PAGE,
+ ScopeInterface::SCOPE_STORE
+ );
+ /** @var \Magento\Cms\Model\Page $page */
+ $page = $this->objectManager->get(\Magento\Cms\Model\Page::class);
+ $page->load($homePageIdentifier);
+ $homePageId = $page->getId();
+ /** @var \Magento\CmsUrlRewrite\Model\CmsPageUrlPathGenerator $urlPathGenerator */
+ $urlPathGenerator = $this->objectManager->get(\Magento\CmsUrlRewrite\Model\CmsPageUrlPathGenerator::class);
+ /** @param \Magento\Cms\Api\Data\PageInterface $page */
+ $targetPath = $urlPathGenerator->getCanonicalUrlPath($page);
+ $query
+ = <<graphQlQuery($query);
+ $this->assertArrayHasKey('urlResolver', $response);
+ $this->assertEquals($homePageId, $response['urlResolver']['id']);
+ $this->assertEquals($targetPath, $response['urlResolver']['relative_url']);
+ $this->assertEquals('CMS_PAGE', $response['urlResolver']['type']);
+ }
+}
diff --git a/dev/tests/api-functional/testsuite/Magento/GraphQl/UrlRewrite/UrlResolverTest.php b/dev/tests/api-functional/testsuite/Magento/GraphQl/UrlRewrite/UrlResolverTest.php
index 8eaf33483531d..bd20741fb7417 100644
--- a/dev/tests/api-functional/testsuite/Magento/GraphQl/UrlRewrite/UrlResolverTest.php
+++ b/dev/tests/api-functional/testsuite/Magento/GraphQl/UrlRewrite/UrlResolverTest.php
@@ -7,23 +7,15 @@
namespace Magento\GraphQl\UrlRewrite;
-use Magento\Catalog\Api\ProductRepositoryInterface;
-use Magento\CmsUrlRewrite\Model\CmsPageUrlRewriteGenerator;
use Magento\TestFramework\ObjectManager;
use Magento\TestFramework\TestCase\GraphQlAbstract;
-use Magento\UrlRewrite\Model\UrlFinderInterface;
-use Magento\Cms\Helper\Page as PageHelper;
-use Magento\Store\Model\ScopeInterface;
-use Magento\Framework\App\Config\ScopeConfigInterface;
-use Magento\UrlRewrite\Model\UrlRewrite;
/**
* Test the GraphQL endpoint's URLResolver query to verify canonical URL's are correctly returned.
*/
class UrlResolverTest extends GraphQlAbstract
{
-
- /** @var ObjectManager */
+ /** @var ObjectManager */
private $objectManager;
protected function setUp()
@@ -31,370 +23,6 @@ protected function setUp()
$this->objectManager = \Magento\TestFramework\Helper\Bootstrap::getObjectManager();
}
- /**
- * Tests if target_path(relative_url) is resolved for Product entity
- *
- * @magentoApiDataFixture Magento/CatalogUrlRewrite/_files/product_with_category.php
- */
- public function testProductUrlResolver()
- {
- $productSku = 'p002';
- $urlPath = 'p002.html';
- /** @var ProductRepositoryInterface $productRepository */
- $productRepository = $this->objectManager->get(ProductRepositoryInterface::class);
- $product = $productRepository->get($productSku, false, null, true);
- $storeId = $product->getStoreId();
-
- /** @var UrlFinderInterface $urlFinder */
- $urlFinder = $this->objectManager->get(UrlFinderInterface::class);
- $actualUrls = $urlFinder->findOneByData(
- [
- 'request_path' => $urlPath,
- 'store_id' => $storeId
- ]
- );
- $targetPath = $actualUrls->getTargetPath();
- $expectedType = $actualUrls->getEntityType();
- $query
- = <<graphQlQuery($query);
- $this->assertArrayHasKey('urlResolver', $response);
- $this->assertEquals($product->getEntityId(), $response['urlResolver']['id']);
- $this->assertEquals($targetPath, $response['urlResolver']['relative_url']);
- $this->assertEquals(strtoupper($expectedType), $response['urlResolver']['type']);
- }
-
- /**
- * Tests the use case where relative_url is provided as resolver input in the Query
- *
- * @magentoApiDataFixture Magento/CatalogUrlRewrite/_files/product_with_category.php
- */
- public function testProductUrlWithCanonicalUrlInput()
- {
- $productSku = 'p002';
- $urlPath = 'p002.html';
- /** @var ProductRepositoryInterface $productRepository */
- $productRepository = $this->objectManager->get(ProductRepositoryInterface::class);
- $product = $productRepository->get($productSku, false, null, true);
- $storeId = $product->getStoreId();
- $product->getUrlKey();
-
- /** @var UrlFinderInterface $urlFinder */
- $urlFinder = $this->objectManager->get(UrlFinderInterface::class);
- $actualUrls = $urlFinder->findOneByData(
- [
- 'request_path' => $urlPath,
- 'store_id' => $storeId
- ]
- );
- $targetPath = $actualUrls->getTargetPath();
- $expectedType = $actualUrls->getEntityType();
- $canonicalPath = $actualUrls->getTargetPath();
- $query
- = <<graphQlQuery($query);
- $this->assertArrayHasKey('urlResolver', $response);
- $this->assertEquals($product->getEntityId(), $response['urlResolver']['id']);
- $this->assertEquals($targetPath, $response['urlResolver']['relative_url']);
- $this->assertEquals(strtoupper($expectedType), $response['urlResolver']['type']);
- }
-
- /**
- * Test for category entity
- *
- * @magentoApiDataFixture Magento/CatalogUrlRewrite/_files/product_with_category.php
- */
- public function testCategoryUrlResolver()
- {
- $productSku = 'p002';
- $urlPath2 = 'cat-1.html';
- /** @var ProductRepositoryInterface $productRepository */
- $productRepository = $this->objectManager->get(ProductRepositoryInterface::class);
- $product = $productRepository->get($productSku, false, null, true);
- $storeId = $product->getStoreId();
-
- /** @var UrlFinderInterface $urlFinder */
- $urlFinder = $this->objectManager->get(UrlFinderInterface::class);
- $actualUrls = $urlFinder->findOneByData(
- [
- 'request_path' => $urlPath2,
- 'store_id' => $storeId
- ]
- );
- $categoryId = $actualUrls->getEntityId();
- $targetPath = $actualUrls->getTargetPath();
- $expectedType = $actualUrls->getEntityType();
- $query
- = <<graphQlQuery($query);
- $this->assertArrayHasKey('urlResolver', $response);
- $this->assertEquals($categoryId, $response['urlResolver']['id']);
- $this->assertEquals($targetPath, $response['urlResolver']['relative_url']);
- $this->assertEquals(strtoupper($expectedType), $response['urlResolver']['type']);
- }
-
- /**
- * @magentoApiDataFixture Magento/Cms/_files/pages.php
- */
- public function testCMSPageUrlResolver()
- {
- /** @var \Magento\Cms\Model\Page $page */
- $page = $this->objectManager->get(\Magento\Cms\Model\Page::class);
- $page->load('page100');
- $cmsPageId = $page->getId();
- $requestPath = $page->getIdentifier();
-
- /** @var \Magento\CmsUrlRewrite\Model\CmsPageUrlPathGenerator $urlPathGenerator */
- $urlPathGenerator = $this->objectManager->get(\Magento\CmsUrlRewrite\Model\CmsPageUrlPathGenerator::class);
-
- /** @param \Magento\Cms\Api\Data\PageInterface $page */
- $targetPath = $urlPathGenerator->getCanonicalUrlPath($page);
- $expectedEntityType = CmsPageUrlRewriteGenerator::ENTITY_TYPE;
-
- $query
- = <<graphQlQuery($query);
- $this->assertEquals($cmsPageId, $response['urlResolver']['id']);
- $this->assertEquals($targetPath, $response['urlResolver']['relative_url']);
- $this->assertEquals(strtoupper(str_replace('-', '_', $expectedEntityType)), $response['urlResolver']['type']);
- }
-
- /**
- * Tests the use case where the url_key of the existing product is changed
- *
- * @magentoApiDataFixture Magento/CatalogUrlRewrite/_files/product_with_category.php
- */
- public function testProductUrlRewriteResolver()
- {
- $productSku = 'p002';
- /** @var ProductRepositoryInterface $productRepository */
- $productRepository = $this->objectManager->get(ProductRepositoryInterface::class);
- $product = $productRepository->get($productSku, false, null, true);
- $storeId = $product->getStoreId();
- $product->setUrlKey('p002-new')->save();
- $urlPath = $product->getUrlKey() . '.html';
- $this->assertEquals($urlPath, 'p002-new.html');
-
- /** @var UrlFinderInterface $urlFinder */
- $urlFinder = $this->objectManager->get(UrlFinderInterface::class);
- $actualUrls = $urlFinder->findOneByData(
- [
- 'request_path' => $urlPath,
- 'store_id' => $storeId
- ]
- );
- $targetPath = $actualUrls->getTargetPath();
- $expectedType = $actualUrls->getEntityType();
- $query
- = <<graphQlQuery($query);
- $this->assertArrayHasKey('urlResolver', $response);
- $this->assertEquals($product->getEntityId(), $response['urlResolver']['id']);
- $this->assertEquals($targetPath, $response['urlResolver']['relative_url']);
- $this->assertEquals(strtoupper($expectedType), $response['urlResolver']['type']);
- }
-
- /**
- * Tests if null is returned when an invalid request_path is provided as input to urlResolver
- *
- * @magentoApiDataFixture Magento/CatalogUrlRewrite/_files/product_with_category.php
- */
- public function testInvalidUrlResolverInput()
- {
- $productSku = 'p002';
- $urlPath = 'p002';
- /** @var ProductRepositoryInterface $productRepository */
- $productRepository = $this->objectManager->get(ProductRepositoryInterface::class);
- $product = $productRepository->get($productSku, false, null, true);
- $storeId = $product->getStoreId();
-
- /** @var UrlFinderInterface $urlFinder */
- $urlFinder = $this->objectManager->get(UrlFinderInterface::class);
- $urlFinder->findOneByData(
- [
- 'request_path' => $urlPath,
- 'store_id' => $storeId
- ]
- );
- $query
- = <<graphQlQuery($query);
- $this->assertArrayHasKey('urlResolver', $response);
- $this->assertNull($response['urlResolver']);
- }
-
- /**
- * Test for category entity with leading slash
- *
- * @magentoApiDataFixture Magento/CatalogUrlRewrite/_files/product_with_category.php
- */
- public function testCategoryUrlWithLeadingSlash()
- {
- $productSku = 'p002';
- $urlPath = 'cat-1.html';
- /** @var ProductRepositoryInterface $productRepository */
- $productRepository = $this->objectManager->get(ProductRepositoryInterface::class);
- $product = $productRepository->get($productSku, false, null, true);
- $storeId = $product->getStoreId();
-
- /** @var UrlFinderInterface $urlFinder */
- $urlFinder = $this->objectManager->get(UrlFinderInterface::class);
- $actualUrls = $urlFinder->findOneByData(
- [
- 'request_path' => $urlPath,
- 'store_id' => $storeId
- ]
- );
- $categoryId = $actualUrls->getEntityId();
- $targetPath = $actualUrls->getTargetPath();
- $expectedType = $actualUrls->getEntityType();
-
- $query = <<graphQlQuery($query);
- $this->assertArrayHasKey('urlResolver', $response);
- $this->assertEquals($categoryId, $response['urlResolver']['id']);
- $this->assertEquals($targetPath, $response['urlResolver']['relative_url']);
- $this->assertEquals(strtoupper($expectedType), $response['urlResolver']['type']);
- }
-
- /**
- * Test resolution of '/' path to home page
- */
- public function testResolveSlash()
- {
- /** @var \Magento\Framework\App\Config\ScopeConfigInterface $scopeConfigInterface */
- $scopeConfigInterface = $this->objectManager->get(ScopeConfigInterface::class);
- $homePageIdentifier = $scopeConfigInterface->getValue(
- PageHelper::XML_PATH_HOME_PAGE,
- ScopeInterface::SCOPE_STORE
- );
- /** @var \Magento\Cms\Model\Page $page */
- $page = $this->objectManager->get(\Magento\Cms\Model\Page::class);
- $page->load($homePageIdentifier);
- $homePageId = $page->getId();
- /** @var \Magento\CmsUrlRewrite\Model\CmsPageUrlPathGenerator $urlPathGenerator */
- $urlPathGenerator = $this->objectManager->get(\Magento\CmsUrlRewrite\Model\CmsPageUrlPathGenerator::class);
- /** @param \Magento\Cms\Api\Data\PageInterface $page */
- $targetPath = $urlPathGenerator->getCanonicalUrlPath($page);
- $query
- = <<graphQlQuery($query);
- $this->assertArrayHasKey('urlResolver', $response);
- $this->assertEquals($homePageId, $response['urlResolver']['id']);
- $this->assertEquals($targetPath, $response['urlResolver']['relative_url']);
- $this->assertEquals('CMS_PAGE', $response['urlResolver']['type']);
- }
-
- /**
- * Test for custom type which point to the valid product/category/cms page.
- *
- * @magentoApiDataFixture Magento/CatalogUrlRewrite/_files/product_with_category.php
- */
- public function testGetNonExistentUrlRewrite()
- {
- $urlPath = 'non-exist-product.html';
- /** @var UrlRewrite $urlRewrite */
- $urlRewrite = $this->objectManager->create(UrlRewrite::class);
- $urlRewrite->load($urlPath, 'request_path');
-
- /** @var UrlFinderInterface $urlFinder */
- $urlFinder = $this->objectManager->get(UrlFinderInterface::class);
- $actualUrls = $urlFinder->findOneByData(
- [
- 'request_path' => $urlPath,
- 'store_id' => 1
- ]
- );
- $targetPath = $actualUrls->getTargetPath();
-
- $query = <<graphQlQuery($query);
- $this->assertArrayHasKey('urlResolver', $response);
- $this->assertEquals('PRODUCT', $response['urlResolver']['type']);
- $this->assertEquals($targetPath, $response['urlResolver']['relative_url']);
- }
-
/**
* Test for custom type which point to the invalid product/category/cms page.
*
From d0773c440b3ae95d83b84969f9e8569a50c77de6 Mon Sep 17 00:00:00 2001
From: Cristian Partica
Date: Tue, 17 Sep 2019 13:30:49 -0500
Subject: [PATCH 339/937] MC-18996: GraphQl Url Resolver doesn't return any
results if the url_key doesn't have the extension
- fix code review in category class
---
.../Model/Resolver/CategoryUrlSuffix.php | 25 +++++++++++--------
.../Model/Resolver/ProductUrlSuffix.php | 13 ++++++----
.../UrlRewriteGraphQl/etc/schema.graphqls | 2 +-
3 files changed, 23 insertions(+), 17 deletions(-)
diff --git a/app/code/Magento/CatalogUrlRewriteGraphQl/Model/Resolver/CategoryUrlSuffix.php b/app/code/Magento/CatalogUrlRewriteGraphQl/Model/Resolver/CategoryUrlSuffix.php
index ba33f56f472d2..59708d90c23b7 100644
--- a/app/code/Magento/CatalogUrlRewriteGraphQl/Model/Resolver/CategoryUrlSuffix.php
+++ b/app/code/Magento/CatalogUrlRewriteGraphQl/Model/Resolver/CategoryUrlSuffix.php
@@ -19,14 +19,19 @@
*/
class CategoryUrlSuffix implements ResolverInterface
{
- const XML_PATH_PRODUCT_URL_SUFFIX = 'catalog/seo/category_url_suffix';
+ /**
+ * System setting for the url suffix for categories
+ *
+ * @var string
+ */
+ private static $xml_path_category_url_suffix = 'catalog/seo/category_url_suffix';
/**
* Cache for product rewrite suffix
*
* @var array
*/
- private $cateogryUrlSuffix = [];
+ private $categoryUrlSuffix = [];
/**
* @var ScopeConfigInterface
@@ -35,11 +40,9 @@ class CategoryUrlSuffix implements ResolverInterface
/**
* @param ScopeConfigInterface $scopeConfig
- * @param array $cateogryUrlSuffix
*/
- public function __construct(ScopeConfigInterface $scopeConfig, array $cateogryUrlSuffix = [])
+ public function __construct(ScopeConfigInterface $scopeConfig)
{
- $this->cateogryUrlSuffix = $cateogryUrlSuffix;
$this->scopeConfig = $scopeConfig;
}
@@ -56,7 +59,7 @@ public function resolve(
/** @var StoreInterface $store */
$store = $context->getExtensionAttributes()->getStore();
$storeId = (int)$store->getId();
- return $this->getProductUrlSuffix($storeId);
+ return $this->getCategoryUrlSuffix($storeId);
}
/**
@@ -65,15 +68,15 @@ public function resolve(
* @param int $storeId
* @return string
*/
- private function getProductUrlSuffix(int $storeId): string
+ private function getCategoryUrlSuffix(int $storeId): string
{
- if (!isset($this->cateogryUrlSuffix[$storeId])) {
- $this->cateogryUrlSuffix[$storeId] = $this->scopeConfig->getValue(
- self::XML_PATH_PRODUCT_URL_SUFFIX,
+ if (!isset($this->categoryUrlSuffix[$storeId])) {
+ $this->categoryUrlSuffix[$storeId] = $this->scopeConfig->getValue(
+ self::$xml_path_category_url_suffix,
ScopeInterface::SCOPE_STORE,
$storeId
);
}
- return $this->cateogryUrlSuffix[$storeId];
+ return $this->categoryUrlSuffix[$storeId];
}
}
diff --git a/app/code/Magento/CatalogUrlRewriteGraphQl/Model/Resolver/ProductUrlSuffix.php b/app/code/Magento/CatalogUrlRewriteGraphQl/Model/Resolver/ProductUrlSuffix.php
index 47ac15cc60754..9a0193ba36367 100644
--- a/app/code/Magento/CatalogUrlRewriteGraphQl/Model/Resolver/ProductUrlSuffix.php
+++ b/app/code/Magento/CatalogUrlRewriteGraphQl/Model/Resolver/ProductUrlSuffix.php
@@ -19,7 +19,12 @@
*/
class ProductUrlSuffix implements ResolverInterface
{
- const XML_PATH_PRODUCT_URL_SUFFIX = 'catalog/seo/product_url_suffix';
+ /**
+ * System setting for the url suffix for products
+ *
+ * @var string
+ */
+ private static $xml_path_product_url_suffix = 'catalog/seo/product_url_suffix';
/**
* Cache for product rewrite suffix
@@ -35,11 +40,9 @@ class ProductUrlSuffix implements ResolverInterface
/**
* @param ScopeConfigInterface $scopeConfig
- * @param array $productUrlSuffix
*/
- public function __construct(ScopeConfigInterface $scopeConfig, array $productUrlSuffix = [])
+ public function __construct(ScopeConfigInterface $scopeConfig)
{
- $this->productUrlSuffix = $productUrlSuffix;
$this->scopeConfig = $scopeConfig;
}
@@ -69,7 +72,7 @@ private function getProductUrlSuffix(int $storeId): string
{
if (!isset($this->productUrlSuffix[$storeId])) {
$this->productUrlSuffix[$storeId] = $this->scopeConfig->getValue(
- self::XML_PATH_PRODUCT_URL_SUFFIX,
+ self::$xml_path_product_url_suffix,
ScopeInterface::SCOPE_STORE,
$storeId
);
diff --git a/app/code/Magento/UrlRewriteGraphQl/etc/schema.graphqls b/app/code/Magento/UrlRewriteGraphQl/etc/schema.graphqls
index e7291aae4b8e2..ace3e0eae831e 100644
--- a/app/code/Magento/UrlRewriteGraphQl/etc/schema.graphqls
+++ b/app/code/Magento/UrlRewriteGraphQl/etc/schema.graphqls
@@ -2,7 +2,7 @@
# See COPYING.txt for license details.
type Query {
- urlResolver(url: String!): EntityUrl @resolver(class: "Magento\\UrlRewriteGraphQl\\Model\\Resolver\\EntityUrl") @doc(description: "The urlResolver query returns the relative URL for a specified product, category or CMS page, using as input a url_key prepended by the url_suffix, if one exists") @cache(cacheIdentity: "Magento\\UrlRewriteGraphQl\\Model\\Resolver\\UrlRewrite\\UrlResolverIdentity")
+ urlResolver(url: String!): EntityUrl @resolver(class: "Magento\\UrlRewriteGraphQl\\Model\\Resolver\\EntityUrl") @doc(description: "The urlResolver query returns the relative URL for a specified product, category or CMS page, using as input a url_key appended by the url_suffix, if one exists") @cache(cacheIdentity: "Magento\\UrlRewriteGraphQl\\Model\\Resolver\\UrlRewrite\\UrlResolverIdentity")
}
type EntityUrl @doc(description: "EntityUrl is an output object containing the `id`, `relative_url`, and `type` attributes") {
From f83c18753b7d829b810bf0494d162594a0882970 Mon Sep 17 00:00:00 2001
From: Prabhu Ram
Date: Tue, 17 Sep 2019 13:56:42 -0500
Subject: [PATCH 340/937] MC-19254: Implement the schema changes - unit test
fixes
---
.../SalesRule/Test/Unit/Model/RulesApplierTest.php | 11 ++++++++++-
1 file changed, 10 insertions(+), 1 deletion(-)
diff --git a/app/code/Magento/SalesRule/Test/Unit/Model/RulesApplierTest.php b/app/code/Magento/SalesRule/Test/Unit/Model/RulesApplierTest.php
index 969e22d6d0e77..9b2747945305d 100644
--- a/app/code/Magento/SalesRule/Test/Unit/Model/RulesApplierTest.php
+++ b/app/code/Magento/SalesRule/Test/Unit/Model/RulesApplierTest.php
@@ -199,11 +199,20 @@ protected function getPreparedItem()
'getAddress',
'setAppliedRuleIds',
'__wakeup',
- 'getChildren'
+ 'getChildren',
+ 'getExtensionAttributes'
]
);
+ $itemExtension = $this->getMockBuilder(
+ \Magento\Framework\Api\ExtensionAttributesInterface::class
+ )->setMethods(['setDiscounts', 'getDiscounts'])->getMock();
+ $itemExtension->method('getDiscounts')->willReturn([]);
+ $itemExtension->expects($this->once())
+ ->method('setDiscounts')
+ ->willReturn([]);
$quote = $this->createPartialMock(\Magento\Quote\Model\Quote::class, ['getStore', '__wakeUp']);
$item->expects($this->any())->method('getAddress')->will($this->returnValue($address));
+ $item->expects($this->any())->method('getExtensionAttributes')->will($this->returnValue($itemExtension));
$address->expects($this->any())
->method('getQuote')
->will($this->returnValue($quote));
From 3aeaacffbcc043396f82af1dbffed47c20e256ef Mon Sep 17 00:00:00 2001
From: Dmytro Poperechnyy
Date: Tue, 17 Sep 2019 14:21:27 -0500
Subject: [PATCH 341/937] MC-19247: Broken translations with advanced bundling
- Add json parse to dictionary file content in template;
---
.../Magento/Translation/view/base/templates/dictionary.phtml | 5 ++++-
dev/tests/js/jasmine/tests/lib/mage/fake-dictionary.js | 2 +-
2 files changed, 5 insertions(+), 2 deletions(-)
diff --git a/app/code/Magento/Translation/view/base/templates/dictionary.phtml b/app/code/Magento/Translation/view/base/templates/dictionary.phtml
index fb082439b1c39..2e1389abcffdc 100644
--- a/app/code/Magento/Translation/view/base/templates/dictionary.phtml
+++ b/app/code/Magento/Translation/view/base/templates/dictionary.phtml
@@ -6,9 +6,12 @@
/** @var \Magento\Translation\ViewModel\Dictionary $viewModel */
$viewModel = $block->getData('dictionary_view_model');
+$dictionary = json_encode($viewModel->getTranslationDictionary(), JSON_HEX_APOS | JSON_UNESCAPED_SLASHES);
?>
diff --git a/dev/tests/js/jasmine/tests/lib/mage/fake-dictionary.js b/dev/tests/js/jasmine/tests/lib/mage/fake-dictionary.js
index bdaf66991a30b..005a5817dfa1f 100644
--- a/dev/tests/js/jasmine/tests/lib/mage/fake-dictionary.js
+++ b/dev/tests/js/jasmine/tests/lib/mage/fake-dictionary.js
@@ -2,7 +2,7 @@
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
-// Fake dictionary for js unit tests as real dictionary is defined is template and cannot be initialized by requirejs
+// Fake dictionary for js unit tests as real dictionary is defined in template and cannot be initialized by requirejs
define([], function () {
'use strict';
From 943950187b4a7a972f75921545c315db39963d5a Mon Sep 17 00:00:00 2001
From: Prabhu Ram
Date: Tue, 17 Sep 2019 14:34:06 -0500
Subject: [PATCH 342/937] MC-19254: Implement the schema changes -
composer.json changes
---
app/code/Magento/QuoteGraphQl/composer.json | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/app/code/Magento/QuoteGraphQl/composer.json b/app/code/Magento/QuoteGraphQl/composer.json
index b56f86364ec65..4ed989bf7c157 100644
--- a/app/code/Magento/QuoteGraphQl/composer.json
+++ b/app/code/Magento/QuoteGraphQl/composer.json
@@ -13,7 +13,8 @@
"magento/module-customer-graph-ql": "*",
"magento/module-sales": "*",
"magento/module-directory": "*",
- "magento/module-graph-ql": "*"
+ "magento/module-graph-ql": "*",
+ "magento/module-sales-rule": "*"
},
"suggest": {
"magento/module-graph-ql-cache": "*"
From 06a2513731d22fa32a776a6a15f5296d20a53bb3 Mon Sep 17 00:00:00 2001
From: Vitalii Zabaznov
Date: Tue, 17 Sep 2019 14:42:44 -0500
Subject: [PATCH 343/937] MC-18719: private cookie version increments each post
request
---
.../Magento/Checkout/view/frontend/web/js/view/minicart.js | 7 ++-----
app/code/Magento/Customer/Block/SectionNamesProvider.php | 5 ++++-
.../Magento/Customer/view/frontend/web/js/customer-data.js | 5 ++---
3 files changed, 8 insertions(+), 9 deletions(-)
diff --git a/app/code/Magento/Checkout/view/frontend/web/js/view/minicart.js b/app/code/Magento/Checkout/view/frontend/web/js/view/minicart.js
index 5529ff7e95767..39dc10c6db8ef 100644
--- a/app/code/Magento/Checkout/view/frontend/web/js/view/minicart.js
+++ b/app/code/Magento/Checkout/view/frontend/web/js/view/minicart.js
@@ -103,11 +103,8 @@ define([
});
if (
- (cartData().website_id !== window.checkout.websiteId &&
- cartData().website_id !== undefined)
- ||
- (cartData().storeId !== window.checkout.storeId &&
- cartData().storeId !== undefined)
+ (cartData().website_id !== window.checkout.websiteId && cartData().website_id !== undefined) ||
+ (cartData().storeId !== window.checkout.storeId && cartData().storeId !== undefined)
) {
customerData.reload(['cart'], false);
}
diff --git a/app/code/Magento/Customer/Block/SectionNamesProvider.php b/app/code/Magento/Customer/Block/SectionNamesProvider.php
index 3f9f67336b70d..92029d1715d4b 100644
--- a/app/code/Magento/Customer/Block/SectionNamesProvider.php
+++ b/app/code/Magento/Customer/Block/SectionNamesProvider.php
@@ -1,5 +1,8 @@
Date: Tue, 17 Sep 2019 17:54:18 -0500
Subject: [PATCH 344/937] MC-19255: API functional tests to cover cart
promotions
- added test coverage to include taxes
---
.../GraphQl/Quote/CartPromotionsTest.php | 210 ++++++++++++++----
...lation_price_and_cart_display_settings.php | 28 +++
...ice_and_cart_display_settings_rollback.php | 28 +++
...ent_off_qty_more_than_2_items_rollback.php | 2 +-
.../_files/rules_categories_rollback.php | 26 ++-
.../SalesRule/_files/rules_category.php | 6 +-
6 files changed, 250 insertions(+), 50 deletions(-)
create mode 100644 dev/tests/integration/testsuite/Magento/GraphQl/Tax/_files/tax_calculation_price_and_cart_display_settings.php
create mode 100644 dev/tests/integration/testsuite/Magento/GraphQl/Tax/_files/tax_calculation_price_and_cart_display_settings_rollback.php
diff --git a/dev/tests/api-functional/testsuite/Magento/GraphQl/Quote/CartPromotionsTest.php b/dev/tests/api-functional/testsuite/Magento/GraphQl/Quote/CartPromotionsTest.php
index ccfdfc9f741f4..52f95c5abdd8a 100644
--- a/dev/tests/api-functional/testsuite/Magento/GraphQl/Quote/CartPromotionsTest.php
+++ b/dev/tests/api-functional/testsuite/Magento/GraphQl/Quote/CartPromotionsTest.php
@@ -11,11 +11,12 @@
use Magento\Catalog\Api\ProductRepositoryInterface;
use Magento\Catalog\Model\Product;
use Magento\Catalog\Model\Product\Visibility;
-use Magento\SalesRule\Api\RuleRepositoryInterface;
use Magento\SalesRule\Model\ResourceModel\Rule\Collection;
use Magento\SalesRule\Model\Rule;
use Magento\TestFramework\Helper\Bootstrap;
use Magento\TestFramework\TestCase\GraphQlAbstract;
+use Magento\Tax\Model\ClassModel as TaxClassModel;
+use Magento\Tax\Model\ResourceModel\TaxClass\CollectionFactory as TaxClassCollectionFactory;
/**
* Test cases for applying cart promotions to items in cart
@@ -56,7 +57,6 @@ public function testCartPromotionSingleCartRule()
foreach ($ruleCollection as $rule) {
$ruleLabels = $rule->getStoreLabels();
}
-
$qty = 2;
$cartId = $this->createEmptyCart();
$this->addMultipleSimpleProductsToCart($cartId, $qty, $skus[0], $skus[1]);
@@ -64,6 +64,19 @@ public function testCartPromotionSingleCartRule()
$response = $this->graphQlMutation($query);
$this->assertCount(2, $response['cart']['items']);
//validating the line item prices, quantity and discount
+ $this->assertLineItemDiscountPrices($response, $productsInCart, $qty, $ruleLabels);
+ }
+
+ /**
+ * Assert the row total discounts and individual discount break down and cart rule labels
+ *
+ * @param $response
+ * @param $productsInCart
+ * @param $qty
+ * @param $ruleLabels
+ */
+ private function assertLineItemDiscountPrices($response, $productsInCart, $qty, $ruleLabels)
+ {
$productsInResponse = array_map(null, $response['cart']['items'], $productsInCart);
$count = count($productsInCart);
for ($itemIndex = 0; $itemIndex < $count; $itemIndex++) {
@@ -80,54 +93,17 @@ public function testCartPromotionSingleCartRule()
0 =>[
'amount' =>
['value' => $productsInCart[$itemIndex]->getSpecialPrice()*$qty*0.5],
- 'label' => $ruleLabels[0]
+ 'label' => 'TestRule_Label'
]
]
],
]
);
}
-
- /** @var Collection $ruleCollection */
- // $ruleCollection = $objectManager->get(Collection::class);
- /** @var RuleRepositoryInterface $ruleRepository */
- // $ruleRepository = $objectManager->get(RuleRepositoryInterface::class);
-
- /** @var Rule $rule */
-// foreach ($ruleCollection as $rule) {
-// $ruleName = $rule->getName();
-// if($ruleName === '50% Off on Large Orders'){
-// $ruleId = $rule->getRuleId();
- /** @var \Magento\SalesRule\Model\Data\Rule $salesRule */
-// $salesRule = $ruleRepository->getById($ruleId);
-// $salesRule->setStoreLabels(['store_labels' => 'Test Label']);
-
-// $salesRule->setStoreLabels([
-// 'store_labels' => [
-// [
-// 'store_id' => 0,
-// 'store_label' => 'TestRule_Label',
-// ]
-// ]
-//
-// ]
-// );
- // $ruleRepository->save($salesRule);
- // $salesRule->save();
- /** @var Rule $salesRule */
- // $salesRule = $objectManager->get(Rule::class);
-// $salesRule->setData
-// ([
-// 'store_labels' => [0 => '50% discount for products in category']
-// ]
-// );
-// $salesRule->save();
-
-
}
/**
- * Test adding multiple cart rules to multiple products in a cart
+ * Test applying multiple cart rules to multiple products in a cart
*
* @magentoApiDataFixture Magento/Catalog/_files/multiple_products.php
* @magentoApiDataFixture Magento/SalesRule/_files/rules_category.php
@@ -174,15 +150,22 @@ public function testCartPromotionsMultipleCartRules()
for ($itemIndex = 0; $itemIndex < $count; $itemIndex++) {
$this->assertNotEmpty($productsInResponse[$itemIndex]);
$lineItemDiscount = $productsInResponse[$itemIndex][0]['prices']['discounts'];
- $expectedTotalDiscountValue = ($productsInCart[$itemIndex]->getSpecialPrice()*$qty*0.5)+($productsInCart[$itemIndex]->getSpecialPrice()*$qty*0.5*0.1);
- $this->assertEquals($productsInCart[$itemIndex]->getSpecialPrice()*$qty*0.5, current($lineItemDiscount)['amount']['value']);
+ $expectedTotalDiscountValue = ($productsInCart[$itemIndex]->getSpecialPrice()*$qty*0.5) +
+ ($productsInCart[$itemIndex]->getSpecialPrice()*$qty*0.5*0.1);
+ $this->assertEquals(
+ $productsInCart[$itemIndex]->getSpecialPrice()*$qty*0.5,
+ current($lineItemDiscount)['amount']['value']
+ );
$this->assertEquals('TestRule_Label', current($lineItemDiscount)['label']);
$lineItemDiscountValue = next($lineItemDiscount)['amount']['value'];
- $this->assertEquals(round($productsInCart[$itemIndex]->getSpecialPrice()*$qty*0.5)*0.1, $lineItemDiscountValue );
+ $this->assertEquals(
+ round($productsInCart[$itemIndex]->getSpecialPrice()*$qty*0.5)*0.1,
+ $lineItemDiscountValue
+ );
$this->assertEquals('10% off with two items_Label', end($lineItemDiscount)['label']);
- $actualTotalDiscountValue = $lineItemDiscount[0]['amount']['value'] + $lineItemDiscount[1]['amount']['value'];
- $this->assertEquals(round($expectedTotalDiscountValue,2), $actualTotalDiscountValue);
+ $actualTotalDiscountValue = $lineItemDiscount[0]['amount']['value']+$lineItemDiscount[1]['amount']['value'];
+ $this->assertEquals(round($expectedTotalDiscountValue, 2), $actualTotalDiscountValue);
//removing the elements from the response so that the rest of the response values can be compared
unset($productsInResponse[$itemIndex][0]['prices']['discounts']);
@@ -200,6 +183,90 @@ public function testCartPromotionsMultipleCartRules()
}
}
+ /**
+ * Test applying single cart rules to multiple products in a cart with tax settings
+ * Tax settings are : Including and Excluding tax for Price Display and Shopping cart display settings
+ * Discount on Prices Includes Tax
+ * Tax rate = 7.5%
+ * Cart rule to apply 50% for products assigned to a specific category
+ *
+ * @magentoApiDataFixture Magento/Catalog/_files/multiple_products.php
+ * @magentoApiDataFixture Magento/GraphQl/Tax/_files/tax_rule_for_region_1.php
+ * @magentoApiDataFixture Magento/GraphQl/Tax/_files/tax_calculation_price_and_cart_display_settings.php
+ * @magentoApiDataFixture Magento/SalesRule/_files/rules_category.php
+ *
+ */
+ public function testCartPromotionsSingleCartRulesWithTaxes()
+ {
+ $objectManager = Bootstrap::getObjectManager();
+ /** @var ProductRepositoryInterface $productRepository */
+ $productRepository = $objectManager->get(ProductRepositoryInterface::class);
+ /** @var Product $prod2 */
+ $prod1 = $productRepository->get('simple1');
+ $prod2 = $productRepository->get('simple2');
+ $productsInCart = [$prod1, $prod2];
+ $skus =['simple1', 'simple2'];
+
+ /** @var TaxClassCollectionFactory $taxClassCollectionFactory */
+ $taxClassCollectionFactory = $objectManager->get(TaxClassCollectionFactory::class);
+ $taxClassCollection = $taxClassCollectionFactory->create();
+
+ /** @var TaxClassModel $taxClass */
+ $taxClassCollection->addFieldToFilter('class_type', TaxClassModel::TAX_CLASS_TYPE_PRODUCT);
+ $taxClass = $taxClassCollection->getFirstItem();
+ foreach ($productsInCart as $product) {
+ $product->setCustomAttribute('tax_class_id', $taxClass->getClassId());
+ $productRepository->save($product);
+ }
+ $categoryId = 66;
+ /** @var \Magento\Catalog\Api\CategoryLinkManagementInterface $categoryLinkManagement */
+ $categoryLinkManagement = $objectManager->create(CategoryLinkManagementInterface::class);
+ foreach ($skus as $sku) {
+ $categoryLinkManagement->assignProductToCategories(
+ $sku,
+ [$categoryId]
+ );
+ }
+ $qty = 1;
+ $cartId = $this->createEmptyCart();
+ $this->addMultipleSimpleProductsToCart($cartId, $qty, $skus[0], $skus[1]);
+ $this->setShippingAddressOnCart($cartId);
+ $query = $this->getCartItemPricesQuery($cartId);
+ $response = $this->graphQlMutation($query);
+ $this->assertCount(2, $response['cart']['items']);
+ $productsInResponse = array_map(null, $response['cart']['items'], $productsInCart);
+ $count = count($productsInCart);
+ for ($itemIndex = 0; $itemIndex < $count; $itemIndex++) {
+ $this->assertNotEmpty($productsInResponse[$itemIndex]);
+ $rowTotalIncludingTax = round(
+ $productsInCart[$itemIndex]->getSpecialPrice()*$qty +
+ $productsInCart[$itemIndex]->getSpecialPrice()*$qty*.075,
+ 2
+ );
+ $this->assertResponseFields(
+ $productsInResponse[$itemIndex][0],
+ [
+ 'quantity' => $qty,
+ 'prices' => [
+ // row_total is the line item price without the tax
+ 'row_total' => ['value' => $productsInCart[$itemIndex]->getSpecialPrice()*$qty],
+ // row_total including tax is the price + price * tax rate
+ 'row_total_including_tax' => ['value' => $rowTotalIncludingTax],
+ // discount from cart rule after tax is applied : 50% of row_total_including_tax
+ 'discount' => ['value' => round($rowTotalIncludingTax/2, 2)],
+ 'discounts' => [
+ 0 =>[
+ 'amount' =>
+ ['value' => round($rowTotalIncludingTax/2, 2)],
+ 'label' => 'TestRule_Label'
+ ]
+ ]
+ ],
+ ]
+ );
+ }
+ }
+
/**
* @param string $cartId
* @return string
@@ -292,4 +359,55 @@ private function addMultipleSimpleProductsToCart(string $cartId, int $qty, strin
self::assertEquals($qty, $response['addSimpleProductsToCart']['cart']['items'][1]['quantity']);
self::assertEquals($sku2, $response['addSimpleProductsToCart']['cart']['items'][1]['product']['sku']);
}
+
+ /**
+ * Set shipping address for the region for which tax rule is set
+ *
+ * @param string $cartId
+ * @return void
+ */
+ private function setShippingAddressOnCart(string $cartId) :void
+ {
+ $query = <<graphQlMutation($query);
+ self::assertEquals(
+ 'Montgomery',
+ $response['setShippingAddressesOnCart']['cart']['shipping_addresses'][0]['city']
+ );
+ self::assertEquals(
+ 'Alabama',
+ $response['setShippingAddressesOnCart']['cart']['shipping_addresses'][0]['region']['label']
+ );
+ }
}
diff --git a/dev/tests/integration/testsuite/Magento/GraphQl/Tax/_files/tax_calculation_price_and_cart_display_settings.php b/dev/tests/integration/testsuite/Magento/GraphQl/Tax/_files/tax_calculation_price_and_cart_display_settings.php
new file mode 100644
index 0000000000000..aca41b236c7bf
--- /dev/null
+++ b/dev/tests/integration/testsuite/Magento/GraphQl/Tax/_files/tax_calculation_price_and_cart_display_settings.php
@@ -0,0 +1,28 @@
+get(WriterInterface::class);
+
+//Apply discount on prices to include tax
+$configWriter->save('tax/calculation/discount_tax', '1');
+$configWriter->save('tax/display/type', '3');
+$configWriter->save('tax/display/shipping', '3');
+
+$configWriter->save('tax/cart_display/price', '3');
+$configWriter->save('tax/cart_display/subtotal', '3');
+$configWriter->save('tax/cart_display/shipping', '3');
+$configWriter->save('tax/cart_display/grandtotal', '1');
+
+$scopeConfig = $objectManager->get(ScopeConfigInterface::class);
+$scopeConfig->clean();
diff --git a/dev/tests/integration/testsuite/Magento/GraphQl/Tax/_files/tax_calculation_price_and_cart_display_settings_rollback.php b/dev/tests/integration/testsuite/Magento/GraphQl/Tax/_files/tax_calculation_price_and_cart_display_settings_rollback.php
new file mode 100644
index 0000000000000..7448a71dcbf18
--- /dev/null
+++ b/dev/tests/integration/testsuite/Magento/GraphQl/Tax/_files/tax_calculation_price_and_cart_display_settings_rollback.php
@@ -0,0 +1,28 @@
+get(WriterInterface::class);
+
+//Apply discount on prices to include tax
+$configWriter->save('tax/calculation/discount_tax', '0');
+$configWriter->save('tax/display/type', '1');
+$configWriter->save('tax/display/shipping', '1');
+
+$configWriter->save('tax/cart_display/price', '1');
+$configWriter->save('tax/cart_display/subtotal', '1');
+$configWriter->save('tax/cart_display/shipping', '1');
+$configWriter->save('tax/cart_display/grandtotal', '0');
+
+$scopeConfig = $objectManager->get(ScopeConfigInterface::class);
+$scopeConfig->clean();
diff --git a/dev/tests/integration/testsuite/Magento/SalesRule/_files/cart_rule_10_percent_off_qty_more_than_2_items_rollback.php b/dev/tests/integration/testsuite/Magento/SalesRule/_files/cart_rule_10_percent_off_qty_more_than_2_items_rollback.php
index 54f09a29e4a2e..f6866a8066ee3 100644
--- a/dev/tests/integration/testsuite/Magento/SalesRule/_files/cart_rule_10_percent_off_qty_more_than_2_items_rollback.php
+++ b/dev/tests/integration/testsuite/Magento/SalesRule/_files/cart_rule_10_percent_off_qty_more_than_2_items_rollback.php
@@ -6,4 +6,4 @@
declare(strict_types=1);
// phpcs:ignore Magento2.Security.IncludeFile
-require __DIR__ . '/rules_rollback.php';
\ No newline at end of file
+require __DIR__ . '/rules_rollback.php';
diff --git a/dev/tests/integration/testsuite/Magento/SalesRule/_files/rules_categories_rollback.php b/dev/tests/integration/testsuite/Magento/SalesRule/_files/rules_categories_rollback.php
index 968193b26fe17..0f7de0efe41f6 100644
--- a/dev/tests/integration/testsuite/Magento/SalesRule/_files/rules_categories_rollback.php
+++ b/dev/tests/integration/testsuite/Magento/SalesRule/_files/rules_categories_rollback.php
@@ -3,11 +3,35 @@
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
+use Magento\TestFramework\Helper\Bootstrap;
+use Magento\Framework\Api\SearchCriteriaBuilder;
+use Magento\Catalog\Api\CategoryListInterface;
+use Magento\Catalog\Api\CategoryRepositoryInterface;
+
+$objectManager = Bootstrap::getObjectManager();
/** @var Magento\Framework\Registry $registry */
-$registry = \Magento\TestFramework\Helper\Bootstrap::getObjectManager()->get(\Magento\Framework\Registry::class);
+$registry = $objectManager->get(\Magento\Framework\Registry::class);
/** @var Magento\SalesRule\Model\Rule $rule */
$rule = $registry->registry('_fixture/Magento_SalesRule_Multiple_Categories');
$rule->delete();
+
+// logic to delete the category that was created as part of the rules_category fixture
+/** @var SearchCriteriaBuilder $searchCriteriaBuilder */
+$searchCriteriaBuilder = $objectManager->get(SearchCriteriaBuilder::class);
+$searchCriteria = $searchCriteriaBuilder->addFilter('name', 'Category 1')
+ ->create();
+
+/** @var CategoryListInterface $categoryList */
+$categoryList = $objectManager->get(CategoryListInterface::class);
+$categories = $categoryList->getList($searchCriteria)
+ ->getItems();
+
+/** @var CategoryRepositoryInterface $categoryRepository */
+$categoryRepository = $objectManager->get(CategoryRepositoryInterface::class);
+
+foreach ($categories as $category) {
+ $categoryRepository->delete($category);
+}
diff --git a/dev/tests/integration/testsuite/Magento/SalesRule/_files/rules_category.php b/dev/tests/integration/testsuite/Magento/SalesRule/_files/rules_category.php
index 5b469c8680c13..0009ae4d7d3cc 100644
--- a/dev/tests/integration/testsuite/Magento/SalesRule/_files/rules_category.php
+++ b/dev/tests/integration/testsuite/Magento/SalesRule/_files/rules_category.php
@@ -30,7 +30,8 @@
]
);
-$salesRule->getConditions()->loadArray([
+$salesRule->getConditions()->loadArray(
+ [
'type' => \Magento\SalesRule\Model\Rule\Condition\Combine::class,
'attribute' => null,
'operator' => null,
@@ -58,7 +59,8 @@
],
],
],
-]);
+ ]
+);
$salesRule->save();
From 8f0c2252ecf8b43f725502c7badec1779e144576 Mon Sep 17 00:00:00 2001
From: Tiago
Date: Tue, 17 Sep 2019 22:57:13 -0300
Subject: [PATCH 345/937] adding validation to unit test, line before return
statement, and remove unused jquery/ui from validation
---
.../Customer/Test/Unit/Block/Widget/DobTest.php | 12 ++++++------
.../view/base/ui_component/customer_form.xml | 12 +++++++++---
.../Customer/view/frontend/web/js/validation.js | 2 +-
3 files changed, 16 insertions(+), 10 deletions(-)
diff --git a/app/code/Magento/Customer/Test/Unit/Block/Widget/DobTest.php b/app/code/Magento/Customer/Test/Unit/Block/Widget/DobTest.php
index 8bfddac3cef8f..da5e089f93ecb 100644
--- a/app/code/Magento/Customer/Test/Unit/Block/Widget/DobTest.php
+++ b/app/code/Magento/Customer/Test/Unit/Block/Widget/DobTest.php
@@ -521,8 +521,8 @@ public function testGetHtmlExtraParamsWithoutRequiredOption()
{
$this->escaper->expects($this->any())
->method('escapeHtml')
- ->with('{"validate-date":{"dateFormat":"M\/d\/Y"}}')
- ->will($this->returnValue('{"validate-date":{"dateFormat":"M\/d\/Y"}}'));
+ ->with('{"validate-date":{"dateFormat":"M\/d\/Y"},"validate-dob":true}')
+ ->will($this->returnValue('{"validate-date":{"dateFormat":"M\/d\/Y"},"validate-dob":true}'));
$this->attribute->expects($this->once())
->method("isRequired")
@@ -530,7 +530,7 @@ public function testGetHtmlExtraParamsWithoutRequiredOption()
$this->assertEquals(
$this->_block->getHtmlExtraParams(),
- 'data-validate="{"validate-date":{"dateFormat":"M\/d\/Y"}}"'
+ 'data-validate="{"validate-date":{"dateFormat":"M\/d\/Y"},"validate-dob":true}"'
);
}
@@ -544,13 +544,13 @@ public function testGetHtmlExtraParamsWithRequiredOption()
->willReturn(true);
$this->escaper->expects($this->any())
->method('escapeHtml')
- ->with('{"required":true,"validate-date":{"dateFormat":"M\/d\/Y"}}')
- ->will($this->returnValue('{"required":true,"validate-date":{"dateFormat":"M\/d\/Y"}}'));
+ ->with('{"required":true,"validate-date":{"dateFormat":"M\/d\/Y"},"validate-dob":true}')
+ ->will($this->returnValue('{"required":true,"validate-date":{"dateFormat":"M\/d\/Y"},"validate-dob":true}'));
$this->context->expects($this->any())->method('getEscaper')->will($this->returnValue($this->escaper));
$this->assertEquals(
- 'data-validate="{"required":true,"validate-date":{"dateFormat":"M\/d\/Y"}}"',
+ 'data-validate="{"required":true,"validate-date":{"dateFormat":"M\/d\/Y"},"validate-dob":true}"',
$this->_block->getHtmlExtraParams()
);
}
diff --git a/app/code/Magento/Customer/view/base/ui_component/customer_form.xml b/app/code/Magento/Customer/view/base/ui_component/customer_form.xml
index 7eb1394f77a41..954b44ec19bbb 100644
--- a/app/code/Magento/Customer/view/base/ui_component/customer_form.xml
+++ b/app/code/Magento/Customer/view/base/ui_component/customer_form.xml
@@ -260,9 +260,6 @@
-
- customer
- -
-
- -1d
-
@@ -273,6 +270,15 @@
text
true
+
+
+
+
+ -1d
+
+
+
+
diff --git a/app/code/Magento/Customer/view/frontend/web/js/validation.js b/app/code/Magento/Customer/view/frontend/web/js/validation.js
index 840134d64422e..14ae69b020809 100644
--- a/app/code/Magento/Customer/view/frontend/web/js/validation.js
+++ b/app/code/Magento/Customer/view/frontend/web/js/validation.js
@@ -1,7 +1,6 @@
require([
'jquery',
'moment',
- 'jquery/ui',
'jquery/validate',
'mage/translate',
], function($, moment) {
@@ -12,6 +11,7 @@ require([
if (value === '') {
return true;
}
+
return moment(value).isBefore(moment());
},
$.mage.__('The Date of Birth should not be greater than today.')
From 9ebde0708b28a683511b0de5c73bda5b48aaefc6 Mon Sep 17 00:00:00 2001
From: Cristian Partica
Date: Tue, 17 Sep 2019 21:12:08 -0500
Subject: [PATCH 346/937] MC-18996: GraphQl Url Resolver doesn't return any
results if the url_key doesn't have the extension
- fix namespace
---
.../Magento/GraphQl/CatalogUrlRewrite/UrlResolverTest.php | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/dev/tests/api-functional/testsuite/Magento/GraphQl/CatalogUrlRewrite/UrlResolverTest.php b/dev/tests/api-functional/testsuite/Magento/GraphQl/CatalogUrlRewrite/UrlResolverTest.php
index 1b2776e66b7e7..b15cfe3a5b913 100644
--- a/dev/tests/api-functional/testsuite/Magento/GraphQl/CatalogUrlRewrite/UrlResolverTest.php
+++ b/dev/tests/api-functional/testsuite/Magento/GraphQl/CatalogUrlRewrite/UrlResolverTest.php
@@ -5,7 +5,7 @@
*/
declare(strict_types=1);
-namespace Magento\CatalogGraphQl\UrlRewrite;
+namespace Magento\GraphQl\CatalogUrlRewrite;
use Magento\Catalog\Api\ProductRepositoryInterface;
use Magento\TestFramework\ObjectManager;
From 78b6776e39463b9391b765e001dddd6404a56c9e Mon Sep 17 00:00:00 2001
From: Prabhu Ram
Date: Tue, 17 Sep 2019 21:41:24 -0500
Subject: [PATCH 347/937] MC-19254: Implement the schema changes
- integration test fix
---
app/code/Magento/SalesRule/etc/extension_attributes.xml | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/app/code/Magento/SalesRule/etc/extension_attributes.xml b/app/code/Magento/SalesRule/etc/extension_attributes.xml
index 5fba88c747fe1..202ced4204f73 100644
--- a/app/code/Magento/SalesRule/etc/extension_attributes.xml
+++ b/app/code/Magento/SalesRule/etc/extension_attributes.xml
@@ -7,6 +7,6 @@
-->
-
+
-
+
\ No newline at end of file
From f1a6a94842ea6ac28ec87ac99fdaab30c431f13a Mon Sep 17 00:00:00 2001
From: "rostyslav.hymon"
Date: Wed, 18 Sep 2019 10:06:12 +0300
Subject: [PATCH 348/937] MC-19916: Attribute not showing on layered navigation
if no value set for "All Store Views"
---
.../Product/Indexer/Eav/Source.php | 41 ++++++++++++++++++-
1 file changed, 39 insertions(+), 2 deletions(-)
diff --git a/app/code/Magento/Catalog/Model/ResourceModel/Product/Indexer/Eav/Source.php b/app/code/Magento/Catalog/Model/ResourceModel/Product/Indexer/Eav/Source.php
index 7730d7cc9a7fd..f0fe95467087f 100644
--- a/app/code/Magento/Catalog/Model/ResourceModel/Product/Indexer/Eav/Source.php
+++ b/app/code/Magento/Catalog/Model/ResourceModel/Product/Indexer/Eav/Source.php
@@ -8,6 +8,8 @@
use Magento\Catalog\Model\Product\Attribute\Source\Status as ProductStatus;
use Magento\Catalog\Api\Data\ProductInterface;
use Magento\Catalog\Api\Data\ProductAttributeInterface;
+use Magento\Framework\DB\Select;
+use Magento\Framework\DB\Sql\UnionExpression;
/**
* Catalog Product Eav Select and Multiply Select Attributes Indexer resource model
@@ -199,13 +201,48 @@ protected function _prepareSelectIndex($entityIds = null, $attributeId = null)
'dd.attribute_id',
's.store_id',
'value' => new \Zend_Db_Expr('COALESCE(ds.value, dd.value)'),
- 'cpe.entity_id',
+ 'cpe.entity_id AS source_id',
]
);
if ($entityIds !== null) {
$ids = implode(',', array_map('intval', $entityIds));
+ $selectWithoutDefaultStore = $connection->select()->from(
+ ['wd' => $this->getTable('catalog_product_entity_int')],
+ [
+ $productIdField,
+ 'attribute_id',
+ 'store_id',
+ 'value',
+ $productIdField
+ ]
+ )->joinLeft(
+ ['d2d' => $this->getTable('catalog_product_entity_int')],
+ sprintf(
+ "d2d.store_id = 0 AND d2d.{$productIdField} = wd.{$productIdField} AND d2d.attribute_id = %s",
+ $this->_eavConfig->getAttribute(\Magento\Catalog\Model\Product::ENTITY, 'status')->getId()
+ ),
+ []
+ )->joinLeft(
+ ['d2s' => $this->getTable('catalog_product_entity_int')],
+ "d2s.store_id != 0 AND d2s.attribute_id = d2d.attribute_id AND " .
+ "d2s.{$productIdField} = d2d.{$productIdField}",
+ []
+ )
+ ->where((new \Zend_Db_Expr('COALESCE(d2s.value, d2d.value)')) . ' = ' . ProductStatus::STATUS_ENABLED)
+ ->where("wd.attribute_id IN({$attrIdsFlat})")
+ ->where('wd.value IS NOT NULL')
+ ->where('wd.store_id != 0')
+ ->where("wd.{$productIdField} IN({$ids})");
$select->where("cpe.entity_id IN({$ids})");
+ $selects = new UnionExpression(
+ [$select, $selectWithoutDefaultStore],
+ Select::SQL_UNION,
+ '( %s )'
+ );
+
+ $select = $connection->select();
+ $select->from(['u' => $selects]);
}
/**
@@ -342,7 +379,7 @@ private function getMultiSelectAttributeWithSourceModels($attrIds)
ProductAttributeInterface::ENTITY_TYPE_CODE,
$criteria
)->getItems();
-
+
$options = [];
foreach ($attributes as $attribute) {
$sourceModelOptions = $attribute->getOptions();
From 43f8d2a48dd73eecc906f88ee6c6a702aed2bded Mon Sep 17 00:00:00 2001
From: Serhii Balko
Date: Wed, 18 Sep 2019 10:58:39 +0300
Subject: [PATCH 349/937] MC-20139: Wishlist Items of customers not displaying
on admin for secondary store
---
.../Model/ResourceModel/Item/Collection/Grid.php | 10 +---------
1 file changed, 1 insertion(+), 9 deletions(-)
diff --git a/app/code/Magento/Wishlist/Model/ResourceModel/Item/Collection/Grid.php b/app/code/Magento/Wishlist/Model/ResourceModel/Item/Collection/Grid.php
index 5d2ab2db3fc77..6ef55bbe81b73 100644
--- a/app/code/Magento/Wishlist/Model/ResourceModel/Item/Collection/Grid.php
+++ b/app/code/Magento/Wishlist/Model/ResourceModel/Item/Collection/Grid.php
@@ -17,14 +17,6 @@
*/
class Grid extends \Magento\Wishlist\Model\ResourceModel\Item\Collection
{
- /**
- * Load product attributes to present in grid
- */
- private const PRODUCT_ATTRIBUTES_TO_GRID = [
- 'name',
- 'price',
- ];
-
/**
* @var \Magento\Framework\Registry
*/
@@ -120,7 +112,7 @@ protected function _assignProducts()
{
/** @var ProductCollection $productCollection */
$productCollection = $this->_productCollectionFactory->create()
- ->addAttributeToSelect(self::PRODUCT_ATTRIBUTES_TO_GRID)
+ ->addAttributeToSelect($this->_wishlistConfig->getProductAttributes())
->addIdFilter($this->_productIds);
/** @var Item $item */
From edafb0a14d7ea5e6f9f65536d997acf9a71d34c5 Mon Sep 17 00:00:00 2001
From: natalia
Date: Tue, 17 Sep 2019 12:19:25 +0300
Subject: [PATCH 350/937] MC-18821: Increase test coverage for Catalog
functional area
- Fixes for MC-6328 test
---
.../Magento/Catalog/Controller/Adminhtml/ProductTest.php | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/dev/tests/integration/testsuite/Magento/Catalog/Controller/Adminhtml/ProductTest.php b/dev/tests/integration/testsuite/Magento/Catalog/Controller/Adminhtml/ProductTest.php
index 90b03510044d7..3a28801b1ace1 100644
--- a/dev/tests/integration/testsuite/Magento/Catalog/Controller/Adminhtml/ProductTest.php
+++ b/dev/tests/integration/testsuite/Magento/Catalog/Controller/Adminhtml/ProductTest.php
@@ -79,7 +79,7 @@ public function testSaveActionAndDuplicate()
}
/**
- * Test saving and duplicate existing product after the script execution.
+ * Tests of saving and duplicating existing product after the script execution.
*
* @magentoDataFixture Magento/Catalog/_files/product_simple.php
*/
From 33903f8a320f3d5e8695d497fe3df4b1b104341f Mon Sep 17 00:00:00 2001
From: natalia
Date: Tue, 17 Sep 2019 11:59:46 +0300
Subject: [PATCH 351/937] MC-18821: Increase test coverage for Catalog
functional area
- Fixes for MC-6354 test
---
.../Swatches/view/frontend/web/js/swatch-renderer.test.js | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/dev/tests/js/jasmine/tests/app/code/Magento/Swatches/view/frontend/web/js/swatch-renderer.test.js b/dev/tests/js/jasmine/tests/app/code/Magento/Swatches/view/frontend/web/js/swatch-renderer.test.js
index b3172beec770a..f7248f71d3031 100644
--- a/dev/tests/js/jasmine/tests/app/code/Magento/Swatches/view/frontend/web/js/swatch-renderer.test.js
+++ b/dev/tests/js/jasmine/tests/app/code/Magento/Swatches/view/frontend/web/js/swatch-renderer.test.js
@@ -49,11 +49,11 @@ define([
html = $(widget._RenderSwatchOptions(attribute, 'option-label-control-id-1'))[0];
});
- it('check first conditional statement', function () {
+ it('check if swatch config has attribute id', function () {
expect(widget.options.jsonSwatchConfig.hasOwnProperty(attribute.id)).toEqual(true);
});
- it('check second conditional statement', function () {
+ it('check if option config has option id', function () {
expect(optionConfig.hasOwnProperty(optionId)).toEqual(true);
});
From 77562dabf929b7018682d0f5fa70adcf8a89af79 Mon Sep 17 00:00:00 2001
From: Eden
Date: Wed, 18 Sep 2019 17:37:21 +0700
Subject: [PATCH 352/937] Resolve No error message when click "Import Tax
Rates" without select file issue24642
---
app/code/Magento/TaxImportExport/i18n/en_US.csv | 2 ++
.../view/adminhtml/templates/importExport.phtml | 6 +++++-
2 files changed, 7 insertions(+), 1 deletion(-)
diff --git a/app/code/Magento/TaxImportExport/i18n/en_US.csv b/app/code/Magento/TaxImportExport/i18n/en_US.csv
index 95f94dcfd3b2c..56815947ed1fa 100644
--- a/app/code/Magento/TaxImportExport/i18n/en_US.csv
+++ b/app/code/Magento/TaxImportExport/i18n/en_US.csv
@@ -18,3 +18,5 @@ Rate,Rate
CSV,CSV
"Excel XML","Excel XML"
"Import/Export Tax Rates","Import/Export Tax Rates"
+"Please select a file to import!","Please select a file to import!"
+
diff --git a/app/code/Magento/TaxImportExport/view/adminhtml/templates/importExport.phtml b/app/code/Magento/TaxImportExport/view/adminhtml/templates/importExport.phtml
index 7473612252bb2..1c6b267cd9289 100644
--- a/app/code/Magento/TaxImportExport/view/adminhtml/templates/importExport.phtml
+++ b/app/code/Magento/TaxImportExport/view/adminhtml/templates/importExport.phtml
@@ -31,7 +31,7 @@