Skip to content

Commit 9648881

Browse files
author
Oleksandr Manchenko
committed
MTA-550: Re-factor Tests for Assign Promoted Products
- Fixed logical and code style errors
1 parent 01a1d35 commit 9648881

File tree

12 files changed

+177
-328
lines changed

12 files changed

+177
-328
lines changed

dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAbsentCrossSellSection.php

Lines changed: 0 additions & 47 deletions
This file was deleted.

dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductCrossSellSection.php

Lines changed: 0 additions & 58 deletions
This file was deleted.

dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductRelatedProducts.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ class AssertProductRelatedProducts extends AbstractConstraint
2222
/* end tags */
2323

2424
/**
25-
* Assert that product is displayed in related products section.
25+
* Assert that products are displayed in related products section.
2626
*
2727
* @param BrowserInterface $browser
2828
* @param CatalogProductSimple $product

dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductUpSells.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ class AssertProductUpSells extends AbstractConstraint
2222
/* end tags */
2323

2424
/**
25-
* Assert that product is displayed in up-sell section.
25+
* Assert that products are displayed in up-sell section.
2626
*
2727
* @param BrowserInterface $browser
2828
* @param CatalogProductView $catalogProductView

dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/AbstractAddRelatedProductsEntityTest.php

Lines changed: 0 additions & 113 deletions
This file was deleted.

dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/AbstractProductPromotedProductsTest.php

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -169,26 +169,26 @@ protected function parsePromotedProducts($promotedProducts)
169169
}
170170

171171
/**
172-
* Convert list steps to array.
172+
* Convert list of navigate products to array.
173173
*
174-
* @param string $steps
174+
* @param string $navigateProductsOrder
175175
* @return array
176176
*/
177-
protected function parseSteps($steps)
177+
protected function parseNavigateProductsOrder($navigateProductsOrder)
178178
{
179-
return array_map('trim', explode(',', $steps));
179+
return array_map('trim', explode(',', $navigateProductsOrder));
180180
}
181181

182182
/**
183-
* Convert assert data to array.
183+
* Convert products to verify data to array.
184184
*
185-
* @param string $assert
185+
* @param string $productsToVerify
186186
* @return array
187187
*/
188-
protected function parseAssert($assert)
188+
protected function parseProductsToVerify($productsToVerify)
189189
{
190190
$result = [];
191-
$list = array_map('trim', explode(';', $assert));
191+
$list = array_map('trim', explode(';', $productsToVerify));
192192

193193
foreach ($list as $item) {
194194
list($step, $products) = array_map('trim', explode(':', $item));

0 commit comments

Comments
 (0)