• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1//
2// Copyright (C) 2020 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//
16package {
17    default_applicable_licenses: ["Android-Apache-2.0"],
18}
19
20java_defaults {
21    name: "TetheringIntegrationTestsDefaults",
22    defaults: ["framework-connectivity-test-defaults"],
23    srcs: [
24        "base/**/*.java",
25    ],
26    min_sdk_version: "30",
27    static_libs: [
28        "NetworkStackApiStableLib",
29        "androidx.test.rules",
30        "cts-net-utils",
31        "mockito-target-extended-minus-junit4",
32        "net-tests-utils",
33        "net-utils-device-common-bpf",
34        "testables",
35        "connectivity-net-module-utils-bpf",
36    ],
37    libs: [
38        "android.test.runner",
39        "android.test.base",
40        "android.test.mock",
41    ],
42    jni_libs: [
43        // For mockito extended
44        "libdexmakerjvmtiagent",
45        "libstaticjvmtiagent",
46    ],
47}
48
49android_library {
50    name: "TetheringIntegrationTestsBaseLib",
51    target_sdk_version: "current",
52    platform_apis: true,
53    defaults: ["TetheringIntegrationTestsDefaults"],
54    visibility: [
55        "//packages/modules/Connectivity/Tethering/tests/mts",
56    ]
57}
58
59// Library including tethering integration tests targeting the latest stable SDK.
60// Use with NetworkStackJarJarRules.
61android_library {
62    name: "TetheringIntegrationTestsLatestSdkLib",
63    target_sdk_version: "33",
64    platform_apis: true,
65    defaults: ["TetheringIntegrationTestsDefaults"],
66    srcs: [
67        "src/**/*.java",
68    ],
69    visibility: [
70        "//packages/modules/Connectivity/tests/cts/tethering",
71        "//packages/modules/Connectivity/tests:__subpackages__",
72        "//packages/modules/Connectivity/Tethering/tests:__subpackages__",
73    ]
74}
75
76// Library including tethering integration tests targeting current development SDK.
77// Use with NetworkStackJarJarRules.
78android_library {
79    name: "TetheringIntegrationTestsLib",
80    target_sdk_version: "current",
81    platform_apis: true,
82    defaults: ["TetheringIntegrationTestsDefaults"],
83    srcs: [
84        "src/**/*.java",
85    ],
86    visibility: [
87        "//packages/modules/Connectivity/tests/cts/tethering",
88        "//packages/modules/Connectivity/Tethering/tests/mts",
89    ]
90}
91
92// TODO: remove because TetheringIntegrationTests has been covered by ConnectivityCoverageTests.
93android_test {
94    name: "TetheringIntegrationTests",
95    platform_apis: true,
96    defaults: ["TetheringIntegrationTestsDefaults"],
97    test_suites: [
98        "device-tests",
99    ],
100    srcs: [
101        "src/**/*.java",
102    ],
103    compile_multilib: "both",
104    jarjar_rules: ":NetworkStackJarJarRules",
105}
106