Add scripts to mount/unmount the Runtime APEX under ART's chroot dir.
These scripts (`tools/mount-buildbot-apexes.sh` and
`tools/unmount-buildbot-apexes.sh`) emulate the role of `apexd` under
the chroot directory for chroot-based on-device testing.
They currently only handle the Runtime APEX (com.android.runtime), but
we plan to use them to also activate/deactivate other packages
(required by ART's standalone test setup) in the future.
Also:
- Provide an `/apex' tmpfs under the choot directory as part of the
device set-up.
- Build and push `unzip` during (chroot-based) on-device testing, as
it is needed to extract payload (ext4 images) from APEX(ex).
Test: Manual local testing.
Bug: 121117762
Bug: 113373927
Bug: 34729697
Change-Id: Id1a7b3378ea5822c511d6cc74f784fa38ddd4968
diff --git a/tools/teardown-buildbot-device.sh b/tools/teardown-buildbot-device.sh
index 6634fb4..7eb5cc3 100755
--- a/tools/teardown-buildbot-device.sh
+++ b/tools/teardown-buildbot-device.sh
@@ -89,6 +89,9 @@
fi
}
+ # Remove /apex from chroot.
+ remove_filesystem_from_chroot apex tmpfs true
+
# Remove /dev from chroot.
remove_filesystem_from_chroot dev tmpfs true