Exemplo n.º 1
0
 def test_subst_pattern_nonmatches(self):
     tests = ["|bad_test",
              "bad_test|"]
     for test in tests:
         assert_true(subst_pattern.search(test) is None,
                         "substitution pattern matches %s" % test)
Exemplo n.º 2
0
 def test_subst_pattern_matches(self):
     assert_equal(subst_pattern.search("|test_replacement|").groups()[0],"test_replacement")