19 $cacheContextMock = $this->createMock(\
Magento\Framework\Indexer\CacheContext::class);
21 $eventManagerMock = $this->createMock(\
Magento\Framework\Event\ManagerInterface::class);
22 $eventManagerMock->expects($this->once())
24 ->with(
'clean_cache_by_tags', [
'object' => $cacheContextMock]);
26 $objectManager = new \Magento\Framework\TestFramework\Unit\Helper\ObjectManager($this);
30 'cacheContext' => $cacheContextMock,
31 'eventManager' => $eventManagerMock,
36 public function testAroundUpdateAttributes()
39 $productActionMock = $this->createMock(\
Magento\Catalog\Model\
Product\Action::class);
40 $this->model->afterUpdateAttributes($productActionMock, $productActionMock);
43 public function testAroundUpdateWebsites()
46 $productActionMock = $this->createMock(\
Magento\Catalog\Model\Product\Action::class);
47 $this->model->afterUpdateWebsites($productActionMock, $productActionMock);