-
Notifications
You must be signed in to change notification settings - Fork 3.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[image_picker] Fix XCTests in Xcode 15 #5074
[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
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
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 stuartmorgan@google.com [image_picker] Fix XCTests in Xcode 15 (flutter/packages#5074) 2023-10-05 engine-flutter-autoroll@skia.org 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 flutter-ecosystem@google.com,rmistry@google.com 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 stuartmorgan@google.com [image_picker] Fix XCTests in Xcode 15 (flutter/packages#5074) 2023-10-05 engine-flutter-autoroll@skia.org 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 flutter-ecosystem@google.com,rmistry@google.com 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: - 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
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