@Override
  public boolean equals(Object o) {
    if (this == o) return true;
    if (o == null || getClass() != o.getClass()) return false;

    RepaymentSummary that = (RepaymentSummary) o;

    if (!remainingDebt.equals(that.remainingDebt)) return false;
    if (!totalInterest.equals(that.totalInterest)) return false;
    if (!totalRepayments.equals(that.totalRepayments)) return false;
    return totalRates.equals(that.totalRates);
  }
 @Test
 public void testEquality() {
   Money fiveFrancs = Money.franc(5);
   Money fiveDollars = Money.dollar(5);
   assertFalse(fiveFrancs.equals(fiveDollars));
 }