CLI will help you with project setup and mocks generation. Also, it supports new Mockfile format.
To install it:
> brew install mint
> mint install MakeAWishFoundation/SwiftyMocky
> marathon install MakeAWishFoundation/SwiftyMocky
Make:
Clone from https://github.com/MakeAWishFoundation/SwiftyMockyCLI and run make
in the root directory.
More information about CLI you will fund in "Command Line Interface" section.
SwiftyMocky Runtime is available through:
1. CocoaPods.
To install it, simply add the following line to your Podfile:
pod "SwiftyMocky"
Then execute pod install
The integration part is described in setup page.
2. Carthage.
To install, add following to you Cartfile:
github "MakeAWishFoundation/SwiftyMocky"
Then execute carthage update
For Carthage, few additional steps are required:
-
In your test target, add SwiftyMocky to linked libraries:
-
In your test target, add new copy files phase:
-
Select destination to frameworks, and add SwiftyMocky:
The integration part is described in setup page.
> ice add MakeAWishFoundation/SwiftyMocky
It will be supported when Ice reviews PR, fallback to SwiftPM if any issues.
Add SwiftyMocky to you Package.swift dependencies:
dependencies: [
.package(url: "https://github.com/MakeAWishFoundation/SwiftyMocky", from: "4.2.0"),
]
And add SwiftyMocky
to your test target dependencies.
Download/build Sourcery binary manually, or use prebuilt sourcery versions from: https://github.com/MakeAWishFoundation/SwiftyMocky.wiki.git
Currentyly we support:
- 5.0
- 4.2
- 4.1