Skip to content

Commit

Permalink
waftools/unittest.py: fix regex syntax
Browse files Browse the repository at this point in the history
Invalid regex escape is detected by python-3.12 warning as:

     waftools/unittest.py:27: SyntaxWarning: invalid escape sequence '\s'
  • Loading branch information
trofi committed Sep 21, 2024
1 parent fcbd6e4 commit 8dd1e85
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion waftools/unittest.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ def run(self):
code = code.replace("@@REGISTER_TEST_SUITES@@", register)
self.outputs[0].write(code)

scraper = re.compile("^(CASE|SETUP)\s*\(([^)]+)\)")
scraper = re.compile(r'^(CASE|SETUP)\s*\(([^)]+)\)')

def scrape_test_cases(node):
suite = ""
Expand Down

0 comments on commit 8dd1e85

Please sign in to comment.