This is a little demo projects that tests Remote Notification handling using Xcode UITests. For details checkout this blogpost: http://www.pixeldock.com/blog/testing-push-notifications-with-xcode-uitests/
To make this demo work on your machine follow these steps:
- Clone the project
- Add the project as a new app to your developer account (don't forget to change the appID inside the project)
- Create a APN development certificate for this new app, download it and add it to your Keychain
- Export the certificate as "pusher.p12" (use the password "pusher")
- Add the p12 file to the project UITest target
That should be it.
Here is a video of the test in action: https://youtu.be/Nl97SBXk7bU