Build CtsNetTestCases against API
Instead of building against hidden API, build against module API. This does not build against test API as test API does not contain module API stubs, and this test uses more module APIs than test APIs. Building against stubs should make the build faster (no need to build all of framework.jar), and is desirable in CTS to avoid depending on methods that may change over time or be modified by OEMs. Test: atest Flag: TEST_ONLY Bug: 410435307 Change-Id: I2ac80daa144416cab5477843ecf32041fe0882c5
This commit is contained in:
parent
1e66940f0b
commit
0c3142bdce
1 changed files with 18 additions and 18 deletions
|
|
@ -21,13 +21,28 @@ java_defaults {
|
|||
name: "CtsNetTestCasesDefaults",
|
||||
defaults: [
|
||||
"cts_defaults",
|
||||
"framework-connectivity-test-defaults",
|
||||
],
|
||||
|
||||
// Include both the 32 and 64 bit versions
|
||||
compile_multilib: "both",
|
||||
|
||||
sdk_version: "module_current",
|
||||
libs: [
|
||||
"framework-annotations-lib",
|
||||
"framework-connectivity.impl",
|
||||
"framework-connectivity-b.impl",
|
||||
"framework-connectivity-t.impl",
|
||||
"framework-tethering.impl",
|
||||
"framework-configinfrastructure.stubs.module_lib",
|
||||
"framework-bluetooth.stubs.module_lib",
|
||||
"android.net.ipsec.ike.stubs.module_lib",
|
||||
"framework-wifi.stubs.module_lib",
|
||||
|
||||
// module_current stubs will hide test_stubs symbols in classes that also have module API
|
||||
// (for example UserManager#isVisibleBackgroundUsersSupported is test API but UserManager
|
||||
// is picked up from module lib stubs so that method will not be there). But test_stubs
|
||||
// still provide stubs for classes that are only test API, such as VintfRuntimeInfo.
|
||||
"android_test_stubs_current",
|
||||
"voip-common",
|
||||
"android.test.base.stubs",
|
||||
],
|
||||
|
|
@ -53,11 +68,13 @@ java_defaults {
|
|||
"cts-net-utils",
|
||||
"CtsNetTestsNonUpdatableLib",
|
||||
"ctstestrunner-axt",
|
||||
"DhcpPacketLib",
|
||||
"junit",
|
||||
"junit-params",
|
||||
"modules-utils-build",
|
||||
"net-tests-utils",
|
||||
"net-utils-framework-common",
|
||||
"NetworkStackApiCurrentShims",
|
||||
"truth",
|
||||
"TetheringIntegrationTestsBaseLib",
|
||||
],
|
||||
|
|
@ -88,11 +105,6 @@ android_test {
|
|||
name: "CtsNetTestCases",
|
||||
defaults: [
|
||||
"CtsNetTestCasesDefaults",
|
||||
"ConnectivityNextEnableDefaults",
|
||||
],
|
||||
static_libs: [
|
||||
"DhcpPacketLib",
|
||||
"NetworkStackApiCurrentShims",
|
||||
],
|
||||
test_suites: [
|
||||
"automotive-general-tests",
|
||||
|
|
@ -104,22 +116,10 @@ android_test {
|
|||
resource_zips: [":connectivity-module-version-as-resource-zip"],
|
||||
}
|
||||
|
||||
java_defaults {
|
||||
name: "CtsNetTestCasesApiStableDefaults",
|
||||
// TODO: CTS should not depend on the entirety of the networkstack code.
|
||||
static_libs: [
|
||||
"DhcpPacketLib",
|
||||
"NetworkStackApiStableShims",
|
||||
],
|
||||
jni_uses_sdk_apis: true,
|
||||
min_sdk_version: "30",
|
||||
}
|
||||
|
||||
java_defaults {
|
||||
name: "CtsNetTestCasesMaxTargetSdkDefaults",
|
||||
defaults: [
|
||||
"CtsNetTestCasesDefaults",
|
||||
"CtsNetTestCasesApiStableDefaults",
|
||||
],
|
||||
test_suites: [
|
||||
"cts",
|
||||
|
|
|
|||
Loading…
Reference in a new issue