Exemplo n.º 1
0
        public void CompareSortedWords_WillReturnBool_CompareWords()
        {
            AnagramProgram TestAnagram = new AnagramProgram();
            string         testword    = "save";
            string         testword2   = "vase";

            char[] testString = { 'a', 'e', 's', 'v' };
            TestAnagram.GetWordOne(testString);
            char[] testChar  = TestAnagram.SplitWordList(testword);
            char[] testChar2 = TestAnagram.SplitWordList(testword2);
            CollectionAssert.AreEqual(true, TestAnagram.CompareWords(testChar2));
        }
Exemplo n.º 2
0
        public void SplitList_WillSplitandSort_StringList()
        {
            AnagramProgram TestAnagram = new AnagramProgram();
            string         name        = "apple";

            char[] testString = { 'a', 'e', 'l', 'p', 'p' };
            CollectionAssert.AreEqual(testString, TestAnagram.SplitWordList(name));
        }