xcode-test

xcode-test is a command for coding agents from SethCalkins/claude-ios-swift-plugin. It costs 16 tokens per session (620 once invoked), scanned A, original, MIT.

A command for building and testing an iOS application with Xcode, Apple’s development tool. It finds the project or workspace, selects a scheme and simulator, then reports build and test results.

In plain words
What is it for?
Use it to build an iOS app, run its tests on a simulator, and identify failed tests, build errors, warnings, and their file locations.
Why use it?
It collects the project setup and test steps in one workflow instead of requiring you to run them separately.

Command

Part of the swift-skills plugin — 10 skills, 4 commands, 3 agents shipped together

Install

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.

agentmods
npx agentmods add commands/sethcalkins/claude-ios-swift-plugin/xcode-test
Clone the repo
git clone --depth 1 https://github.com/SethCalkins/claude-ios-swift-plugin

Or install swift-skills, the plugin that ships this one along with the rest of its 10 skills, 4 commands, 3 agents.

Wrote 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.

agentmods badge for xcode-test

README.md
[![agentmods](https://agentmods.dev/badge/commands/sethcalkins/claude-ios-swift-plugin/xcode-test.svg)](https://agentmods.dev/commands/sethcalkins/claude-ios-swift-plugin/xcode-test)
Your own site
<a href="https://agentmods.dev/commands/sethcalkins/claude-ios-swift-plugin/xcode-test"><img src="https://agentmods.dev/badge/commands/sethcalkins/claude-ios-swift-plugin/xcode-test.svg" alt="Measured on agentmods" height="20"></a>
Per session 16 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 620 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

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.

ModelPer sessionOnce invoked
Fable 5 $0.00016 $0.00620
Opus 5 $0.00008 $0.00310
Sonnet 5 $0.00003 $0.00124
Haiku 4.5 $0.00002 $0.00062

Measured 4d ago against content hash e05e0674d9dd, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

xcode-test 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 4d 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.

commands/xcode-test.md · 86 lines

How it starts

The opening of the file, as written. The whole thing — 86 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Xcode Build and Test

Build and run tests for the iOS project using XcodeBuildMCP.

Instructions

  1. Detect project configuration:

    • Look for .xcworkspace first (prefer workspace over project)
    • Fall back to .xcodeproj if no workspace
    • Read scheme list if scheme not specified
  2. Set session defaults:

    • Call mcp__XcodeBuildMCP__session-set-defaults with:
      • workspacePath or projectPath
      • scheme (from argument or auto-detect main app scheme)
      • configuration: "Debug"
  3. Find or boot simulator:

    • Call mcp__XcodeBuildMCP__list_sims to find booted simulators
    • If --simulator NAME provided, find matching simulator
    • If none booted, suggest user boot one or use most recent
  4. Build the project:

    • Call mcp__XcodeBuildMCP__build_sim
    • Report any build errors with file locations
    • If build fails, provide actionable suggestions
  5. Run tests:

    • Call mcp__XcodeBuildMCP__test_sim
    • Capture test results
    • Report failures with:
      • Test name
      • Failure reason
      • File and line number
  6. Summary:

    • Total tests run
    • Passed / Failed / Skipped counts
    • Build time
    • Any warnings worth noting

Output Format

## Xcode Test Results

### Configuration
- Workspace: MyApp.xcworkspace
- Scheme: MyApp
- Simulator: iPhone 16 Pro (iOS 18.0)

### Build: SUCCESS (12.3s)
- 2 warnings (see details)

### Tests: 45 passed, 2 failed, 1 skipped

#### Failures
1. `testUserLogin` in `AuthTests.swift:42`
   - Expected true, got false
   - Assertion: User should be authenticated after valid login

2. `testDataSync` in `SyncTests.swift:88`
   - Timeout after 10s
   - Network mock may not be configured

### Warnings
- `ViewModel.swift:15` - 'async' call in actor-isolated context

Tips

  • Use --simulator "iPhone 16 Pro" to target a specific device
  • If macOS tests fail due to deployment target, try iOS simulator tests
  • For CI, ensure a simulator is booted before running

Read the full file on GitHub · 86 lines

Changes

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.

  1. 4d ago First seen · 86 lines · 16 tokens per session scan A e05e0674d9dd

Subscribe to this mod's changes

xcode-test is a command published in the GitHub repository SethCalkins/claude-ios-swift-plugin (2 stars, last pushed 7mo ago), licensed MIT. It adds 16 tokens to every session and 620 once invoked, about $0.0001 per session on Opus 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-31.