Search in sources :

Example 1 with YamlMapperProvider

use of io.stackgres.common.YamlMapperProvider in project stackgres by ongres.

the class CrdMatchTest method withEveryYaml.

private static void withEveryYaml(Consumer<JsonNode> crdDefinition) throws IOException {
    YAMLMapper yamlMapper = new YamlMapperProvider().yamlMapper();
    for (File crd : crdFiles) {
        JsonNode crdTree = yamlMapper.readTree(crd);
        crdDefinition.accept(crdTree);
    }
}
Also used : YAMLMapper(com.fasterxml.jackson.dataformat.yaml.YAMLMapper) JsonNode(com.fasterxml.jackson.databind.JsonNode) YamlMapperProvider(io.stackgres.common.YamlMapperProvider) File(java.io.File)

Aggregations

JsonNode (com.fasterxml.jackson.databind.JsonNode)1 YAMLMapper (com.fasterxml.jackson.dataformat.yaml.YAMLMapper)1 YamlMapperProvider (io.stackgres.common.YamlMapperProvider)1 File (java.io.File)1