ios-e2e-scaffold
Installation
SKILL.md
ios-e2e-scaffold
Manual-invocation skill that bootstraps XCUITest infrastructure for iOS SwiftUI projects.
Mirrors macos-e2e-scaffold's deterministic Read+Grep heuristic; differs only where iOS differs.
Phase 0 — Self-check
Before any other action, run three refuse-conditions. Any failure → return early with explicit message; no files modified.
| Check | Detect via | Refuse-message |
|---|---|---|
| Swift project | *.xcodeproj directory or Package.swift in cwd |
"Not a Swift project. /ios-e2e-scaffold requires .xcodeproj or Package.swift in project root." |
| iOS SwiftUI app | iOS-discriminating signal (see below) AND SwiftUI scene (@main + App/WindowGroup/TabView/NavigationStack) |
"No iOS SwiftUI app target detected. Skill is iOS-only — for macOS use /macos-e2e-scaffold, for AppKit use /appkit-e2e-scaffold (deferred)." |
| Not already scaffolded | any directory matching *UITests/ at cwd — EXCLUDING the macOS sibling's *macOSUITests/ (which must not block iOS scaffolding on multiplatform projects) — contains > 1 *.swift (find . -maxdepth 2 -type d -name '*UITests' ! -name '*macOSUITests' then count) — do NOT assume the <App>-prefixed name, since the scheme is not detected until Step 2 |
"UI test target already exists (<found-dir>/, N test files). Skill won't overwrite — extend manually instead." |
iOS-discriminating signal — REQUIRED
WindowGroup is cross-platform (shared with macOS) and does NOT identify iOS on its own. Detect iOS via the FIRST that matches: