public function testDeleteAddressInvalidAction()
{
$this->setExpectedException('Symfony\\Component\\HttpKernel\\Exception\\NotFoundHttpException');
$addressManager = $this->getMock('Sonata\\Component\\Customer\\AddressManagerInterface');
$addressManager->expects($this->once())->method('findOneBy')->will($this->returnValue(null));
$addressManager->expects($this->never())->method('delete');
$this->createAddressController(null, $addressManager)->deleteAddressAction(1);
}