[CI] Add unittest Claude skill and supplement unit test coverage#7888
[CI] Add unittest Claude skill and supplement unit test coverage#7888EmmonsCurse wants to merge 1 commit into
Conversation
|
Thanks for your contribution! |
|
/skip-ci ci_iluvatar |
This comment was marked as outdated.
This comment was marked as outdated.
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## develop #7888 +/- ##
==========================================
Coverage ? 77.79%
==========================================
Files ? 396
Lines ? 56001
Branches ? 8769
==========================================
Hits ? 43568
Misses ? 9633
Partials ? 2800
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
869f725 to
6fdda48
Compare
6fdda48 to
4e3408b
Compare
4e3408b to
9b646ba
Compare
PaddlePaddle-bot
left a comment
There was a problem hiding this comment.
🤖 Paddle-CI-Agent | pr_review |
2026-05-23 19:45:17
📋 Review 摘要
PR 概述:新增 FastDeploy unittest Claude Skill 文档,删除非规范测试脚本,补充约 39 个单测文件以提升覆盖率,同时扩展 .coveragerc omit 规则。
变更范围:.claude/skills/(Skill 文档)、scripts/.coveragerc、tests/(大量新增单测)、fastdeploy/entrypoints/openai/(删除遗留脚本)
影响面 Tag:[CI]
问题
| 级别 | 文件 | 概述 |
|---|---|---|
| 🟡 建议 | — | PR 变更量较大(43 文件),建议拆分以降低审查难度和合入风险 |
| ❓ 疑问 | tests/entrypoints/test_api_server.py |
test_launch_uvicorn_exception_handled 无任何 assert,仅靠"不抛异常"通过 |
| ❓ 疑问 | tests/layers/test_fused_moe_marlin_backend.py |
test_create_weights_scale_shapes 中 up_gate 与 down 两个 scale shape 断言值完全相同 [4, 1, 2048],需确认源码意图 |
建议拆分方案:
- PR 1: [CI] Skill 文档 + coveragerc —
.claude/skills/write-fastdeploy-unittest/,scripts/.coveragerc - PR 2: [CI] cache_manager / layers / quantization 单测 —
tests/cache_manager/,tests/layers/,tests/quantization/ - PR 3: [CI] worker / model_executor / scheduler / multimodal 单测 —
tests/worker/,tests/model_executor/,tests/scheduler/,tests/multimodal/ - PR 4: [CI] entrypoints / input / inter_communicator / rl 单测 + 遗留脚本清理 —
tests/entrypoints/,tests/input/,tests/inter_communicator/,tests/rl/,fastdeploy/entrypoints/openai/test_openai.py
📝 PR 规范检查
PR 结构合规,## Motivation、## Modifications、## Usage or Command、## Accuracy Tests、## Checklist 各段均存在且内容完整,标题 Tag [CI] 与 diff 主要影响面(Skill 文档 + CI 脚本 + 单测覆盖)匹配。
总体评价
整体质量较高:Skill 文档结构完整、规范清晰;抽样的 5 个测试文件(test_ipc_cache_transfer、test_fused_moe_marlin_backend、test_w8a8、test_worker_tbo、test_api_server)均有实质性断言,mock 隔离合理,命名符合规范,资源清理到位。存在一处空断言测试(test_launch_uvicorn_exception_handled)和一处 scale shape 断言待确认,建议作者核实后酌情补强,不阻塞合入。
Motivation
To improve unit test development efficiency and standardization, a dedicated Claude skill for FastDeploy unittest generation is introduced. In addition, related unit tests need to be supplemented to improve test coverage and validation completeness.
Modifications
Usage or Command
N/A
Accuracy Tests
N/A
Checklist
[FDConfig],[APIServer],[Engine],[Scheduler],[PD Disaggregation],[Executor],[Graph Optimization],[Speculative Decoding],[RL],[Models],[Quantization],[Loader],[OP],[KVCache],[DataProcessor],[BugFix],[Docs],[CI],[Optimization],[Feature],[Benchmark],[Others],[XPU],[HPU],[GCU],[DCU],[Iluvatar],[Metax]]pre-commitbefore commit.releasebranch, make sure the PR has been submitted to thedevelopbranch, then cherry-pick it to thereleasebranch with the[Cherry-Pick]PR tag.