Notifier implements JsonSerializable { private Notifier(Builder builder) { this.name = builder.name; this.version = builder.version; } private  Notifier(Builder builder); String getName(); String getVersion(); @Override boolean equals(Object o); @Override int hashCode(); @Override String toString(); @Override Map<String, Object> asJson();  }
@Test public void shouldBeEqual() { Notifier notifier1 = notifier(); Notifier notifier2 = notifier(); assertThat(notifier2, is(notifier1)); }