Пример #1
0
 def test_isMatch_withdotandstar_notmatch(self):
     solution = Solution()
     self.assertFalse(solution.isMatch("mississippi", "mis*is*p*."))
Пример #2
0
 def test_isMatch_match(self):
     solution = Solution()
     self.assertTrue(solution.isMatch("ab", "ab"))
Пример #3
0
 def test_isMatch_withdotandstar_match(self):
     solution = Solution()
     self.assertTrue(solution.isMatch("", ".*"))
     self.assertTrue(solution.isMatch("ab", ".*"))
Пример #4
0
 def test_isMatch_withstar_notmatch(self):
     solution = Solution()
     self.assertFalse(solution.isMatch("ba", "a*"))
Пример #5
0
 def test_isMatch_withstar_match(self):
     solution = Solution()
     self.assertTrue(solution.isMatch("aab", "a*b"))
     self.assertTrue(solution.isMatch("aab", "c*a*b"))
Пример #6
0
 def test_isMatch_withdot_notmatch(self):
     solution = Solution()
     self.assertFalse(solution.isMatch("aa", "b."))
Пример #7
0
 def test_isMatch_notmatch(self):
     solution = Solution()
     self.assertFalse(solution.isMatch("aa", "a"))