[image_picker] Fix XCTests in Xcode 15#5074
Conversation
When compiled with Xcode 15, images that can't be loaded by UIImage will cause the codepaths in some XCTest tests to throw exceptions. To address this: - Replace the test ICO file with one that UIImage is able to open. - Remove the SVG test, since UIImage cannot directly load SVGs. Fixes flutter/flutter#134973
vashworth
left a comment
There was a problem hiding this comment.
So SVGs don't work with image_picker at all? If SVGs don't work at all, we should probably file an issue to investigate supporting them / making sure we have proper error messaging.
Also, just curious, do you know what was wrong with the ICO image?
Other than that, LGTM. Thanks for fixing this!
I don't know if they work or not, but this test isn't actually testing them because the item provider returns
Nope, I looked around a bit and couldn't figure out what the requirements are for macOS/iOS to handle an ICO. I don't think the ICO itself was invalid, I think Apple's libraries (it's not just UIImage; Finder wouldn't show a preview for it and Preview wouldn't load it) just can't handle some subset of the format. |
|
Changelog/version override: these changes are test-only, just in a way the tooling doesn't detect. |
This comment was marked as off-topic.
This comment was marked as off-topic.
flutter/packages@6714d50...e578a16 2023-10-05 [email protected] [image_picker] Fix XCTests in Xcode 15 (flutter/packages#5074) 2023-10-05 [email protected] Roll Flutter from 5122991 to fe0275f (35 revisions) (flutter/packages#5076) If this roll has caused a breakage, revert this CL and stop the roller using the controls here: https://autoroll.skia.org/r/flutter-packages-flutter-autoroll Please CC [email protected],[email protected] on the revert to ensure that a human is aware of the problem. To file a bug in Flutter: https://github.com/flutter/flutter/issues/new/choose To report a problem with the AutoRoller itself, please file a bug: https://bugs.chromium.org/p/skia/issues/entry?template=Autoroller+Bug Documentation for the AutoRoller is here: https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md
flutter/packages@6714d50...e578a16 2023-10-05 [email protected] [image_picker] Fix XCTests in Xcode 15 (flutter/packages#5074) 2023-10-05 [email protected] Roll Flutter from 5122991 to fe0275f (35 revisions) (flutter/packages#5076) If this roll has caused a breakage, revert this CL and stop the roller using the controls here: https://autoroll.skia.org/r/flutter-packages-flutter-autoroll Please CC [email protected],[email protected] on the revert to ensure that a human is aware of the problem. To file a bug in Flutter: https://github.com/flutter/flutter/issues/new/choose To report a problem with the AutoRoller itself, please file a bug: https://bugs.chromium.org/p/skia/issues/entry?template=Autoroller+Bug Documentation for the AutoRoller is here: https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md
When compiled with Xcode 15, images that can't be loaded by UIImage will cause the codepaths in some XCTest tests to throw exceptions. To address this:
Fixes flutter/flutter#134973