Colin Cross | 35be424 | 2018-11-20 09:46:47 -0800 | [diff] [blame] | 1 | //######################################################################## |
| 2 | // Build FrameworksServicesTests package |
| 3 | //######################################################################## |
| 4 | |
| 5 | android_test { |
| 6 | name: "FrameworksServicesTests", |
| 7 | |
| 8 | // Include all test java files. |
| 9 | srcs: [ |
| 10 | "src/**/*.java", |
| 11 | |
| 12 | "aidl/com/android/servicestests/aidl/INetworkStateObserver.aidl", |
| 13 | "aidl/com/android/servicestests/aidl/ICmdReceiverService.aidl", |
| 14 | |
| 15 | "test-apps/JobTestApp/src/**/*.java", |
| 16 | |
| 17 | "test-apps/SuspendTestApp/src/**/*.java", |
| 18 | ], |
| 19 | static_libs: [ |
| 20 | "frameworks-base-testutils", |
| 21 | "services.accessibility", |
| 22 | "services.appwidget", |
| 23 | "services.autofill", |
| 24 | "services.backup", |
Satakshi | ce35ce9 | 2019-10-23 17:31:07 -0700 | [diff] [blame] | 25 | "services.contentsuggestions", |
Colin Cross | 35be424 | 2018-11-20 09:46:47 -0800 | [diff] [blame] | 26 | "services.core", |
| 27 | "services.devicepolicy", |
| 28 | "services.net", |
| 29 | "services.usage", |
| 30 | "guava", |
| 31 | "androidx.test.runner", |
| 32 | "androidx.test.rules", |
| 33 | "mockito-target-minus-junit4", |
| 34 | "platform-test-annotations", |
| 35 | "ShortcutManagerTestUtils", |
| 36 | "truth-prebuilt", |
| 37 | "testables", |
| 38 | "testng", |
| 39 | "ub-uiautomator", |
| 40 | "platformprotosnano", |
| 41 | "hamcrest-library", |
| 42 | "servicestests-utils", |
| 43 | ], |
| 44 | |
| 45 | aidl: { |
| 46 | local_include_dirs: ["aidl"], |
| 47 | }, |
| 48 | |
| 49 | libs: [ |
| 50 | "android.hidl.manager-V1.0-java", |
| 51 | "android.hardware.tv.cec-V1.0-java", |
| 52 | "android.test.mock", |
| 53 | "android.test.base", |
| 54 | "android.test.runner", |
| 55 | ], |
| 56 | |
| 57 | platform_apis: true, |
| 58 | test_suites: ["device-tests"], |
| 59 | |
| 60 | certificate: "platform", |
| 61 | |
| 62 | // These are not normally accessible from apps so they must be explicitly included. |
| 63 | jni_libs: [ |
| 64 | "libbacktrace", |
| 65 | "libbase", |
| 66 | "libbinder", |
| 67 | "libbinderthreadstate", |
| 68 | "libc++", |
| 69 | "libcutils", |
| 70 | "liblog", |
| 71 | "liblzma", |
| 72 | "libnativehelper", |
Tim Murray | 676d42d | 2019-02-13 20:47:46 -0800 | [diff] [blame] | 73 | "libpsi", |
Colin Cross | 35be424 | 2018-11-20 09:46:47 -0800 | [diff] [blame] | 74 | "libui", |
Elliott Hughes | fc885bb | 2018-12-12 12:32:15 -0800 | [diff] [blame] | 75 | "libunwindstack", |
Colin Cross | 35be424 | 2018-11-20 09:46:47 -0800 | [diff] [blame] | 76 | "libutils", |
Jeongik Cha | cc0b57c | 2019-10-15 17:03:51 +0900 | [diff] [blame] | 77 | "netd_aidl_interface-cpp", |
Colin Cross | 35be424 | 2018-11-20 09:46:47 -0800 | [diff] [blame] | 78 | ], |
| 79 | |
| 80 | dxflags: ["--multi-dex"], |
| 81 | |
| 82 | optimize: { |
| 83 | enabled: false, |
| 84 | }, |
Dan Shi | bcef6ae | 2019-07-26 14:16:43 -0700 | [diff] [blame] | 85 | |
| 86 | data: [":JobTestApp"], |
Colin Cross | 35be424 | 2018-11-20 09:46:47 -0800 | [diff] [blame] | 87 | } |
| 88 | |
| 89 | java_library { |
| 90 | name: "servicestests-utils", |
| 91 | srcs: [ |
| 92 | "utils/**/*.java", |
| 93 | ], |
| 94 | static_libs: [ |
Brett Chabot | c45f171 | 2018-12-10 16:03:34 -0800 | [diff] [blame] | 95 | "junit", |
Colin Cross | 35be424 | 2018-11-20 09:46:47 -0800 | [diff] [blame] | 96 | "mockito-target-minus-junit4", |
| 97 | ], |
| 98 | libs: [ |
| 99 | "android.test.runner", |
| 100 | ], |
| 101 | } |
| 102 | |
| 103 | filegroup { |
| 104 | name: "servicestests-SuspendTestApp-files", |
| 105 | srcs: [ |
| 106 | "src/com/android/server/pm/SuspendPackagesTest.java", |
| 107 | ], |
| 108 | } |