1// Copyright (C) 2008 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 19java_defaults { 20 name: "CtsNetTestCasesDefaults", 21 defaults: [ 22 "cts_defaults", 23 "framework-connectivity-test-defaults", 24 ], 25 26 // Include both the 32 and 64 bit versions 27 compile_multilib: "both", 28 29 libs: [ 30 "voip-common", 31 "android.test.base", 32 ], 33 34 jni_libs: [ 35 "libcts_jni", 36 "libnativedns_jni", 37 "libnativemultinetwork_jni", 38 "libnativehelper_compat_libc++", 39 ], 40 41 srcs: [ 42 "src/**/*.java", 43 "src/**/*.kt", 44 ":ike-aes-xcbc", 45 ], 46 jarjar_rules: "jarjar-rules-shared.txt", 47 static_libs: [ 48 "bouncycastle-unbundled", 49 "FrameworksNetCommonTests", 50 "core-tests-support", 51 "cts-net-utils", 52 "CtsNetTestsNonUpdatableLib", 53 "ctstestrunner-axt", 54 "junit", 55 "junit-params", 56 "modules-utils-build", 57 "net-utils-framework-common", 58 "truth-prebuilt", 59 ], 60 61 // uncomment when b/13249961 is fixed 62 // sdk_version: "current", 63 platform_apis: true, 64 required: ["ConnectivityChecker"], 65 test_config_template: "AndroidTestTemplate.xml", 66} 67 68// Networking CTS tests for development and release. These tests always target the platform SDK 69// version, and are subject to all the restrictions appropriate to that version. Before SDK 70// finalization, these tests have a min_sdk_version of 10000, and cannot be installed on release 71// devices. 72android_test { 73 name: "CtsNetTestCases", 74 defaults: ["CtsNetTestCasesDefaults", "ConnectivityNextEnableDefaults"], 75 // TODO: CTS should not depend on the entirety of the networkstack code. 76 static_libs: [ 77 "NetworkStackApiCurrentLib", 78 ], 79 test_suites: [ 80 "cts", 81 "general-tests", 82 ], 83} 84 85java_defaults { 86 name: "CtsNetTestCasesApiStableDefaults", 87 // TODO: CTS should not depend on the entirety of the networkstack code. 88 static_libs: [ 89 "NetworkStackApiStableLib", 90 ], 91 jni_uses_sdk_apis: true, 92 min_sdk_version: "29", 93} 94 95// Networking CTS tests that target the latest released SDK. These tests can be installed on release 96// devices at any point in the Android release cycle and are useful for qualifying mainline modules 97// on release devices. 98android_test { 99 name: "CtsNetTestCasesLatestSdk", 100 defaults: [ 101 "CtsNetTestCasesDefaults", 102 "CtsNetTestCasesApiStableDefaults", 103 ], 104 target_sdk_version: "33", 105 test_suites: [ 106 "general-tests", 107 "mts-dnsresolver", 108 "mts-networking", 109 "mts-tethering", 110 "mts-wifi", 111 ], 112} 113 114android_test { 115 name: "CtsNetTestCasesMaxTargetSdk31", // Must match CtsNetTestCasesMaxTargetSdk31 annotation. 116 defaults: [ 117 "CtsNetTestCasesDefaults", 118 "CtsNetTestCasesApiStableDefaults", 119 ], 120 target_sdk_version: "31", 121 package_name: "android.net.cts.maxtargetsdk31", // CTS package names must be unique. 122 instrumentation_target_package: "android.net.cts.maxtargetsdk31", 123 test_suites: [ 124 "cts", 125 "general-tests", 126 "mts-networking", 127 ], 128} 129 130