Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
git clone --depth 1 https://github.com/steph-dove/klaussy-agentsWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/rules/steph-dove/klaussy-agents/tests)<a href="https://agentmods.dev/rules/steph-dove/klaussy-agents/tests"><img src="https://agentmods.dev/badge/rules/steph-dove/klaussy-agents/tests.svg" alt="Measured on agentmods" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00000 | $0.00698 |
| Opus 5 | $0.00000 | $0.00349 |
| Sonnet 5 | $0.00000 | $0.00140 |
| Haiku 4.5 | $0.00000 | $0.00070 |
Grade A, and why
tests scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 7d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
What it actually says
Conventions
- FastAPI-style session dependency injection: Use get_db() dependency pattern with Depends() for session lifecycle.
Example context from
tests/test_security_scopes.py(lines 10-20):return {"count": 0} @pytest.fixture(name="app") def app_fixture(call_counter: dict[str, int]): def get_db(): call_counter["count"] += 1 return f"db_{call_counter['count']}" def get_user(db: Annotated[str, Depends(get_db)]): return "user" - HTTP errors raised in service layer: HTTPException is frequently raised outside the API layer.
Example context from
tests/test_starlette_exception.py(lines 9-19):@app.get("/items/{item_id}") async def read_item(item_id: str): if item_id not in items: raise HTTPException( status_code=404, detail="Item not found", headers={"X-Error": "Some custom header"}, ) return {"item": items[item_id]} - Semi-centralized exception handling: Exception handlers are spread across 2 modules.
Example context from
tests/test_validation_error_context.py(lines 27-37):captured_exception = ExceptionCapture() app.mount(path="/sub", app=sub_app) @app.exception_handler(RequestValidationError) @sub_app.exception_handler(RequestValidationError) async def request_validation_handler(request: Request, exc: RequestValidationError): captured_exception.capture(exc) raise exc - OAuth2 authentication: Use OAuth2 for authentication. OAuth2 usages: 13.
Example context from
tests/test_dependency_paramless.py(lines 1-9):from typing import Annotated from fastapi import FastAPI, HTTPException, Security from fastapi.security import ( OAuth2PasswordBearer, SecurityScopes, ) from fastapi.testclient import TestClient - Mocking with pytest monkeypatch fixture: Use pytest monkeypatch fixture for test mocking. Also uses: unittest.mock / Mock, @patch decorator.
Example context from
tests/test_frontend.py(lines 24-34):calls.append(name) return dependency def test_frontend_exact_prefix_path_serves_index(tmp_path: Path): dist = tmp_path / "dist" write_file(dist / "index.html", "app") app = FastAPI() app.frontend("/", directory=dist) - Test naming: Simple style (test_feature): Use Use Simple style (test_feature) naming. 2215/2274 test functions. naming style for all test functions.
Example context from
tests/test_datastructures.py(lines 8-14):from fastapi.testclient import TestClient def test_upload_file_invalid_pydantic_v2(): with pytest.raises(ValueError): UploadFile._validate("not a Starlette UploadFile", {})
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 7d ago First seen · 88 lines · 0 tokens per session scan A 7f2b8018ba4b
tests is a cursor rule published in the GitHub repository steph-dove/klaussy-agents (16 stars, last pushed 10d ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 698 tokens. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.
Other cursor rules, from other repositories
atmos-rules
This is a Golang CLI project using Cobra for command structure and Viper for configuration management. The project maintains high code quality standards through golangci-lint and aims for maximum test coverage. The repository also includes the website source code for https://atmos.tools.
workflow
BDD-style workflow, UI screenshots in the PR, HTTP OpenAPI and config schema sync before lint, final checks.
implementation-order
Layered implementation order (cake model).
hatch3r-dynamic-stack-verification
Runtime-evidence gates for stacks with no static type layer (plain-JS Vue, dynamic persistence) — smoke-mount changed components, dormant-collection-read ratchet, runtime smoke evidence on module-boundary changes; a green lint+build+mock-suite proves a layer, not the system.
development-workflow-react
Essential linting and quality checks for React + Vite development.
pytest-what-to-test-and-mocking
We mock external API calls (mark live tests with @pytest.mark.flaky()). We reuse fixtures from conftest.py. We always use pytest as testing framework - never import unittest. We use pytest-mock (mocker fixture) and monkeypatch for mocking, not unittest.mock.