blob: c2c545bcb4ecd638752bbee08c91739267fa1680 [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 Badoura7548b52022-01-27 22:04:48 -080014
Bob Badour390b27e2021-03-19 04:22:23 -070015package {
16 // See: http://go/android-license-faq
Bob Badoura7548b52022-01-27 22:04:48 -080017 default_applicable_licenses: ["Android-Apache-2.0"],
Bob Badour390b27e2021-03-19 04:22:23 -070018}
19
Sunny Goyal4af8cf92021-07-29 15:48:24 -070020// Source code used for test
Sunny Goyalf5c42ea2021-03-12 16:00:40 -080021filegroup {
Sunny Goyal4af8cf92021-07-29 15:48:24 -070022 name: "launcher-tests-src",
Thales Limaa1012902022-01-13 17:58:42 +000023 srcs: [
24 "src/**/*.java",
25 "src/**/*.kt"
26 ],
Sunny Goyal4af8cf92021-07-29 15:48:24 -070027}
28
29// Source code used for oop test helpers
30filegroup {
31 name: "launcher-oop-tests-src",
32 srcs: [
33 "src/com/android/launcher3/ui/AbstractLauncherUiTest.java",
Sunny Goyal4af8cf92021-07-29 15:48:24 -070034 "src/com/android/launcher3/ui/PortraitLandscapeRunner.java",
My Name5b59e752021-12-15 20:54:45 -050035 "src/com/android/launcher3/util/TestUtil.java",
Sunny Goyal4af8cf92021-07-29 15:48:24 -070036 "src/com/android/launcher3/util/Wait.java",
37 "src/com/android/launcher3/util/WidgetUtils.java",
38 "src/com/android/launcher3/util/rule/FailureWatcher.java",
39 "src/com/android/launcher3/util/rule/LauncherActivityRule.java",
40 "src/com/android/launcher3/util/rule/ScreenRecordRule.java",
41 "src/com/android/launcher3/util/rule/ShellCommandRule.java",
42 "src/com/android/launcher3/util/rule/SimpleActivityRule.java",
43 "src/com/android/launcher3/util/rule/TestStabilityRule.java",
44 "src/com/android/launcher3/ui/TaplTestsLauncher3.java",
45 "src/com/android/launcher3/testcomponent/BaseTestingActivity.java",
Pat Manning30c28a02022-01-31 16:01:51 +000046 "src/com/android/launcher3/testcomponent/OtherBaseTestingActivity.java",
Sunny Goyal4af8cf92021-07-29 15:48:24 -070047 "src/com/android/launcher3/testcomponent/CustomShortcutConfigActivity.java",
48 "src/com/android/launcher3/testcomponent/TestCommandReceiver.java",
49 "src/com/android/launcher3/testcomponent/TestLauncherActivity.java",
50 ],
51}
52
53// Library with all the dependencies for building quickstep
54android_library {
55 name: "Launcher3TestLib",
56 srcs: [ ],
57 resource_dirs: ["res"],
58 static_libs: [
59 "launcher-aosp-tapl",
Sunny Goyal177785e2021-07-29 15:48:24 -070060 "androidx.test.core",
Sunny Goyal4af8cf92021-07-29 15:48:24 -070061 "androidx.test.runner",
62 "androidx.test.rules",
63 "androidx.test.ext.junit",
64 "androidx.test.espresso.core",
65 "androidx.test.espresso.contrib",
66 "androidx.test.espresso.intents",
67 "androidx.test.uiautomator_uiautomator",
68 "mockito-target-inline-minus-junit4",
69 "launcher_log_protos_lite",
70 "truth-prebuilt"
71 ],
72 manifest: "AndroidManifest-common.xml",
73 platform_apis: true,
74}
75
My Name5b59e752021-12-15 20:54:45 -050076android_library {
77 name: "Launcher3TestResources",
78 resource_dirs: ["res"],
79}
80
Sunny Goyal4af8cf92021-07-29 15:48:24 -070081android_test {
82 name: "Launcher3Tests",
83 srcs: [
84 ":launcher-tests-src",
85 ],
86 static_libs: ["Launcher3TestLib"],
87 libs: [
88 "android.test.base",
89 "android.test.runner",
90 "android.test.mock",
91 ],
92 jni_libs: [
93 "libdexmakerjvmtiagent",
94 "libstaticjvmtiagent",
95 ],
96 use_embedded_native_libs: false,
97 compile_multilib: "both",
98 instrumentation_for: "Launcher3",
99 manifest: "AndroidManifest.xml",
100 platform_apis: true,
101 test_config: "Launcher3Tests.xml",
102 data: [":Launcher3"]
Sunny Goyalf5c42ea2021-03-12 16:00:40 -0800103}