This answer is written in Sep, 2021 with these gradle dependencies:
implementation 'com.google.firebase:firebase-messaging:22.0.0'
implementation 'com.google.firebase:firebase-iid:21.1.0'
Some times, Emulator stops to receive the FCM notification, here is what I do to solve it:
1- Chose Emulator with Google API.

2-wipe data:

3-Use below function to get multicast ID, or to get the reason for failure registration.
private void check_token() {
String TAG = "_testing";
FirebaseInstanceId.getInstance().getInstanceId()
.addOnCompleteListener(new OnCompleteListener<InstanceIdResult>() {
@Override
public void onComplete(@NonNull Task<InstanceIdResult> task) {
if (!task.isSuccessful()) {
Log.e(TAG, "getInstanceId failed", task.getException());
return;
}
// Get new Instance ID token
String token = task.getResult().getToken();
// Log and toast
// String msg = getString(R.string.msg_token_fmt, token);
Log.e(TAG, token);
Toast.makeText(MainActivity3.this, token, Toast.LENGTH_SHORT).show();
}
});
}
Once, you got the token , you can try to send the notification message.
Note:
No need to login with google account. FCM is working without gmail login.