~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/tests/__init__.py

(parthm) Better regex compile errors (Parth Malwankar)

Show diffs side-by-side

added added

removed removed

Lines of Context:
2744
2744
    :param pattern: A regular expression string.
2745
2745
    :return: A callable that returns True if the re matches.
2746
2746
    """
2747
 
    filter_re = osutils.re_compile_checked(pattern, 0,
2748
 
        'test filter')
 
2747
    filter_re = re.compile(pattern, 0)
2749
2748
    def condition(test):
2750
2749
        test_id = test.id()
2751
2750
        return filter_re.search(test_id)