@ParameterizedTest
    @ValueSource(strings = { "WithoutAbstracts", "WithoutInterfaces" })
    public void testPackageName(String scenario) throws Exception {
        File testCaseLocation = new File("src/test/resources/reference-test-cases");
        File generationLocation = new File("target/generated-test-sources/PackageName" + scenario);

        // Execute the pom
        executePom(new File("src/test/resources/reference-test-cases/PackageName" + scenario + "-pom.xml"));

        // Validate that the schema files are created.
        File resultFileA = new File(generationLocation,"TestClassA-schema.json");
        Assertions.assertTrue(resultFileA.exists());
        resultFileA.deleteOnExit();

        // explicitly excluded, although it is in the target
        File resultFileB = new File(generationLocation,"TestClassB-schema.json");
        Assertions.assertFalse(resultFileB.exists());

        File resultFileC = new File(generationLocation,"TestClassC-schema.json");
        Assertions.assertTrue(resultFileC.exists());
        resultFileC.deleteOnExit();

        File resultFileAbstract = new File(generationLocation,"AbstractTestClass-schema.json");
        Assertions.assertNotEquals("WithoutAbstracts".equals(scenario), resultFileAbstract.exists());
        File resultFileInterface = new File(generationLocation,"TestInterface-schema.json");
        Assertions.assertNotEquals("WithoutInterfaces".equals(scenario), resultFileInterface.exists());

        // Validate that they are the same as the reference
        File referenceFileA = new File(testCaseLocation, "TestClassA-reference.json");
        Assertions.assertTrue(referenceFileA.exists());
        Assertions.assertTrue(FileUtils.contentEqualsIgnoreEOL(resultFileA, referenceFileA, CHARSET_NAME),
                "Generated schema for TestClassA is not equal to the expected reference.");

        File referenceFileC = new File(testCaseLocation, "TestClassC-reference.json");
        Assertions.assertTrue(referenceFileC.exists());
        Assertions.assertTrue(FileUtils.contentEqualsIgnoreEOL(resultFileC, referenceFileC, CHARSET_NAME),
                "Generated schema for TestClassC is not equal to the expected reference.");
    }
Unit test to test the generation of schemas for multiple classes
jsonschema-maven-plugin/src/test/java/com/github/victools/jsonschema/plugin/maven/SchemaGeneratorMojoTest.java