summaryrefslogtreecommitdiffstats
path: root/tests/Android.bp
diff options
context:
space:
mode:
Diffstat (limited to 'tests/Android.bp')
-rw-r--r--tests/Android.bp20
1 files changed, 19 insertions, 1 deletions
diff --git a/tests/Android.bp b/tests/Android.bp
index 640bb042e..a9a088a32 100644
--- a/tests/Android.bp
+++ b/tests/Android.bp
@@ -90,12 +90,29 @@ librecovery_static_libs = [
"libfs_mgr",
"libhidl-gen-utils",
"libhidlbase",
- "libbinderthreadstate",
"liblp",
"libtinyxml2",
"libc++fs",
]
+// recovery image for unittests.
+// ========================================================
+genrule {
+ name: "recovery_image",
+ cmd: "cat $(location testdata/recovery_head) <(cat $(location testdata/recovery_body) | $(location minigzip)) $(location testdata/recovery_tail) > $(out)",
+ srcs: [
+ "testdata/recovery_head",
+ "testdata/recovery_body",
+ "testdata/recovery_tail",
+ ],
+ tools: [
+ "minigzip",
+ ],
+ out: [
+ "testdata/recovery.img",
+ ],
+}
+
cc_test {
name: "recovery_unit_test",
isolated: true,
@@ -129,6 +146,7 @@ cc_test {
data: [
"testdata/*",
+ ":recovery_image",
":res-testdata",
],
}