### Question:
Money implements IMoney { @Override public int hashCode() { if (fAmount == 0) { return 0; } return fCurrency.hashCode() + fAmount; } Money(int amount, String currency); IMoney add(IMoney m); IMoney addMoney(Money m); IMoney addMoneyBag(MoneyBag s); int amount(); String currency(); @Override boolean equals(Object anObject); @Override int hashCode(); boolean isZero(); IMoney multiply(int factor); IMoney negate(); IMoney subtract(IMoney m); @Override String toString(); void appendTo(MoneyBag m);  }### Answer:
@Test public void testMoneyBagHash() { IMoney equal = MoneyBag.create(new Money(12, "CHF"), new Money(7, "USD")); assertEquals(fMB1.hashCode(), equal.hashCode()); }
@Test public void zeroMoniesAreEqualRegardlessOfCurrency() { Money zeroDollars = new Money(0, "USD"); Money zeroFrancs = new Money(0, "CHF"); assertEquals(zeroDollars, zeroFrancs); assertEquals(zeroDollars.hashCode(), zeroFrancs.hashCode()); }