SwiftyMocky CLI is a custom command line tool, writtten in swift, that will simplify setting up mock configuration, validating and troubleshooting configuration and simplify mocks generation.
CLI is hosted at: https://github.com/MakeAWishFoundation/SwiftyMocky
Please refer to Guides/Installation.md
// From cloned repo main dir
$ swift run swiftymocky <command>
// From Pods
$ ./Pods/SwiftyMocky/bin/swiftymocky <command>
// Using mint
$ mint run MakeAWishFoundation/SwiftyMocky <command>
init
- Creates template of Mockfile to fillgenerate
- generate mocks. Usage 'swiftymocky options optional-mock-name'. Allowed flags:--disableCache
: disables using cahche--verbose
,-v
: additional sourcery debug info--watch
,-w
: run in watcher mode, allowed only if mock name specified
watch
- run in watcher mode, allowed only if mock name specifiedsetup
- if more than one xcodeproj in directory, add a selected project path:mocky setup <project>.xcodeproj
migrate
- migrate existing SwiftyMocky yml configurations into Mockfile™autoimport
- scans sources and automatically resolves imports for the mocksdoctor
- run to inspect status of SwiftyMocky setup