diff options
author | 2020-06-01 21:39:15 +0900 | |
---|---|---|
committer | 2020-06-02 11:54:01 +0900 | |
commit | 77acec63fec7d2f3e08f56954a4fb70f7906b2ed (patch) | |
tree | 899cb91cf51720fad907b0d1b967e3d0f919e105 /apex/apex_test.go | |
parent | 0e666433cd02a12ec9a2ea80c1427a964cde293b (diff) |
dex_import can be added to apex
Bug:157886942
Test: m
Change-Id: Ida6f7bb784efe74cc1fa0e8d370eaee803f08b0f
Diffstat (limited to 'apex/apex_test.go')
-rw-r--r-- | apex/apex_test.go | 16 |
1 files changed, 15 insertions, 1 deletions
diff --git a/apex/apex_test.go b/apex/apex_test.go index 29bd087c6..1142cbcc9 100644 --- a/apex/apex_test.go +++ b/apex/apex_test.go @@ -327,7 +327,10 @@ func TestBasicApex(t *testing.T) { binaries: ["foo",], } }, - java_libs: ["myjar"], + java_libs: [ + "myjar", + "myjar_dex", + ], } apex { @@ -436,6 +439,15 @@ func TestBasicApex(t *testing.T) { ], } + dex_import { + name: "myjar_dex", + jars: ["prebuilt.jar"], + apex_available: [ + "//apex_available:platform", + "myapex", + ], + } + java_library { name: "myotherjar", srcs: ["foo/bar/MyClass.java"], @@ -471,6 +483,7 @@ func TestBasicApex(t *testing.T) { // Ensure that apex variant is created for the direct dep ensureListContains(t, ctx.ModuleVariantsForTests("mylib"), "android_arm64_armv8-a_shared_myapex") ensureListContains(t, ctx.ModuleVariantsForTests("myjar"), "android_common_myapex") + ensureListContains(t, ctx.ModuleVariantsForTests("myjar_dex"), "android_common_myapex") // Ensure that apex variant is created for the indirect dep ensureListContains(t, ctx.ModuleVariantsForTests("mylib2"), "android_arm64_armv8-a_shared_myapex") @@ -480,6 +493,7 @@ func TestBasicApex(t *testing.T) { ensureContains(t, copyCmds, "image.apex/lib64/mylib.so") ensureContains(t, copyCmds, "image.apex/lib64/mylib2.so") ensureContains(t, copyCmds, "image.apex/javalib/myjar_stem.jar") + ensureContains(t, copyCmds, "image.apex/javalib/myjar_dex.jar") // .. but not for java libs ensureNotContains(t, copyCmds, "image.apex/javalib/myotherjar.jar") ensureNotContains(t, copyCmds, "image.apex/javalib/msharedjar.jar") |