mirror of
https://github.com/krzysztofzablocki/Sourcery.git
synced 2026-04-07 19:17:40 +00:00
Fixed tests under linux (#1390)
This commit is contained in:
Vendored
+4
-4
@@ -7,9 +7,9 @@
|
||||
"swift"
|
||||
],
|
||||
"name": "Debug sourcery",
|
||||
"program": "${workspaceFolder:Sourcery-master}/.build/debug/sourcery",
|
||||
"program": "${workspaceFolder:Sourcery}/.build/debug/sourcery",
|
||||
"args": [],
|
||||
"cwd": "${workspaceFolder:Sourcery-master}",
|
||||
"cwd": "${workspaceFolder:Sourcery}",
|
||||
"preLaunchTask": "swift: Build Debug sourcery"
|
||||
},
|
||||
{
|
||||
@@ -19,9 +19,9 @@
|
||||
"swift"
|
||||
],
|
||||
"name": "Release sourcery",
|
||||
"program": "${workspaceFolder:Sourcery-master}/.build/release/sourcery",
|
||||
"program": "${workspaceFolder:Sourcery}/.build/release/sourcery",
|
||||
"args": [],
|
||||
"cwd": "${workspaceFolder:Sourcery-master}",
|
||||
"cwd": "${workspaceFolder:Sourcery}",
|
||||
"preLaunchTask": "swift: Build Release sourcery"
|
||||
}
|
||||
]
|
||||
|
||||
@@ -18,24 +18,6 @@
|
||||
"version" : "0.9.1"
|
||||
}
|
||||
},
|
||||
{
|
||||
"identity" : "cwlcatchexception",
|
||||
"kind" : "remoteSourceControl",
|
||||
"location" : "https://github.com/mattgallagher/CwlCatchException.git",
|
||||
"state" : {
|
||||
"revision" : "f809deb30dc5c9d9b78c872e553261a61177721a",
|
||||
"version" : "2.0.0"
|
||||
}
|
||||
},
|
||||
{
|
||||
"identity" : "cwlpreconditiontesting",
|
||||
"kind" : "remoteSourceControl",
|
||||
"location" : "https://github.com/mattgallagher/CwlPreconditionTesting.git",
|
||||
"state" : {
|
||||
"revision" : "02b7a39a99c4da27abe03cab2053a9034379639f",
|
||||
"version" : "2.0.0"
|
||||
}
|
||||
},
|
||||
{
|
||||
"identity" : "nimble",
|
||||
"kind" : "remoteSourceControl",
|
||||
|
||||
@@ -21,6 +21,8 @@ public class MethodParameter: NSObject, SourceryModel, Typed, Annotated, Diffabl
|
||||
return asSource
|
||||
case "index":
|
||||
return index
|
||||
case "isOptional":
|
||||
return isOptional
|
||||
default:
|
||||
fatalError("unable to lookup: \(member) in \(self)")
|
||||
}
|
||||
|
||||
@@ -1386,6 +1386,7 @@ class SourcerySpecTests: QuickSpec {
|
||||
|
||||
}
|
||||
|
||||
#if canImport(ObjectiveC)
|
||||
context("given project") {
|
||||
var originalProject: XcodeProj?
|
||||
|
||||
@@ -1429,7 +1430,6 @@ class SourcerySpecTests: QuickSpec {
|
||||
}.toNot(throwError())
|
||||
}
|
||||
|
||||
#if canImport(ObjectiveC)
|
||||
it("links generated files") {
|
||||
expect {
|
||||
try Sourcery(cacheDisabled: true, prune: true).processFiles(sources, usingTemplates: templates, output: output, baseIndentation: 0)
|
||||
@@ -1437,7 +1437,7 @@ class SourcerySpecTests: QuickSpec {
|
||||
|
||||
expect(sourceFilesPaths.contains(outputDir + "Other.generated.swift")).to(beTrue())
|
||||
}
|
||||
#endif
|
||||
|
||||
it("links generated files when using per file generation") {
|
||||
templatePath = outputDir + "PerFileGeneration.stencil"
|
||||
update(code: """
|
||||
@@ -1463,6 +1463,7 @@ class SourcerySpecTests: QuickSpec {
|
||||
}.toNot(throwError())
|
||||
}
|
||||
}
|
||||
#endif
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -75,10 +75,18 @@ protocol ClosureProtocol: AutoMockable {
|
||||
func setClosure(_ closure: @escaping () -> Void)
|
||||
}
|
||||
|
||||
protocol NullableClosureProtocol: AutoMockable {
|
||||
func setClosure(_ closure: (() -> Void)?)
|
||||
}
|
||||
|
||||
protocol MultiClosureProtocol: AutoMockable {
|
||||
func setClosure(name: String, _ closure: @escaping () -> Void)
|
||||
}
|
||||
|
||||
protocol MultiNullableClosureProtocol: AutoMockable {
|
||||
func setClosure(name: String, _ closure: (() -> Void)?)
|
||||
}
|
||||
|
||||
protocol NonEscapingClosureProtocol: AutoMockable {
|
||||
func executeClosure(_ closure: () -> Void)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user