示例#1
0
 public function testGetAddressCollection()
 {
     $addressData = $this->_getAddresses();
     $searchResult = $this->getMockForAbstractClass('Magento\\Customer\\Api\\Data\\AddressSearchResultsInterface', [], '', false, true, true, ['getItems']);
     $searchResult->expects($this->any())->method('getItems')->will($this->returnValue($addressData));
     $this->addressRepository->expects($this->any())->method('getList')->will($this->returnValue($searchResult));
     $this->assertEquals($addressData, $this->_addressBlock->getAddressCollection());
 }
示例#2
0
 public function testGetAddressCollection()
 {
     $addressData = $this->_getAddresses();
     $this->_addressService->expects($this->any())->method('getAddresses')->will($this->returnValue($addressData));
     $this->assertEquals($addressData, $this->_addressBlock->getAddressCollection());
 }