This repo includes a small Node-based CLI wrapper to make macOS UI automation easier to drive from agent workflows.
It shells out to:
xcodebuild(build + run XCUITest for macOS/iOS Simulator)xcrun(Xcode toolchain checks)
It also runs a local Tauri session server (Playwright-backed) for browser-style automation and screenshots.
- Install Xcode + Command Line Tools
- Ensure Node.js 22+ is installed
- Install dependencies:
npm install
- Playwright Chromium (usually installed with npm):
- If needed:
npx playwright install chromium
- If needed:
From the repo root:
# Build the CLI
npm run build
# Verify dependencies
node dist/src/bin/mac-dev-agent.js doctor
# List UI test schemes
node dist/src/bin/mac-dev-agent.js xcuitest list --project path/to/App.xcodeproj
# Build UI tests (generates an .xctestrun)
node dist/src/bin/mac-dev-agent.js xcuitest build --project path/to/App.xcodeproj --scheme AppUITests
# Run UI tests
node dist/src/bin/mac-dev-agent.js xcuitest run --project path/to/App.xcodeproj --scheme AppUITestsStart the local server:
node dist/src/bin/mac-dev-agent.js tauri server --port 9232Open a session and navigate:
node dist/src/bin/mac-dev-agent.js tauri session open --name demo --url https://example.com
node dist/src/bin/mac-dev-agent.js tauri session listTake a screenshot:
node dist/src/bin/mac-dev-agent.js tauri screenshot --name demo --out /tmp/demo.pngEvery command supports --json for machine-readable output:
node dist/src/bin/mac-dev-agent.js xcuitest list --project path/to/App.xcodeproj --jsonnpm run build
node --test dist/test/*.test.js