Skip to content

Commit

Permalink
fix build failure on iOS
Browse files Browse the repository at this point in the history
  • Loading branch information
yeatse committed Jan 13, 2024
1 parent 5d3cd56 commit cbcfc24
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions Tests/KingfisherWebPTests.swift
Original file line number Diff line number Diff line change
Expand Up @@ -192,8 +192,13 @@ class KingfisherWebPTests: XCTestCase {
XCTAssertEqual(originalFrameSource.frameCount, encodedFrameSource.frameCount)

(0..<originalFrameSource.frameCount).forEach { index in
#if os(macOS)
let frame1 = KFCrossPlatformImage(cgImage: originalFrameSource.frame(at: index)!, size: .zero)
let frame2 = KFCrossPlatformImage(cgImage: encodedFrameSource.frame(at: index)!, size: .zero)
#else
let frame1 = KFCrossPlatformImage(cgImage: originalFrameSource.frame(at: index)!)
let frame2 = KFCrossPlatformImage(cgImage: encodedFrameSource.frame(at: index)!)
#endif
XCTAssertTrue(frame1.renderEqual(to: frame2), "Frame \(index) of \(fileName) should be equal")

let duration1 = originalFrameSource.duration(at: index)
Expand Down

0 comments on commit cbcfc24

Please sign in to comment.