本文整理汇总了C#中AttributeCollection.Equals方法的典型用法代码示例。如果您正苦于以下问题:C# AttributeCollection.Equals方法的具体用法?C# AttributeCollection.Equals怎么用?C# AttributeCollection.Equals使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类AttributeCollection
的用法示例。
在下文中一共展示了AttributeCollection.Equals方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: Equals_CreateTwoIdenticallCollection_CollectionsAreNotEqual
public void Equals_CreateTwoIdenticallCollection_CollectionsAreNotEqual() {
var attributeValueCollection = A.CollectionOfFake<object>(1);
var dictionary = new Hashtable();
dictionary.Add("key", attributeValueCollection);
var collection1 = new AttributeCollection(dictionary);
var collection2 = new AttributeCollection(dictionary);
Assert.IsFalse(collection1.Equals(collection2));
}
示例2: Equals_CreateCollection_CollectionIsNotEquaNull
public void Equals_CreateCollection_CollectionIsNotEquaNull() {
var attributeValueCollection = A.CollectionOfFake<object>(1);
var dictionary = new Hashtable();
dictionary.Add("key", attributeValueCollection);
var collection = new AttributeCollection(dictionary);
Assert.IsFalse(collection.Equals(null));
}
示例3: Equals_CreateCollection_CollectionIsEqualsItself
public void Equals_CreateCollection_CollectionIsEqualsItself() {
var attributeValueCollection = A.CollectionOfFake<object>(1);
var dictionary = new Hashtable();
dictionary.Add("key", attributeValueCollection);
var collection = new AttributeCollection(dictionary);
Assert.IsTrue(collection.Equals(collection));
}