private void notifyTestListenersOfEnd(SearchByClass<TestStateListener> testListeners) { log.info("Notifying test listeners of end of test"); for (TestStateListener tl : testListeners.getSearchResults()) { try { if (host == null) { tl.testEnded(); } else { tl.testEnded(host); } } catch (Exception e) { log.warn("Error encountered during shutdown of "+tl.toString(),e); } } if (host != null) { log.info("Test has ended on host {} ", host); long now=System.currentTimeMillis(); System.out.println("Finished the test on host " + host + " @ "+new Date(now)+" ("+now+")" // NOSONAR Intentional +(EXIT_AFTER_TEST ? " - exit requested." : "")); if (EXIT_AFTER_TEST){ exit(); } } active=false; }