1// Copyright (C) 2018 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
15// Build the common utility library for use host-side
16package {
17    default_visibility: [":__subpackages__"],
18    default_applicable_licenses: ["Android-Apache-2.0"],
19}
20
21java_library_host {
22    name: "Robolectric-aosp-plugins",
23    srcs: ["plugins/src/main/java/**/*.java"],
24    visibility: [
25        "//external/robolectric",
26    ],
27    libs: [
28        "Robolectric_nativeruntime_upstream",
29        "Robolectric_robolectric_upstream",
30        "Robolectric_sandbox_upstream",
31        "Robolectric_shadows_versioning_upstream",
32        "Robolectric_utils_reflector_upstream",
33        "robolectric-host-android_all",
34    ],
35    plugins: ["auto_service_plugin"],
36}
37
38//#############################################
39// Compile Robolectric utils tests
40//#############################################
41
42java_test_host {
43    name: "Robolectric-aosp-plugins_tests",
44    srcs: ["src/test/java/**/*.java"],
45    static_libs: [
46        "Robolectric-aosp-plugins",
47        "Robolectric_robolectric_upstream",
48        "Robolectric_shadows_versioning_upstream",
49        "hamcrest",
50        "guava",
51        "junit",
52        "truth",
53    ],
54    libs: ["robolectric-host-android_all"],
55    test_suites: ["general-tests"],
56}
57