53 $this->objectManagerHelper =
new ObjectManagerHelper($this);
54 $this->productMock = $this->createMock(ProductInterface::class);
55 $this->locatorMock = $this->createMock(LocatorInterface::class);
56 $this->arrayManagerMock = $this->createMock(ArrayManager::class);
57 $this->downloadablePanel = $this->objectManagerHelper->getObject(
58 DownloadablePanel::class,
60 'locator' => $this->locatorMock,
61 'arrayManager' => $this->arrayManagerMock
75 $this->locatorMock->expects(static::once())
76 ->method(
'getProduct')
77 ->willReturn($this->productMock);
78 $this->productMock->expects(static::once())
81 $this->productMock->expects(static::once())
83 ->willReturn($typeId);
90 $this->assertEquals($resultData, $this->downloadablePanel->modifyData([]));
100 [
'typeId' =>
'someType',
'isDownloadable' =>
'0'],
109 $this->locatorMock->expects(static::once())
110 ->method(
'getProduct')
111 ->willReturn($this->productMock);
112 $this->productMock->expects(static::any())
113 ->method(
'getTypeId');
114 $this->arrayManagerMock->expects(static::exactly(3))
118 $this->assertEquals([], $this->downloadablePanel->modifyMeta([]));
const CODE_IS_DOWNLOADABLE