Testing iOS Code
bitwarden/ios
Write tests, add test coverage, unit test, or add missing tests for Bitwarden iOS.
Write, review, or migrate unit tests using Swift Testing (@Test, @Suite, expect, require).
$ npx skills add nimblehq/ios-templates --skill swift-testing -a claude-codeProject install by default; add -g for ~/.claude/skills/.
$ gh skill install nimblehq/ios-templates swift-testing --agent claude-codeProject scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).
$ git clone --depth 1 https://github.com/nimblehq/ios-templates.git skills-src && mkdir -p .claude/skills && cp -r skills-src/skills/swift-testing .claude/skills/swift-testing && rm -rf skills-srcUse ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.
Claude Code skills documentation · loads skills from .claude/skills/
Install the "swift-testing" agent skill from https://github.com/nimblehq/ios-templates/tree/develop/skills/swift-testing into .claude/skills/swift-testing/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "swift-testing", then confirm the skill loads.Claude Code copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$skill-installer install https://github.com/nimblehq/ios-templates/tree/develop/skills/swift-testingType this inside Codex. $skill-installer <name> installs a curated skill from openai/skills. The installer writes to $CODEX_HOME/skills (default ~/.codex/skills). Restart Codex if the skill does not show up.
$ npx skills add nimblehq/ios-templates --skill swift-testing -a codexProject install goes to .agents/skills/; add -g for ~/.codex/skills/.
$ gh skill install nimblehq/ios-templates swift-testing --agent codexProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/nimblehq/ios-templates.git skills-src && mkdir -p .agents/skills && cp -r skills-src/skills/swift-testing .agents/skills/swift-testing && rm -rf skills-srcUse ~/.agents/skills/ instead of .agents/skills for a personal install.
Codex skills documentation · loads skills from .agents/skills/
Install the "swift-testing" agent skill from https://github.com/nimblehq/ios-templates/tree/develop/skills/swift-testing into .agents/skills/swift-testing/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "swift-testing", then confirm the skill loads.Codex copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add nimblehq/ios-templates --skill swift-testing -a cursorProject install goes to .agents/skills/; add -g for ~/.cursor/skills/.
$ gh skill install nimblehq/ios-templates swift-testing --agent cursorProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/nimblehq/ios-templates.git skills-src && mkdir -p .cursor/skills && cp -r skills-src/skills/swift-testing .cursor/skills/swift-testing && rm -rf skills-srcUse ~/.cursor/skills/ instead of .cursor/skills for a personal install.
Cursor skills documentation · loads skills from .cursor/skills/, .agents/skills/, .claude/skills/, .codex/skills/
Install the "swift-testing" agent skill from https://github.com/nimblehq/ios-templates/tree/develop/skills/swift-testing into .cursor/skills/swift-testing/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "swift-testing", then confirm the skill loads.Cursor copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gemini skills install https://github.com/nimblehq/ios-templates.git --path skills/swift-testing--scope user (default) or --scope workspace; --path is the subfolder of the repo that holds the skill; --consent skips the security confirmation prompt.
$ npx skills add nimblehq/ios-templates --skill swift-testing -a gemini-cliProject install goes to .agents/skills/; add -g for ~/.gemini/skills/.
$ gh skill install nimblehq/ios-templates swift-testing --agent gemini-cliProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/nimblehq/ios-templates.git skills-src && mkdir -p .gemini/skills && cp -r skills-src/skills/swift-testing .gemini/skills/swift-testing && rm -rf skills-srcUse ~/.gemini/skills/ instead of .gemini/skills for a personal install, then run /skills reload.
Gemini CLI skills documentation · loads skills from .gemini/skills/, .agents/skills/
Install the "swift-testing" agent skill from https://github.com/nimblehq/ios-templates/tree/develop/skills/swift-testing into .gemini/skills/swift-testing/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "swift-testing", then confirm the skill loads.Gemini CLI copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gh skill install nimblehq/ios-templates swift-testingInstalls for Copilot at project scope by default; add --scope user for a personal install. Preview a skill first with gh skill preview. Needs GitHub CLI 2.90.0 or later (public preview).
$ npx skills add nimblehq/ios-templates --skill swift-testing -a github-copilotProject install goes to .agents/skills/; add -g for ~/.copilot/skills/.
$ git clone --depth 1 https://github.com/nimblehq/ios-templates.git skills-src && mkdir -p .github/skills && cp -r skills-src/skills/swift-testing .github/skills/swift-testing && rm -rf skills-srcUse ~/.copilot/skills/ instead of .github/skills for a personal install. Commit .github/skills so cloud agent and code review can use it.
GitHub Copilot skills documentation · loads skills from .github/skills/, .claude/skills/, .agents/skills/
Install the "swift-testing" agent skill from https://github.com/nimblehq/ios-templates/tree/develop/skills/swift-testing into .github/skills/swift-testing/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "swift-testing", then confirm the skill loads.GitHub Copilot copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add nimblehq/ios-templates --skill swift-testing -a opencodeOpenCode documents no install command of its own. Project install goes to .agents/skills/; add -g for ~/.config/opencode/skills/.
$ gh skill install nimblehq/ios-templates swift-testing --agent opencodeProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/nimblehq/ios-templates.git skills-src && mkdir -p .opencode/skills && cp -r skills-src/skills/swift-testing .opencode/skills/swift-testing && rm -rf skills-srcUse ~/.config/opencode/skills/ instead of .opencode/skills for a personal install.
OpenCode skills documentation · loads skills from .opencode/skills/, .claude/skills/, .agents/skills/
Install the "swift-testing" agent skill from https://github.com/nimblehq/ios-templates/tree/develop/skills/swift-testing into .opencode/skills/swift-testing/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "swift-testing", then confirm the skill loads.OpenCode copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
swift-testingWrite, review, or migrate unit tests using Swift Testing (@Test, @Suite, expect, require).
Swift Testing is an agent skill from nimblehq/ios-templates. Write, review, or migrate unit tests using Swift Testing (@Test, @Suite, expect, require). Use when writing new tests, converting existing Quick+Nimble specs to Swift Testing, reviewing test quality, debugging flaky tests, or improving test structure in this iOS template project. Triggers on: "write test", "add test", "test this", "migrate test", "convert spec", "Swift Testing".
Its SKILL.md is about 1.3k tokens, which your agent loads only when the skill is triggered. The skill folder holds 7 other files, including reference files (for example `references/async-testing.md`, `references/expectations.md` and `references/fundamentals.md`).
It sits in Testing & QA, covering iOS development and Test generation. It works with iOS. The repository describes itself as: Our optimized iOS templates used in our projects. The licence is MIT.
9 steps, taken from the first numbered list in SKILL.md.
Read from SKILL.md and the folder at commit f009d02. It shows what the files ask for, not the result of running them.
Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.
From allowed-tools in the SKILL.md frontmatter.
No scripts in the folder and no shell commands in SKILL.md (its code samples are swift).
From the folder's file list and the shell code blocks in SKILL.md.
No URLs in SKILL.md.
From URLs in SKILL.md, links to its own repository left out.
Names no API keys, tokens, secrets or passwords.
From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.
Swift Testing loads about 1.3k tokens when it runs, and up to ~6.8k if it reads all its reference files. Until then it costs about 99 tokens; SKILL.md has 429 words of instructions outside code blocks.
Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.
The automated check found no risky patterns in SKILL.md.
Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.
The full file from nimblehq/ios-templates at commit f009d02, republished under its MIT licence (© nimblehq). 429 words, ~1,258 tokens.
.claude/skills/swift-testing/SKILL.md (or your agent's skills folder). This skill also uses 6 other files; get the full folder from GitHub.Write, review, migrate, and debug tests using Swift Testing for this iOS template project. This project uses Quick + Nimble (*Spec.swift) as the legacy framework and Swift Testing (*Tests.swift) for all new tests.
#expect as the default assertion; use #require only when subsequent lines depend on a prerequisite value..serialized.private struct / private actor stubs conforming to domain protocols — no generated mocks.actor stubs when the protocol requires async or has mutable state; use struct stubs otherwise.@Test(arguments:)) over duplicated test methods..enabled, .disabled, .timeLimit, .bug, .tags) instead of ad-hoc comments.Testing only in test targets, never in app/library targets.NetworkStubber (OHHTTPStubs) for network-level tests.Before writing or reviewing tests, clarify:
*Spec.swift.{PROJECT_NAME}Tests/), Data (Modules/Data/Tests/), Domain (Modules/Domain/Tests/), or Model (Modules/Model/Tests/).async/await?| Framework | Suffix | Placement |
|---|---|---|
| Swift Testing | *Tests.swift | Tests/Sources/ mirroring production path (e.g. Repositories/, Entities/) |
| Quick + Nimble | *Spec.swift | Tests/Sources/Specs/ |
import Testing
@testable import Data
import Domain
@Suite("DefaultRemoteConfigRepository")
struct DefaultRemoteConfigRepositoryTests {
@Test("returns a typed stored value")
func returnsATypedStoredValue() async {
let booleanKey = RemoteConfigKey(name: "feature_enabled", defaultValue: false)
let repository = DefaultRemoteConfigRepository(
source: StubRemoteConfigSource(values: [
booleanKey.name: .string("true")
])
)
let value = await repository.value(for: booleanKey)
#expect(value == true)
}
}
private actor StubRemoteConfigSource: RemoteConfigSource {
private let values: [String: RemoteConfigStoredValue]
init(values: [String: RemoteConfigStoredValue] = [:]) {
self.values = values
}
func refresh() async throws {}
func value(forKey key: String) async -> RemoteConfigStoredValue? {
values[key]
}
}Key observations:
struct suite, not class@Suite("DisplayName") with human-readable name matching the type under test@Test("description") with lowercase sentence describing behaviortest prefix)private actor stub at bottom of file (actor because protocol has async)@testable import for the module under test; regular import for its dependenciesLoad the appropriate reference file based on the task:
| Task | Reference |
|---|---|
| Writing new tests, suite structure, naming | references/fundamentals.md |
| Assertions, error checking, known issues | references/expectations.md |
| Traits, tags, conditional execution | references/traits-and-tags.md |
| Data-driven / parameterized tests | references/parameterized-testing.md |
| Async/await, callbacks, confirmations | references/async-testing.md |
| Creating stubs, fakes, network mocks | references/test-doubles.md |
Before finishing, confirm:
#require is used for prerequisites; #expect for everything elseasync functions directly (no Task.sleep hacks)private struct or private actor at bottom of file*Tests.swift and placed in the correct module test directoryNetworkStubber or protocol stubs used© nimblehq, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file
SKILL.md and 6 other files (references) in skills/swift-testing of nimblehq/ios-templates.
Open the folder on GitHubat commit f009d02
Swift Testing next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.
| Skill | Stars | Used in | Tokens | Auto-check | Licence | Repo updated |
|---|---|---|---|---|---|---|
| Swift Testing this skillnimblehq/ios-templates | 110 | — | ~1.3k | Automated safety check: Pass | MIT | |
| Testing iOS Codebitwarden/ios | 695 | — | ~1.8k | Automated safety check: Pass | GPL-3.0 | |
| Test Generatorgustavscirulis/snapgrid | 117 | 1 repos | ~2.7k | Automated safety check: Notes | Custom licence | |
| Engine E2Ewix/react-native-navigation | 13k | — | ~1.1k | Automated safety check: Pass | MIT | |
| iOS Accessibility Testingconorluddy/xclaude-plugin | 183 | — | ~5k | Automated safety check: Pass | MIT | |
| MAUI UI Test Writerdotnet/maui | 23k | — | ~3k | Automated safety check: Pass | MIT |
bitwarden/ios
Write tests, add test coverage, unit test, or add missing tests for Bitwarden iOS.
gustavscirulis/snapgrid
Generate test templates for unit tests, integration tests, and UI tests using Swift Testing and XCTest.
wix/react-native-navigation
Run Wix Engine (mobile-apps-engine) iOS E2E tests locally to validate RNN changes.
conorluddy/xclaude-plugin
Guides WCAG 2.1 and VoiceOver accessibility testing for iOS apps, working from the accessibility tree and not from screenshots.
dotnet/maui
Writes UI tests that reproduce a GitHub issue in .NET MAUI and keeps iterating until the tests actually fail, proving they catch the bug.
n0an/VivaDicta
Measure VivaDicta test code coverage from the terminal. An agent skill from n0an/VivaDicta.
nimblehq/ios-templates
Write, review, or fix Swift 6 concurrency code using actors, Sendable, structured concurrency, and the strict data-race-safety model.
nimblehq/ios-templates
Find, build, and install mobile artifacts for the current repository through GitHub Actions and Tophat.
nimblehq/ios-templates
Generate and create a git commit following Nimble's Compass convention ([ID] Verb message).
nimblehq/ios-templates
Guided workflow to address, reply to, and resolve GitHub PR review threads — one at a time, collaboratively.
Works with
Categories
Write, review, or migrate unit tests using Swift Testing (@Test, @Suite, expect, require). Swift Testing is an agent skill from nimblehq/ios-templates. Write, review, or migrate unit tests using Swift Testing (@Test, @Suite, expect, require).
Swift Testing fits situations like: writing new tests; converting existing Quick+Nimble specs to Swift Testing; reviewing test quality; debugging flaky tests.
Run `npx skills add nimblehq/ios-templates --skill swift-testing -a claude-code`. Or copy the skill folder (skills/swift-testing in nimblehq/ios-templates) into .claude/skills/swift-testing in your project. Claude Code loads it when a task matches its description.
Run `npx skills add nimblehq/ios-templates --skill swift-testing -a codex`. Or copy the skill folder (skills/swift-testing in nimblehq/ios-templates) into .agents/skills/swift-testing in your project. Codex loads it when a task matches its description.
Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add nimblehq/ios-templates --skill swift-testing -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/swift-testing, .gemini/skills/swift-testing, .github/skills/swift-testing and .opencode/skills/swift-testing in your project.
SKILL.md names no scripts, command-line tools or credentials: Swift Testing is instructions for the agent only.
SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.
Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.
Swift Testing is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.
About 1.3k tokens (SKILL.md is roughly 5k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full. Its references folder adds about 5.5k tokens, read only when the agent opens those files.
Skills that share tags, products or a category with Swift Testing: Testing iOS Code (bitwarden/ios, 695 stars), Test Generator (gustavscirulis/snapgrid, 117 stars), Engine E2E (wix/react-native-navigation, 13k stars) and iOS Accessibility Testing (conorluddy/xclaude-plugin, 183 stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.
nimblehq (a GitHub organization) maintains it in nimblehq/ios-templates, which has 110 GitHub stars. The repository holds 5 skills in this directory. The repository was last updated on July 27, 2026.
Source: nimblehq/ios-templates on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.