/**
  * Verify Identity endpoint
  * @param IdentityDal $identityDal
  * @return JsonResponse
  */
 public function verifyAction(IdentityDal $identityDal)
 {
     $identityType = $this->getParameter('type');
     $identityValue = $this->getParameter('value');
     $identity = AbstractIdentity::create($identityType, $identityValue);
     $identityDal->save($identity);
     return new JsonResponse($identity->jsonSerializeBrief());
 }
 /**
  * Tests creation of the Application document
  * @expectedException \Virgil\WebServices\RA\Exceptions\ApplicationException
  * @expectedExceptionCode 42000
  * @test
  */
 public function create__withInvalidType__throwsException()
 {
     AbstractIdentity::create('INVALID IDENTITY TYPE', '');
     // Exception was thrown
 }
Exemplo n.º 3
0
 public function jsonSerializeBri()
 {
     return parent::jsonSerialize();
     // TODO: Change the autogenerated stub
 }