@Test
void testNonPrimitiveObjectPropertyField() throws Exception {

  NonPrimitiveClass instance = new NonPrimitiveClass();

  Class<NonPrimitiveClass> clazz = NonPrimitiveClass.class;
  ObjectPropertyField field_string =
      new ObjectPropertyField(clazz.getDeclaredField("str"), propName);
  ObjectPropertyField field_duration =
      new ObjectPropertyField(clazz.getDeclaredField("duration"), propName);

  field_string.applyValueParser(instance, "just str");
  field_duration.applyValueParser(instance, "100ms");

  assertEquals("just str", instance.str);
  assertEquals(Duration.ofMillis(100), instance.duration);
}