public void DictionarySet_EqualSets() { var a = Ds(1, S(2, 3)); var b = Ds(1, S(2, 3)); Assert.IsTrue(HashCodeUtils.For(Seed, a) == HashCodeUtils.For(Seed, b)); }
public void Dictionary_EqualContents() { var a = D(1, 2); var b = D(1, 2); Assert.IsTrue(HashCodeUtils.For(Seed, a) == HashCodeUtils.For(Seed, b)); }
public void DictionarySet_UnequalLists2() { var a = Ds(1, L(2, 3)); var b = Ds(1, L(4, 3)); Assert.IsFalse(HashCodeUtils.For(Seed, a) == HashCodeUtils.For(Seed, b)); }
public void Dictionary_UnequalContents() { var a = D(1, 2); var b = D(3, 4); Assert.IsFalse(HashCodeUtils.For(Seed, a) == HashCodeUtils.For(Seed, b)); }
public override int GetHashCode() { unchecked { var valuesHashCode = HashCodeUtils.For(337, _values); return((_maxCacheSize * 397) ^ valuesHashCode); } }
public override int GetHashCode() { unchecked { var hashCode = base.GetHashCode(); hashCode = (hashCode * 397) ^ (HashCodeUtils.For(397, ConcurrentEventList)); return(hashCode); } }
public override int GetHashCode() { unchecked { var hashCode = (ParentResolver != null ? ParentResolver.GetHashCode() : 2); hashCode = (hashCode * 397) ^ HashCodeUtils.For(13, _typeToQuery); hashCode = (hashCode * 397) ^ HashCodeUtils.For(17, _idToQuery); return(hashCode); } }
public override int GetHashCode() { unchecked { var hashCode = base.GetHashCode(); hashCode = (hashCode * 397) ^ (Content != null ? Content.GetHashCode() : 17); hashCode = (hashCode * 397) ^ (StackTrace != null ? HashCodeUtils.For(397, StackTrace) : 13); return(hashCode); } }
public override int GetHashCode() { unchecked { var hashCode = base.GetHashCode(); hashCode = (hashCode * 397) ^ (Scope != null ? Scope.GetHashCode() : 0); hashCode = (hashCode * 397) ^ (Action != null ? Action.GetHashCode() : 0); hashCode = (hashCode * 397) ^ (HashCodeUtils.For(397, Targets)); return(hashCode); } }
public override int GetHashCode() { unchecked { var hashCode = base.GetHashCode(); hashCode = (hashCode * 397) ^ (int)IDELifecyclePhase; hashCode = (hashCode * 397) ^ (OpenWindows != null ? HashCodeUtils.For(397, OpenWindows) : 0); hashCode = (hashCode * 397) ^ (OpenDocuments != null ? HashCodeUtils.For(397, OpenDocuments) : 0); return(hashCode); } }
public void DictionarySet_UnequalSets3_AdaptationOfContextBug() { var a = new Dictionary <string, ISet <IMethodName> > { { "A", new HashSet <IMethodName> { M("C") } } }; var b = new Dictionary <string, ISet <IMethodName> > { { "A", new HashSet <IMethodName> { M("C") } } }; Assert.AreEqual(a, b); Assert.IsTrue(HashCodeUtils.For(1, a) == HashCodeUtils.For(1, b)); }
public override int GetHashCode() { unchecked { var hashCode = 2954786; hashCode = (hashCode * 397) ^ DayFirst.GetHashCode(); hashCode = (hashCode * 397) ^ DayLast.GetHashCode(); hashCode = (hashCode * 397) ^ NumDays; hashCode = (hashCode * 397) ^ NumMonth; hashCode = (hashCode * 397) ^ NumEventsTotal; hashCode = (hashCode * 397) ^ HashCodeUtils.For(397, NumEventsDetailed); hashCode = (hashCode * 397) ^ (int)Education; hashCode = (hashCode * 397) ^ (int)Position; hashCode = (hashCode * 397) ^ NumCodeCompletion; hashCode = (hashCode * 397) ^ NumTestRuns; hashCode = (hashCode * 397) ^ ActiveTime.GetHashCode(); return(hashCode); } }
public void DictionarySet_EmptyReturnsSeed() { var a = new Dictionary <int, IEnumerable <int> >(); Assert.IsTrue(HashCodeUtils.For(Seed, a) == Seed); }
public void Dictionary_EmptyReturnsSeed() { var a = new Dictionary <int, int>(); Assert.IsTrue(HashCodeUtils.For(Seed, a) == Seed); }