1// Copyright (C) 2020 The Android Open Source Project 2// 3// Licensed under the Apache License, Version 2.0 (the "License"); 4// you may not use this file except in compliance with the License. 5// You may obtain a copy of the License at 6// 7// http://www.apache.org/licenses/LICENSE-2.0 8// 9// Unless required by applicable law or agreed to in writing, software 10// distributed under the License is distributed on an "AS IS" BASIS, 11// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12// See the License for the specific language governing permissions and 13// limitations under the License. 14 15package { 16 default_applicable_licenses: ["Android-Apache-2.0"], 17} 18 19android_test_helper_app { 20 name: "CtsHealthConnectTestApp", 21 defaults: ["cts_defaults"], 22 manifest: "HealthConnectTestHelper/CtsHealthConnectTestApp.xml", 23 platform_apis: true, 24 static_libs: [ 25 "ctstestrunner-axt", 26 "cts-healthconnect-lib", 27 ], 28 sdk_version: "test_current", 29 min_sdk_version: "34", 30 target_sdk_version: "34", 31 srcs: [ 32 "HealthConnectTestHelper/src/**/*.java", 33 "HealthConnectTestHelper/src/**/*.kt", 34 ], 35 libs: ["junit"], 36} 37 38android_test_helper_app { 39 name: "CtsHealthConnectTestAppAWithNormalReadWritePermission", 40 manifest: "HealthConnectTestHelper/CtsHealthConnectTestAppAWithNormalReadWritePermission.xml", 41 static_libs: ["cts-healthconnect-lib", "cts-healthconnect-test-helper"], 42 sdk_version: "test_current", 43 min_sdk_version: "34", 44 target_sdk_version: "34", 45} 46 47android_test_helper_app { 48 name: "CtsHealthConnectTestAppBWithNormalReadWritePermission", 49 manifest: "HealthConnectTestHelper/CtsHealthConnectTestAppBWithNormalReadWritePermission.xml", 50 static_libs: ["cts-healthconnect-lib", "cts-healthconnect-test-helper"], 51 sdk_version: "test_current", 52 min_sdk_version: "34", 53 target_sdk_version: "34", 54} 55 56android_test_helper_app { 57 name: "CtsHealthConnectTestAppWithDataManagePermission", 58 manifest: "HealthConnectTestHelper/CtsHealthConnectTestAppWithDataManagePermission.xml", 59 static_libs: ["cts-healthconnect-lib", "cts-healthconnect-test-helper"], 60 sdk_version: "test_current", 61 min_sdk_version: "34", 62 target_sdk_version: "34", 63} 64 65android_test_helper_app { 66 name: "CtsHealthConnectTestAppWithNoPermission", 67 manifest: "HealthConnectTestHelper/CtsHealthConnectTestAppWithNoPermission.xml", 68 static_libs: ["cts-healthconnect-lib", "cts-healthconnect-test-helper"], 69 sdk_version: "test_current", 70 min_sdk_version: "34", 71 target_sdk_version: "34", 72} 73 74android_test_helper_app { 75 name: "CtsHealthConnectTestAppWithWritePermissionsOnly", 76 manifest: "HealthConnectTestHelper/CtsHealthConnectTestAppWithWritePermissionsOnly.xml", 77 static_libs: ["cts-healthconnect-lib", "cts-healthconnect-test-helper"], 78 sdk_version: "test_current", 79 min_sdk_version: "34", 80 target_sdk_version: "34", 81} 82 83android_test { 84 name: "CtsHealthConnectHostSideDeviceTestCases", 85 team: "trendy_team_android_health", 86 manifest: "device/AndroidManifest.xml", 87 test_config: "device/AndroidTest.xml", 88 defaults: ["cts_defaults"], 89 srcs: [ 90 "device/**/*.java", 91 "device/**/*.kt", 92 ], 93 static_libs: [ 94 "cts-healthconnect-lib", 95 "modules-utils-build_system", 96 "androidx.test.rules", 97 "androidx.test.ext.truth", 98 "compatibility-device-util-axt", 99 "ctstestrunner-axt", 100 "cts-wm-util", 101 "testng", 102 "cts-healthconnect-utils", 103 ], 104 test_suites: [ 105 "cts", 106 "general-tests", 107 "mts-healthfitness", 108 "mcts-healthfitness", 109 ], 110 sdk_version: "test_current", 111 min_sdk_version: "34", 112 libs: [ 113 "android.test.base", 114 "android.test.mock", 115 "android.test.runner", 116 "framework-healthfitness", 117 ], 118 java_resource_dirs: ["res"], 119 data: [ 120 ":CtsHealthConnectTestAppAWithNormalReadWritePermission", 121 ":CtsHealthConnectTestAppBWithNormalReadWritePermission", 122 ":CtsHealthConnectTestAppWithDataManagePermission", 123 ":CtsHealthConnectTestAppWithNoPermission", 124 ":CtsHealthConnectTestAppWithWritePermissionsOnly", 125 ], 126} 127 128java_test_host { 129 name: "CtsHealthConnectHostTestCases", 130 team: "trendy_team_android_health", 131 defaults: ["cts_defaults"], 132 srcs: [ 133 "host/**/*.java", 134 "host/**/*.kt", 135 ], 136 test_suites: [ 137 "cts", 138 "general-tests", 139 "mts-healthfitness", 140 "mcts-healthfitness", 141 ], 142 libs: [ 143 "compatibility-host-util", 144 "cts-tradefed", 145 "tradefed", 146 "truth", 147 ], 148 static_libs: [ 149 "cts-statsd-atom-host-test-utils", 150 "androidx.annotation_annotation", 151 ], 152 java_resource_dirs: ["host/res"], 153 data: [ 154 ":CtsHealthConnectTestApp", 155 ], 156}