Make prebuilt_apex report an error if no apex file is found
Previously, if an appropriate src property was not specified it would
return "" which resolves to the top level directory. This change causes
it to report an error.
Bug: 181267622
Test: m droid
Change-Id: Ia5be324a0eff18e43b352d71c6768c8767986053
diff --git a/apex/apex_test.go b/apex/apex_test.go
index 87d551b..bdff41e 100644
--- a/apex/apex_test.go
+++ b/apex/apex_test.go
@@ -4316,6 +4316,14 @@
}
}
+func TestPrebuiltMissingSrc(t *testing.T) {
+ testApexError(t, `module "myapex" variant "android_common".*: prebuilt_apex does not support "arm64_armv8-a"`, `
+ prebuilt_apex {
+ name: "myapex",
+ }
+ `)
+}
+
func TestPrebuiltFilenameOverride(t *testing.T) {
ctx := testApex(t, `
prebuilt_apex {