SlobrokMonitorManagerImpl implements SlobrokApi, MonitorManager { @Override public void applicationActivated(ApplicationInfo application) { if (wouldNotMonitor(application.getApplicationId())) { return; } synchronized (monitor) { SlobrokMonitor slobrokMonitor = slobrokMonitors.computeIfAbsent( application.getApplicationId(), id -> slobrokMonitorFactory.get()); slobrokMonitor.updateSlobrokList(application); } } @Inject  SlobrokMonitorManagerImpl(DuperModelManager duperModel);   SlobrokMonitorManagerImpl(Supplier<SlobrokMonitor> slobrokMonitorFactory, DuperModelManager duperModel); @Override void applicationActivated(ApplicationInfo application); @Override void applicationRemoved(ApplicationId id); @Override void bootstrapComplete(); @Override List<Mirror.Entry> lookup(ApplicationId id, String pattern); @Override ServiceStatusInfo getStatus(ApplicationId applicationId,
                                       ClusterId clusterId,
                                       ServiceType serviceType,
                                       ConfigId configId);  }
@Test public void testActivationOfApplication() { slobrokMonitorManager.applicationActivated(application); verify(slobrokMonitorFactory, times(1)).get(); }