def test_retire_success(self): verification = self._create_entry() _listen_for_lms_retire(sender=self.__class__, user=verification.user) ver_obj = SoftwareSecurePhotoVerification.objects.get(user=verification.user) # All values for this user should now be empty string for field in ('name', 'face_image_url', 'photo_id_image_url', 'photo_id_key'): self.assertEqual('', getattr(ver_obj, field))
def test_retire_success(self): verification = self._create_entry() _listen_for_lms_retire(sender=self.__class__, user=verification.user) ver_obj = SoftwareSecurePhotoVerification.objects.get(user=verification.user) # All values for this user should now be empty string for field in ('name', 'face_image_url', 'photo_id_image_url', 'photo_id_key'): self.assertEqual('', getattr(ver_obj, field))
def test_idempotent(self): verification = self._create_entry() # Run this twice to make sure there are no errors raised 2nd time through _listen_for_lms_retire(sender=self.__class__, user=verification.user) fake_completed_retirement(verification.user) _listen_for_lms_retire(sender=self.__class__, user=verification.user) ver_obj = SoftwareSecurePhotoVerification.objects.get(user=verification.user) # All values for this user should now be empty string for field in ('name', 'face_image_url', 'photo_id_image_url', 'photo_id_key'): self.assertEqual('', getattr(ver_obj, field))
def test_idempotent(self): verification = self._create_entry() # Run this twice to make sure there are no errors raised 2nd time through _listen_for_lms_retire(sender=self.__class__, user=verification.user) fake_completed_retirement(verification.user) _listen_for_lms_retire(sender=self.__class__, user=verification.user) ver_obj = SoftwareSecurePhotoVerification.objects.get(user=verification.user) # All values for this user should now be empty string for field in ('name', 'face_image_url', 'photo_id_image_url', 'photo_id_key'): self.assertEqual('', getattr(ver_obj, field))
def test_retire_success_no_entries(self): user = UserFactory() _listen_for_lms_retire(sender=self.__class__, user=user)
def test_retire_success_no_entries(self): user = UserFactory() _listen_for_lms_retire(sender=self.__class__, user=user)