Skip to content

Commit 1f46279

Browse files
committed
STY: Use raw strings to escape regex markers
1 parent 72c0521 commit 1f46279

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

haas/plugins/runner.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ def run(self, result_collector, test):
5353
warnings.filterwarnings(
5454
'module',
5555
category=DeprecationWarning,
56-
message='Please use assert\w+ instead.')
56+
message=r'Please use assert\w+ instead.')
5757
result_collector.startTestRun()
5858
try:
5959
test(result_collector)

haas/tests/test_runner.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -102,4 +102,4 @@ def test_init_from_args(self):
102102
runner = BaseTestRunner.from_args(args, None)
103103

104104
# Then
105-
self.assertEqual(runner.warnings, "ignore")
105+
self.assertEqual(runner.warnings, "ignore")

haas/utils.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ def get_module_by_name(name):
5959

6060

6161
def uncamelcase(string, sep='_'):
62-
replace = '\g<before>{0}\g<caps>'.format(sep)
62+
replace = r'\g<before>{0}\g<caps>'.format(sep)
6363
temp = UNCAMELCASE_FIRST_PASS.sub(replace, string)
6464
return UNCAMELCASE_SECOND_PASS.sub(replace, temp).lower()
6565

0 commit comments

Comments
 (0)