Skip to content

Instantly share code, notes, and snippets.

@Nikoloutsos
Created May 26, 2022 13:30
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Nikoloutsos/cef9f6fe2e805d31e415b4cef1d9462f to your computer and use it in GitHub Desktop.
Save Nikoloutsos/cef9f6fe2e805d31e415b4cef1d9462f to your computer and use it in GitHub Desktop.
configuration with spm
# READ MORE ABOUT configuration here https://merowing.info/Sourcery/usage.html
configurations:
# -- Blueground configuration --
- sources:
include:
- FooApp
templates:
- Sourcery
output:
path: BluegroundTests/Sourcery
link:
project: ./FooApp.xcodeproj
target: FooAppTests
group: FooAppTests/Sourcery
args:
testableImport: "FooApp" # [MANDATORY] Your mocks will have "@testable import <testableImport>"
containedPathSubstringToApplyTemplate: "/FooApp/" # [MANDATORY] If a protocol with Automockable annotation exists but it's path doesn't contain <focusFolder> it will be ignored.
- sources:
- SwiftPackages/Analytics # -- In case your SPM depends on other modules it is REQUIRED to add them here --
templates:
- Sourcery
output:
SwiftPackages/Analytics/Tests/AnalyticsTests/Mocks
args:
testableImport: "Analytics"
containedPathSubstringToApplyTemplate: "/SwiftPackages/Analytics/"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment