1// Copyright (C) 2022 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
15package {
16    default_applicable_licenses: ["Android-Apache-2.0"],
17}
18
19android_test {
20    name: "AdServicesEndToEndTests",
21    srcs: [
22        "src/**/*.java",
23    ],
24    sdk_version: "module_current",
25    min_sdk_version: "33",
26    static_libs: [
27        "adservices-clients",
28        "androidx.concurrent_concurrent-futures",
29        "androidx.test.rules",
30        "compatibility-device-util-axt",
31        "mockito-target-extended-minus-junit4",
32        "truth",
33        "framework-adservices.impl",
34        "framework-sdksandbox.impl",
35        "adservices-test-fixtures",
36        "adservices-test-utility",
37    ],
38    libs: [
39        "android.test.base.stubs.system",
40    ],
41    test_suites: [
42        "general-tests",
43    ],
44    lint: {
45        extra_check_modules: ["AdServicesTestLintChecker"],
46        test: false, // TODO(b/343741206): remove when checks will run on android_test
47    },
48}
49
50java_defaults {
51    name: "AdExtServices-EndToEndTests-Defaults",
52    defaults: ["mts-target-sdk-version-current"],
53    sdk_version: "module_current",
54    static_libs: [
55        "adservices-clients",
56        "androidx.concurrent_concurrent-futures",
57        "androidx.test.rules",
58        "compatibility-device-util-axt",
59        "mockito-target-extended-minus-junit4",
60        "truth",
61        "framework-adservices.impl",
62        "framework-sdksandbox.impl",
63        "adservices-test-fixtures",
64        "adservices-test-utility",
65    ],
66    libs: [
67        "android.test.base.stubs.system",
68        "android.ext.adservices",
69    ],
70    test_suites: [
71        "general-tests",
72    ],
73}
74
75android_test {
76    name: "AdExtServicesEndToEndTests",
77    defaults: ["AdExtServices-EndToEndTests-Defaults"],
78    srcs: [
79        "src/**/*.java",
80    ],
81    min_sdk_version: "31",
82    max_sdk_version: "32",
83    test_config: "AndroidTest.ExtServices.xml",
84    manifest: "AndroidManifestExtServices.xml",
85    lint: {
86        extra_check_modules: ["AdServicesTestLintChecker"],
87        baseline_filename: "lint-baseline-adextservices.xml",
88        test: false, // TODO(b/343741206): remove when checks will run on android_test
89    },
90}
91
92android_test {
93    name: "AdExtServicesRvcEndToEndTests",
94    defaults: ["AdExtServices-EndToEndTests-Defaults"],
95    srcs: [
96        "src/com/android/adservices/measurement/MeasurementManagerRvcTest.java",
97        "src/com/android/adservices/measurement/MeasurementManagerUtil.java",
98        "src/com/android/adservices/AdServicesEndToEndTestCase.java",
99    ],
100    min_sdk_version: "30",
101    max_sdk_version: "30",
102    test_config: "AndroidTest.ExtServicesRvc.xml",
103    manifest: "AndroidManifestExtServicesRvc.xml",
104    lint: {
105        extra_check_modules: ["AdServicesTestLintChecker"],
106        test: false, // TODO(b/343741206): remove when checks will run on android_test
107    },
108}
109