本文整理汇总了Python中verify_student.models.VerificationStatus.get_location_id方法的典型用法代码示例。如果您正苦于以下问题:Python VerificationStatus.get_location_id方法的具体用法?Python VerificationStatus.get_location_id怎么用?Python VerificationStatus.get_location_id使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类verify_student.models.VerificationStatus
的用法示例。
在下文中一共展示了VerificationStatus.get_location_id方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: test_get_location_id
# 需要导入模块: from verify_student.models import VerificationStatus [as 别名]
# 或者: from verify_student.models.VerificationStatus import get_location_id [as 别名]
def test_get_location_id(self):
"""
Getting location id for a specific checkpoint.
"""
# creating software secure attempt against checkpoint
self.first_checkpoint.add_verification_attempt(SoftwareSecurePhotoVerification.objects.create(user=self.user))
# add initial verification status for checkpoint
VerificationStatus.add_verification_status(checkpoint=self.first_checkpoint, user=self.user, status="submitted")
attempt = SoftwareSecurePhotoVerification.objects.filter(user=self.user)
self.assertIsNotNone(VerificationStatus.get_location_id(attempt))
self.assertEqual(VerificationStatus.get_location_id(None), "")
示例2: test_get_location_id
# 需要导入模块: from verify_student.models import VerificationStatus [as 别名]
# 或者: from verify_student.models.VerificationStatus import get_location_id [as 别名]
def test_get_location_id(self):
""" Getting location id for a specific checkpoint """
# creating software secure attempt against checkpoint
self.check_point1.add_verification_attempt(SoftwareSecurePhotoVerification.objects.create(user=self.user))
# add initial verification status for checkpoint
VerificationStatus.add_verification_status(
checkpoint=self.check_point1,
user=self.user,
status='submitted',
location_id=self.dummy_reverification_item_id_1
)
attempt = SoftwareSecurePhotoVerification.objects.filter(user=self.user)
self.assertIsNotNone(VerificationStatus.get_location_id(attempt))
self.assertEqual(VerificationStatus.get_location_id(None), '')