agentleFS
NVIDIAKnown publisherNVIDIA/Personal-AI-Router/.agents/skills/pair-test-style/SKILL.md

pair-test-style

Skill1.5k starsChanged 2 months agoApache-2.0View on GitHub

Write, refactor, or review tests in Personal AI Router using focused cases, descriptive subtests, explicit error handling, and structured assertions. Use when adding or changing Go service or desktop tests; apply to the tests in scope rather than starting a repository-wide cleanup.

Trending

Quiet since September.thin dataabout the whole repository

Dec 2025: 0 mentionsJan 2026: 0 mentionsFeb 2026: 0 mentionsMar 2026: 0 mentionsApr 2026: 0 mentionsMay 2026: 0 mentionsJun 2026: 0 mentionsJul 2026: 0 mentionsAug 2026: 0 mentionsSep 2026: 10 mentionsOct 2026: 0 mentionsNov 2026: 0 mentions
Dec 2025Jun 2026Nov 2026
Mentions a month of the NVIDIA/Personal-AI-Router repository that our weekly crawl found: only 10 in all, so this is a hint, not a trend. There is no adoption data for this file yet.

Who's talking about NVIDIA/Personal-AI-Router

The biggest 5 of 10 mentions linking to the repository that our crawl found. Each line is their own headline.

See all 10

Talked about on GitHub, Hacker News and Bluesky (10 times).

On GitHub · 6

1 more on GitHub

On Hacker News · 2

The file

We split this skill into the rules it gives an agent

12 rules. About 0 are common, 9 are distinctive, and 3 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈9

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 3

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Keep each test's setup, action, and expected behavior easy to follow.

    line 16
  2. Distinctive:

    Keep a table-driven test dedicated to its related cases.

    line 24
  3. Distinctive:

    Prefer explicit cases over nested loops and boolean mode matrices when the combinations obscure what is being checked.

    line 26
  4. Distinctive:

    Use ordinary tables when they are clearer.

    line 40
  5. Distinctive:

    Keep helpers local unless reuse across tests justifies a shared fixture.

    line 46
  6. Distinctive:

    Check setup, file I/O, encoding, decoding, and operation errors.

    line 50
  7. Very specific:

    Prefer explicit t.Fatalf checks or a small test-only must-succeed helper that fails immediately.

    line 53
  8. Very specific:

    Avoid strings.Contains as evidence that a serialized response or persisted configuration has the correct values.

    line 57
  9. Distinctive:

    Use substring assertions when the contract is actually unstructured text, such as a diagnostic, and the selected text is what the test …

    line 59
  10. Very specific:

    Use named constants such as http.StatusBadGateway and http.MethodPut instead of magic protocol values.

    line 61
  11. Distinctive:

    Do not introduce a new framework or production-only test hooks for this style.

    line 71
  12. Distinctive:

    Run the relevant existing tests and required repository checks.

    line 73

≈ “Common” is an estimate: at least 1 in 5 of the 213,895 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md
<!-- SPDX-FileCopyrightText: Copyright (c) 2026 NVIDIA CORPORATION & AFFILIATES. All rights reserved. SPDX-License-Identifier: Apache-2.0 -->

PAIR test style

Keep each test's setup, action, and expected behavior easy to follow. These conventions apply to contributors and coding agents working on repository tests. They guide test structure; they do not require new coverage or unrelated rewrites.

Focus each test

  • Give each top-level test one behavior to prove. Split long tests that combine validation, persistence, restart, and recovery into independently readable tests.
  • Keep a table-driven test dedicated to its related cases. Put an unrelated one-off assertion or scenario in its own test function.
  • Prefer explicit cases over nested loops and boolean mode matrices when the combinations obscure what is being checked. Keep a matrix when the combinations themselves are the behavior under test and the names explain them.
  • Name subtests after their scenario or outcome: process mode, command mode, rejects bind override, or preserves response body, rather than true, false, or an index.

Share setup without hiding the cases

For Go cases with the same setup and assertions, prefer a local helper closure that captures shared setup and calls t.Run. List explicit, named calls below it. A signature such as test := func(name, input, wantError string) often makes cases easier to read than a large table with mode-dependent branches.

Use ordinary tables when they are clearer. Separate acceptance and rejection helpers when that removes branching and makes expected outcomes explicit. Keep mutable state fresh per case so cases do not depend on execution order.

Mark Go assertion and setup helpers with t.Helper(). Pass the subtest's *testing.T to helpers that report failures so errors belong to the right case. Keep helpers local unless reuse across tests justifies a shared fixture.

Check errors and structured results

  • Check setup, file I/O, encoding, decoding, and operation errors. Do not discard an error just because the fixture is expected to be valid. Fail at the operation that failed, with enough context to diagnose it.
  • Prefer explicit t.Fatalf checks or a small test-only must-succeed helper that fails immediately. A Must helper is optional; avoid adding an abstraction when an explicit check is clearer.
  • Decode JSON and other structured output, then assert the relevant fields. Avoid strings.Contains as evidence that a serialized response or persisted configuration has the correct values. Check parsing errors before fields.
  • Use substring assertions when the contract is actually unstructured text, such as a diagnostic, and the selected text is what the test intends to verify.
  • Use named constants such as http.StatusBadGateway and http.MethodPut instead of magic protocol values. Format multiline fixtures and header maps readably; run gofmt on changed Go tests.

Fit the existing test suite

For desktop tests, carry over the same focus, naming, error handling, and structured assertions using Vitest's existing patterns. Follow desktop test conventions for typed mocks, module-boundary fakes, network isolation, and temporary-directory cleanup. Do not introduce a new framework or production-only test hooks for this style.

Run the relevant existing tests and required repository checks. In review, verify that each changed test has a clear failure condition, names the behavior it proves, checks its setup errors, and can be understood without tracing an unrelated scenario. State any verification that could not be run.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.