aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Android.bp25
-rw-r--r--TEST_MAPPING7
-rw-r--r--cargo2android.json5
3 files changed, 19 insertions, 18 deletions
diff --git a/Android.bp b/Android.bp
index 558e5e8..8d3cccd 100644
--- a/Android.bp
+++ b/Android.bp
@@ -1,4 +1,4 @@
-// This file is generated by cargo2android.py --device --run --tests.
+// This file is generated by cargo2android.py --config cargo2android.json.
// Do not modify this file as changes will be overridden on upgrade.
package {
@@ -18,14 +18,18 @@ license {
],
}
-rust_defaults {
- name: "gdbstub_arch_test_defaults",
+rust_test {
+ name: "gdbstub_arch_test_src_lib",
+ host_supported: true,
crate_name: "gdbstub_arch",
- srcs: ["src/lib.rs"],
cargo_env_compat: true,
cargo_pkg_version: "0.1.1",
+ srcs: ["src/lib.rs"],
test_suites: ["general-tests"],
auto_gen_config: true,
+ test_options: {
+ unit_test: true,
+ },
edition: "2018",
rustlibs: [
"libgdbstub",
@@ -33,19 +37,6 @@ rust_defaults {
],
}
-rust_test_host {
- name: "gdbstub_arch_host_test_src_lib",
- defaults: ["gdbstub_arch_test_defaults"],
- test_options: {
- unit_test: true,
- },
-}
-
-rust_test {
- name: "gdbstub_arch_device_test_src_lib",
- defaults: ["gdbstub_arch_test_defaults"],
-}
-
rust_library {
name: "libgdbstub_arch",
host_supported: true,
diff --git a/TEST_MAPPING b/TEST_MAPPING
index 1e91e7e..571f133 100644
--- a/TEST_MAPPING
+++ b/TEST_MAPPING
@@ -2,7 +2,12 @@
{
"presubmit": [
{
- "name": "gdbstub_arch_device_test_src_lib"
+ "name": "gdbstub_arch_test_src_lib"
+ }
+ ],
+ "presubmit-rust": [
+ {
+ "name": "gdbstub_arch_test_src_lib"
}
]
}
diff --git a/cargo2android.json b/cargo2android.json
new file mode 100644
index 0000000..d36fb44
--- /dev/null
+++ b/cargo2android.json
@@ -0,0 +1,5 @@
+{
+ "device": true,
+ "run": true,
+ "tests": true
+} \ No newline at end of file