How to test GCM notifications without app?

假装没事ソ 提交于 2019-12-22 06:59:53

问题


I am currently implementing a push functionality using Amazon SNS in my backend. Now, I would like to write tests for the backend and make somehow sure that the published notifications get delivered to the endpoint (GCM mobile device).

Is there a way to get a mock registrationID from the Google dev console and check an inbox if any notifications actually arrived? All without ever building an app?


回答1:


GCM works also with Chrome.

And there's a sample Chrome App available here: https://github.com/GoogleChrome/chrome-app-samples/tree/master/samples/gcm-notifications - it's available in Chrome's app store and it lets you obtain the registration_id for your sender_id and then see your messages as Chrome notifications. All using a simple popup window, without writing a single line of code.



来源:https://stackoverflow.com/questions/33364218/how-to-test-gcm-notifications-without-app

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!