### Question:
PersistentId implements Serializable { @Override public String toString() { final StringBuilder sb = new StringBuilder("PersistentId{"); sb.append("nameId='").append(nameId).append('\''); sb.append('}'); return sb.toString(); } @SuppressWarnings("unused")//Needed by JAXB private  PersistentId(); @JsonCreator  PersistentId(@JsonProperty("nameId") String nameId); String getNameId(); @Override String toString(); @Override boolean equals(Object o); @Override int hashCode();  }### Answer:
@Test public void testToString() { final StringBuilder sb = new StringBuilder("PersistentId{"); sb.append("nameId='").append(NAME_ID).append('\''); sb.append('}'); assertThat(persistentId.toString()).isEqualTo(sb.toString()); }