From 64345ff14fe701153f6e2b243574518d85367c79 Mon Sep 17 00:00:00 2001 From: Raphael Kubo da Costa Date: Wed, 21 Sep 2016 17:10:16 +0200 Subject: [PATCH] instrumentation tests: Stop passing a generator to posixpath.join() > Commit d4d66d4d ("Reland #2: Move side-loaded test data /sdcard -> > /sdcard/gtestdata") introduced a regression in > LocalDeviceInstrumentationTestRun.substitute_device_root() when it's > passed a list: the posixpath.join() call ends up receiving a generator > instead of multiple arguments. > > This means the call will return a generator instead of 'foo/bar/baz', > which is not what's intended. > > R=jbudorick@chromium.org > Review-Url: https://codereview.chromium.org/2360693002 --- .../pylib/local/device/local_device_instrumentation_test_run.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) 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 d5426bc3e66d5..87f0a04471960 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 @@ -63,7 +63,7 @@ def substitute_device_root(d, device_root): if not d: return device_root elif isinstance(d, list): - return posixpath.join(p if p else device_root for p in d) + return posixpath.join(*(p if p else device_root for p in d)) else: return d