blob: 7e69e02ae472318926e0b73c4697c568c3ff26ef [file] [log] [blame]
Remi NGUYEN VAN057bf202018-12-04 12:13:09 +09001//
2// Copyright (C) 2018 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
Remi NGUYEN VAN5f48efe2019-09-06 15:16:29 +090017java_defaults {
18 name: "NetworkStackTestsDefaults",
Remi NGUYEN VAN4a2eb872019-01-10 19:12:46 +090019 certificate: "platform",
Chalard Jean3674b552019-06-03 13:37:08 +090020 srcs: ["src/**/*.java", "src/**/*.kt"],
Remi NGUYEN VAN4a2eb872019-01-10 19:12:46 +090021 resource_dirs: ["res"],
Remi NGUYEN VAN057bf202018-12-04 12:13:09 +090022 static_libs: [
Brett Chabot189c5982019-02-26 14:52:33 -080023 "androidx.test.rules",
Chalard Jean3c9f6872019-07-03 12:31:05 +090024 "kotlin-reflect",
Remi NGUYEN VAN057bf202018-12-04 12:13:09 +090025 "mockito-target-extended-minus-junit4",
Chalard Jean0d0cc8c2019-05-28 16:48:32 +090026 "net-tests-utils",
Remi NGUYEN VAN057bf202018-12-04 12:13:09 +090027 "testables",
28 ],
29 libs: [
30 "android.test.runner",
31 "android.test.base",
Remi NGUYEN VAN4a2eb872019-01-10 19:12:46 +090032 "android.test.mock",
Remi NGUYEN VAN057bf202018-12-04 12:13:09 +090033 ],
Xiao Ma53ed1ac2019-06-03 15:48:39 +090034 defaults: ["libnetworkstackutilsjni_deps"],
Remi NGUYEN VAN057bf202018-12-04 12:13:09 +090035 jni_libs: [
36 // For mockito extended
37 "libdexmakerjvmtiagent",
38 "libstaticjvmtiagent",
Xiao Ma53ed1ac2019-06-03 15:48:39 +090039 "libnetworkstackutilsjni",
40 ],
41}
42
Remi NGUYEN VAN5f48efe2019-09-06 15:16:29 +090043android_test {
44 name: "NetworkStackNextTests",
45 srcs: [], // TODO: tests that only apply to the current, non-stable API can be added here
46 test_suites: ["device-tests"],
47 defaults: ["NetworkStackTestsDefaults"],
48 static_libs: ["NetworkStackApiCurrentLib"],
49}
50
51android_test {
52 name: "NetworkStackTests",
Remi NGUYEN VANa42c9482019-11-26 17:11:50 +090053 min_sdk_version: "29",
Remi NGUYEN VAN5f48efe2019-09-06 15:16:29 +090054 test_suites: ["device-tests"],
55 defaults: ["NetworkStackTestsDefaults"],
56 static_libs: ["NetworkStackApiStableLib"],
57}
58
Xiao Ma53ed1ac2019-06-03 15:48:39 +090059// Additional dependencies of libnetworkstackutilsjni that are not provided by the system when
60// running as a test application.
61// Using java_defaults as jni_libs does not support filegroups.
62java_defaults {
63 name: "libnetworkstackutilsjni_deps",
64 jni_libs: [
65 "libartbase",
Remi NGUYEN VAN4a2eb872019-01-10 19:12:46 +090066 "libbacktrace",
67 "libbase",
68 "libbinder",
69 "libbinderthreadstate",
70 "libc++",
Yifan Hong4a55b452019-04-03 18:15:22 -070071 "libcgrouprc",
Remi NGUYEN VAN4a2eb872019-01-10 19:12:46 +090072 "libcrypto",
73 "libcutils",
Remi NGUYEN VAN1c88d602019-03-29 14:49:02 +090074 "ld-android",
75 "libdl_android",
Remi NGUYEN VAN4a2eb872019-01-10 19:12:46 +090076 "libhidl-gen-utils",
77 "libhidlbase",
junyulaicd924e52019-01-08 20:04:33 +080078 "libjsoncpp",
Remi NGUYEN VAN4a2eb872019-01-10 19:12:46 +090079 "liblog",
80 "liblzma",
81 "libnativehelper",
Lorenzo Colitti88ddd8822019-05-01 11:54:33 +090082 "libnativehelper_compat_libc++",
Remi NGUYEN VAN4a2eb872019-01-10 19:12:46 +090083 "libnetworkstacktestsjni",
84 "libpackagelistparser",
85 "libpcre2",
86 "libprocessgroup",
87 "libselinux",
88 "libui",
89 "libutils",
90 "libvintf",
91 "libvndksupport",
92 "libtinyxml2",
93 "libunwindstack",
94 "libutilscallstack",
95 "libziparchive",
96 "libz",
Jeongik Cha87036092019-10-25 02:02:00 +090097 "netd_aidl_interface-cpp",
Remi NGUYEN VAN4a2eb872019-01-10 19:12:46 +090098 ],
99}