Beispiel #1
0
        public void TestPalindromeMethod()
        {
            bool expected1 = true;
            bool expected2 = false;


            bool actual1 = PalindromeFunctions.isPalindrome("racecar");

            bool actual2 = PalindromeFunctions.isPalindrome("race");


            Assert.AreEqual(expected1, actual1);

            Assert.AreEqual(expected2, actual2);
        }
Beispiel #2
0
        public void TestMethod1()
        {
            {
                bool expected1 = true;
                bool expected2 = true;

                bool expected3 = false;


                bool actual1 = PalindromeFunctions.IsPalindromeWithRegex("racecar");
                bool actual2 = PalindromeFunctions.IsPalindromeWithRegex("Never odd or even");


                bool actual3 = PalindromeFunctions.IsPalindromeWithRegex("Not a palindrome");


                Assert.AreEqual(expected1, actual1);

                Assert.AreEqual(expected2, actual2);

                Assert.AreEqual(expected3, actual3);
            }
        }