PayrollManagementSystem/backend/tests/integration
liuwenxin 680661a80b feat(allocation): 二次分配方案录入/替换/终态门槛(分摊计算待澄清另批)
- SecondaryAllocationIn/Out:比例走金额红线口径(str 入参、两位小数、
  超 100 拒绝不静默舍入);参与人 schema 层去重(uk 前置友好提示)
- create/update 同事务写入(replace_allocations,先删后 flush 再插——
  uk 表防御写法);create 放编号重试循环内,rollback 后方案随业务重来
- 人员在职复用 ensure_active(label=分摊参与),personnel_name 冗余固化;
  FK RESTRICT:被方案引用人员禁删,方案回显不静默失联
- 合计不强制 100%(需求原文):详情 allocation_hint 只展示合计/余额,
  余额归属待澄清 #2 不落库
- 单测 13 例(比例边界/去重)+ 集成 9 例(回显/替换清空/离职 400/
  终态禁改/RESTRICT 保护)

Co-Authored-By: Claude Code <noreply@anthropic.com>
2026-10-15 18:31:27 +08:00
..
__init__.py chore: 初始化项目结构与登录鉴权模块 2026-10-09 18:46:36 +08:00
conftest.py test(business): 业务数据管理模块集成用例(70 例)与两处缺陷修复 2026-10-13 13:39:09 +08:00
factories.py refactor(test): 集成工厂上提共用,submit_change 拆校验段,审计重试断言对齐全局兜底 2026-10-15 10:58:44 +08:00
test_audit_retry.py refactor(test): 集成工厂上提共用,submit_change 拆校验段,审计重试断言对齐全局兜底 2026-10-15 10:58:44 +08:00
test_auth_flow.py chore: 初始化项目结构与登录鉴权模块 2026-10-09 18:46:36 +08:00
test_business_roles.py test(system): 补交岗位角色与参数管理集成用例(M1 遗漏入库) 2026-10-13 09:26:08 +08:00
test_businesses.py fix(business): 行金额乘积显式两位固化,计提比例对负天数钳制 2026-10-14 18:58:30 +08:00
test_customers.py style(backend): ruff format 统一此前批次的排版残留 2026-10-14 18:46:43 +08:00
test_health.py chore: 初始化项目结构与登录鉴权模块 2026-10-09 18:46:36 +08:00
test_log_query.py feat(system): 完成后端系统管理(审计/角色/操作日志/日志查询) 2026-10-10 16:28:04 +08:00
test_no_generator.py fix(no_generator): 编号 MAX 检索改长度优先排序,破解位宽进位后字典序失效 2026-10-14 14:09:30 +08:00
test_param_management.py feat(migration): V6 系统设置/二次分配/审批表与角色参数种子 2026-10-15 17:25:23 +08:00
test_personnel.py style(backend): ruff format 统一此前批次的排版残留 2026-10-14 18:46:43 +08:00
test_products.py fix(product): 删除引用保护/单价小数位校验,IntegrityError 全局兜底转 400 2026-10-14 18:48:32 +08:00
test_ratings.py fix(rating): 区间重叠判定改用锁定读取,防并发重叠双提交 2026-10-14 19:01:11 +08:00
test_receipts.py refactor(test): 集成工厂上提共用,submit_change 拆校验段,审计重试断言对齐全局兜底 2026-10-15 10:58:44 +08:00
test_role_management.py feat(system): 完成后端系统管理(审计/角色/操作日志/日志查询) 2026-10-10 16:28:04 +08:00
test_schema_sync.py feat(migration): V6 系统设置/二次分配/审批表与角色参数种子 2026-10-15 17:25:23 +08:00
test_secondary_allocation.py feat(allocation): 二次分配方案录入/替换/终态门槛(分摊计算待澄清另批) 2026-10-15 18:31:27 +08:00
test_settings.py feat(settings): 公司信息配置与 logo 管理(public 端点供登录页) 2026-10-15 18:22:12 +08:00
test_shipments.py refactor(test): 集成工厂上提共用,submit_change 拆校验段,审计重试断言对齐全局兜底 2026-10-15 10:58:44 +08:00
test_user_management.py feat(system): 完成后端系统管理(审计/角色/操作日志/日志查询) 2026-10-10 16:28:04 +08:00