diff options
author | 2023-01-25 17:49:46 +0000 | |
---|---|---|
committer | 2023-01-27 04:02:45 +0000 | |
commit | 29743c842306136a7658cbcb04c5c0ceafe759dc (patch) | |
tree | f094c06efee327da7bb31cd4083864c16f1424db /apex/apex_test.go | |
parent | 6cf5e0d9cb89b909b5087d4057e6f09e4d093f85 (diff) |
Read ApexMkInfo for modules to be installed.
This piggybacks onto the ApexInfo cquery handler, so we're issuing a
single bazel query call that reads two providers in the starlark expr.
Also rename requiredDeps to makeModulesToInstall to differentiate it from
APEX's required/provided libs in the apex manifest.
Test: unit test
Test: mkdiff
Fixes: 263123189
Change-Id: Ib7e43f1586f29864eee8627dba3631bfaff27afa
Diffstat (limited to 'apex/apex_test.go')
-rw-r--r-- | apex/apex_test.go | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/apex/apex_test.go b/apex/apex_test.go index 28097aa98..2eab318b1 100644 --- a/apex/apex_test.go +++ b/apex/apex_test.go @@ -5713,7 +5713,7 @@ func TestInstallExtraFlattenedApexes(t *testing.T) { }), ) ab := ctx.ModuleForTests("myapex", "android_common_myapex_image").Module().(*apexBundle) - ensureListContains(t, ab.requiredDeps, "myapex.flattened") + ensureListContains(t, ab.makeModulesToInstall, "myapex.flattened") mk := android.AndroidMkDataForTest(t, ctx, ab) var builder strings.Builder mk.Custom(&builder, ab.Name(), "TARGET_", "", mk) @@ -9290,7 +9290,7 @@ func TestAndroidMk_RequiredDeps(t *testing.T) { `) bundle := ctx.ModuleForTests("myapex", "android_common_myapex_image").Module().(*apexBundle) - bundle.requiredDeps = append(bundle.requiredDeps, "foo") + bundle.makeModulesToInstall = append(bundle.makeModulesToInstall, "foo") data := android.AndroidMkDataForTest(t, ctx, bundle) var builder strings.Builder data.Custom(&builder, bundle.BaseModuleName(), "TARGET_", "", data) @@ -9298,7 +9298,7 @@ func TestAndroidMk_RequiredDeps(t *testing.T) { ensureContains(t, androidMk, "LOCAL_REQUIRED_MODULES := foo\n") flattenedBundle := ctx.ModuleForTests("myapex", "android_common_myapex_flattened").Module().(*apexBundle) - flattenedBundle.requiredDeps = append(flattenedBundle.requiredDeps, "foo") + flattenedBundle.makeModulesToInstall = append(flattenedBundle.makeModulesToInstall, "foo") flattenedData := android.AndroidMkDataForTest(t, ctx, flattenedBundle) var flattenedBuilder strings.Builder flattenedData.Custom(&flattenedBuilder, flattenedBundle.BaseModuleName(), "TARGET_", "", flattenedData) @@ -9542,7 +9542,7 @@ func TestSdkLibraryCanHaveHigherMinSdkVersion(t *testing.T) { func ensureContainsRequiredDeps(t *testing.T, ctx *android.TestContext, moduleName, variant string, deps []string) { a := ctx.ModuleForTests(moduleName, variant).Module().(*apexBundle) for _, dep := range deps { - android.AssertStringListContains(t, "", a.requiredDeps, dep) + android.AssertStringListContains(t, "", a.makeModulesToInstall, dep) } } @@ -9550,7 +9550,7 @@ func ensureContainsRequiredDeps(t *testing.T, ctx *android.TestContext, moduleNa func ensureDoesNotContainRequiredDeps(t *testing.T, ctx *android.TestContext, moduleName, variant string, deps []string) { a := ctx.ModuleForTests(moduleName, variant).Module().(*apexBundle) for _, dep := range deps { - android.AssertStringListDoesNotContain(t, "", a.requiredDeps, dep) + android.AssertStringListDoesNotContain(t, "", a.makeModulesToInstall, dep) } } |