Skip to content

Commit cc7c0b6

Browse files
committed
Fix one unit test to work with modified RequestInterface
Example of how the broken unit tests can be fixed. Please identify all broken tests as part of your pull request and provide fixes for them so that we may accept your pull request.
1 parent d3a9668 commit cc7c0b6

File tree

1 file changed

+2
-7
lines changed
  • dev/tests/unit/testsuite/Magento/Catalog/Controller/Adminhtml/Product/Action/Attribute

1 file changed

+2
-7
lines changed

dev/tests/unit/testsuite/Magento/Catalog/Controller/Adminhtml/Product/Action/Attribute/SaveTest.php

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -151,13 +151,8 @@ protected function prepareContext()
151151
->disableOriginalConstructor()
152152
->getMock();
153153

154-
$this->request = $this->getMock(
155-
'Magento\Framework\App\RequestInterface',
156-
['getParam', 'getModuleName', 'setModuleName', 'getActionName', 'setActionName', 'getCookie'],
157-
[],
158-
'',
159-
false
160-
);
154+
$this->request = $this->getMockBuilder('Magento\Framework\App\RequestInterface')
155+
->disableOriginalConstructor()->getMock();
161156
$this->response = $this->getMock('Magento\Framework\App\Response\Http', [], [], '', false);
162157
$this->objectManager = $this->getMock('Magento\Framework\ObjectManagerInterface');
163158
$this->eventManager = $this->getMock('Magento\Framework\Event\ManagerInterface', [], [], '', false);

0 commit comments

Comments
 (0)