### Question:
NotificationConsumer implements Consumer<NotificationContent> { @Override public void accept(NotificationContent notificationContent) throws Exception { ThreadUtil.ensureWorkThread("NotificationConsumer"); if (mNotification == null) { return; } mNotification.onNotificationReceive(System.currentTimeMillis(), notificationContent); } NotificationConsumer(NotificationListener notifications); @Override void accept(NotificationContent notificationContent);  }### Answer:
@Test public void accept() { try { new NotificationConsumer(null).accept(new NotificationContent("AndroidGodEye_message", null)); CountDownLatch countDownLatch = new CountDownLatch(1); final NotificationContent[] notificationContent0 = new NotificationContent[1]; new NotificationConsumer(new NotificationListener() { @Override public void onInstalled() { } @Override public void onUninstalled() { } @Override public void onNotificationReceive(long timeMillis, NotificationContent notificationContent) { notificationContent0[0] = notificationContent; countDownLatch.countDown(); } }).accept(new NotificationContent("AndroidGodEye_message", null)); countDownLatch.await(1, TimeUnit.SECONDS); assertEquals("AndroidGodEye_message", notificationContent0[0].message); } catch (Exception e) { fail(); } }