Skip to content
Snippets Groups Projects
Commit 1550d511 authored by vtymchynskyi's avatar vtymchynskyi
Browse files

MAGETWO-35385: Fatal error when trying to send notify customer by email about shipment

parent 552fa09d
No related merge requests found
...@@ -215,10 +215,12 @@ class AddCommentTest extends \PHPUnit_Framework_TestCase ...@@ -215,10 +215,12 @@ class AddCommentTest extends \PHPUnit_Framework_TestCase
$layoutMock = $this->getMock('Magento\Framework\View\Layout', ['getBlock'], [], '', false); $layoutMock = $this->getMock('Magento\Framework\View\Layout', ['getBlock'], [], '', false);
$blockMock = $this->getMock('Magento\Shipping\Block\Adminhtml\View\Comments', ['toHtml'], [], '', false); $blockMock = $this->getMock('Magento\Shipping\Block\Adminhtml\View\Comments', ['toHtml'], [], '', false);
$blockMock->expects($this->once())->method('toHtml')->willReturn($result); $blockMock->expects($this->once())->method('toHtml')->willReturn($result);
$layoutMock->expects($this->once())->method('getBlock')->with('shipment_comments')->willReturn($blockMock); $layoutMock->expects($this->once())->method('getBlock')
->with('shipment_comments')->willReturn($blockMock);
$resultLayoutMock->expects($this->once())->method('getLayout')->willReturn($layoutMock); $resultLayoutMock->expects($this->once())->method('getLayout')->willReturn($layoutMock);
$resultLayoutMock->expects($this->once())->method('addDefaultHandle'); $resultLayoutMock->expects($this->once())->method('addDefaultHandle');
$this->resultLayoutFactoryMock->expects($this->once())->method('create')->will($this->returnValue($resultLayoutMock)); $this->resultLayoutFactoryMock->expects($this->once())->method('create')
->will($this->returnValue($resultLayoutMock));
$this->responseMock->expects($this->once())->method('setBody')->with($result); $this->responseMock->expects($this->once())->method('setBody')->with($result);
$this->assertNull($this->controller->execute()); $this->assertNull($this->controller->execute());
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment