Files
android_packages_modules_Co…/tests/smoketest/Android.bp
Paul Duffin 4ceb8c1f25 Workaround prebuilt name conflict for service-connectivity
When building against prebuilts some dependencies on
service-connectivity get replaced by the prebuilts which does not have
an implementation library and so it breaks.

If it was a java_sdk_library that would be handled automatically but
it is just a java_library.

Ignore-AOSP-First: Needed urgently here.
Bug: 223592962
Test: m FrameworksNetSmokeTests FrameworksNetTests FrameworksNetIntegrationTests
      # Fails when building from prebuilts without this change works with this change.
Change-Id: Ib2fbd3c7703e9ed606650643db6e1977f550d90d
2022-05-20 15:06:27 +00:00

28 lines
1.2 KiB
Plaintext

// This test exists only because the jni_libs list for these tests is difficult to
// maintain: the test itself only depends on libnetworkstatsfactorytestjni, but the test
// fails to load that library unless *all* the dependencies of that library are explicitly
// listed in jni_libs. This means that whenever any of the dependencies changes the test
// starts failing and breaking presubmits in frameworks/base. We cannot easily put
// FrameworksNetTests into global presubmit because they are at times flaky, but this
// test is effectively empty beyond validating that the libraries load correctly, and
// thus should be stable enough to put in global presubmit.
//
// TODO: remove this hack when there is a better solution for jni_libs that includes
// dependent libraries.
package {
// See: http://go/android-license-faq
default_applicable_licenses: ["Android-Apache-2.0"],
}
android_test {
name: "FrameworksNetSmokeTests",
defaults: ["FrameworksNetTests-jni-defaults"],
srcs: ["java/SmokeTest.java"],
test_suites: ["device-tests"],
static_libs: [
"androidx.test.rules",
"mockito-target-minus-junit4",
"service-connectivity-for-tests",
],
}