@Test public void testEquals() { SeasonDate date1 = new SeasonDate(mockSlot, 1, Season.SU); SeasonDate date2 = new SeasonDate(mockSlot, 1, Season.SU); assertEquals(date1, date2); assertEquals(date1.getSeason(), date2.getSeason()); assertEquals(date1.getYear(), date2.getYear()); assertEquals(date1.getSlot(), date2.getSlot()); assertEquals(date1.hashCode(), date2.hashCode()); assertEquals(date1.toString(), date2.toString()); }
@Override public boolean equals(Object o) { if (!super.equals(o)) return false; SeasonDate that = (SeasonDate) o; return year == that.year && season == that.season; }
SeasonDate extends AmazonDate { @Override public boolean equals(Object o) { if (!super.equals(o)) return false; SeasonDate that = (SeasonDate) o; return year == that.year && season == that.season; } }
SeasonDate extends AmazonDate { @Override public boolean equals(Object o) { if (!super.equals(o)) return false; SeasonDate that = (SeasonDate) o; return year == that.year && season == that.season; } SeasonDate(Slot slot, int year, Season season); }
SeasonDate extends AmazonDate { @Override public boolean equals(Object o) { if (!super.equals(o)) return false; SeasonDate that = (SeasonDate) o; return year == that.year && season == that.season; } SeasonDate(Slot slot, int year, Season season); int getYear(); Season getSeason(); @Override boolean equals(Object o); @Override int hashCode(); @Override String toString(); }
SeasonDate extends AmazonDate { @Override public boolean equals(Object o) { if (!super.equals(o)) return false; SeasonDate that = (SeasonDate) o; return year == that.year && season == that.season; } SeasonDate(Slot slot, int year, Season season); int getYear(); Season getSeason(); @Override boolean equals(Object o); @Override int hashCode(); @Override String toString();  }