[英]Android | Is it possible to receive a push notification when running test against your application
In my android application, actions are invoked based on the command received through push notification. 在我的android应用程序中,根据通过推送通知接收的命令调用操作。 I was wondering if there is any way through which i can test the complete use case (as it runs like in application) that includes:
我想知道是否有什么方法可以测试完整的用例(因为它像在应用程序中一样运行),包括:
while sending your push notification add a key value pair to identify the command. 在发送推送通知时,添加一个键值对以标识命令。 while receiving the request in your broadcast receiver check for the key and execute the appropriate operation
在广播接收器中接收请求时,检查密钥并执行适当的操作
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.