ln-502-regression-checker

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese

Regression Checker

回归检查器

Runs the existing test suite to ensure no regressions after implementation changes.
运行现有测试套件,确保代码实现变更后不会出现回归问题。

Purpose & Scope

目的与范围

  • Detect test framework (pytest/jest/vitest/go test/etc.) and test dirs.
  • Execute full suite; capture results for Story quality gate.
  • Return PASS/FAIL with counts/log excerpts; never modifies Linear or kanban.
  • 自动检测测试框架(pytest/jest/vitest/go test等)及测试目录。
  • 执行完整测试套件;为Story质量门捕获测试结果。
  • 返回通过/失败状态及对应数量、日志片段;绝不修改Linear或看板内容。

When to Use

使用场景

  • Invoked by ln-500-story-quality-gate Pass 1 (after ln-501)
  • Code quality check passed
  • Before test planning pipeline (ln-510)
  • 由ln-500-story-quality-gate调用 第一阶段(在ln-501之后)
  • 代码质量检查已通过
  • 测试规划流水线(ln-510)之前

Workflow (concise)

工作流程(精简版)

  1. Auto-discover framework and test locations from repo config/files.
  2. Read
    docs/project/runbook.md
    — get exact test commands, Docker setup, environment variables. Use commands from runbook, NOT guessed commands.
  3. Build appropriate test command; run with timeout (~5m); capture stdout/stderr.
  4. Parse results: passed/failed counts; key failing tests.
  5. Output verdict JSON (PASS or FAIL + failures list) and add Linear comment.
  1. 从仓库配置/文件中自动识别测试框架及测试位置。
  2. 读取
    docs/project/runbook.md
    — 获取准确的测试命令、Docker配置、环境变量。必须使用运行手册中的命令,而非推测的命令。
  3. 构建合适的测试命令;设置超时时间(约5分钟)后执行;捕获标准输出/标准错误信息。
  4. 解析结果:统计通过/失败的测试数量;提取关键失败测试信息。
  5. 输出包含判定结果的JSON(通过或失败 + 失败测试列表),并添加Linear评论。

Critical Rules

关键规则

  • No selective test runs; run full suite.
  • Do not fix tests or change status; only report.
  • Language preservation in comment (EN/RU).
  • 不得选择性运行测试;必须执行完整套件。
  • 不得修复测试或修改状态;仅进行结果报告。
  • 评论需保留原语言(英文/俄文)。

Definition of Done

完成标准

  • Framework detected; command executed.
  • Results parsed; verdict produced with failing tests (if any).
  • Linear comment posted with summary.
  • 已检测到测试框架;已执行测试命令。
  • 已解析测试结果;生成包含失败测试(如有)的判定结果。
  • 已在Linear中发布包含摘要的评论。

Reference Files

参考文件

  • Risk-based limits used downstream:
    ../ln-510-test-planner/references/risk_based_testing_guide.md

Version: 3.1.0 (Added mandatory runbook.md reading before test execution) Last Updated: 2026-01-09
  • 下游使用的基于风险的限制:
    ../ln-510-test-planner/references/risk_based_testing_guide.md

版本: 3.1.0(新增执行测试前必须读取runbook.md的要求) 最后更新日期: 2026年1月9日