public function testCreateUrlAliasThrowsInvalidArgumentException()
{
$location = $this->getLocationStub();
$urlAliasService = $this->getRepository()->getURLAliasService();
$urlAliasHandler = $this->getPersistenceMockHandler('Content\\UrlAlias\\Handler');
$urlAliasHandler->expects($this->once())->method('createCustomUrlAlias')->with($this->equalTo($location->id), $this->equalTo('path'), $this->equalTo('forwarding'), $this->equalTo('languageCode'), $this->equalTo('alwaysAvailable'))->will($this->throwException(new ForbiddenException('Forbidden!')));
$urlAliasService->createUrlAlias($location, 'path', 'languageCode', 'forwarding', 'alwaysAvailable');
}