From 168858f52d72eccad6873dfc6066bffd4b058398 Mon Sep 17 00:00:00 2001 From: Gilles Peskine Date: Fri, 20 Sep 2019 17:54:45 +0200 Subject: [PATCH] Fix regex matching run_test calls in ssl-opt.sh No descriptions were processed before due to bugs in the regex. Support \" inside double-quoted strings. --- tests/scripts/check-test-cases.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/scripts/check-test-cases.py b/tests/scripts/check-test-cases.py index 688ad25c9..9e67a4207 100755 --- a/tests/scripts/check-test-cases.py +++ b/tests/scripts/check-test-cases.py @@ -92,7 +92,7 @@ def check_ssl_opt_sh(results, file_name): # Assume that all run_test calls have the same simple form # with the test description entirely on the same line as the # function name. - m = re.match(r'\s+run_test\s+"([^"])"', line) + m = re.match(r'\s*run_test\s+"((?:[^\\"]|\\.)*)"', line) if not m: continue description = m.group(1)