Add Singleton class to collect and validate test spec metadata.

Bug: 296873595
Test: Manual testing (Will add unit test case in the next change.)
Change-Id: Ic4177c5f76602088d52a31ca8d9fbaa703855837
This commit is contained in:
Aditya Choudhary
2023-11-09 20:07:52 +00:00
parent b91108c9c0
commit 2368e9ea9e
3 changed files with 52 additions and 0 deletions

View File

@@ -18,10 +18,16 @@ import (
"android/soong/android"
)
var (
pctx = android.NewPackageContext("android/soong/testing")
)
func init() {
RegisterBuildComponents(android.InitRegistrationContext)
pctx.HostBinToolVariable("metadata", "metadata")
}
func RegisterBuildComponents(ctx android.RegistrationContext) {
ctx.RegisterModuleType("test_spec", TestSpecFactory)
ctx.RegisterParallelSingletonType("all_test_specs", AllTestSpecsFactory)
}