Index: build/android/pylib/local/device/local_device_instrumentation_test_run.py |
diff --git a/build/android/pylib/local/device/local_device_instrumentation_test_run.py b/build/android/pylib/local/device/local_device_instrumentation_test_run.py |
index 8f2b2e74327a4f78cfde413a380d7b09f873c449..12f3a8255dae98984c80e002aba1e04cf6c65856 100644 |
--- a/build/android/pylib/local/device/local_device_instrumentation_test_run.py |
+++ b/build/android/pylib/local/device/local_device_instrumentation_test_run.py |
@@ -318,7 +318,6 @@ class LocalDeviceInstrumentationTestRun( |
extras = {} |
flags_to_add = [] |
- flags_to_remove = [] |
test_timeout_scale = None |
if self._test_instance.coverage_directory: |
coverage_basename = '%s.ec' % ('%s_group' % test[0]['method'] |
@@ -374,9 +373,8 @@ class LocalDeviceInstrumentationTestRun( |
target = '%s/%s' % ( |
self._test_instance.test_package, self._test_instance.test_runner) |
extras['class'] = test_name |
- if 'flags' in test: |
- flags_to_add.extend(test['flags'].add) |
- flags_to_remove.extend(test['flags'].remove) |
+ if 'flags' in test and test['flags']: |
+ flags_to_add.extend(test['flags']) |
timeout = self._GetTimeoutFromAnnotations( |
test['annotations'], test_display_name) |
@@ -397,10 +395,9 @@ class LocalDeviceInstrumentationTestRun( |
flags_to_add.append('--render-test-output-dir=%s' % |
render_tests_device_output_dir) |
- if flags_to_add or flags_to_remove: |
+ if flags_to_add: |
self._CreateFlagChangerIfNeeded(device) |
- self._flag_changers[str(device)].PushFlags( |
- add=flags_to_add, remove=flags_to_remove) |
+ self._flag_changers[str(device)].PushFlags(add=flags_to_add) |
time_ms = lambda: int(time.time() * 1e3) |
start_ms = time_ms() |
@@ -423,7 +420,7 @@ class LocalDeviceInstrumentationTestRun( |
logcat_url = logmon.GetLogcatURL() |
duration_ms = time_ms() - start_ms |
- if flags_to_add or flags_to_remove: |
+ if flags_to_add: |
self._flag_changers[str(device)].Restore() |
if test_timeout_scale: |
valgrind_tools.SetChromeTimeoutScale( |
@@ -451,7 +448,7 @@ class LocalDeviceInstrumentationTestRun( |
recursive=True, force=True) |
# Update the result name if the test used flags. |
- if flags_to_add or flags_to_remove: |
+ if flags_to_add: |
for r in results: |
if r.GetName() == test_name: |
r.SetName(test_display_name) |