• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1#############################################################
2# Build test package for locale picker lib.                 #
3#############################################################
4
5LOCAL_PATH := $(call my-dir)
6include $(CLEAR_VARS)
7
8LOCAL_PACKAGE_NAME := LocalePickerTest
9
10LOCAL_PRIVATE_PLATFORM_APIS := true
11LOCAL_PROGUARD_ENABLED := disabled
12
13LOCAL_STATIC_ANDROID_LIBRARIES += localepicker
14
15LOCAL_USE_AAPT2 := true
16
17LOCAL_MODULE_TAGS := optional
18
19LOCAL_LICENSE_KINDS := SPDX-license-identifier-Apache-2.0
20LOCAL_LICENSE_CONDITIONS := notice
21include $(BUILD_PACKAGE)
22
23#############################################################
24# LocalePicker Robolectric test target.                     #
25#############################################################
26include $(CLEAR_VARS)
27
28LOCAL_MODULE := LocalePickerRoboTests
29LOCAL_LICENSE_KINDS := SPDX-license-identifier-Apache-2.0
30LOCAL_LICENSE_CONDITIONS := notice
31LOCAL_MODULE_CLASS := JAVA_LIBRARIES
32
33LOCAL_SRC_FILES := $(call all-java-files-under, src)
34LOCAL_RESOURCE_DIR := $(LOCAL_PATH)/res
35LOCAL_JAVA_RESOURCE_DIRS := config
36
37LOCAL_JAVA_LIBRARIES := \
38    robolectric_android-all-stub \
39    Robolectric_all-target \
40    mockito-robolectric-prebuilt \
41    truth-prebuilt
42
43LOCAL_INSTRUMENTATION_FOR := LocalePickerTest
44
45LOCAL_MODULE_TAGS := optional
46
47# Generate test_config.properties
48include external/robolectric-shadows/gen_test_config.mk
49
50include $(BUILD_STATIC_JAVA_LIBRARY)
51
52#############################################################
53# LocalePicker runner target to run the previous target.    #
54#############################################################
55include $(CLEAR_VARS)
56
57LOCAL_MODULE := RunLocalePickerRoboTests
58LOCAL_LICENSE_KINDS := SPDX-license-identifier-Apache-2.0
59LOCAL_LICENSE_CONDITIONS := notice
60
61LOCAL_JAVA_LIBRARIES := \
62    LocalePickerRoboTests \
63    robolectric_android-all-stub \
64    Robolectric_all-target \
65    mockito-robolectric-prebuilt \
66    truth-prebuilt
67
68LOCAL_TEST_PACKAGE := LocalePickerTest
69
70LOCAL_INSTRUMENT_SOURCE_DIRS := $(LOCAL_PATH)/../src
71
72include external/robolectric-shadows/run_robotests.mk
73