Command { IO<Nothing> printVersion(final @NotNull Function<Object, IO<Nothing>> linePrinter) { return uncheck0(() -> { final Properties properties = new Properties(); try (InputStream input = Command.class.getResourceAsStream(VERSION_PROPERTIES_NAME)) { properties.load(input); return linePrinter.apply("OakPAL CLI " + properties.getProperty("version")); } }).get(); }    }
@Test public void testPrintVersion() { final String output = captureOutput(Command::printVersion); LOGGER.info("version: \n{}", output); assertFalse("version should not be empty", output.isEmpty()); }