blob: 066b83fb2dd233ce14245a875a5f8d538822ece8 [file] [log] [blame]
Luca Farsidb136442024-03-26 10:55:21 -07001// Copyright 2024 Google Inc. All rights reserved.
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
19python_test_host {
20 name: "build_test_suites_test",
21 main: "build_test_suites_test.py",
22 pkg_path: "testdata",
23 srcs: [
24 "build_test_suites_test.py",
25 ],
26 libs: [
27 "build_test_suites",
28 "pyfakefs",
29 "ci_test_lib",
30 ],
31 test_options: {
32 unit_test: true,
33 },
34 data: [
35 ":py3-cmd",
36 ],
37 version: {
38 py3: {
39 embedded_launcher: true,
40 },
41 },
42}
43
44// This test is only intended to be run locally since it's slow, not hermetic,
45// and requires a lot of system state. It is therefore not marked as `unit_test`
46// and is not part of any test suite. Note that we also don't want to run this
47// test with Bazel since that would require disabling sandboxing and explicitly
48// passing in all the env vars we depend on via the command-line. The test
49// target could be configured to do so but it's not worth doing seeing that
50// we're moving away from Bazel.
51python_test_host {
52 name: "build_test_suites_local_test",
53 main: "build_test_suites_local_test.py",
54 srcs: [
55 "build_test_suites_local_test.py",
56 ],
57 libs: [
58 "build_test_suites",
59 "pyfakefs",
60 "ci_test_lib",
61 ],
62 test_config_template: "AndroidTest.xml.template",
63 test_options: {
64 unit_test: false,
65 },
66 version: {
67 py3: {
68 embedded_launcher: true,
69 },
70 },
71}
72
73python_library_host {
74 name: "build_test_suites",
75 srcs: [
76 "build_test_suites.py",
77 ],
78}
79
80python_library_host {
81 name: "ci_test_lib",
82 srcs: [
83 "ci_test_lib.py",
84 ],
85}