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

Unified Diff: build/android/pylib/gtest/gtest_test_instance.py

Issue 2582263003: [Android] Fix empty gtest test name parsing. (Closed)
Patch Set: Created 4 years 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 | build/android/pylib/gtest/gtest_test_instance_test.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: build/android/pylib/gtest/gtest_test_instance.py
diff --git a/build/android/pylib/gtest/gtest_test_instance.py b/build/android/pylib/gtest/gtest_test_instance.py
index 3cdf586a48feadeddbcede2b9cda21b1b17197f0..394b9e8999504614554eb68ee3ad2931d61d0c46 100644
--- a/build/android/pylib/gtest/gtest_test_instance.py
+++ b/build/android/pylib/gtest/gtest_test_instance.py
@@ -99,13 +99,15 @@ def ParseGTestListTests(raw_list):
for test in raw_list:
if not test:
continue
- if test[0] != ' ':
+ if not test.startswith(' '):
test_case = test.split()[0]
if test_case.endswith('.'):
current = test_case
- elif not 'YOU HAVE' in test:
- test_name = test.split()[0]
- ret += [current + test_name]
+ else:
+ test = test.strip()
+ if test and not 'YOU HAVE' in test:
+ test_name = test.split()[0]
+ ret += [current + test_name]
return ret
« no previous file with comments | « no previous file | build/android/pylib/gtest/gtest_test_instance_test.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698