diff options
author | Joel Galenson <jgalenson@google.com> | 2021-12-15 15:28:00 +0000 |
---|---|---|
committer | Gerrit Code Review <noreply-gerritcodereview@google.com> | 2021-12-15 15:28:00 +0000 |
commit | 26dbc6db75fb2e3b0234099b31c867f8f7afd8f1 (patch) | |
tree | 0f87eed98dc16370f3a434fdaaa5ae95f908d846 | |
parent | a23b3a5669d7d29de4247a4dcd3054da4bf2e81b (diff) | |
parent | 7782ea75788992ca6d4819f51ead68b691483ae4 (diff) | |
download | shared_library-26dbc6db75fb2e3b0234099b31c867f8f7afd8f1.tar.gz |
Merge "Refresh Android.bp, cargo2android.json, TEST_MAPPING."
-rw-r--r-- | Android.bp | 27 | ||||
-rw-r--r-- | TEST_MAPPING | 13 | ||||
-rw-r--r-- | cargo2android.json | 4 | ||||
-rw-r--r-- | patches/Android.bp.patch | 11 |
4 files changed, 21 insertions, 34 deletions
@@ -57,32 +57,23 @@ rust_library { ], } -rust_defaults { - name: "shared_library_test_defaults", +rust_test { + name: "shared_library_test_src_lib", + host_supported: true, crate_name: "shared_library", - srcs: ["src/lib.rs"], cargo_env_compat: true, cargo_pkg_version: "0.1.9", + srcs: ["src/lib.rs"], test_suites: ["general-tests"], auto_gen_config: true, - edition: "2015", - rustlibs: [ - "liblazy_static", - "liblibc", - ], -} - -rust_test_host { - name: "shared_library_host_test_src_lib", - defaults: ["shared_library_test_defaults"], // Manually disabled as these tests depend on specific graphics libraries // being available on the machine running the tests. test_options: { unit_test: false, }, -} - -rust_test { - name: "shared_library_device_test_src_lib", - defaults: ["shared_library_test_defaults"], + edition: "2015", + rustlibs: [ + "liblazy_static", + "liblibc", + ], } diff --git a/TEST_MAPPING b/TEST_MAPPING index cf54784..f439cf8 100644 --- a/TEST_MAPPING +++ b/TEST_MAPPING @@ -1,13 +1,8 @@ // Generated by update_crate_tests.py for tests that depend on this crate. { - "presubmit": [ - // Manually disabled as these tests depend on specific graphics libraries - // being available on the machine running the tests. - //{ - // "name": "shared_library_device_test_src_lib" - //}, - //{ - // "name": "vulkano_device_test_src_lib" - //} + "imports": [ + { + "path": "external/rust/crates/vulkano" + } ] } diff --git a/cargo2android.json b/cargo2android.json index 9a0499e..bbea40c 100644 --- a/cargo2android.json +++ b/cargo2android.json @@ -4,7 +4,7 @@ "com.android.virt" ], "device": true, + "patch": "patches/Android.bp.patch", "run": true, - "tests": true, - "patch": "patches/Android.bp.patch" + "tests": true }
\ No newline at end of file diff --git a/patches/Android.bp.patch b/patches/Android.bp.patch index 7eb1f13..32794df 100644 --- a/patches/Android.bp.patch +++ b/patches/Android.bp.patch @@ -2,15 +2,16 @@ diff --git a/Android.bp b/Android.bp index 3e82eff..550133f 100644 --- a/Android.bp +++ b/Android.bp -@@ -35,8 +35,10 @@ rust_defaults { - rust_test_host { - name: "shared_library_host_test_src_lib", - defaults: ["shared_library_test_defaults"], +@@ -35,9 +35,11 @@ rust_test { + srcs: ["src/lib.rs"], + test_suites: ["general-tests"], + auto_gen_config: true, + // Manually disabled as these tests depend on specific graphics libraries + // being available on the machine running the tests. test_options: { - unit_test: true, + unit_test: false, }, - } + edition: "2015", + rustlibs: [ |