test(shipping): 更新订单复核库存与通知流程测试

This commit is contained in:
hugo committed 2026-09-04 20:53:06 +08:00
1 parent 8ec028e6a3
commit 265a6e179a
168 files changed
+9420 -4613

No files matched your search

@@ -63,7 +63,7 @@ def test_sanitize_audit_field_value_truncates_long_text() -> None:
def test_excel_ready_requires_ready_artifact(app) -> None:
"""仅有 export_file_path、无 ready Artifact 时不得冻结(BE-09)。"""
"""无 ready Artifact 时不得冻结;只有 Artifact 进入 ready 才冻结。"""
from app import db
from app.models import (
ShippingExcelTemplate,
@@ -76,14 +76,7 @@ def test_excel_ready_requires_ready_artifact(app) -> None:
)
with app.app_context():
task = ShippingNotice(
task_no='SN-EXCEL-READY-BE09',
source_type='manual',
export_file_path='/tmp/be09.xlsx',
export_file_name='be09.xlsx',
order_data_version=1,
order_lines_migration_status='pending',
)
task = ShippingNotice(task_no='SN-EXCEL-READY-BE09', source_type='manual')
db.session.add(task)
db.session.flush()
assert is_excel_ready_for_task(task) is False