blob: 4f6e8a3390a52a3a23056c2489a241af47db1a1d [file] [log] [blame]
Sunny Goyalf5c42ea2021-03-12 16:00:40 -08001// Copyright (C) 2021 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.
Bob Badour390b27e2021-03-19 04:22:23 -070014package {
15 // See: http://go/android-license-faq
Bob Badour596ebbc2022-01-27 20:30:50 -080016 default_applicable_licenses: ["Android-Apache-2.0"],
Bob Badour390b27e2021-03-19 04:22:23 -070017}
18
Sunny Goyal4af8cf92021-07-29 15:48:24 -070019// Source code used for test
Sunny Goyalf5c42ea2021-03-12 16:00:40 -080020filegroup {
Sunny Goyal4af8cf92021-07-29 15:48:24 -070021 name: "launcher-tests-src",
Alex Chau4075f172021-11-25 11:54:26 +000022 srcs: ["src/**/*.java"],
Sunny Goyal4af8cf92021-07-29 15:48:24 -070023}
24
25// Source code used for oop test helpers
26filegroup {
27 name: "launcher-oop-tests-src",
28 srcs: [
29 "src/com/android/launcher3/ui/AbstractLauncherUiTest.java",
Sunny Goyal4af8cf92021-07-29 15:48:24 -070030 "src/com/android/launcher3/ui/PortraitLandscapeRunner.java",
31 "src/com/android/launcher3/util/Wait.java",
32 "src/com/android/launcher3/util/WidgetUtils.java",
33 "src/com/android/launcher3/util/rule/FailureWatcher.java",
34 "src/com/android/launcher3/util/rule/LauncherActivityRule.java",
35 "src/com/android/launcher3/util/rule/ScreenRecordRule.java",
36 "src/com/android/launcher3/util/rule/ShellCommandRule.java",
37 "src/com/android/launcher3/util/rule/SimpleActivityRule.java",
38 "src/com/android/launcher3/util/rule/TestStabilityRule.java",
39 "src/com/android/launcher3/ui/TaplTestsLauncher3.java",
40 "src/com/android/launcher3/testcomponent/BaseTestingActivity.java",
41 "src/com/android/launcher3/testcomponent/CustomShortcutConfigActivity.java",
42 "src/com/android/launcher3/testcomponent/TestCommandReceiver.java",
43 "src/com/android/launcher3/testcomponent/TestLauncherActivity.java",
44 ],
45}
46
47// Library with all the dependencies for building quickstep
48android_library {
49 name: "Launcher3TestLib",
50 srcs: [ ],
51 resource_dirs: ["res"],
52 static_libs: [
53 "launcher-aosp-tapl",
Sunny Goyal177785e2021-07-29 15:48:24 -070054 "androidx.test.core",
Sunny Goyal4af8cf92021-07-29 15:48:24 -070055 "androidx.test.runner",
56 "androidx.test.rules",
57 "androidx.test.ext.junit",
58 "androidx.test.espresso.core",
59 "androidx.test.espresso.contrib",
60 "androidx.test.espresso.intents",
61 "androidx.test.uiautomator_uiautomator",
62 "mockito-target-inline-minus-junit4",
63 "launcher_log_protos_lite",
64 "truth-prebuilt"
65 ],
66 manifest: "AndroidManifest-common.xml",
67 platform_apis: true,
68}
69
70android_test {
71 name: "Launcher3Tests",
72 srcs: [
73 ":launcher-tests-src",
74 ],
75 static_libs: ["Launcher3TestLib"],
76 libs: [
77 "android.test.base",
78 "android.test.runner",
79 "android.test.mock",
80 ],
81 jni_libs: [
82 "libdexmakerjvmtiagent",
83 "libstaticjvmtiagent",
84 ],
85 use_embedded_native_libs: false,
86 compile_multilib: "both",
87 instrumentation_for: "Launcher3",
88 manifest: "AndroidManifest.xml",
89 platform_apis: true,
90 test_config: "Launcher3Tests.xml",
91 data: [":Launcher3"]
Sunny Goyalf5c42ea2021-03-12 16:00:40 -080092}