Add test for hiddenAPI index file generation
The index file and the metadata file both currently include duplicate entries due to them including both the <x> and <x>.impl libraries created by java_sdk_library in their inputs, plus including both source and prebuilt versions of the same named module. This change adds a test to illustrate that behavior. A follow up change will correct the problem and update the test accordingly. This change only adds a test for the index file because the metadata file depends on files from frameworks/base which makes it difficult to test. Bug 177317659 will fix that and allow the metadata file generation to be tested too. Bug: 178361284 Test: m nothing Change-Id: I33921d7267c9f4bb42726343d73f8a396d536aaa
This commit is contained in:
@@ -22,9 +22,13 @@ import (
|
||||
)
|
||||
|
||||
func init() {
|
||||
android.RegisterSingletonType("hiddenapi", hiddenAPISingletonFactory)
|
||||
android.RegisterSingletonType("hiddenapi_index", hiddenAPIIndexSingletonFactory)
|
||||
android.RegisterModuleType("hiddenapi_flags", hiddenAPIFlagsFactory)
|
||||
RegisterHiddenApiSingletonComponents(android.InitRegistrationContext)
|
||||
}
|
||||
|
||||
func RegisterHiddenApiSingletonComponents(ctx android.RegistrationContext) {
|
||||
ctx.RegisterSingletonType("hiddenapi", hiddenAPISingletonFactory)
|
||||
ctx.RegisterSingletonType("hiddenapi_index", hiddenAPIIndexSingletonFactory)
|
||||
ctx.RegisterModuleType("hiddenapi_flags", hiddenAPIFlagsFactory)
|
||||
}
|
||||
|
||||
type hiddenAPISingletonPathsStruct struct {
|
||||
|
Reference in New Issue
Block a user