summaryrefslogtreecommitdiff
path: root/tools/releasetools/test_apex_utils.py
diff options
context:
space:
mode:
author Tao Bao <tbao@google.com> 2019-04-09 00:12:30 -0700
committer Tao Bao <tbao@google.com> 2019-04-12 15:26:32 -0700
commit30e31142ce669666b4850fc843878f798ffbef90 (patch)
tree477ef7b2682274956399f7e0b8533c35ebd630f3 /tools/releasetools/test_apex_utils.py
parentfc6948b588033d41df92757ee54ee53eddd06ac7 (diff)
relesetools: Support running all the unittests with atest.
All the unittests will be built into releasetools_test. One can run the tests with `atest releasetools_test` or the traditional way `test_utils.py`. The atest way is recommended, which additionally builds the required tools. With the current support in Soong, we can't pack the built tools into releasetools_test yet. So running `releasetools_test` alone in clound would fail. Follow-up CLs will address the issue in order to deploy the tests with TEST_MAPPING. Bug: 112080715 Test: `atest releasetools_test` Change-Id: Ica95517a5ab326f4e58fc57c6c2c276cfe882f3c
Diffstat (limited to 'tools/releasetools/test_apex_utils.py')
-rw-r--r--tools/releasetools/test_apex_utils.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/tools/releasetools/test_apex_utils.py b/tools/releasetools/test_apex_utils.py
index 2f8ee49823..76d4d58df2 100644
--- a/tools/releasetools/test_apex_utils.py
+++ b/tools/releasetools/test_apex_utils.py
@@ -56,8 +56,10 @@ class ApexUtilsTest(test_utils.ReleaseToolsTestCase):
def test_SignApexPayload_withSignerHelper(self):
payload_file = self._GetTestPayload()
+ signing_helper = os.path.join(self.testdata_dir, 'signing_helper.sh')
+ os.chmod(signing_helper, 0o700)
payload_signer_args = '--signing_helper_with_files {}'.format(
- os.path.join(self.testdata_dir, 'signing_helper.sh'))
+ signing_helper)
apex_utils.SignApexPayload(
payload_file,
self.payload_key,