SonarQualityMetric { @Override public int hashCode() { return Objects.hashCode(description, domain, key, name); }  String getKey(); String getName(); String getDescription(); String getDomain(); Boolean getQualitative(); Integer getDirection(); Boolean getUserManaged(); String getValTyp(); Boolean getHidden(); @Override String toString(); @Override boolean equals(Object o); @Override int hashCode(); void setKey(String key); void setName(String name); void setDescription(String description); void setDomain(String domain); void setQualitative(Boolean qualitative); void setDirection(Integer direction); void setUserManaged(Boolean userManaged); void setValTyp(String valTyp); void setHidden(Boolean hidden);  }
@Test public void should_build_hash_code() { SonarQualityMetric sonarQualityMetric2 = new SonarQualityMetric(); sonarQualityMetric2.name = "name2"; int hashCode1 = sonarQualityMetric2.hashCode(); int hashCode2 = sonarQualityMetric2.hashCode(); assertEquals(hashCode1, hashCode2); }