Framework for automatic mock generation. Adds a set of handy methods, simplifying testing. One of the best and most complete solutions, including generics support and much more.
MIT License
1.03k
stars
104
forks
source link
Removed characters from Mock.swifttemplate since it's obsolete in Swift 5.0 #356
To fix the compilation issues that arise from using the file Mock.swifttemplate in Swift 5.0, I have proceeded with removing the property .characters from the file.
With this property, we get the following kind of errors:
/private/var/folders/21/8dtt1gkn5175rwk038fjbv300000gp/T/SwiftTemplate/2.1.3/Sources/SwiftTemplate/main.swift:1192:21: error: 'characters' is unavailable: Please use String directly
return part.characters.split(separator: ":").map(String.init).first!
^~~~~~~~~~
Swift.String:5:16: note: 'characters' was obsoleted in Swift 5.0
public var characters: String { get set }
^
error: fatalError
To fix the compilation issues that arise from using the file
Mock.swifttemplate
in Swift 5.0, I have proceeded with removing the property.characters
from the file.With this property, we get the following kind of errors:
String doesn't have the property
characters
anymore: https://developer.apple.com/documentation/swift/string/1540072-characters