From c724fb670f3a57d123cda7ba8bbea9d38eb069db Mon Sep 17 00:00:00 2001 From: Chen Zhu Date: Wed, 20 May 2020 13:06:24 -0700 Subject: [PATCH] Add test config to libstatspull_test and libstatssocket_test and apply mainline module test controller to it so that the tests will only be run when statsd apex is found on device. Bug: 154845935 Test: m mts && mts-tradefed run mts-statsd Change-Id: I8939e68b4d4c3772e248c1960b74c0f1bd6a21a6 --- libstats/pull/Android.bp | 7 ++++- libstats/pull/libstatspull_test.xml | 37 ++++++++++++++++++++++++ libstats/socket/Android.bp | 6 +++- libstats/socket/libstatssocket_test.xml | 38 +++++++++++++++++++++++++ 4 files changed, 86 insertions(+), 2 deletions(-) create mode 100644 libstats/pull/libstatspull_test.xml create mode 100644 libstats/socket/libstatssocket_test.xml diff --git a/libstats/pull/Android.bp b/libstats/pull/Android.bp index 2658639c0..a8b4a4faf 100644 --- a/libstats/pull/Android.bp +++ b/libstats/pull/Android.bp @@ -85,13 +85,18 @@ cc_test { "libstatssocket", ], test_suites: ["general-tests", "mts"], + test_config: "libstatspull_test.xml", + //TODO(b/153588990): Remove when the build system properly separates //32bit and 64bit architectures. compile_multilib: "both", multilib: { lib64: { suffix: "64", - } + }, + lib32: { + suffix: "32", + }, }, cflags: [ "-Wall", diff --git a/libstats/pull/libstatspull_test.xml b/libstats/pull/libstatspull_test.xml new file mode 100644 index 000000000..233fc1f18 --- /dev/null +++ b/libstats/pull/libstatspull_test.xml @@ -0,0 +1,37 @@ + + + + diff --git a/libstats/socket/Android.bp b/libstats/socket/Android.bp index 4e89b9420..2bf0261b2 100644 --- a/libstats/socket/Android.bp +++ b/libstats/socket/Android.bp @@ -127,13 +127,17 @@ cc_test { "libutils", ], test_suites: ["device-tests", "mts"], + test_config: "libstatssocket_test.xml", //TODO(b/153588990): Remove when the build system properly separates //32bit and 64bit architectures. compile_multilib: "both", multilib: { lib64: { suffix: "64", - } + }, + lib32: { + suffix: "32", + }, }, require_root: true, } diff --git a/libstats/socket/libstatssocket_test.xml b/libstats/socket/libstatssocket_test.xml new file mode 100644 index 000000000..d2694d1dd --- /dev/null +++ b/libstats/socket/libstatssocket_test.xml @@ -0,0 +1,38 @@ + + + + +