Lineage properties support module references.

They should have had `android:"path"` tags attached so that users can
point them to filegroup modules.

Test: app_test.go & app_import_test.go
Bug: 182175153
Change-Id: I5580408488ffe5fc12c869cbfb7a468713dcbc96
This commit is contained in:
Jaewoong Jung
2021-03-09 15:02:31 -08:00
parent 05ebca4f7f
commit 1c1b6e6d95
6 changed files with 73 additions and 5 deletions

View File

@@ -1576,6 +1576,31 @@ func TestCertificates(t *testing.T) {
expectedLineage: "--lineage lineage.bin",
expectedCertificate: "cert/new_cert.x509.pem cert/new_cert.pk8",
},
{
name: "lineage from filegroup",
bp: `
android_app {
name: "foo",
srcs: ["a.java"],
certificate: ":new_certificate",
lineage: ":lineage_bin",
sdk_version: "current",
}
android_app_certificate {
name: "new_certificate",
certificate: "cert/new_cert",
}
filegroup {
name: "lineage_bin",
srcs: ["lineage.bin"],
}
`,
certificateOverride: "",
expectedLineage: "--lineage lineage.bin",
expectedCertificate: "cert/new_cert.x509.pem cert/new_cert.pk8",
},
}
for _, test := range testCases {