/** * Test the entity update * * @param User $entity the entity * * @depends testCreate * * @return void */ public function testUpdate($entity) { $updateData = $this->entityData; $updateData['id'] = $entity->getId(); $updateData['username'] = '******'; $updatedEntity = $this->manager->update($updateData); $this->checkEntity($updatedEntity, $updateData, array('password')); }
/** * @param User $user */ public function createActivationHash(User $user) { $user->setActivationHash(sha1($user->getId() . $user->getUsername() . $user->getCreated()->getTimestamp())); }