### Question:
DurationPropertyDefinition extends PropertyDefinition<Long> { @Override public int compare(Long o1, Long o2) { return o1.compareTo(o2); } private  DurationPropertyDefinition(AbstractManagedObjectDefinition<?, ?> d, String propertyName,
        EnumSet<PropertyOption> options, AdministratorAction adminAction,
        DefaultBehaviorProvider<Long> defaultBehavior, DurationUnit baseUnit, DurationUnit maximumUnit,
        Long lowerLimit, Long upperLimit, boolean allowUnlimited); static Builder createBuilder(AbstractManagedObjectDefinition<?, ?> d, String propertyName); DurationUnit getBaseUnit(); DurationUnit getMaximumUnit(); long getLowerLimit(); Long getUpperLimit(); boolean isAllowUnlimited(); @Override void validateValue(Long value); @Override String encodeValue(Long value); @Override Long decodeValue(String value); @Override R accept(PropertyDefinitionVisitor<R, P> v, P p); @Override R accept(PropertyValueVisitor<R, P> v, Long value, P p); @Override void toString(StringBuilder builder); @Override int compare(Long o1, Long o2);  }### Answer:
@Test public void testCompare() { DurationPropertyDefinition.Builder builder = createTestBuilder(); builder.setAllowUnlimited(true); DurationPropertyDefinition def = buildTestDefinition(builder); def.compare(1L, 2L); }