示例#1
0
 def test_random_size(self):
     n = randint(3, 100)
     self.assertTrue(
         is_palindrome(TestRecursivePalindrome.generate_palindrome(n)))
示例#2
0
 def test_size_2(self):
     self.assertTrue(
         is_palindrome(TestRecursivePalindrome.generate_palindrome(2)))
示例#3
0
 def test_size_2_not(self):
     self.assertFalse(is_palindrome("xy"))
示例#4
0
 def test_empty_str(self):
     self.assertTrue(is_palindrome(""))