push_image: Make --buildroot adjustable.
Allow buildroot pushed from to be different from the buildroot
containing push_image. Default to using the same buildroot.
BUG=chromium:855291
TEST=run_tests
Change-Id: Ia5db9a34a58c313611cc1e93e2d65cfdfe6e306a
Reviewed-on: https://chromium-review.googlesource.com/1179261
Commit-Ready: Mike Frysinger <vapier@chromium.org>
Tested-by: Don Garrett <dgarrett@chromium.org>
Reviewed-by: Don Garrett <dgarrett@chromium.org>
diff --git a/scripts/pushimage_unittest.py b/scripts/pushimage_unittest.py
index cf8a618..4fdcf7e 100644
--- a/scripts/pushimage_unittest.py
+++ b/scripts/pushimage_unittest.py
@@ -399,9 +399,10 @@
def main(_argv):
- # Use our local copy of insns for testing as the main one is not
- # available in the public manifest.
- signing.INPUT_INSN_DIR = signing.TEST_INPUT_INSN_DIR
+ # Use our local copy of insns for testing as the main one is not available in
+ # the public manifest. Even though _REL is a relative path, this works because
+ # os.join leaves absolute paths on the right hand side alone.
+ signing.INPUT_INSN_DIR_REL = signing.TEST_INPUT_INSN_DIR
# Run the tests.
cros_test_lib.main(level='notice', module=__name__)