diff options
| author | 2022-03-23 13:24:15 +0000 | |
|---|---|---|
| committer | 2022-03-23 23:02:30 +0000 | |
| commit | 9292b88f07dff23b6dcafff07bfdeb2e67809149 (patch) | |
| tree | fb15f385f11178e5359dcb1f94b79090b034d2b7 /test/run-test-build.py | |
| parent | a7e47813083bf04ae9d365e09eec59e8857ff551 (diff) | |
Add buildfailures.json
Explicitly enumerate run-tests configurations that don't build.
(because they depend on Android APIs while building for the RI)
This removes run-test build dependency on knownfailures.json.
Bug: 213297521
Test: m art-run-test-{host,target,jvm}-data
Test: test.py -b -r --host --jvm
Change-Id: Ie6886df17fedd7d31394c511187936fa36ed9a97
Diffstat (limited to 'test/run-test-build.py')
| -rwxr-xr-x | test/run-test-build.py | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/test/run-test-build.py b/test/run-test-build.py index aaee89c169..03ac18f391 100755 --- a/test/run-test-build.py +++ b/test/run-test-build.py @@ -22,7 +22,7 @@ It is intended to be used only from soong genrule. import argparse, os, tempfile, shutil, subprocess, glob, textwrap, re, json, concurrent.futures ZIP = "prebuilts/build-tools/linux-x86/bin/soong_zip" -KNOWNFAILURES = json.loads(open(os.path.join("art", "test", "knownfailures.json"), "rt").read()) +BUILDFAILURES = json.loads(open(os.path.join("art", "test", "buildfailures.json"), "rt").read()) def copy_sources(args, tmp, mode, srcdir): """Copy test files from Android tree into the build sandbox and return its path.""" @@ -32,9 +32,9 @@ def copy_sources(args, tmp, mode, srcdir): dstdir = join(tmp, mode, test) # Don't build tests that are disabled since they might not compile (e.g. on jvm). - def is_knownfailure(kf): + def is_buildfailure(kf): return test in kf.get("tests", []) and mode == kf.get("variant") and not kf.get("env_vars") - if any(is_knownfailure(kf) for kf in KNOWNFAILURES): + if any(is_buildfailure(kf) for kf in BUILDFAILURES): return None # Copy all source files to the temporary directory. @@ -99,7 +99,7 @@ def main(): for stdout, exitcode in pool.map(lambda dstdir: build_test(args, args.mode, dstdir), dstdirs): if stdout: print(stdout.strip()) - assert(exitcode == 0) # Build failed. + assert(exitcode == 0) # Build failed. Add test to buildfailures.json if this is expected. # Create the final zip file which contains the content of the temporary directory. proc = subprocess.run([ZIP, "-o", args.out, "-C", tmp, "-D", tmp], check=True) |