بنقرة واحدة
verification-before-completion
Use before claiming work is complete, fixed, or ready to review
التثبيت باستخدام Codex أو Claude انسخ هذا Prompt والصقه في Codex أو Claude أو مساعد آخر ليراجع صفحة Skill ويثبّتها لك.
القائمة
Use before claiming work is complete, fixed, or ready to review
التثبيت باستخدام Codex أو Claude انسخ هذا Prompt والصقه في Codex أو Claude أو مساعد آخر ليراجع صفحة Skill ويثبّتها لك.
استنادا إلى تصنيف SOC المهني
Use when receiving an ambiguous feature request, when scope is unclear, or before writing any plan
Use after verification-before-completion passes and code review is clean, to close out the development branch
Use after writing a plan document in docs/plans/, before requesting user confirmation
Use when receiving feedback from code-reviewer subagent or human reviewer
Use when a feature, bugfix, or refactoring step is completed and needs review, or before merging to main, or when user says "review", "审查", "帮我看看代码"
Use when executing an implementation plan with 3+ independent tasks in the current session
| name | verification-before-completion |
| description | Use before claiming work is complete, fixed, or ready to review |
Type: Technique | Discipline: Rigid
在声明工作完成之前,必须运行验证命令并亲眼读完输出。
核心原则: 没有运行的验证 = 没有验证。"应该能过"不是证据,** TEST SUCCEEDED ** 才是。
绝对禁止:
| 变更范围 | 验证命令 |
|---|---|
只改 GrowingTrackerCore/ 下的源码 | 跑 GrowingAnalyticsTests scheme,用 -only-testing:GrowingAnalyticsTests/<子目录或 case> 聚焦 TrackerCoreTests 子集 |
| 改了无埋点核心模块 | 同上,聚焦 AutotrackerCoreTests 子集 |
改了某个可选 Module(Modules/*/) | 跑 ModulesTests 下对应子集(如 ModulesTests/HybridTests、ModulesTests/ProtobufTests) |
| 改了 agent/skill/文档配置文件 | 无需构建,确认文件内容正确即可 |
| 改了核心路径(事件/存储/网络/Session) | 完整跑 GrowingAnalyticsTests.xctestplan(不加 -only-testing:) |
测试目标全部编译进
GrowingAnalyticsTests这一个 scheme,TrackerCoreTests/等是源码子目录,不是独立 target/scheme。如果不确定范围,直接跑完整 testplan(多花几分钟比漏验证强)。
# 构建 + 运行测试(与 .github/workflows/ci.yml 对齐)
xcodebuild test \
-workspace Example/GrowingAnalytics.xcworkspace \
-scheme GrowingAnalyticsTests \
-testPlan GrowingAnalyticsTests \
-destination 'platform=iOS Simulator,name=iPhone 17 Pro' \
| xcbeautify
# 仅构建(Example App,无测试)
xcodebuild build \
-workspace Example/GrowingAnalytics.xcworkspace \
-scheme Example \
-destination 'platform=iOS Simulator,name=iPhone 17 Pro' \
| xcbeautify
# Pod lint(发布前校验 podspec)
pod lib lint GrowingAnalytics.podspec --allow-warnings
# SPM 构建(跨平台抽查,参考 .github/workflows/spm.yml)
xcodebuild build -scheme GrowingAutotracker \
-destination 'platform=iOS Simulator,name=iPhone 17 Pro' \
| xcbeautify
xcodebuild build -scheme GrowingTracker \
-destination 'platform=macOS' \
| xcbeautify
设备名以
xcrun simctl list devices available为准;CI 当前用iPhone 17 Pro。 若本机未装xcbeautify(brew install xcbeautify),临时可用xcpretty代替。
等命令执行完毕,不提前下结论。
测试通过的标志:
** TEST SUCCEEDED **
构建成功的标志:
** BUILD SUCCEEDED **
失败的标志(任意一条 = 失败):
** TEST FAILED **
** BUILD FAILED **
error:
FAILED
** TEST SUCCEEDED ** 或 ** BUILD SUCCEEDED **error: 行✅ 正确做法:
构建通过(** BUILD SUCCEEDED **)。
测试通过(42 tests passed,0 failed)。
❌ 错误做法:
改好了。应该没问题。(没有运行命令)
本次改动是什么?
├── agent/skill/docs/配置文件 → 确认文件内容正确 → 完成
├── SDK 源码(非核心路径) → 构建对应模块 → 通过 → 完成
│ → 失败 → systematic-debugging
└── SDK 核心路径(事件/存储/网络)
├── 构建 → 失败 → systematic-debugging
│ → 通过
└── 运行测试 → 失败 → systematic-debugging
→ 通过 → 完成
| Excuse | Reality |
|---|---|
| "改完了应该能过吧" | 猜不算证据,跑命令才算 |
| "上次跑过一次没问题" | 当前 commit 要重新跑 |
| "构建过了就算验证" | 构建 ≠ 测试 |
| "改 README 这种不用验证" | 纯文档改动可跳过,但必须显式判定 |
** TEST SUCCEEDED ** 出现才算sdk-code-review 或 finishing-a-development-branchsystematic-debugging