Skip to content
cccskills
FreePublished on GitHub

test-harness-auditor

Audit a repo's test, lint, type-check, static analysis, build, and debug infrastructure for AI coding agents. Generate scored reports and optimized configs for the lint-on-write hook. Triggers on audit tests, test harness, lint setup, check test infrastructure, entering a new repo.

The English summary is being prepared. Showing the original description.

See how to install

Files included (13)

  • SKILL.md7.7 KB
  • README.md2.6 KB
  • references/anti-patterns.md7.8 KB
  • references/factory-lint-categories.md6.8 KB
  • references/stack-profiles.md6.4 KB
  • rule-library/functional-ts.json5.6 KB
  • rule-library/INDEX.md5.2 KB
  • rule-library/python-cli.json4.9 KB
  • rule-library/react.json4.2 KB
  • rule-library/rust-workspace.json3.0 KB
  • scripts/audit.py36.7 KB
  • scripts/extract_conventions.py8.0 KB
  • scripts/generate.py21.0 KB

SKILL.md (original)

Review the instructions the agent will receive before you install.

Test Harness Auditor

Audit any repo's feedback infrastructure across six layers and generate optimized configs for AI coding agents.

When to Run

  • Entering a new repo with no .claude/lint-rules.json
  • User asks to audit tests, lint setup, or agent infrastructure
  • After cloning a repo to check what feedback loops exist
  • Periodically to catch configuration drift

Two-Phase Workflow

Phase 1: Audit (read-only)

Run the audit script to scan the current repo:

uv run ~/.claude/skills/test-harness-auditor/scripts/audit.py

Or target a specific directory:

uv run ~/.claude/skills/test-harness-auditor/scripts/audit.py /path/to/repo

For machine-readable output (consumed by Phase 2):

uv run ~/.claude/skills/test-harness-auditor/scripts/audit.py --json > /tmp/audit.json

To save a snapshot for drift detection (tracks score changes over time):

uv run ~/.claude/skills/test-harness-auditor/scripts/audit.py --save

Combine flags: --json --save saves the snapshot AND outputs JSON. On subsequent --save runs, the report includes a drift section showing score regressions, config changes, and residue file changes.

The script produces a structured Markdown report (or JSON with --json) with:

  • Stack summary: detected language, frameworks, package manager, actual scripts from package.json
  • Scorecard: 0-3 score for each of the six layers (test, lint, type-check, SA, build, debug)
  • Findings: per-layer details on what was detected
  • Debugging residue: files matching *_v2.*, *_backup.*, *_fixed.* patterns
  • Recommendations: prioritized by impact on agent feedback quality (P0-P3)

Present the report to the user. Ask which recommendations to implement before proceeding to Phase 2.

Phase 1.5: Convention Extraction (optional)

Extract "never X"/"always Y" constraints from CLAUDE.md into candidate lint rules:

uv run ~/.claude/skills/test-harness-auditor/scripts/extract_conventions.py

Outputs JSON with candidate lint-rules.json entries derived from project constraints. Present candidates to the user for approval before merging.

Phase 2: Config Generation (after user approval)

Run the generation script (optionally with audit JSON for accurate commands):

uv run ~/.claude/skills/test-harness-auditor/scripts/generate.py --audit /tmp/audit.json

Or without audit data (re-detects stack):

uv run ~/.claude/skills/test-harness-auditor/scripts/generate.py

When --audit is used, generate.py uses actual commands from package.json (vitest, playwright, biome, etc.) instead of generic templates, and detects separate E2E vs unit test runners.

This produces three outputs:

  1. .claude/lint-rules.json — custom grep-based rules for the lint-on-write hook

    • Stack-specific rules (security, debugging residue, error boundaries, observability)
    • Auto-includes matching rule packs from rule-library/ (react, rust-workspace, python-cli; functional-ts is opt-in only)
    • Merges with existing config if present (preserves user customizations)
    • Tagged rules (_tag field) enable idempotent re-runs
  2. CLAUDE.md testing section — test/lint/typecheck/build/SA commands

    • Follows claude-md-manager conventions (command-first, concise)
    • Section-aware merge: when existing CLAUDE.md is found, surgically replaces only ## Commands and ## Testing sections, preserving all other content
    • Present as a proposal — do not overwrite existing CLAUDE.md content
  3. Hook recommendations — which PostToolUse hooks to enable

    • lint-on-write (primary), test-on-fix, type-check-on-write

For each generated config, present it to the user and ask for approval before writing.

Scoring System

ScoreMeaning
0Absent — agent is flying blind on this layer
1Minimal — basic tool present but not configured for agents
2Adequate — tool configured and runnable
3Excellent — strict mode, mutation testing, or advanced config

Six Assessment Layers

  1. Test suite: framework, runner command, coverage config, mutation testing
  2. Linting: standard linter, custom rules, agent-specific rules
  3. Type checking: type checker, strict mode, CI integration
  4. Static analysis: security scanners, complexity checkers, dependency audit
  5. Build/compilation: build command, incremental build, CI validation
  6. Debugger/REPL: debugger availability, REPL access

Integration

  • lint-on-write hook: generated lint-rules.json is consumed by ~/.claude/hooks/lint-on-write.py (violations are severity-tiered: BLOCKING > HIGH > MEDIUM)
  • claude-md-manager: generated CLAUDE.md sections follow its conventions (WHAT/WHY/HOW, command-first)
  • agents-md-manager: for cross-agent compatibility, consider also generating AGENTS.md
  • agnix: complementary tool — validates the agent config files themselves (385 rules for CLAUDE.md/AGENTS.md/SKILL.md stale paths, dead commands, context rot). Our skill validates the codebase infrastructure.

Rule Library

44 rules across 4 domain-specific packs in rule-library/. Auto-loaded packs are selected by generate.py based on detected frameworks and stack. All patterns are single-line grep -En detectable.

PackMatchesRulesHighlights
react.jsonreact, next frameworks10disabled-exhaustive-deps, key-index, async-use-effect, disabled-hooks-rule, context-object-literal
rust-workspace.jsonrust stack8expect-empty-msg, anyhow-in-lib, dbg-macro, panic-outside-tests, println-residue
python-cli.jsonpython stack13shell-true, insecure-deserialization, mutable-default-arg, requests-no-timeout, commonprefix
functional-ts.jsonOpt-in only13array-mutation, sort-reverse, delete-operator, any-type, enum-declaration, namespace-declaration

Opt-in packs

Packs with "_opt_in": true are never auto-loaded. The functional-ts pack enforces strict-FP immutability patterns (Open Souls paradigm). To use it, manually copy its rules into your project's .claude/lint-rules.json.

Exclusion fields

Rules support two exclusion mechanisms:

  • exclude_paths — glob-matched against file paths (e.g. "*/bin/*", "*/main.rs"). Skips the file entirely before grep runs.
  • exclude_patterns — regex-matched against grep output line text (e.g. "test", "// nosec"). Filters matched lines after grep runs.

To add a custom rule pack, create a JSON file in rule-library/ with _frameworks (list) and/or _stack (string) matching fields, plus a rules array. Set "_opt_in": true to prevent auto-loading. Pack rules use pack: prefix in _tag for dedup. See rule-library/INDEX.md for the full inventory.

References

Load these on-demand when deeper context is needed:

  • references/stack-profiles.md — per-stack detection rules and tool recommendations
  • references/factory-lint-categories.md — 7 Factory.ai agent lint categories with grep patterns
  • references/anti-patterns.md — 10 AI-specific anti-patterns with detection heuristics

Scope

  • First-class stacks: JavaScript/TypeScript, Rust, Python, Go, Ruby
  • Other stacks get basic detection with generic recommendations
  • Does not write or modify test files
  • Does not install tools (recommends what to install)
  • Does not modify CI/CD pipelines

Reviews

No reviews yet. Tell others what you thought.

Comments

No login needed. Share how it worked for you, ask a question, or note where it did not run.

No comments yet. Be the first to write one.

Comments are published right away. Do not include personal information such as email addresses or phone numbers. Up to 2 URLs.

0 / 1,000 characters

This form is protected by reCAPTCHA, and the Google Privacy Policy and Terms of Service apply.

More skills from this repository

Search academic papers, build literature reviews, and synthesize research findings — combines Exa search (publication category, domain and date filters) with arxiv-mcp-server for paper discovery, download, and deep analysis. Triggers on academic paper, literature review, research synthesis, arxiv, find papers, scholarly search.

The English summary is being prepared. Showing the original description.

tdimino/claude-code-minoan41Updated Oct 20, 2026

Automates browser interactions for web testing, form filling, screenshots, and data extraction. Use when the user needs to navigate websites, interact with web pages, fill forms, take screenshots, test web applications, or extract information from web pages.

The English summary is being prepared. Showing the original description.

tdimino/claude-code-minoan41Updated Oct 20, 2026

This skill should be used when creating, auditing, or maintaining AGENTS.md files and Codex CLI configuration for any project—including initializing AGENTS.md for cross-agent compatibility (Codex, Cursor, Copilot, Devin, Jules, Amp, Gemini CLI), generating config.toml or .rules files, scaffolding .agents/skills/, converting CLAUDE.md to AGENTS.md, or auditing existing agent configs for bloat and staleness. Complementary to codex-orchestrator (which executes subagents; this skill creates the config files they consume).

The English summary is being prepared. Showing the original description.

tdimino/claude-code-minoan41Updated Oct 20, 2026

Academic research skill for Biblical Hebrew, Semitic linguistics, cuneiform studies, and comparative Ancient Near Eastern research. Provides Sefaria API for Hebrew Bible, CDLI/ORACC for cuneiform databases, and web discovery via Omnisearch, Exa, Firecrawl, and Obscura for finding scholarly sources across JSTOR, Perseus, Persée, Google Scholar, and academia.edu. Triggers on Hebrew quotes, cuneiform, Sefaria, ANE research, Minoan, search for scholarship, find papers, literature review, scholarly search, academic search, Genesis/Tehom, Ugaritic, Talmudic sources, extract from PDF, OCR academic.

The English summary is being prepared. Showing the original description.

tdimino/claude-code-minoan41Updated Oct 20, 2026

Build comprehensive ARCHITECTURE.md files following matklad's canonical guidelines — bird's-eye views, ASCII/Mermaid diagrams, codemaps, invariants, and layer boundaries. Triggers on document the architecture, create ARCHITECTURE.md, map this codebase, architectural overview.

The English summary is being prepared. Showing the original description.

tdimino/claude-code-minoan41Updated Oct 20, 2026

Generate physically-based atmospheric scattering shaders — sky domes, planetary atmospheres, LUT-optimized pipelines, depth-aware post-processing. Four modes — sky-dome, atmosphere-post, planet, lut. Triggers on atmospheric scattering, sky shader, sunset rendering, planet atmosphere, Rayleigh scattering, Mie scattering, volumetric sky, sky dome, atmosphere post-processing, aerial perspective, transmittance LUT, sky rendering, realistic sky, planetary rendering.

The English summary is being prepared. Showing the original description.

tdimino/claude-code-minoan41Updated Oct 20, 2026

See all skills by tdimino

Report a problem with this skill