Beispiel #1
0
 def test_no_match(self):
     """Test REGEX_DISTANT_SEMICOLIN with no spaces"""
     s = "CREATE DATABSE foobar;"
     matches = REGEX_DISTANT_SEMICOLIN.search(s)
     self.assertFalse(matches)
Beispiel #2
0
 def test_tabs(self):
     """Test REGEX_DISTANT_SEMICOLIN with tabs"""
     s = "CREATE DATABSE foobar      ;"
     matches = REGEX_DISTANT_SEMICOLIN.search(s)
     self.assertTrue(matches)
Beispiel #3
0
 def test_newline(self):
     """Test REGEX_DISTANT_SEMICOLIN with newline"""
     s = """CREATE DATABSE foobar
     ;"""
     matches = REGEX_DISTANT_SEMICOLIN.search(s)
     self.assertTrue(matches)
Beispiel #4
0
 def test_multiple_spaces(self):
     """Test REGEX_DISTANT_SEMICOLIN with multiple spaces"""
     s = "CREATE DATABSE foobar    ;"
     matches = REGEX_DISTANT_SEMICOLIN.search(s)
     self.assertTrue(matches)