### Question:
RemoteResult { @Override public boolean equals(Object o) { if (this == o) { return true; } if (!(o instanceof RemoteResult)) { return false; } RemoteResult that = (RemoteResult) o; return mType == that.mType && mValue == that.mValue; } private  RemoteResult(@Type int type, long value); static RemoteResult of(long value); boolean isPresent(); long get(); @Override String toString(); @Override boolean equals(Object o); @Override int hashCode(); static final RemoteResult FAILED_TIMED_OUT; static final RemoteResult FAILED_CANCELLED; static final RemoteResult FAILED_THREAD_INTERRUPTED; }### Answer:
@Test public void testEquals() { assertThat(RemoteResult.of(3).equals(RemoteResult.of(3))).isTrue(); assertThat(RemoteResult.of(3).equals(RemoteResult.of(7))).isFalse(); assertThat(RemoteResult.of(-1).equals(RemoteResult.of(1))).isFalse(); assertThat(RemoteResult.of(Long.MAX_VALUE).equals(RemoteResult.of(-1))) .isFalse(); assertThat(RemoteResult.of(3).equals(RemoteResult.FAILED_TIMED_OUT)).isFalse(); assertThat(RemoteResult.of(3).equals("3")).isFalse(); assertThat(RemoteResult.of(3).equals(null)).isFalse(); assertThat(RemoteResult.FAILED_TIMED_OUT.equals(RemoteResult.FAILED_TIMED_OUT)).isTrue(); assertThat(RemoteResult.FAILED_TIMED_OUT.equals(RemoteResult.FAILED_CANCELLED)).isFalse(); }