private bool ContainsTest(TestGSet.IntElement key) { bool e = expected.Contains(key); Assert.Equal(e, gset.Contains(key)); return(e); }
private bool ContainsTest(TestLightWeightCache.IntEntry key) { bool c = cache.Contains(key); if (c) { Assert.True(hashMap.Contains(key)); } else { TestLightWeightCache.IntEntry h = hashMap.Remove(key); if (h != null) { Assert.True(cache.IsExpired(h, currentTestTime)); } } return(c); }