Esempio n. 1
0
        public void ShouldCompareTwoInstances()
        {
            CategoryEditorAttribute attribute1 = new CategoryEditorAttribute("category", "type");
              CategoryEditorAttribute attribute2 = new CategoryEditorAttribute("category", "type");
              Assert.IsTrue(attribute1.Equals(attribute2));

              attribute2 = new CategoryEditorAttribute("category2", "type");
              Assert.IsFalse(attribute1.Equals(attribute2));

              attribute2 = new CategoryEditorAttribute("category", "type2");
              Assert.IsFalse(attribute1.Equals(attribute2));
        }
Esempio n. 2
0
 public void ShouldCompareSameInstance()
 {
     CategoryEditorAttribute attribute = new CategoryEditorAttribute("category", "type");
       Assert.IsTrue(attribute.Equals(attribute));
 }