class DemoScenarioLoader {

    String getResourceAsUtf8String(String name) {
        try (final InputStream stream = getClass().getClassLoader().getResourceAsStream(name)) {
            return IOUtils.toString(stream, StandardCharsets.UTF_8);
        } catch (IOException | NullPointerException e) {
            log.error("Cannot read demo resource file in classpath: {}", name, e);
            throw new NotGonnaHappenException("Demo file should exist and be valid in classpath: " + name);
        }
    }

}