Send Test Messages
We are now ready to send some test messages.
Open the application menu on the developer portal and select the "Push" icon like below:
Select the "New Message" and input the following information:
- Set the receiver to "User".
- Select "Login Name" in the pull-down menu and enter the target user's name (
user1). This is the user who was logging in when the initialization method
- Toggle on the "Android".
- Click the "Confirm" button.
You should be able to see the
MyFirebaseMessagingService.onMessageReceived() being executed right after you click the "Confirm" button.
The code we present in this tutorial only records messages in the debug log. You might also want to use breakpoints on a debugger to check if the code works fine.
Did you get the push notification successfully? If you did not receive the push notification, check FCM Troubleshooting and solve the issue.
Here is the wrap-up: What's Next?.
|<< Implement Your Application||What's Next? >>|