Update config to use self-contained python binaries
Build from source and remove need for virtualenv to
make it self-contained.
Test: presubmit, forrest (https://android-build.googleplex.com/builds/abtd/run/L76600000954930260)
Bug: 234458076
Ignore-AOSP-First: nearby_not_in_aosp_yet
Change-Id: Ib0afb414fdeb510577345afd650fa6f0f5b3c721
diff --git a/nearby/tests/multidevices/host/Android.bp b/nearby/tests/multidevices/host/Android.bp
index ff795e8..fb03073 100644
--- a/nearby/tests/multidevices/host/Android.bp
+++ b/nearby/tests/multidevices/host/Android.bp
@@ -22,7 +22,10 @@
name: "CtsNearbyMultiDevicesTestSuite",
main: "suite_main.py",
srcs: ["*.py"],
- libs: ["NearbyMultiDevicesHostHelper"],
+ libs: [
+ "NearbyMultiDevicesHostHelper",
+ "mobly",
+ ],
test_suites: [
"cts",
"general-tests",
@@ -38,6 +41,15 @@
// Package the JSON metadata with the Mobly test.
"test_data/**/*",
],
+ version: {
+ py2: {
+ enabled: false,
+ },
+ py3: {
+ enabled: true,
+ embedded_launcher: true,
+ },
+ },
}
python_library_host {
diff --git a/nearby/tests/multidevices/host/AndroidTest.xml b/nearby/tests/multidevices/host/AndroidTest.xml
index 43cf136..8fd28a8 100644
--- a/nearby/tests/multidevices/host/AndroidTest.xml
+++ b/nearby/tests/multidevices/host/AndroidTest.xml
@@ -32,11 +32,6 @@
<option name="run-command" value="input keyevent KEYCODE_WAKEUP" />
<option name="run-command" value="wm dismiss-keyguard" />
</target_preparer>
- <target_preparer class="com.android.tradefed.targetprep.PythonVirtualenvPreparer">
- <!-- Any python dependencies can be specified and will be installed with pip -->
- <!-- TODO(b/225958696): Import python dependencies -->
- <option name="dep-module" value="mobly" />
- </target_preparer>
<target_preparer class="com.android.tradefed.targetprep.DeviceSetup">
<option name="force-skip-system-props" value="true" /> <!-- avoid restarting device -->
<option name="screen-always-on" value="on" />