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/marianfoo/mcp-sap-docsWrote 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/marianfoo/mcp-sap-docs/30-tests-and-output)<a href="https://agentmods.dev/rules/marianfoo/mcp-sap-docs/30-tests-and-output"><img src="https://agentmods.dev/badge/rules/marianfoo/mcp-sap-docs/30-tests-and-output/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/rules/marianfoo/mcp-sap-docs/30-tests-and-output"><img src="https://agentmods.dev/badge/rules/marianfoo/mcp-sap-docs/30-tests-and-output.svg" alt="Reviewed on agentmods" width="80" 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.00510 | $0.00510 |
| Opus 5.5 | $0.00204 | $0.00204 |
| Sonnet 5.5 | $0.00102 | $0.00102 |
| Haiku 4.5 | $0.00051 | $0.00051 |
Grade A, and why
30-tests-and-output 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 3mo 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.
Copies of this mod
1 near-identical copy found in the catalogue:
- 30-tests-and-output — 100% identical, 0 lines differ
What it actually says
Tests & Expected Output (Rule)
When changing output formatting or test stability.
Test Architecture
- Test Runner:
test/tools/run-tests.js- Unified test execution - HTTP Client:
test/_utils/httpClient.js- Server interaction utilities - Result Parser:
test/_utils/parseResults.js- Output format validation - Smoke Tests:
test/tools/search.smoke.js- Quick functionality validation
Expected Output Format (BM25-Only)
⭐️ **<document-id>** (Score: <final-score>)
<description-preview>
Use in sap_docs_get
Test Categories
- Search Tests: Verify query results and context detection
- Retrieval Tests: Document fetching and formatting
- Integration Tests: End-to-end MCP tool functionality
- Performance Tests: Response time and resource usage
Test Data Structure
{
name: 'Test Name',
tool: 'sap_docs_search',
query: 'search term',
expectIncludes: ['/expected/document/id'],
validate: (results) => { /* custom validation */ }
}
Output Validation
- Score Format: Numeric scores with 2 decimal places
- Context Indicators: Emoji-based context detection (🎨🏗️🧪)
- Source Attribution: Clear library identification
- Result Limits: Configurable via
CONFIG.RETURN_K(default: 25)
Test Execution
- Fast Tests:
npm run test:fast- Skip build, use existing artifacts - Full Tests:
npm run test- Build + test complete pipeline - Smoke Tests:
npm run test:smoke- Quick validation only - Community Tests:
npm run test:community- SAP Community search functionality - MCP Inspector:
npm run inspect- Debug MCP protocol interactions
@file test/tools/run-tests.js @file test/_utils/parseResults.js @file test/_utils/httpClient.js @file test/tools/search.smoke.js @file test/tools/sap_docs_search/search-cap-docs.js @file test/tools/sap_docs_search/search-cloud-sdk-js.js @file test/tools/sap_docs_search/search-sapui5-docs.js @file docs/TESTS.md @file docs/DEV.md
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.
- 3mo ago First seen · 56 lines · 510 tokens per session scan A 95a8ed8e4a06
30-tests-and-output is a cursor rule published in the GitHub repository marianfoo/mcp-sap-docs (255 stars, last pushed 13d ago), licensed Apache-2.0. It adds 510 tokens to every session, about $0.0020 per session on Opus 5.5. 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.
30-tests-and-output compared with cursor rules from other repositories
| Mod | Type | Stars | Last push | Licence | Scan | Tokens | Works with |
|---|---|---|---|---|---|---|---|
| 30-tests-and-outputmarianfoo/mcp-sap-docs | Cursor rule | 255 | 13d ago | Apache-2.0 | A | 510 | Cursor |
| puppeteersanjeed5/awesome-cursor-rules-mdc | Cursor rule | 3.6k | 10d ago | CC0-1.0 | A | 1,826 | Cursor |
| web-pages-e2e-test-maintenanceTACC/HPCPerfStats | Cursor rule | 60 | today | LGPL-2.1 | A | 0 | Cursor |
| local-compose-db-lifecycle-for-web-testsTACC/HPCPerfStats | Cursor rule | 60 | today | LGPL-2.1 | A | 9 | Cursor |
| cypress-e2e-testing-cursorrules-prompt-fileXD3an/awesome-ai-coding-all-in-one | Cursor rule | 14 | yesterday | none | A | 709 | Cursor |
| vasu-playwright-utilsvasu31dev/playwright-ts-lib | Cursor rule | 25 | 8mo ago | MIT | A | 14 | Cursor |
| ponytailDietrichGebert/ponytail | Cursor rule | 204k | 11d ago | MIT | A | 604 | Cursor |