urbanairship-core/src/test/java/com/urbanairship/CoreReceiverTest.java
@Test
    public void testNotifyLegacyIamManager() {
        Bundle pushBundle = new Bundle();
        pushBundle.putString(PushMessage.EXTRA_SEND_ID, "sendId");
        PushMessage message = new PushMessage(pushBundle);

        // Create the intent
        Intent intent = new Intent()
                .setAction(PushManager.ACTION_NOTIFICATION_OPENED_PROXY)
                .putExtra(PushManager.EXTRA_PUSH_MESSAGE_BUNDLE, message.getPushBundle());


        receiver.onReceive(context, intent);
        verify(legacyInAppMessageManager).onPushResponse(message);
    }
/**
     * Test when a notification is opened it notifies the legacy in-app messaging manager.
     */
Test when a notification is opened it notifies the legacy in-app messaging manager.
Test when a notification is opened it notifies the legacy in - app messaging manager .
@Test
    public void testNotifyLegacyIamManager() {
        Bundle pushBundle = new Bundle();
        pushBundle.putString(PushMessage.EXTRA_SEND_ID, "sendId");
        PushMessage message = new PushMessage(pushBundle);
        Intent intent = new Intent()
                .setAction(PushManager.ACTION_NOTIFICATION_OPENED_PROXY)
                .putExtra(PushManager.EXTRA_PUSH_MESSAGE_BUNDLE, message.getPushBundle());
        receiver.onReceive(context, intent);
        verify(legacyInAppMessageManager).onPushResponse(message);
    }
@ Test public void testNotifyLegacyIamManager ( ) { Bundle pushBundle = new Bundle ( ) ; pushBundle . putString ( PushMessage . EXTRA_SEND_ID , "sendId" ) ; PushMessage message = new PushMessage ( pushBundle ) ; Intent intent = new Intent ( ) . setAction ( PushManager . ACTION_NOTIFICATION_OPENED_PROXY ) . putExtra ( PushManager . EXTRA_PUSH_MESSAGE_BUNDLE , message . getPushBundle ( ) ) ; receiver . onReceive ( context , intent ) ; verify ( legacyInAppMessageManager ) . onPushResponse ( message ) ; }
Test when a notification is opened it notifies the legacy in-app messaging manager.
Test when a notification is opened it notifies the legacy in - app messaging manager .
// Create the intent