Collection<String> getLogMessages() {
      return log.stream()
          .map(LogRecord::getMessage)
          .collect(Collectors.toList());
    }
Log handler for testing. Capture logged messages for later inspection.

@see Handler#publish(LogRecord)
geode-gfsh/src/integrationTest/java/org/apache/geode/management/internal/cli/shell/GfshInitFileIntegrationTest.java