ClusterAlertingService implements InternalAlertingService { @Override public synchronized boolean hasAlertListener(final DistributedMember member, final AlertLevel alertLevel) { for (AlertListener listener : listeners) { if (listener.getMember().equals(member) && listener.getLevel().equals(alertLevel)) { return true; } } return false; } ClusterAlertingService(); @Override void useAlertMessaging(AlertMessaging alertMessaging); @Override void sendAlerts(final AlertLevel alertLevel,
      final Instant timestamp,
      final String threadName,
      final long threadId,
      final String formattedMessage,
      final String stackTrace); @Override synchronized void addAlertListener(final DistributedMember member,
      final AlertLevel alertLevel); @Override synchronized boolean removeAlertListener(final DistributedMember member); @Override synchronized boolean hasAlertListener(final DistributedMember member,
      final AlertLevel alertLevel); @Override boolean hasAlertListeners(); @Override String toString();  }
@Test public void hasAlertListenerReturnsFalseByDefault() { alertingService.hasAlertListener(member, AlertLevel.WARNING); }