AppleSimulatorUtils icon indicating copy to clipboard operation
AppleSimulatorUtils copied to clipboard

Add critical alerts notification permission

Open ps2 opened this issue 3 years ago • 2 comments

ps2 avatar Sep 26 '22 22:09 ps2

Closing until we find time to implement this properly, with a separate flag.

ps2 avatar Sep 27 '22 01:09 ps2

On second thought, this probably is useful to some as is, and shouldn't cause issues for those who don't need it, so I'll re-open it for your consideration.

ps2 avatar Sep 27 '22 02:09 ps2

Thanks for the contribution @ps2, still relevant I guess? In addition, I think this should be a separate flag.

asafkorem avatar Oct 23 '22 08:10 asafkorem

Hello, is there a work around possible until this is merged? I'm currently trying to setup Detox on a react native app that uses critical alerts and from what I understand Detox uses AppleSimulatorUtils to handle the permissions. Ideally I'm looking to use this in the following way in Detox: describe('Critical Alert Example', () => { beforeAll(async () => { await device.launchApp({ permissions: { location: 'always', notifications: 'YES', criticalAlertSetting: 'YES', }, }); }); } Happy to help in anyway I can, although not sure what adding a separate flag would entail.

Simon-ent avatar Jan 19 '23 16:01 Simon-ent

Hi @Simon-ent, shouldn't be very complicated to add this flag. You can add commits to this PR or open a new one, and if you find any complications you can contact me on Discord server (Detox Discord). IMO we should add another flag that is enabling this feature (critical alerts) only if its value is true + notifications are allowed.

asafkorem avatar Jan 24 '23 08:01 asafkorem

Thanks to @Simon-ent, we now have a better solution for this change (https://github.com/wix/AppleSimulatorUtils/pull/112). I'm closing this PR and I will make sure to mention @darinkrauss & @ps2 on the merge commit of #112 as they were the initial contributors for this.

asafkorem avatar Jan 29 '23 08:01 asafkorem