40 $this->objectManager = new \Magento\Framework\TestFramework\Unit\Helper\ObjectManager($this);
42 $this->customerRegistry =
44 $this->customerResourceModel =
47 $this->model = $this->objectManager->getObject(
50 'customerRegistry' => $this->customerRegistry,
51 'customerResourceModel' => $this->customerResourceModel,
63 $customerSecureMock = $this->createMock(\
Magento\
Customer\Model\Data\CustomerSecure::class);
65 $dbAdapter = $this->createMock(\
Magento\Framework\DB\Adapter\AdapterInterface::class);
67 $this->customerRegistry->expects($this->once())
68 ->method(
'retrieveSecureData')
69 ->willReturn($customerSecureMock);
71 $customerSecureMock->expects($this->exactly(3))
75 $this->customerResourceModel->expects($this->any())
76 ->method(
'getConnection')
77 ->willReturn($dbAdapter);
79 $this->customerResourceModel->expects($this->any())
81 ->willReturn(
'customer_entity');
83 $dbAdapter->expects($this->any())
94 $dbAdapter->expects($this->any())