示例#1
0
        public void TestGetHashCodeWithNoAccounts()
        {
            AccountCollection collection = TestObjectBuilder.GetAccountCollectionWithNoAccounts();

            try
            {
                int hashCode = collection.GetHashCode();
            }
            catch (Exception ex)
            {
                Assert.Fail("There was an exception when generating a hash code for a collection with no accounts:  " + ex.ToString());
            }
        }
示例#2
0
        public void TestEqualityWithNoAccounts()
        {
            AccountCollection coll1 = TestObjectBuilder.GetAccountCollectionWithNoAccounts();
            AccountCollection coll2 = TestObjectBuilder.GetAccountCollection();

            try
            {
                bool isEqual = coll1.Equals(coll2);
                isEqual = coll2.Equals(coll1);
            }
            catch (Exception ex)
            {
                Assert.Fail("An exception was thrown when checking equality with a collection with no accounts:  " + ex.ToString());
            }
        }