Skip to content

Commit 7ac1872

Browse files
committed
Fixed failed unit test
1 parent 77a45a8 commit 7ac1872

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

app/code/Magento/Quote/Test/Unit/Model/Quote/AddressTest.php

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,11 @@ class AddressTest extends \PHPUnit\Framework\TestCase
4747
*/
4848
private $quote;
4949

50+
/**
51+
* @var \Magento\Quote\Model\Quote\Address\CustomAttributeListInterface | \PHPUnit_Framework_MockObject_MockObject
52+
*/
53+
private $attributeList;
54+
5055
/**
5156
* @var \Magento\Framework\App\Config | \PHPUnit_Framework_MockObject_MockObject
5257
*/
@@ -165,9 +170,13 @@ protected function setUp()
165170
->disableOriginalConstructor()
166171
->getMock();
167172

173+
$this->attributeList = $this->createMock(\Magento\Quote\Model\Quote\Address\CustomAttributeListInterface::class);
174+
$this->attributeList->method('getAttributes')->willReturn([]);
175+
168176
$this->address = $objectManager->getObject(
169177
\Magento\Quote\Model\Quote\Address::class,
170178
[
179+
'attributeList' => $this->attributeList,
171180
'scopeConfig' => $this->scopeConfig,
172181
'serializer' => $this->serializer,
173182
'storeManager' => $this->storeManager,

0 commit comments

Comments
 (0)