@Test
    public void testPropertyNameOverride() {
        String name1 = "name1";
        String name2 = "name2";
        String name3 = "name3";

        Assertions.assertNull(this.instance.resolvePropertyNameOverride(this.field1));

        ConfigFunction<FieldScope, String> resolver1 = member -> member == this.field1 ? name1 : null;
        Assertions.assertSame(this.instance, this.instance.withPropertyNameOverrideResolver(resolver1));
        Assertions.assertSame(name1, this.instance.resolvePropertyNameOverride(this.field1));
        Assertions.assertNull(this.instance.resolvePropertyNameOverride(this.field2));
        Assertions.assertNull(this.instance.resolvePropertyNameOverride(this.field3));

        ConfigFunction<FieldScope, String> resolver2 = member -> member == this.field1 ? name2 : null;
        Assertions.assertSame(this.instance, this.instance.withPropertyNameOverrideResolver(resolver2));
        Assertions.assertSame(name1, this.instance.resolvePropertyNameOverride(this.field1));
        Assertions.assertNull(this.instance.resolvePropertyNameOverride(this.field2));
        Assertions.assertNull(this.instance.resolvePropertyNameOverride(this.field3));

        ConfigFunction<FieldScope, String> resolver3 = member -> member == this.field2 ? name3 : null;
        Assertions.assertSame(this.instance, this.instance.withPropertyNameOverrideResolver(resolver3));
        Assertions.assertSame(name1, this.instance.resolvePropertyNameOverride(this.field1));
        Assertions.assertSame(name3, this.instance.resolvePropertyNameOverride(this.field2));
        Assertions.assertNull(this.instance.resolvePropertyNameOverride(this.field3));
    }
Test for the {@link SchemaGeneratorConfigPart} class.
jsonschema-generator/src/test/java/com/github/victools/jsonschema/generator/SchemaGeneratorConfigPartTest.java