Skip to content

Commit 7b95f8f

Browse files
committed
Fix static test failure
1 parent 56c9e23 commit 7b95f8f

File tree

1 file changed

+3
-3
lines changed
  • app/code/Magento/Catalog/Test/Unit/Block/Adminhtml/Category/Checkboxes

1 file changed

+3
-3
lines changed

app/code/Magento/Catalog/Test/Unit/Block/Adminhtml/Category/Checkboxes/TreeTest.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,8 @@ private function createCategoryCollectionStub(array $paths)
4646
return new class($paths) implements \IteratorAggregate, \Countable {
4747
/** @var array */
4848
private $items;
49+
/** @var array|null */
50+
public $lastFilter;
4951
public function __construct(array $paths)
5052
{
5153
$items = [];
@@ -74,9 +76,7 @@ public function addAttributeToSelect($arg)
7476
*/
7577
public function addAttributeToFilter($field, $cond)
7678
{
77-
if ($field || $cond) {
78-
// no-op: reference parameters to satisfy static analyzers
79-
}
79+
$this->lastFilter = [$field, $cond];
8080
return $this;
8181
}
8282
public function getIterator(): \Traversable

0 commit comments

Comments
 (0)