Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(102)

Unified Diff: third_party/WebKit/LayoutTests/bluetooth/generate.py

Issue 2652163002: bluetooth: Improve GATT disconnected error message. (Closed)
Patch Set: Merge TOT Created 3 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | third_party/WebKit/LayoutTests/bluetooth/script-tests/server/device-disconnects-before.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/LayoutTests/bluetooth/generate.py
diff --git a/third_party/WebKit/LayoutTests/bluetooth/generate.py b/third_party/WebKit/LayoutTests/bluetooth/generate.py
index 127d3e4be1585e82ac872be9b23c330547d9590c..b81d14706a867b01bf72f01e1f082e318317af7c 100644
--- a/third_party/WebKit/LayoutTests/bluetooth/generate.py
+++ b/third_party/WebKit/LayoutTests/bluetooth/generate.py
@@ -95,8 +95,14 @@ def GetGeneratedTests():
template_name = os.path.splitext(os.path.basename(template))[0]
- result = re.search(r'CALLS\(\[(.*?)\]\)', template_file_data, re.MULTILINE
- | re.DOTALL)
+ # Find function names in multiline pattern: CALLS( [ function_name,function_name2[UUID] ])
+ result = re.search(
+ r'CALLS\(' + # CALLS(
+ r'[^\[]*' + # Any characters not [, allowing for new lines.
+ r'\[' + # [
+ r'(.*?)' + # group matching: function_name(), function_name2[UUID]
+ r'\]\)', # adjacent closing characters: ])
+ template_file_data, re.MULTILINE | re.DOTALL)
if result is None:
raise Exception('Template must contain \'CALLS\' tokens')
« no previous file with comments | « no previous file | third_party/WebKit/LayoutTests/bluetooth/script-tests/server/device-disconnects-before.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698