natsuk4ze / gal

How to Save Image or Video to Photo Gallery in Flutter
https://pub.dev/packages/gal
BSD 3-Clause "New" or "Revised" License
85 stars 13 forks source link

Add test for ios17 in CI #157

Closed natsuk4ze closed 4 months ago

natsuk4ze commented 10 months ago

🎯 PR to add iOS17 to GitHub Actions automated testing

It has passed manual testing, but should be added to automated testing if possible.

✋ Pending for wix/AppleSimulatorUtils#117

Permissions must be granted to the Photos app in order to run the test.

There are three ways to grant permissions

1. Run xcrun simctl privacy~

Apple offers this method, but for some reason it did not work. xcrun simctl privacy booted grant photos studio.midoridesign.galExample And we can't test it on macOS.

2. Auto-tap on authorization dialog with XCTest

This is the only method that has worked so far. And probably works on macOS as well as iOS. However, I discovered method 3 and discontinued it because it is easier. #77

3. Use wix/AppleSimulatorUtils

It is a third party plugin and worked well, but seems to be buggy in iOS17. And we can't use on macOS.

🗒️ Update 2023 12

Maybe macOS should be tested by TCC See: actions/runner-images#8961

🗒️ Update 2024 01

wix/AppleSimulatorUtils is now deprecated. Need to try again to see if xcrun simctl privacy is available in this env.

🗒️ Update 2024 02

wix/AppleSimulatorUtils is fixed in macOS 14. iOS 16 simurator is removed in macOS 14, so it needs replacement to 17.

natsuk4ze commented 6 months ago

🚨 I commit to try the test many times, so I will squash&merge