Пример #1
0
 public void IsPalindrome_NullArgument()
 {
     var target = new Problem1();
     target.IsPalindrome(null);
 }
Пример #2
0
 public void IsPalindrome_EmptyStringIsAPalindrome()
 {
     var target = new Problem1();
     Assert.IsTrue(target.IsPalindrome(string.Empty));
 }
Пример #3
0
 public void IsPalindrome_NotAPalindrome()
 {
     var target = new Problem1();
     Assert.IsFalse(target.IsPalindrome("hello world"));
 }
Пример #4
0
 public void IsPalindrome_Palindromes()
 {
     var target = new Problem1();
     Assert.IsTrue(target.IsPalindrome("A man a plan a canal Panama"));
     Assert.IsTrue(target.IsPalindrome("Z"));
     Assert.IsTrue(target.IsPalindrome("A Toyotas a Toyota"));
     Assert.IsTrue(target.IsPalindrome("Go hang a salami Im a lasagna hog"));
     Assert.IsTrue(target.IsPalindrome("zzzxxyyayyxxzzz"));
 }