本文整理匯總了Python中factory.fuzzy方法的典型用法代碼示例。如果您正苦於以下問題:Python factory.fuzzy方法的具體用法?Python factory.fuzzy怎麽用?Python factory.fuzzy使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類factory
的用法示例。
在下文中一共展示了factory.fuzzy方法的4個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Python代碼示例。
示例1: finished_at
# 需要導入模塊: import factory [as 別名]
# 或者: from factory import fuzzy [as 別名]
def finished_at(self):
"""Returns finished_at attribute based on started_at value.
Value will be between started_at and one year in future.
"""
return factory.fuzzy.FuzzyDateTime(
self.started_at,
_offer_start_date_max,
).fuzz() + datetime.timedelta(days=1)
示例2: recruitment_end_date
# 需要導入模塊: import factory [as 別名]
# 或者: from factory import fuzzy [as 別名]
def recruitment_end_date(self):
"""Returns recruitment_end_date attribute.
Value will be between recruitment_start_date and one year in future.
"""
return factory.fuzzy.FuzzyDateTime(
self.recruitment_start_date,
_offer_start_date_max,
).fuzz() + datetime.timedelta(days=1)
示例3: reserve_recruitment_end_date
# 需要導入模塊: import factory [as 別名]
# 或者: from factory import fuzzy [as 別名]
def reserve_recruitment_end_date(self):
"""Returns reserve_recruitment_end_date attribute.
Value will be between reserve_recruitment_start_date and one year
in future.
"""
return factory.fuzzy.FuzzyDateTime(
self.reserve_recruitment_start_date,
_offer_start_date_max,
).fuzz() + datetime.timedelta(days=1)
示例4: action_end_date
# 需要導入模塊: import factory [as 別名]
# 或者: from factory import fuzzy [as 別名]
def action_end_date(self):
"""Returns action_end_date attribute based on action_start_date value.
Value will be between action_start_date and one year in future.
"""
return factory.fuzzy.FuzzyDateTime(
self.action_start_date,
_offer_start_date_max,
).fuzz() + datetime.timedelta(days=1)