### Question:
RoleMapping extends DomainObject implements Comparable<RoleMapping> { @Override public int compareTo(final RoleMapping other) { if (other == null) { return -1; } return new CompareToBuilder() .append(role, other.getRole()) .append(privileges, other.getPrivileges(), new CollectionComparator<>()) .toComparison(); }  Role getRole(); String getRoleName(); void setRole(final Role role); SortedSet<Privilege> getPrivileges(); SortedSet<String> getPrivilegeNames(); void setPrivileges(final SortedSet<Privilege> privileges); @Override String toString(); @Override int compareTo(final RoleMapping other);  }### Answer:
@Test public void testCompareToNull() { final RoleMapping mapping1 = new RoleMapping(); assertThat(mapping1.compareTo(null) < 0, is(true)); }