title: Is there a Java utility to do a deep comparison of two objects?
body: <p>How to &quot;deep&quot;-compare two objects that do not implement the equals method based on their field values in a test?</p>
  <hr />
  <p>Original Question (closed because lack of precision and thus not fulfilling SO standards), kept for documentation purposes:</p>
  <p>I'm trying to write unit tests for a variety of <code>clone()</code> operations inside a large project and I'm wondering if there is an existing class somewhere that is capable of taking two objects of the same type, doing a deep comparison, and saying if they're identical or not?</p>