示例#1
0
 /* Utilities */
 public static bool VerifySetsIdentical(AbstractTestLog here, UnicodeSet set1, UnicodeSet set2)
 {
     if (set1.Equals(set2))
     {
         return(true);
     }
     TestFmwk.Errln("Sets differ:");
     TestFmwk.Errln("UnicodeMap - HashMap");
     TestFmwk.Errln(new UnicodeSet(set1).RemoveAll(set2).ToPattern(true));
     TestFmwk.Errln("HashMap - UnicodeMap");
     TestFmwk.Errln(new UnicodeSet(set2).RemoveAll(set1).ToPattern(true));
     return(false);
 }
示例#2
0
        public static bool VerifySetsIdentical(AbstractTestLog here, ISet <T> values1, ISet <T> values2)
        {
            if (SetEqualityComparer <T> .Aggressive.Equals(values1, values2))
            {
                return(true);
            }
            ISet <T> temp;

            TestFmwk.Errln("Values differ:");
            TestFmwk.Errln("UnicodeMap - HashMap");
            temp = new JCG.SortedSet <T>(values1, JCG.Comparer <T> .Default);
            temp.ExceptWith(values2);
            TestFmwk.Errln(Show(temp));
            TestFmwk.Errln("HashMap - UnicodeMap");
            temp = new JCG.SortedSet <T>(values2, JCG.Comparer <T> .Default);
            temp.ExceptWith(values1);
            TestFmwk.Errln(Show(temp));
            return(false);
        }
示例#3
0
        public static bool VerifySetsIdentical(AbstractTestLog here, ISet <T> values1, ISet <T> values2)
        {
            if (CollectionUtil.Equals(values1, values2))
            {
                return(true);
            }
            ISet <T> temp;

            TestFmwk.Errln("Values differ:");
            TestFmwk.Errln("UnicodeMap - HashMap");
            temp = new SortedSet <T>(values1, GenericComparer.NaturalComparer <T>());
            temp.ExceptWith(values2);
            TestFmwk.Errln(Show(temp));
            TestFmwk.Errln("HashMap - UnicodeMap");
            temp = new SortedSet <T>(values2, GenericComparer.NaturalComparer <T>());
            temp.ExceptWith(values1);
            TestFmwk.Errln(Show(temp));
            return(false);
        }