blob: a16587ec991df5768dad1e23f8c92e7e7b4399ca [file] [log] [blame]
// Build the unit tests for installd
package {
// See: http://go/android-license-faq
// A large-scale-change added 'default_applicable_licenses' to import
// all of the 'license_kinds' from "frameworks_native_license"
// to get the below license kinds:
// SPDX-license-identifier-Apache-2.0
default_applicable_licenses: ["frameworks_native_license"],
}
cc_defaults {
name: "installd_tests_defaults",
test_suites: ["device-tests"],
clang: true,
cpp_std: "c++2a",
cflags: [
"-Wall",
"-Werror",
],
shared_libs: [
"libbase",
"libcutils",
"libext2_uuid",
"libutils",
],
static_libs: [
"liblog",
],
}
cc_test {
name: "installd_utils_test",
defaults: ["installd_tests_defaults"],
srcs: ["installd_utils_test.cpp"],
static_libs: [
"libasync_safe",
"libdiskusage",
"libinstalld",
],
test_config: "installd_utils_test.xml",
}
cc_test {
name: "installd_cache_test",
defaults: ["installd_tests_defaults"],
srcs: ["installd_cache_test.cpp"],
shared_libs: [
"libbinder",
"libcrypto",
"libprocessgroup",
"libselinux",
"server_configurable_flags",
],
static_libs: [
"libasync_safe",
"libdiskusage",
"libinstalld",
"libziparchive",
"liblogwrap",
],
test_config: "installd_cache_test.xml",
product_variables: {
arc: {
exclude_srcs: [
"QuotaUtils.cpp",
],
static_libs: [
"libarcdiskquota",
"arc_services_aidl",
],
cflags: [
"-DUSE_ARC",
],
},
},
}
cc_test {
name: "installd_service_test",
defaults: ["installd_tests_defaults"],
srcs: ["installd_service_test.cpp"],
shared_libs: [
"libbinder",
"libcrypto",
"libprocessgroup",
"libselinux",
"packagemanager_aidl-cpp",
"server_configurable_flags",
],
static_libs: [
"libasync_safe",
"libdiskusage",
"libinstalld",
"libziparchive",
"liblogwrap",
],
test_config: "installd_service_test.xml",
product_variables: {
arc: {
exclude_srcs: [
"QuotaUtils.cpp",
],
static_libs: [
"libarcdiskquota",
"arc_services_aidl",
],
cflags: [
"-DUSE_ARC",
],
},
},
}
cc_test {
name: "installd_dexopt_test",
defaults: ["installd_tests_defaults"],
srcs: ["installd_dexopt_test.cpp"],
shared_libs: [
"libbinder",
"libcrypto",
"libprocessgroup",
"libselinux",
"server_configurable_flags",
],
static_libs: [
"libasync_safe",
"libdiskusage",
"libinstalld",
"liblogwrap",
"libziparchive",
"libz",
],
test_config: "installd_dexopt_test.xml",
product_variables: {
arc: {
exclude_srcs: [
"QuotaUtils.cpp",
],
static_libs: [
"libarcdiskquota",
"arc_services_aidl",
],
cflags: [
"-DUSE_ARC",
],
},
},
}
cc_test {
name: "installd_otapreopt_test",
defaults: ["installd_tests_defaults"],
srcs: ["installd_otapreopt_test.cpp"],
shared_libs: [
"server_configurable_flags",
],
static_libs: [
"libotapreoptparameters",
],
}
cc_test {
name: "installd_file_test",
defaults: ["installd_tests_defaults"],
srcs: ["installd_file_test.cpp"],
static_libs: [
"libinstalld",
],
}