-
Notifications
You must be signed in to change notification settings - Fork 4.1k
/
postsubmit.yml
326 lines (326 loc) · 12.7 KB
/
postsubmit.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
---
tasks:
centos7_java11_devtoolset10:
shell_commands:
- sed -i.bak -e 's/^# android_sdk_repository/android_sdk_repository/' -e 's/^#
android_ndk_repository/android_ndk_repository/' WORKSPACE
- rm -f WORKSPACE.bak
- rm -rf $HOME/bazeltest
- mkdir $HOME/bazeltest
build_flags:
- "--test_env=TEST_INSTALL_BASE=$HOME/bazeltest/install_base"
- "--test_env=TEST_REPOSITORY_HOME=$OUTPUT_BASE/external"
- "--noremote_accept_cached"
build_targets:
- "//:bazel-distfile.zip"
- "//scripts/packages/debian:bazel-debian.deb"
- "//scripts/packages:with-jdk/install.sh"
- "//src:bazel"
- "//src:bazel_jdk_minimal"
- "//src:test_repos"
- "//src/main/java/..."
test_flags:
- "--sandbox_default_allow_network=false"
- "--sandbox_writable_path=$HOME/bazeltest"
- "--test_env=TEST_INSTALL_BASE=$HOME/bazeltest/install_base"
- "--test_env=TEST_REPOSITORY_HOME=$OUTPUT_BASE/external"
test_targets:
- "//scripts/..."
- "//src/java_tools/..."
- "//src/test/..."
- "//src/tools/execlog/..."
- "//src/tools/singlejar/..."
- "//src/tools/workspacelog/..."
- "//third_party/ijar/..."
- "//tools/android/..."
- "//tools/aquery_differ/..."
- "//tools/python/..."
# Re-enable once fixed: https://github.com/bazelbuild/bazel/issues/8162
- "-//src/java_tools/buildjar/..."
- "-//src/java_tools/import_deps_checker/..."
# These tests are not compatible with the gcov version of CentOS 7.
- "-//src/test/shell/bazel:bazel_cc_code_coverage_test"
- "-//src/test/shell/bazel:bazel_coverage_cc_released_test_gcc"
- "-//src/test/shell/bazel:bazel_coverage_cc_head_test_gcc"
- "-//src/test/shell/bazel:bazel_coverage_sh_test"
include_json_profile:
- build
- test
ubuntu1804:
shell_commands:
- sed -i.bak -e 's/^# android_sdk_repository/android_sdk_repository/' -e 's/^#
android_ndk_repository/android_ndk_repository/' WORKSPACE
- rm -f WORKSPACE.bak
- rm -rf $HOME/bazeltest
- mkdir $HOME/bazeltest
build_flags:
- "--test_env=TEST_INSTALL_BASE=$HOME/bazeltest/install_base"
- "--test_env=TEST_REPOSITORY_HOME=$OUTPUT_BASE/external"
- "--test_env=REMOTE_NETWORK_ADDRESS=bazel.build:80"
- "--noremote_accept_cached"
build_targets:
- "//src:bazel"
- "//src:bazel_jdk_minimal"
- "//src:test_repos"
- "//src/main/java/..."
test_flags:
- "--sandbox_default_allow_network=false"
- "--sandbox_writable_path=$HOME/bazeltest"
- "--test_env=TEST_INSTALL_BASE=$HOME/bazeltest/install_base"
- "--test_env=TEST_REPOSITORY_HOME=$OUTPUT_BASE/external"
# Configure and enable tests that require access to the network.
- "--test_env=REMOTE_NETWORK_ADDRESS=bazel.build:80"
test_targets:
- "//scripts/..."
- "//src/java_tools/..."
- "//src/test/..."
- "//src/tools/execlog/..."
- "//src/tools/singlejar/..."
- "//src/tools/workspacelog/..."
- "//third_party/ijar/..."
- "//tools/android/..."
- "//tools/aquery_differ/..."
- "//tools/python/..."
# Re-enable once fixed: https://github.com/bazelbuild/bazel/issues/8162
- "-//src/java_tools/import_deps_checker/..."
include_json_profile:
- build
- test
ubuntu1804_clang:
platform: ubuntu1804
environment:
CC: clang
CC_CONFIGURE_DEBUG: 1
name: "Clang"
shell_commands:
- sed -i.bak -e 's/^# android_sdk_repository/android_sdk_repository/' -e 's/^#
android_ndk_repository/android_ndk_repository/' WORKSPACE
- rm -f WORKSPACE.bak
- rm -rf $HOME/bazeltest
- mkdir $HOME/bazeltest
build_flags:
- "--test_env=TEST_INSTALL_BASE=$HOME/bazeltest/install_base"
- "--test_env=TEST_REPOSITORY_HOME=$OUTPUT_BASE/external"
- "--noremote_accept_cached"
build_targets:
- "//src:bazel"
- "//src:bazel_jdk_minimal"
- "//src:test_repos"
- "//src/main/java/..."
test_flags:
- "--sandbox_default_allow_network=false"
- "--sandbox_writable_path=$HOME/bazeltest"
- "--test_env=TEST_INSTALL_BASE=$HOME/bazeltest/install_base"
- "--test_env=TEST_REPOSITORY_HOME=$OUTPUT_BASE/external"
test_targets:
- "//src/test/shell/bazel:cc_integration_test"
include_json_profile:
- build
- test
ubuntu2004:
shell_commands:
- sed -i.bak -e 's/^# android_sdk_repository/android_sdk_repository/' -e 's/^#
android_ndk_repository/android_ndk_repository/' WORKSPACE
- rm -f WORKSPACE.bak
- rm -rf $HOME/bazeltest
- mkdir $HOME/bazeltest
build_flags:
- "--test_env=TEST_INSTALL_BASE=$HOME/bazeltest/install_base"
- "--test_env=TEST_REPOSITORY_HOME=$OUTPUT_BASE/external"
- "--test_env=REMOTE_NETWORK_ADDRESS=bazel.build:80"
- "--noremote_accept_cached"
build_targets:
- "//src:bazel"
- "//src:bazel_jdk_minimal"
- "//src:test_repos"
- "//src/main/java/..."
test_flags:
- "--sandbox_default_allow_network=false"
- "--sandbox_writable_path=$HOME/bazeltest"
- "--test_env=TEST_INSTALL_BASE=$HOME/bazeltest/install_base"
- "--test_env=TEST_REPOSITORY_HOME=$OUTPUT_BASE/external"
# Configure and enable tests that require access to the network.
- "--test_env=REMOTE_NETWORK_ADDRESS=bazel.build:80"
test_targets:
- "//scripts/..."
- "//src/java_tools/..."
- "//src/test/..."
- "//src/tools/execlog/..."
- "//src/tools/singlejar/..."
- "//src/tools/workspacelog/..."
- "//third_party/ijar/..."
- "//tools/android/..."
- "//tools/aquery_differ/..."
- "//tools/python/..."
# Re-enable once fixed: https://github.com/bazelbuild/bazel/issues/8162
- "-//src/java_tools/import_deps_checker/..."
include_json_profile:
- build
- test
macos:
xcode_version: "13.0"
shell_commands:
- sed -i.bak -e 's/^# android_sdk_repository/android_sdk_repository/' -e 's/^#
android_ndk_repository/android_ndk_repository/' WORKSPACE
- rm -f WORKSPACE.bak
- rm -rf $HOME/bazeltest
- mkdir $HOME/bazeltest
- ln -sf $OUTPUT_BASE/external $HOME/bazeltest/external
build_flags:
- "--test_env=TEST_INSTALL_BASE=$HOME/bazeltest/install_base"
- "--test_env=TEST_REPOSITORY_HOME=$OUTPUT_BASE/external"
- "--test_env=TEST_REPOSITORY_HOME=$HOME/bazeltest/external"
- "--test_env=REMOTE_NETWORK_ADDRESS=bazel.build:80"
- "--noremote_accept_cached"
build_targets:
- "//src:bazel"
- "//src:bazel_jdk_minimal"
- "//src:test_repos"
- "//src/main/java/..."
test_flags:
- "--sandbox_default_allow_network=false"
- "--sandbox_writable_path=$HOME/bazeltest"
- "--test_env=TEST_INSTALL_BASE=$HOME/bazeltest/install_base"
- "--test_env=TEST_REPOSITORY_HOME=$HOME/bazeltest/external"
# Configure and enable tests that require access to the network.
- "--test_env=REMOTE_NETWORK_ADDRESS=bazel.build:80"
test_targets:
- "//scripts/..."
- "//src/test/..."
- "//src/tools/execlog/..."
- "//src/tools/singlejar/..."
- "//src/tools/workspacelog/..."
- "//third_party/ijar/..."
- "//tools/android/..."
- "//tools/aquery_differ/..."
- "//tools/osx/crosstool/..."
- "//tools/python/..."
# C++ coverage is not supported on macOS yet.
- "-//src/test/shell/bazel:bazel_cc_code_coverage_test"
# MacOS does not have cgroups so it can't support hardened sandbox
- "-//src/test/shell/integration:bazel_hardened_sandboxed_worker_test"
include_json_profile:
- build
- test
windows:
batch_commands:
- powershell -Command "(Get-Content WORKSPACE) -Replace '# android_', 'android_' | Set-Content WORKSPACE"
- mkdir C:\b
- mklink /J C:\b\bazeltest_external %OUTPUT_BASE:/=\%\external
build_flags:
- "--copt=-w"
- "--host_copt=-w"
- "--test_env=JAVA_HOME"
- "--test_env=TEST_INSTALL_BASE=$HOME/bazeltest_install_base"
- "--test_env=TEST_REPOSITORY_HOME=C:/b/bazeltest_external"
- "--noremote_accept_cached"
build_targets:
- "//src:bazel.exe"
- "//src:bazel_jdk_minimal"
- "//src:test_repos"
- "//src/main/java/..."
test_flags:
- "--copt=-w"
- "--host_copt=-w"
- "--test_tag_filters=-no_windows,-slow"
- "--test_env=JAVA_HOME"
- "--test_env=TEST_INSTALL_BASE=$HOME/bazeltest_install_base"
- "--test_env=TEST_REPOSITORY_HOME=C:/b/bazeltest_external"
test_targets:
- "//src:embedded_tools_size_test"
- "//src/test/cpp/..."
- "//src/test/java/com/google/devtools/build/android/..."
- "//src/test/java/com/google/devtools/build/lib/..."
- "//src/test/java/com/google/devtools/build/skyframe/..."
- "//src/test/java/com/google/devtools/common/options/..."
- "//src/test/native/windows/..."
- "//src/test/py/bazel/..."
- "//src/test/res/..."
- "//src/test/shell/..."
- "//src/tools/launcher/..."
- "//src/tools/singlejar/..."
- "//third_party/def_parser/..."
- "//tools/android/..."
- "//tools/aquery_differ/..."
- "//tools/bash/..."
- "//tools/build_defs/..."
- "//tools/cpp/runfiles/..."
- "//tools/java/..."
- "//tools/jdk/..."
- "//tools/python/..."
- "//tools/test/..."
# Re-enable the following tests on Windows:
# https://github.com/bazelbuild/bazel/issues/4292
- "-//src/test/java/com/google/devtools/build/android/r8/..."
- "-//src/test/java/com/google/devtools/build/lib/query2/cquery/..."
- "-//src/test/java/com/google/devtools/build/lib/query2/engine/..."
- "-//src/test/java/com/google/devtools/build/lib/versioning/..."
- "-//src/test/java/com/google/devtools/build/lib/rules/java/..."
- "-//src/test/java/com/google/devtools/build/lib/worker/..."
- "-//src/test/java/com/google/devtools/build/lib/remote:remote"
- "-//src/test/shell/bazel/remote/..."
- "-//tools/python:pywrapper_test"
include_json_profile:
- build
- test
rbe_ubuntu1804:
platform: ubuntu1804
shell_commands:
- sed -i.bak
-e 's/^# android_sdk_repository/android_sdk_repository/'
-e 's/^# android_ndk_repository/android_ndk_repository/' WORKSPACE
- rm -f WORKSPACE.bak
build_flags:
- "--config=ubuntu1804_java11"
- "--remote_executor=grpcs://remotebuildexecution.googleapis.com"
- "--jobs=200"
- "--experimental_remote_download_outputs=minimal"
- "--experimental_inmemory_jdeps_files"
- "--experimental_inmemory_dotd_files"
build_targets:
- "//src:bazel"
- "//src:bazel_jdk_minimal"
- "//src/main/java/..."
test_flags:
- "--config=ubuntu1804_java11"
- "--remote_executor=grpcs://remotebuildexecution.googleapis.com"
- "--jobs=200"
- "--experimental_remote_download_outputs=minimal"
- "--experimental_inmemory_jdeps_files"
- "--experimental_inmemory_dotd_files"
test_targets:
- "//scripts/..."
- "//src/java_tools/..."
- "//src/test/..."
- "//src/tools/execlog/..."
- "//src/tools/singlejar/..."
- "//src/tools/workspacelog/..."
- "//third_party/ijar/..."
- "//tools/aquery_differ/..."
- "//tools/python/..."
- "//tools/android/..."
# See https://github.com/bazelbuild/bazel/issues/8033
- "-//src/tools/singlejar:output_jar_simple_test"
- "-//src/test/shell/bazel:external_integration_test"
- "-//src/test/shell/bazel:bazel_repository_cache_test"
- "-//src/test/shell/integration:java_integration_test"
- "-//src/test/java/com/google/devtools/build/lib/sandbox/..."
# See https://github.com/bazelbuild/bazel/issues/8162 (also disabled for local exec)
- "-//src/java_tools/buildjar/..."
- "-//src/java_tools/import_deps_checker/..."
# We hit connection timeout error when downloading multiple URLs on RBE, see b/217865760
- "-//src/test/py/bazel:bazel_module_test"
- "-//src/test/shell/bazel:verify_workspace"
include_json_profile:
- build
- test
kythe_ubuntu2004:
shell_commands:
- sed -i.bak -e 's/^# android_sdk_repository/android_sdk_repository/'
-e 's/^# android_ndk_repository/android_ndk_repository/' WORKSPACE
- rm -f WORKSPACE.bak
index_flags:
- "--define=kythe_corpus=github.com/bazelbuild/bazel"
index_targets_query: "kind(\"cc_(binary|library|test|proto_library) rule\", ...) union kind(\"java_(binary|import|library|plugin|test|proto_library) rule\", ...) union kind(\"proto_library rule\", ...)"
index_upload_policy: Always
index_upload_gcs: True