# Copyright 2022 The Chromium Authors
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
import("//build/config/android/rules.gni")
import("//third_party/jni_zero/jni_zero.gni")
android_library("java") {
srcjar_deps = [ ":jni_headers" ]
sources = [
"java/src/org/chromium/chrome/browser/usb/UsbBridge.java",
"java/src/org/chromium/chrome/browser/usb/UsbNotificationManager.java",
"java/src/org/chromium/chrome/browser/usb/UsbNotificationManagerDelegate.java",
]
deps = [
":java_resources",
"//base:base_java",
"//build/android:build_java",
"//chrome/android:base_module_java",
"//chrome/browser/notifications:java",
"//chrome/browser/preferences:java",
"//chrome/browser/tab:java",
"//components/browser_ui/notifications/android:java",
"//components/url_formatter/android:url_formatter_java",
"//content/public/android:content_full_java",
"//third_party/androidx:androidx_annotation_annotation_java",
"//third_party/androidx:androidx_fragment_fragment_java",
"//third_party/jni_zero:jni_zero_java",
"//url:gurl_java",
]
resources_package = "org.chromium.chrome.browser.usb"
}
android_resources("java_resources") {
deps = [
"//components/browser_ui/strings/android:browser_ui_strings_grd",
"//components/permissions/android:java_resources",
]
}
generate_jni("jni_headers") {
sources = [ "java/src/org/chromium/chrome/browser/usb/UsbBridge.java" ]
}
robolectric_library("junit") {
sources = [
"junit/src/org/chromium/chrome/browser/usb/UsbNotificationManagerTest.java",
]
deps = [
":java",
"//base:base_java",
"//base:base_java_test_support",
"//base:base_junit_test_support",
"//chrome/test/android:chrome_java_unit_test_support",
"//components/browser_ui/notifications/android:java",
"//components/browser_ui/notifications/android:test_support_java",
"//components/url_formatter/android:url_formatter_java",
"//third_party/jni_zero:jni_zero_java",
"//third_party/junit:junit",
"//third_party/mockito:mockito_java",
"//url:gurl_java",
"//url:gurl_junit_test_support",
]
}