Sonata\Test\CustomerBundle\Controller\Api\AddressControllerTest::testGetAddressesAction PHP Method

testGetAddressesAction() public method

    public function testGetAddressesAction()
    {
        $addressManager = $this->getMock('Sonata\\Component\\Customer\\AddressManagerInterface');
        $addressManager->expects($this->once())->method('getPager')->will($this->returnValue(array()));
        $paramFetcher = $this->getMock('FOS\\RestBundle\\Request\\ParamFetcherInterface');
        $paramFetcher->expects($this->exactly(3))->method('get');
        $paramFetcher->expects($this->once())->method('all')->will($this->returnValue(array()));
        $this->assertEquals(array(), $this->createAddressController(null, $addressManager)->getAddressesAction($paramFetcher));
    }