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.
npx skills add bocato/swift-testing-agent-skill --skill swift-testinggit clone --depth 1 https://github.com/bocato/swift-testing-agent-skillWrote 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/skills/bocato/swift-testing-agent-skill/swift-testing)<a href="https://agentmods.dev/skills/bocato/swift-testing-agent-skill/swift-testing"><img src="https://agentmods.dev/badge/skills/bocato/swift-testing-agent-skill/swift-testing/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/skills/bocato/swift-testing-agent-skill/swift-testing"><img src="https://agentmods.dev/badge/skills/bocato/swift-testing-agent-skill/swift-testing.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.00124 | $0.02309 |
| Opus 5.5 | $0.00050 | $0.00924 |
| Sonnet 5.5 | $0.00025 | $0.00462 |
| Haiku 4.5 | $0.00012 | $0.00231 |
Grade A, and why
swift-testing 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.
How it starts
The opening of the file, as written. The whole thing — 296 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Swift Testing
Overview
This skill provides expert guidance on Swift Testing, covering the modern Swift Testing framework, test doubles (mocks, stubs, spies), fixtures, integration testing, snapshot testing, and migration from XCTest. Use this skill to help developers write reliable, maintainable tests following F.I.R.S.T. principles and Arrange-Act-Assert patterns.
Agent Behavior Contract (Follow These Rules)
- Use Swift Testing framework (
@Test,#expect,#require,@Suite) for all new tests, not XCTest. - Always structure tests with clear Arrange-Act-Assert phases.
- Follow F.I.R.S.T. principles: Fast, Isolated, Repeatable, Self-Validating, Timely.
- Use proper test double terminology per Martin Fowler's taxonomy (Dummy, Fake, Stub, Spy, SpyingStub, Mock).
- Place fixtures close to models with
#if DEBUG, not in test targets. - Place test doubles close to interfaces with
#if DEBUG, not in test targets. - Prefer state verification over behavior verification - simpler, less brittle tests.
- Use
#expectfor soft assertions (continue on failure) and#requirefor hard assertions (stop on failure).
Quick Decision Tree
When a developer needs testing guidance, follow this decision tree:
-
Starting fresh with Swift Testing?
- Read
references/test-organization.mdfor suites, tags, traits - Read
references/async-testing.mdfor async test patterns
- Read
-
Need to create test data?
- Read
references/fixtures.mdfor fixture patterns and placement - Read
references/test-doubles.mdfor mock/stub/spy patterns
- Read
-
Testing multiple inputs?
- Read
references/parameterized-tests.mdfor parameterized testing
- Read
-
Testing module interactions?
- Read
references/integration-testing.mdfor integration test patterns
- Read
-
Testing UI for regressions?
- Read
references/snapshot-testing.mdfor snapshot testing setup
- Read
-
Testing data structures or state?
- Read
references/dump-snapshot-testing.mdfor text-based snapshot testing
- Read
What ships with it
10 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.
- references/_index.md 2.7 KB
- references/async-testing.md 4.7 KB
- references/dump-snapshot-testing.md 6.2 KB
- references/fixtures.md 4.2 KB
- references/integration-testing.md 4.5 KB
- references/migration-xctest.md 5.5 KB
- references/parameterized-tests.md 4.0 KB
- references/snapshot-testing.md 4.3 KB
- references/test-doubles.md 6.0 KB
- references/test-organization.md 4.0 KB
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 · 296 lines · 124 tokens per session scan A 81b4e5a051d4
swift-testing is a skill published in the GitHub repository bocato/swift-testing-agent-skill (80 stars, last pushed 10mo ago), licensed MIT. It adds 124 tokens to every session and 2,309 once invoked, about $0.0005 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.
swift-testing compared with skills from other repositories
| Mod | Type | Stars | Last push | Licence | Scan | Tokens | Works with |
|---|---|---|---|---|---|---|---|
| swift-testingbocato/swift-testing-agent-skill | Skill | 80 | 10mo ago | MIT | A | 124 | Claude Code, Codex |
| swift-testing-expertAvdLee/Swift-Testing-Agent-Skill | Skill | 485 | 2mo ago | MIT | A | 73 | Claude Code |
| ios-agent-skillNagarjuna2997/ios-agent-skill | Skill | 44 | today | MIT | A | 167 | Claude Code |
| ios-builderNagarjuna2997/ios-agent-skill | Skill | 44 | today | MIT | A | 53 | Claude Code, Codex |
| swift_expertApexIQ/skillsmith | Skill | 5 | 8mo ago | MIT | A | 20 | Claude Code, Codex |
| Swift PatternsAmariahAK/atlarix-skills | Skill | 0 | 2mo ago | Apache-2.0 | A | 2 | Claude Code, Codex |
| swift-testing-projacklandrin/OnlySwitch | Skill | 6.1k | yesterday | MIT | A | 34 | Codex |