blob: cab61cfceada3742a8df43c218a1b89b007a4cad [file] [log] [blame]
// This looks a bit awkward, but we need our tests to run against either
// MediaProvider or MediaProviderGoogle, and we don't know which one is
// on the device being tested, so we can't sign our tests with a key that
// will allow instrumentation. Thus we pull all the sources we need to
// run tests against into the test itself.
android_test {
name: "MediaProviderTests",
test_suites: [
"device-tests",
"mts",
],
compile_multilib: "both",
manifest: "AndroidManifest.xml",
resource_dirs: [
"main_res",
"res",
],
srcs: [
":framework-mediaprovider-sources",
":mediaprovider-sources",
"src/**/*.java",
],
libs: [
"android.test.base",
"android.test.mock",
"android.test.runner",
"unsupportedappusage",
],
static_libs: [
"androidx.appcompat_appcompat",
"androidx.core_core",
"androidx.test.rules",
"guava",
"mockito-target",
"truth-prebuilt",
],
certificate: "media",
aaptflags: ["--custom-package com.android.providers.media"],
errorprone: {
javacflags: [
"-Xep:CatchFail:ERROR",
"-Xep:MissingFail:ERROR",
],
},
}