Explicitly set target_sdk_version of vmshareapp
GTS tests are built from the latest desert release and are executed on
the previous desert releases. Because of that, we need to manually set
target_sdk_version of the test apps to a finalized sdk. Otherwise when
built from the branch with non-finalized SDK (e.g. Baklava), the
resulting test apk won't install on the previous SDKs.
Note: this only fixes the following error:
"Requires development platform Baklava but this is a release platform".
The tests still fail on the previous releases because they reference
APIs that were introduced in Baklava. This failure will be addressed in
the follow-up patch.
Bug: 388702766
Test: atest MicrodroidTests.GTS
Change-Id: Ib53c53d1ba597b221f706382d002fa5a3d2237bd
diff --git a/tests/vmshareapp/Android.bp b/tests/vmshareapp/Android.bp
index 5f6dc57..86c48f6 100644
--- a/tests/vmshareapp/Android.bp
+++ b/tests/vmshareapp/Android.bp
@@ -13,4 +13,8 @@
"MicrodroidPayloadInOtherAppNativeLib",
],
min_sdk_version: "34",
+ sdk_version: "system_current",
+ // Ideally we should set something "latest finalized sdk version" here.
+ // However, soong doesn't seem to provide such functionality.
+ target_sdk_version: "VanillaIceCream",
}