markchien | 43e97e0 | 2019-09-03 15:58:06 +0800 | [diff] [blame] | 1 | // |
| 2 | // Copyright (C) 2019 The Android Open Source Project |
| 3 | // |
| 4 | // Licensed under the Apache License, Version 2.0 (the "License"); |
| 5 | // you may not use this file except in compliance with the License. |
| 6 | // You may obtain a copy of the License at |
| 7 | // |
| 8 | // http://www.apache.org/licenses/LICENSE-2.0 |
| 9 | // |
| 10 | // Unless required by applicable law or agreed to in writing, software |
| 11 | // distributed under the License is distributed on an "AS IS" BASIS, |
| 12 | // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 13 | // See the License for the specific language governing permissions and |
| 14 | // limitations under the License. |
| 15 | // |
| 16 | |
paulhu | d1ebb1e | 2020-04-06 14:58:12 +0800 | [diff] [blame] | 17 | java_defaults { |
| 18 | name: "TetheringTestsDefaults", |
markchien | dd6177b | 2019-09-23 20:29:54 +0800 | [diff] [blame] | 19 | srcs: [ |
markchien | dd6177b | 2019-09-23 20:29:54 +0800 | [diff] [blame] | 20 | "src/**/*.java", |
Remi NGUYEN VAN | 5c14666 | 2020-01-24 22:57:09 +0900 | [diff] [blame] | 21 | "src/**/*.kt", |
markchien | dd6177b | 2019-09-23 20:29:54 +0800 | [diff] [blame] | 22 | ], |
markchien | 43e97e0 | 2019-09-03 15:58:06 +0800 | [diff] [blame] | 23 | static_libs: [ |
paulhu | d1ebb1e | 2020-04-06 14:58:12 +0800 | [diff] [blame] | 24 | "TetheringApiCurrentLib", |
markchien | 43e97e0 | 2019-09-03 15:58:06 +0800 | [diff] [blame] | 25 | "androidx.test.rules", |
| 26 | "frameworks-base-testutils", |
| 27 | "mockito-target-extended-minus-junit4", |
paulhu | d1ebb1e | 2020-04-06 14:58:12 +0800 | [diff] [blame] | 28 | "net-tests-utils", |
markchien | 43e97e0 | 2019-09-03 15:58:06 +0800 | [diff] [blame] | 29 | "testables", |
| 30 | ], |
markchien | 44fc26d | 2020-02-06 19:23:26 +0800 | [diff] [blame] | 31 | // TODO(b/147200698) change sdk_version to module-current and |
| 32 | // remove framework-minus-apex, ext, and framework-res |
| 33 | sdk_version: "core_platform", |
markchien | 43e97e0 | 2019-09-03 15:58:06 +0800 | [diff] [blame] | 34 | libs: [ |
| 35 | "android.test.runner", |
| 36 | "android.test.base", |
| 37 | "android.test.mock", |
paulhu | d1ebb1e | 2020-04-06 14:58:12 +0800 | [diff] [blame] | 38 | "ext", |
| 39 | "framework-minus-apex", |
| 40 | "framework-res", |
markchien | 9d35382 | 2019-12-16 20:15:20 +0800 | [diff] [blame] | 41 | "framework-tethering", |
paulhu | d1ebb1e | 2020-04-06 14:58:12 +0800 | [diff] [blame] | 42 | "framework-wifi-stubs-module_libs_api", |
markchien | 43e97e0 | 2019-09-03 15:58:06 +0800 | [diff] [blame] | 43 | ], |
| 44 | jni_libs: [ |
| 45 | // For mockito extended |
| 46 | "libdexmakerjvmtiagent", |
| 47 | "libstaticjvmtiagent", |
| 48 | ], |
markchien | 9d35382 | 2019-12-16 20:15:20 +0800 | [diff] [blame] | 49 | jarjar_rules: "jarjar-rules.txt", |
markchien | 43e97e0 | 2019-09-03 15:58:06 +0800 | [diff] [blame] | 50 | } |
paulhu | d1ebb1e | 2020-04-06 14:58:12 +0800 | [diff] [blame] | 51 | |
| 52 | // Library containing the unit tests. This is used by the coverage test target to pull in the |
| 53 | // unit test code. It is not currently used by the tests themselves because all the build |
| 54 | // configuration needed by the tests is in the TetheringTestsDefaults rule. |
| 55 | android_library { |
| 56 | name: "TetheringTestsLib", |
| 57 | defaults: ["TetheringTestsDefaults"], |
| 58 | visibility: [ |
| 59 | "//frameworks/base/packages/Tethering/tests/integration", |
| 60 | ] |
| 61 | } |
| 62 | |
| 63 | android_test { |
| 64 | name: "TetheringTests", |
| 65 | certificate: "platform", |
| 66 | test_suites: [ |
| 67 | "device-tests", |
| 68 | "mts", |
| 69 | ], |
| 70 | defaults: ["TetheringTestsDefaults"], |
| 71 | compile_multilib: "both", |
| 72 | } |