droidstubs depend on the combined last api filegroup modules

This change creates a "combined" filegroup module, which will contain
all api files of the subset api scopes in the followup change. In this
change, the "combined" filegroup is identical to the currently existing
last api filegroup module in that it only contains the api file /
removed api file of the specific api scope.

This change also passes the "combined" filegroup to the droidstubs
module generated from the sdk_library modules, but this currently does
not lead to any functional changes as the "combined" filegroup is
identical to the currently existing last api filegroup.

Test: m nothing --no-skip-soong-tests
Bug: 321827591
Change-Id: If73a7229f2f970f7e74cd010a8b4808dc9018344
This commit is contained in:
Jihoon Kang
2024-03-20 21:29:39 +00:00
parent 8426848ade
commit 748a24dd6e
3 changed files with 53 additions and 14 deletions

View File

@@ -139,10 +139,10 @@ func TestJavaSdkLibrary(t *testing.T) {
exportedComponentsInfo, _ := android.SingletonModuleProvider(result, foo.Module(), android.ExportedComponentsInfoProvider)
expectedFooExportedComponents := []string{
"foo-removed.api.public.latest",
"foo-removed.api.system.latest",
"foo.api.public.latest",
"foo.api.system.latest",
"foo-removed.api.combined.public.latest",
"foo-removed.api.combined.system.latest",
"foo.api.combined.public.latest",
"foo.api.combined.system.latest",
"foo.stubs",
"foo.stubs.exportable",
"foo.stubs.exportable.system",
@@ -556,8 +556,8 @@ func TestJavaSdkLibrary_Deps(t *testing.T) {
CheckModuleDependencies(t, result.TestContext, "sdklib", "android_common", []string{
`dex2oatd`,
`sdklib-removed.api.public.latest`,
`sdklib.api.public.latest`,
`sdklib-removed.api.combined.public.latest`,
`sdklib.api.combined.public.latest`,
`sdklib.impl`,
`sdklib.stubs`,
`sdklib.stubs.exportable`,
@@ -960,8 +960,8 @@ func TestJavaSdkLibraryImport_WithSource(t *testing.T) {
CheckModuleDependencies(t, result.TestContext, "sdklib", "android_common", []string{
`dex2oatd`,
`prebuilt_sdklib`,
`sdklib-removed.api.public.latest`,
`sdklib.api.public.latest`,
`sdklib-removed.api.combined.public.latest`,
`sdklib.api.combined.public.latest`,
`sdklib.impl`,
`sdklib.stubs`,
`sdklib.stubs.exportable`,
@@ -1039,8 +1039,8 @@ func testJavaSdkLibraryImport_Preferred(t *testing.T, prefer string, preparer an
CheckModuleDependencies(t, result.TestContext, "sdklib", "android_common", []string{
`prebuilt_sdklib`,
`sdklib-removed.api.public.latest`,
`sdklib.api.public.latest`,
`sdklib-removed.api.combined.public.latest`,
`sdklib.api.combined.public.latest`,
`sdklib.impl`,
`sdklib.stubs`,
`sdklib.stubs.exportable`,