Skip to content

Commit c8f74d2

Browse files
committed
Fix the test case on iOS 18.0 simulator
1 parent a261180 commit c8f74d2

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

Tests/Tests/SDImageCoderTests.m

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -563,7 +563,12 @@ - (void)test29ThatJFIFDecodeOrientationShouldNotApplyTwice {
563563
UIImage *systemImage = [[UIImage alloc] initWithData:data];
564564
#if SD_UIKIT
565565
orientation = systemImage.imageOrientation;
566-
expect(orientation).equal(UIImageOrientationDown);
566+
if (@available(iOS 18.0, tvOS 18.0, watchOS 11.0, *)) {
567+
// Apple fix/hack this kind of JFIF on iOS 18
568+
expect(orientation).equal(UIImageOrientationUp);
569+
} else {
570+
expect(orientation).equal(UIImageOrientationDown);
571+
}
567572
#endif
568573

569574
// Check bitmap color equal, between our usage of ImageIO decoder and Apple system API behavior

0 commit comments

Comments
 (0)