Ejemplo n.º 1
0
        public void EqualsTestEquality()
        {
            CountedCategory o1 = new CountedCategory(
                new Category(2, "foo"), 42, new Dictionary<string, int>());
            CountedCategory o2 = new CountedCategory(
                new Category(2, "foo"), 42, new Dictionary<string, int>());

            Assert.IsTrue(o1.Equals(o2));
        }
Ejemplo n.º 2
0
 public void EqualsTestObjectReferenceEquality()
 {
     CountedCategory o1 = new CountedCategory(
         new Category(2, "foo"), 42, new Dictionary<string, int>());
     Object o2 = (Object) new CountedCategory(
         new Category(2, "foo"), 42, new Dictionary<string, int>());
     Assert.IsTrue(o1.Equals(o2));
 }