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

Unified Diff: build/android/pylib/instrumentation/instrumentation_test_instance.py

Issue 2805533003: [build/android] Load/dump pickles directly form/to files (Closed)
Patch Set: Created 3 years, 8 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 | build/android/pylib/local/device/local_device_perf_test_run.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: build/android/pylib/instrumentation/instrumentation_test_instance.py
diff --git a/build/android/pylib/instrumentation/instrumentation_test_instance.py b/build/android/pylib/instrumentation/instrumentation_test_instance.py
index 5261ff284b3c76c78404200be2a3bfff35074f25..d01e36eeeee8a84eba18096a487f0a75eb4ac678 100644
--- a/build/android/pylib/instrumentation/instrumentation_test_instance.py
+++ b/build/android/pylib/instrumentation/instrumentation_test_instance.py
@@ -321,8 +321,8 @@ def _GetTestsFromPickle(pickle_path, jar_path):
raise TestListPickleException(
'%s newer than %s.' % (jar_path, pickle_path))
- with open(pickle_path, 'r') as pickle_file:
- pickle_data = pickle.loads(pickle_file.read())
+ with open(pickle_path, 'r') as f:
+ pickle_data = pickle.load(f)
jar_md5 = md5sum.CalculateHostMd5Sums(jar_path)[jar_path]
if pickle_data['VERSION'] != _PICKLE_FORMAT_VERSION:
« no previous file with comments | « no previous file | build/android/pylib/local/device/local_device_perf_test_run.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698