Ejemplo n.º 1
0
 def test_start(self):
     #basicConfig(level=DEBUG)
     match = DfaRegexp('(*SOL)a*')
     match.config.default_line_aware().no_full_first_match()
     result = list(match.match_string('abc'))[0][0]
     assert result == ['a'], result
Ejemplo n.º 2
0
 def test_start(self):
     #basicConfig(level=DEBUG)
     match = DfaRegexp('(*SOL)a*')
     match.config.default_line_aware().no_full_first_match()
     result = list(match.match_string('abc'))[0][0]
     assert result == ['a'], result
Ejemplo n.º 3
0
 def test_invert_bug_1(self):
     #basicConfig(level=DEBUG)
     match = DfaRegexp('(*SOL)[^c]*')
     match.config.default_line_aware().trace(True).no_full_first_match()
     result = list(match.match_string('abc'))[0][0]
     assert result == ['ab'], result
Ejemplo n.º 4
0
 def test_invert_bug_1(self):
     #basicConfig(level=DEBUG)
     match = DfaRegexp('(*SOL)[^c]*')
     match.config.default_line_aware().trace(True).no_full_first_match()
     result = list(match.match_string('abc'))[0][0]
     assert result == ['ab'], result