public static <T> String render(ClassPluginDocumentation<T> classPluginDocumentation) throws IOException {
        return render("task", JacksonMapper.toMap(classPluginDocumentation));
    }
@SuppressWarnings({"rawtypes", "unchecked"})
    @Test
    void dag() throws IOException {
        PluginScanner pluginScanner = new PluginScanner(ClassPluginDocumentationTest.class.getClassLoader());
        RegisteredPlugin scan = pluginScanner.scan();
        Class dag = scan.findClass(Dag.class.getName()).orElseThrow();

        ClassPluginDocumentation<? extends Task> doc = ClassPluginDocumentation.of(jsonSchemaGenerator, scan, dag, Task.class);

        String render = DocumentationGenerator.render(doc);

        assertThat(render, containsString("Dag"));
        assertThat(render, containsString("**Required:** ✔️"));
        assertThat(render, containsString("`concurrent`"));
        assertThat(render, not(containsString("requires an Enterprise Edition")));

        int propertiesIndex = render.indexOf("Properties");
        int definitionsIndex = render.indexOf("Definitions");

        assertRequiredPropsAreFirst(render.substring(propertiesIndex, definitionsIndex));

        String definitionsDoc = render.substring(definitionsIndex);
        Arrays.stream(definitionsDoc.split("[^#]### "))
            // first is 'Definitions' header
            .skip(1)
                .forEach(DocumentationGeneratorTest::assertRequiredPropsAreFirst);
    }