9 use Magento\Eav\Model\ResourceModel\Entity\Attribute\Group\CollectionFactory;
27 private $objectManagerHelper;
32 private $moduleDataSetupMock;
47 private $collectionFactoryMock;
52 private $scopeConfigMock;
56 $this->moduleDataSetupMock = $this->getMockBuilder(\
Magento\Framework\Setup\ModuleDataSetupInterface::class)
57 ->getMockForAbstractClass();
58 $this->contextMock = $this->getMockBuilder(\
Magento\Eav\Model\Entity\Setup\Context::class)
59 ->disableOriginalConstructor()
61 $this->cacheMock = $this->getMockBuilder(\
Magento\Framework\
App\CacheInterface::class)
62 ->getMockForAbstractClass();
63 $this->collectionFactoryMock = $this->getMockBuilder(CollectionFactory::class)
64 ->disableOriginalConstructor()
66 $this->scopeConfigMock = $this->getMockBuilder(\
Magento\Framework\
App\Config\ScopeConfigInterface::class)
67 ->getMockForAbstractClass();
69 $this->objectManagerHelper =
new ObjectManagerHelper($this);
70 $this->model = $this->objectManagerHelper->getObject(
71 \
Magento\Quote\Setup\QuoteSetup::class,
73 'setup' => $this->moduleDataSetupMock,
74 'context' => $this->contextMock,
75 'cache' => $this->cacheMock,
76 'attrGroupCollectionFactory' => $this->collectionFactoryMock,
77 'config' => $this->scopeConfigMock
84 $this->moduleDataSetupMock->expects($this->once())
85 ->method(
'getConnection')
87 $this->model->getConnection();