Fix tests
This commit is contained in:
parent
f2d63cbc6d
commit
fd693f6d4d
|
@ -21,11 +21,11 @@ public typealias Font = UIFont
|
|||
public struct PlaceholderKit {
|
||||
public static let defaultPalette = ColorPalette(name: "defaultPalette",
|
||||
colors: [
|
||||
UIColor("ff5a5a"),
|
||||
UIColor("ff7b5a"),
|
||||
UIColor("ffb65a"),
|
||||
UIColor("ced07d"),
|
||||
UIColor("7dd0b6")
|
||||
Color("ff5a5a"),
|
||||
Color("ff7b5a"),
|
||||
Color("ffb65a"),
|
||||
Color("ced07d"),
|
||||
Color("7dd0b6")
|
||||
])
|
||||
|
||||
public static let defaultSizes = [
|
||||
|
@ -42,7 +42,7 @@ public struct PlaceholderKit {
|
|||
sizes: defaultSizes)
|
||||
}
|
||||
|
||||
public static var defaultPlaceholders: [UIImage] {
|
||||
public static var defaultPlaceholders: [Image] {
|
||||
return defaultPreset.placeholders.compactMap({$0.render()})
|
||||
}
|
||||
}
|
||||
|
|
|
@ -13,7 +13,7 @@ class PlaceholderTests: XCTestCase {
|
|||
func testSolidColor() {
|
||||
// Given a valid setting
|
||||
let outputSize = CGSize(width: 1600, height: 900)
|
||||
let image = PlaceholderBuilder().coloredBackground(color: .red, size: outputSize)
|
||||
let image = Placeholder(size: outputSize, backgroundStyle: .solidColor(.red)).render()
|
||||
|
||||
// output should not be nil
|
||||
XCTAssertNotNil(image)
|
||||
|
|
Loading…
Reference in New Issue