summaryrefslogtreecommitdiff
path: root/test/default_run.py
diff options
context:
space:
mode:
author David Srbecky <dsrbecky@google.com> 2024-11-14 08:48:30 +0000
committer David Srbecky <dsrbecky@google.com> 2024-11-15 20:25:26 +0000
commit9fbfe26b27a7ff9068018e3c4808a545f577212c (patch)
tree93e1ab737145f4f88165d96f84c1c5694a503501 /test/default_run.py
parentb881f3015e1cae94232d4925b2f4c855ea32a404 (diff)
run-test: Create boot-image-compilation script
Add script which compiles the boot image to the run-test zip file. Also add json file with all the test rules. Each rule can adb-push data from the zip file, and adb-shell execute any pushed bash script. The boot-image compilation is just another rule, and the other rules have a dependency on it. Therefore it will execute first and only once. Test: Install ART test APEX on device and manually perform the commands Change-Id: I70bad11b11f81a427bf16eecd773dc10c34ff664
Diffstat (limited to 'test/default_run.py')
-rwxr-xr-xtest/default_run.py21
1 files changed, 2 insertions, 19 deletions
diff --git a/test/default_run.py b/test/default_run.py
index c5e9d376ae..9d7179e68a 100755
--- a/test/default_run.py
+++ b/test/default_run.py
@@ -15,6 +15,7 @@
import sys, os, shutil, shlex, re, subprocess, glob
from argparse import ArgumentParser, BooleanOptionalAction, Namespace
+from globals import BOOTCLASSPATH
from os import path
from os.path import isfile, isdir, basename
from subprocess import check_output, DEVNULL, PIPE, STDOUT
@@ -144,29 +145,11 @@ def get_target_arch(is64: bool) -> str:
assert len(arches) == 1, f"Can not find (unique) 32-bit arch in {arches}"
return arches[0]
-# Note: This must start with the CORE_IMG_JARS in Android.common_path.mk
-# because that's what we use for compiling the boot.art image.
-# It may contain additional modules from TEST_CORE_JARS.
-bpath_modules = ("core-oj core-libart okhttp bouncycastle apache-xml core-icu4j"
- " conscrypt")
-
# Helper function to construct paths for apex modules (for both -Xbootclasspath and
# -Xbootclasspath-location).
def get_apex_bootclasspath_impl(bpath_prefix: str):
- bpath_separator = ""
- bpath = ""
- bpath_jar = ""
- for bpath_module in bpath_modules.split(" "):
- apex_module = "com.android.art"
- if bpath_module == "conscrypt":
- apex_module = "com.android.conscrypt"
- if bpath_module == "core-icu4j":
- apex_module = "com.android.i18n"
- bpath_jar = f"/apex/{apex_module}/javalib/{bpath_module}.jar"
- bpath += f"{bpath_separator}{bpath_prefix}{bpath_jar}"
- bpath_separator = ":"
- return bpath
+ return ":".join(bpath_prefix + bpath for bpath in BOOTCLASSPATH)
# Gets a -Xbootclasspath paths with the apex modules.