agentleFS
Kevin-Liu-01Kevin-Liu-01/Local-Search/tests/SKILL.md

tests-skill

Skill16 starsChanged 31 days agoMITView on GitHub

How to work in `tests/`. Read before editing here.

The file

We split this skill into the rules it gives an agent

5 rules. About 0 are common, 3 are distinctive, and 2 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈3

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 2

    Very specific

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

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Never connect to a real signed-in browser or fetch a registry in unit/integration tests.

    line 24
  2. Distinctive:

    Keep stdout contracts parseable, and assert stderr and exit status separately.

    line 25
  3. Distinctive:

    Use subprocess-specific environment overrides, not global environment mutations.

    line 26
  4. Very specific:

    Run cargo test --test updates for release-check changes.

    line 33
  5. Very specific:

    Run cargo test --test connection for browser authority and lifecycle changes.

    line 34

≈ “Common” is an estimate: at least 1 in 5 of the 350,495 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

Local-Search / tests

Purpose

<!-- agent-docs:fill:purpose -->

Public CLI regression tests. Exercise real binaries against isolated local state, fake browser endpoints, and fake registries rather than personal browser data.

Mental model & key files

<!-- agent-docs:fill:model -->
  • cli.rs checks help, welcome text, output modes, and structured errors.
  • connection.rs checks explicit browser selection, background work tabs, disconnection, and cleanup boundaries with local fake CDP endpoints.
  • updates.rs checks update JSON, aliases, package-manager detection, opt-out, timeout, and macOS interactive startup via /usr/bin/script.

Patterns to follow / invariants

<!-- agent-docs:fill:patterns -->
  • Set LOCAL_SEARCH_CONFIG_DIR to a test-owned temporary directory.
  • Never connect to a real signed-in browser or fetch a registry in unit/integration tests.
  • Keep stdout contracts parseable, and assert stderr and exit status separately.
  • Use subprocess-specific environment overrides, not global environment mutations.
  • Bound waits and shut down fake listeners and child processes at test completion.
  • Serialize update-check subprocess/PTY fixtures because their real two-second deadlines must not compete with sibling cold process launches on loaded hosts.

Common tasks → first action

<!-- agent-docs:fill:tasks -->
  • Run cargo test --test updates for release-check changes.
  • Run cargo test --test connection for browser authority and lifecycle changes.
  • Finish with cargo fmt --check, cargo test, and cargo clippy --all-targets --all-features -- -D warnings.

Gotchas

<!-- agent-docs:fill:gotchas -->
  • The npm wrapper has its own version; fixtures must not equate it with the native crate.
  • Interactive update checks require both output streams to be terminals. Pipes intentionally do not exercise that path.
  • Unix fake executables need execute permission. PTY assertions are macOS-only; pure update/cache tests also run on other platforms.

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.