skills.guanliai
How-tosAll SkillsCombos
中EN
How-tosAll SkillsCombos

skills.guanliai.com

An AI how-to library organised by scene: which skills to use, how to install, how to prompt, and what traps to avoid.

How-tosAll SkillsCombos

Supported clients

  • Claude Code
  • Cline / Roo Code
  • CodeBuddy
  • CodeGeeX (Zhipu)
  • Comate (Baidu)
  • Cursor
  • Fitten Code
  • Gemini CLI
  • GitHub Copilot
  • Kiro
  • Lingma (Alibaba)
  • MarsCode
  • OpenAI Codex
  • OpenClaw
  • OpenCode
  • Qoder
  • Tencent CloudBase AI
  • Trae
  • VS Code
  • Windsurf
skills.guanliai.com · Agent Skill DirectoryData from GitHub · Next.js + MySQL
HomeGuidesTesting & QualityGuard code quality with AI (translated)

Guard code quality with AI (translated)

Updated 2026-10-11 25 分钟(含落地) Difficulty ★★★☆☆Author Skills 编辑部(译编)

Skills used in this guide (3)

  • webapp-testingwebapp-testingPrimary

    使用 Playwright 与本地 Web 应用交互并测试的工具集。支持验证前端功能、调试 UI 行为、截取浏览器截图、查看浏览器日志。

    npx skills add anthropics/skills -g
  • requesting-code-reviewrequesting-code-reviewSupporting

    当完成任务、实现主要功能,或在合并前验证工作是否符合需求时使用。

    npx skills add obra/superpowers -g
  • tdd-workflowtdd-workflowSupporting

    写新功能、修 bug 或重构时使用:强制测试驱动开发,单元、集成与端到端测试合计覆盖率 80% 以上。

    npx skills add affaan-m/ECC -g

AI writes fast, but the quality gate matters more. Community consensus in three: reverse TDD (AI writes tests, then minimal impl), zero-warning gate (--max-warnings=0, warnings silently become the new baseline), review as a gate (every change through the same gate). Make AI output verifiable and gated, not fast and wild.

Who this is for / not for

For: teams using AI to code, wanting quality not to drop. Not for: those merging untested / unreviewed AI code.

Step-by-step

1. Reverse TDD

Spec in natural language → AI writes tests → AI writes minimal impl to pass:

text
From this spec, write tests first (cover edges and errors), then minimal impl to go green. Don't over-build.

2. Zero-warning gate

ESLint --max-warnings=0, pre-commit for the mechanical layer; accumulated warnings become the baseline — only zero holds.

text
eslint . --max-warnings=0

3. Review as gate

Every change goes through requesting-code-review; auto checks block a batch first, humans only judge "does the standard hold cross-scene".

text
Review this change against team standards: issues, severity, fix; judge if the standard holds cross-scene.

Pitfalls

PitSymptomFix
No testsRegressReverse TDD
Warning pileRot baselineZero warnings
No gateMiss defectsPre-commit
Blind trustIncidentHuman final call

FAQ

TDD with AI?

Tests before impl.

Manage warnings?

Yes, zero-warning gate.

Who reviews?

Auto + human final.

Team uniform?

Same gate for all.

相关源码

  • Quality Assurance in AI-Assisted Development (yushi91)
  • Test-Driven Development with AI (Kinde)
  • Making AI Coding Agents Follow True TDD (brgr.one)
  • Keep Consistent Coding Standards with AI Code (exceeds.ai)

一句话结论

结论:AI 写代码要把质量门做硬——反向 TDD、零警告门禁、审查当关卡,让 AI 产出可验证可守门,你做最终判断。

References

  • Quality Assurance in AI-Assisted Development (yushi91)
  • Test-Driven Development with AI (Kinde)
  • Making AI Coding Agents Follow True TDD (brgr.one)
  • Keep Consistent Coding Standards with AI Code (exceeds.ai)

Related Scenes

Testing & Quality

Write test cases and automation scripts with AI

The biggest value of testing isn't "high coverage" — it's "catching the paths that actually break". The point of AI-generated tests: give it the implemented code or a clear behavior contract, then have it add edge cases. Don't let it invent the thing under test; a test that passes on a fake object p

★★☆☆☆ 20 分钟(含跑通)3 skills
Testing & Quality

Get an AI code review worth reading

The classic failure mode is twenty "suggestions" where eighteen are style preferences. A useful review contains only two kinds of information: what will break, and what will confuse the next reader. So the job is not to make AI say more. It is to forbid everything else.

★★★☆☆ 一次 PR 约 15 分钟3 skills

Contents

  • Who this is for / not for
  • Step-by-step
  • 1. Reverse TDD
  • 2. Zero-warning gate
  • 3. Review as gate
  • Pitfalls
  • FAQ
  • TDD with AI?
  • Manage warnings?
  • Who reviews?
  • Team uniform?
  • 相关源码
  • 一句话结论