// the find
zalando/SwiftMonkey
A framework for doing randomised UI testing of iOS apps
SwiftMonkey generates randomized touch and gesture input through XCTest UI testing to stress-test iOS apps and surface rare crashes or slow memory leaks that normal scripted UI tests won't find. A companion library, SwiftMonkeyPaws, visualizes where the generated taps land so you can actually reproduce what the monkey broke. It's for iOS teams chasing flaky, hard-to-repro crashes rather than general UI test automation.
Integrates straight into XCTest UI testing instead of being a bolt-on black box, so a crash gets you a normal Xcode stack trace to debug from. Seeded generation (Monkey(seed:)) lets you replay the exact same input sequence that caused a failure, which is the actual hard part of monkey testing and most clones skip it. SwiftMonkeyPaws is decoupled from the monkey itself — it'll render any UIEvent stream you feed it, not just this library's output.
The core input generation relies on private XCTest APIs (MonkeyXCTestPrivate.swift) that Apple doesn't guarantee between Xcode versions; the README's own hedge that the public-API path 'seems to work better' is not a confidence-inspiring endorsement. The project is effectively dead — Swift 4.0 target, no real development since around 2019 despite a 2022 push, and the README's own TODO list (device rotation, detecting when the monkey escapes the app, SPM support) has sat untouched for years. Swift Package Manager doesn't actually work for iOS here per the README, leaving CocoaPods or manual file-copying as the only real install paths. Documentation is thin by the maintainers' own admission — past the one example project, you're reading Monkey.swift source to find anything beyond basic usage.