Navigation Menu

Skip to content

Commit

Permalink
escape '/' inside of method re
Browse files Browse the repository at this point in the history
  • Loading branch information
modosc committed Nov 7, 2013
1 parent d444678 commit a375d08
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion run_ruby_test.py
Expand Up @@ -88,7 +88,7 @@ def find_first_match(test_file_content):
if match_obj:
return match_obj.group(1)[::-1]

match_obj = re.search('\s?[\"\']([a-zA-Z_\"\'\s\d\-\.#=?!:/]+)[\"\']\s+tset', test_file_content) # 2nd search for 'test "name"'
match_obj = re.search('\s?[\"\']([a-zA-Z_\"\'\s\d\-\.#=?!:\/]+)[\"\']\s+tset', test_file_content) # 2nd search for 'test "name"'
if match_obj:
test_name = match_obj.group(1)[::-1]
return "test_%s" % test_name.replace("\"", "\\\"").replace(" ", "_").replace("'", "\\'")
Expand Down

0 comments on commit a375d08

Please sign in to comment.