is there a way to test push notifications ? (with Appium)
I understand that it’s not possible on emulators but let’s say i run it on real devices on some cloud service.
if its possible to test push notifs then, how to do it? can’t find much info on it on the web
Hi, i can’t get my driver to contain openNotifications() method.
i’m declaring the driver as AppiumDriver (and instantiated as AndroidDriver in runtime) since i have a generic wrapper for iOS and Android. I can only get openNotifications() if i declare the driver as AndroidDriver.
SimulatorRemoteNotifications is a library to send mock remote notifications to the iOS simulator.
The library extends UIApplication by embedding a mini server that listen for UDP packets containing JSON-formated payload, and a service to send notifications to the mini server.
This project includes the iOS Simulator Notifications MacOSX app to help you send the mock notifications.
Note that SimulatorRemoteNotifications does not send notification through Apple’s Push Service.
I decided to try a workaround to test push notifications. Currently, I jailbroken a device and I’m using this specific device just for push notification testing. I wrote a tweak to create an extra routine on the publishBulletin method (method used to add notifications to the notification center) in the iOS core. Therefore, I get the needed data in that method and export it to a log. I might not be able to access the notification center data, but access an external text file is possible.
I know this solution is not the most elegant one and also has nothing to do with appium, but I hope this might help someone. In addition, with the device being jailbroken, I am able to change the iOS date and time using the terminal, which is also needed for most push notifications to be triggered.