test(pool): 修复测试用例中硬编码历史日期导致租约过期判定的问题
This commit is contained in:
@@ -19,7 +19,7 @@ from web.backend.models import (
|
||||
from web.backend.services import account_pool as pool
|
||||
from web.backend.services.automation.jobs import account_lease_reaper as reaper
|
||||
|
||||
NOW = datetime(2026, 10, 7, 12, 0, 0, tzinfo=UTC)
|
||||
NOW = datetime.now(UTC).replace(microsecond=0)
|
||||
|
||||
|
||||
class _ReaperBase:
|
||||
|
||||
@@ -19,7 +19,7 @@ from tests.support.db import get_test_engine, make_test_session
|
||||
from web.backend.models import Account, AccountEvent, AccountLease, DouyuTask, User
|
||||
from web.backend.services import account_pool as pool
|
||||
|
||||
NOW = datetime(2026, 10, 7, 10, 0, 0, tzinfo=UTC)
|
||||
NOW = datetime.now(UTC).replace(microsecond=0)
|
||||
COMMODITY = "20260120QYOOB_bag10"
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user