@ParameterizedTest
    @EnumSource(SchemaVersion.class)
    public void testSetPatternProperties_SpecificEntries(SchemaVersion schemaVersion) {
        SchemaGenerationContextImpl generationContext = this.generateContext(schemaVersion);
        LinkedHashMap<String, JsonNode> patterns = new LinkedHashMap<>();
        patterns.put("^intClass.*$", generationContext.createDefinitionReference(generationContext.getTypeContext().resolve(int.class)));
        patterns.put("^stringClass.*$", generationContext.createDefinitionReference(generationContext.getTypeContext().resolve(String.class)));
        this.collector.setPatternProperties(this.definitionNode, patterns, generationContext);
        Assertions.assertEquals(1, this.definitionNode.size());
        JsonNode patternPropertiesNode = this.definitionNode.get(SchemaKeyword.TAG_PATTERN_PROPERTIES.forVersion(schemaVersion));
        Assertions.assertNotNull(patternPropertiesNode);
        Assertions.assertTrue(patternPropertiesNode.isObject());
        Assertions.assertEquals(2, patternPropertiesNode.size());
        Assertions.assertTrue(patternPropertiesNode.get("^intClass.*$").isObject());
        Assertions.assertTrue(patternPropertiesNode.get("^stringClass.*$").isObject());
    }
Helper method for creating the test context for a given JSON Schema version.

@param schemaVersion designated JSON Schema version
@return schema generation context for the given JSON Schema version
jsonschema-generator/src/test/java/com/github/victools/jsonschema/generator/impl/AttributeCollectorTest.java