You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
87 lines
2.3 KiB
87 lines
2.3 KiB
//########################################################################
|
|
// Build WmTests package
|
|
//########################################################################
|
|
|
|
package {
|
|
// See: http://go/android-license-faq
|
|
// A large-scale-change added 'default_applicable_licenses' to import
|
|
// all of the 'license_kinds' from "frameworks_base_license"
|
|
// to get the below license kinds:
|
|
// SPDX-license-identifier-Apache-2.0
|
|
default_applicable_licenses: ["frameworks_base_license"],
|
|
}
|
|
|
|
// Include all test java files.
|
|
filegroup {
|
|
name: "wmtests-sources",
|
|
srcs: [
|
|
"src/**/*.java",
|
|
],
|
|
}
|
|
|
|
genrule {
|
|
name: "wmtests.protologsrc",
|
|
srcs: [
|
|
":protolog-groups",
|
|
":wmtests-sources",
|
|
],
|
|
tools: ["protologtool"],
|
|
cmd: "$(location protologtool) transform-protolog-calls " +
|
|
"--protolog-class com.android.internal.protolog.common.ProtoLog " +
|
|
"--protolog-impl-class com.android.internal.protolog.ProtoLogImpl " +
|
|
"--protolog-cache-class 'com.android.server.wm.ProtoLogCache' " +
|
|
"--loggroups-class com.android.internal.protolog.ProtoLogGroup " +
|
|
"--loggroups-jar $(location :protolog-groups) " +
|
|
"--output-srcjar $(out) " +
|
|
"$(locations :wmtests-sources)",
|
|
out: ["wmtests.protolog.srcjar"],
|
|
}
|
|
|
|
android_test {
|
|
name: "WmTests",
|
|
|
|
// We only want this apk build for tests.
|
|
srcs: [":wmtests.protologsrc"],
|
|
|
|
static_libs: [
|
|
"frameworks-base-testutils",
|
|
"services.core",
|
|
"androidx.test.runner",
|
|
"androidx.test.rules",
|
|
"mockito-target-extended-minus-junit4",
|
|
"platform-test-annotations",
|
|
"servicestests-utils",
|
|
"testng",
|
|
"truth-prebuilt",
|
|
"testables",
|
|
"ub-uiautomator",
|
|
"hamcrest-library",
|
|
"platform-compat-test-rules",
|
|
],
|
|
|
|
libs: [
|
|
"android.hardware.power-V1-java",
|
|
"android.test.mock",
|
|
"android.test.base",
|
|
"android.test.runner",
|
|
],
|
|
|
|
// These are not normally accessible from apps so they must be explicitly included.
|
|
jni_libs: [
|
|
"libdexmakerjvmtiagent",
|
|
"libstaticjvmtiagent",
|
|
],
|
|
|
|
platform_apis: true,
|
|
test_suites: ["device-tests"],
|
|
|
|
certificate: "platform",
|
|
|
|
dxflags: ["--multi-dex"],
|
|
|
|
optimize: {
|
|
enabled: false,
|
|
},
|
|
|
|
}
|