Skip to content

Commit e0067b4

Browse files
committed
MC-16607: Fix Unrelated Static Test Failures
- create and use parameters wrapper
1 parent dc6ef86 commit e0067b4

File tree

2 files changed

+32
-13
lines changed

2 files changed

+32
-13
lines changed

app/code/Magento/Reports/Block/Adminhtml/Grid.php

Lines changed: 19 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,12 @@
66

77
namespace Magento\Reports\Block\Adminhtml;
88

9+
use Magento\Backend\Block\Template\Context;
10+
use Magento\Backend\Helper\Data;
11+
use Magento\Framework\Url\DecoderInterface;
12+
use Magento\Framework\App\ObjectManager;
13+
use Magento\Framework\Stdlib\Parameters;
14+
915
/**
1016
* Backend report grid block
1117
*
@@ -16,12 +22,12 @@
1622
class Grid extends \Magento\Backend\Block\Widget\Grid
1723
{
1824
/**
19-
* @var \Magento\Framework\Url\DecoderInterface
25+
* @var DecoderInterface
2026
*/
2127
private $urlDecoder;
2228

2329
/**
24-
* @var \Zend\Stdlib\Parameters
30+
* @var Parameters
2531
*/
2632
private $parameters;
2733

@@ -82,24 +88,24 @@ class Grid extends \Magento\Backend\Block\Widget\Grid
8288
protected $_filterValues;
8389

8490
/**
85-
* @param \Magento\Backend\Block\Template\Context $context
86-
* @param \Magento\Backend\Helper\Data $backendHelper
91+
* @param Context $context
92+
* @param Data $backendHelper
8793
* @param array $data
88-
* @param \Magento\Framework\Url\DecoderInterface|null $urlDecoder
89-
* @param \Zend\Stdlib\Parameters $parameters
94+
* @param DecoderInterface|null $urlDecoder
95+
* @param Parameters $parameters
9096
*/
9197
public function __construct(
92-
\Magento\Backend\Block\Template\Context $context,
93-
\Magento\Backend\Helper\Data $backendHelper,
98+
Context $context,
99+
Data $backendHelper,
94100
array $data = [],
95-
\Magento\Framework\Url\DecoderInterface $urlDecoder = null,
96-
\Zend\Stdlib\Parameters $parameters = null
101+
DecoderInterface $urlDecoder = null,
102+
Parameters $parameters = null
97103
) {
98-
$this->urlDecoder = $urlDecoder ?? \Magento\Framework\App\ObjectManager::getInstance()->get(
99-
\Magento\Framework\Url\DecoderInterface::class
104+
$this->urlDecoder = $urlDecoder ?? ObjectManager::getInstance()->get(
105+
DecoderInterface::class
100106
);
101107

102-
$this->parameters = $parameters ?? new \Zend\Stdlib\Parameters();
108+
$this->parameters = $parameters ?? new Parameters();
103109

104110
parent::__construct($context, $backendHelper, $data);
105111
}
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
<?php
2+
/**
3+
* Copyright © Magento, Inc. All rights reserved.
4+
* See COPYING.txt for license details.
5+
*/
6+
namespace Magento\Framework\Stdlib;
7+
8+
/**
9+
* Class Parameters
10+
*/
11+
class Parameters extends \Zend\Stdlib\Parameters
12+
{
13+
}

0 commit comments

Comments
 (0)