### Question:
WebSocketNotificationService implements NotificationService { @Override public void notify(final ServerTemplate serverTemplate, final ContainerSpec containerSpec, final List<Container> containers) { LOGGER.info("WebSocket notification about change requested on server {} with container spec {} with following result {}", serverTemplate, containerSpec, containers); notifySessions(new ContainerSpecUpdated(serverTemplate, containerSpec, containers)); } protected  WebSocketNotificationService(); static WebSocketNotificationService getInstance(); @Override void notify(final ServerTemplate serverTemplate,
                       final ContainerSpec containerSpec,
                       final List<Container> containers); @Override void notify(final ServerTemplateUpdated serverTemplateUpdated); @Override void notify(final ServerTemplateDeleted serverTemplateDeleted); @Override void notify(final ServerInstanceUpdated serverInstanceUpdated); @Override void notify(final ServerInstanceDeleted serverInstanceDeleted); @Override void notify(final ServerInstanceConnected serverInstanceConnected); @Override void notify(final ServerInstanceDisconnected serverInstanceDisconnected);  }### Answer:
@Test public void testServerInstanceConnected() throws Exception { final ServerInstanceConnected event = new ServerInstanceConnected(new ServerInstance()); notificationService.notify(event); verify(endpoint, timeout(TIMEOUT)).sendObject(new KieServerControllerNotification(event)); }
@Test public void testServerInstanceDisconnected() throws Exception { final ServerInstanceDisconnected event = new ServerInstanceDisconnected("serverId"); notificationService.notify(event); verify(endpoint, timeout(TIMEOUT)).sendObject(new KieServerControllerNotification(event)); }
@Test public void testServerInstanceDeleted() throws Exception { final ServerInstanceDeleted event = new ServerInstanceDeleted("serverId"); notificationService.notify(event); verify(endpoint, timeout(TIMEOUT)).sendObject(new KieServerControllerNotification(event)); }
@Test public void testServerInstanceUpdated() throws Exception { final ServerInstanceUpdated event = new ServerInstanceUpdated(new ServerInstance()); notificationService.notify(event); verify(endpoint, timeout(TIMEOUT)).sendObject(new KieServerControllerNotification(event)); }
@Test public void testServerTemplateUpdated() throws Exception { final ServerTemplateUpdated event = new ServerTemplateUpdated(new ServerTemplate()); notificationService.notify(event); verify(endpoint, timeout(TIMEOUT)).sendObject(new KieServerControllerNotification(event)); }
@Test public void testServerTemplateDeleted() throws Exception { final ServerTemplateDeleted event = new ServerTemplateDeleted("serverTemplateId"); notificationService.notify(event); verify(endpoint, timeout(TIMEOUT)).sendObject(new KieServerControllerNotification(event)); }
@Test public void testContainerSpecUpdated() throws Exception { final ServerTemplate serverTemplate = new ServerTemplate(); final ContainerSpec containerSpec = new ContainerSpec(); final ArrayList<Container> containers = new ArrayList<>(); final ContainerSpecUpdated event = new ContainerSpecUpdated(serverTemplate, containerSpec, containers); notificationService.notify(serverTemplate, containerSpec, containers); verify(endpoint, timeout(TIMEOUT)).sendObject(new KieServerControllerNotification(event)); }