3333 - dda inv -- -e gitlab.generate-ci-visibility-links --output=$EXTERNAL_LINKS_PATH
3434
3535bazel:test:linux-amd64 :
36- extends : [ .bazel:test:reporting, .bazel:runner:linux-amd64, .bazel:test ]
36+ extends : [.bazel:test:reporting, .bazel:runner:linux-amd64, .bazel:test]
3737 script :
3838 - !reference [.bazel:test:reporting:ci_links]
39- - bazel test --jobs=$KUBERNETES_CPU_REQUEST --keep_going --remote_download_outputs=toplevel --build_event_json_file=$BEP_FILE --config=no-dd-agent-go-tests //...
39+ - bazel test --config=gorace -- jobs=$KUBERNETES_CPU_REQUEST --keep_going --remote_download_outputs=toplevel --build_event_json_file=$BEP_FILE //...
4040
4141bazel:test:linux-arm64 :
42- extends : [ .bazel:test:reporting, .bazel:runner:linux-arm64, .bazel:test ]
42+ extends : [.bazel:test:reporting, .bazel:runner:linux-arm64, .bazel:test]
4343 script :
4444 - !reference [.bazel:test:reporting:ci_links]
45- - bazel test --jobs=$KUBERNETES_CPU_REQUEST --keep_going --remote_download_outputs=toplevel --build_event_json_file=$BEP_FILE --config=no-dd-agent-go-tests //...
45+ - bazel test --config=gorace -- jobs=$KUBERNETES_CPU_REQUEST --keep_going --remote_download_outputs=toplevel --build_event_json_file=$BEP_FILE //...
4646
4747bazel:test:macos-amd64 :
48- extends : [ .bazel:test:reporting, .bazel:runner:macos-amd64, .bazel:test ]
48+ extends : [.bazel:test:reporting, .bazel:runner:macos-amd64, .bazel:test]
4949 script :
5050 - !reference [.install_python_dependencies]
5151 - !reference [.bazel:test:reporting:ci_links]
52- - bazel test --keep_going --remote_download_outputs=toplevel --build_event_json_file=$BEP_FILE --config=no-dd-agent-go-tests //...
52+ - bazel test --config=gorace -- keep_going --remote_download_outputs=toplevel --build_event_json_file=$BEP_FILE //...
5353 after_script :
5454 - !reference [.install_python_dependencies]
5555 - !reference [.bazel:test:reporting, after_script]
5656
5757bazel:test:macos-arm64 :
58- extends : [ .bazel:test:reporting, .bazel:runner:macos-arm64, .bazel:test ]
58+ extends : [.bazel:test:reporting, .bazel:runner:macos-arm64, .bazel:test]
5959 script :
6060 - !reference [.install_python_dependencies]
6161 - !reference [.bazel:test:reporting:ci_links]
62- - bazel test --keep_going --remote_download_outputs=toplevel --build_event_json_file=$BEP_FILE --execution_log_compact_file=$CI_PROJECT_DIR/bazel-exec.log --config=no-dd-agent-go-tests //...
62+ - bazel test --config=gorace -- keep_going --remote_download_outputs=toplevel --build_event_json_file=$BEP_FILE --execution_log_compact_file=$CI_PROJECT_DIR/bazel-exec.log //...
6363 after_script :
6464 - !reference [.install_python_dependencies]
6565 - !reference [.bazel:test:reporting, after_script]
@@ -69,112 +69,22 @@ bazel:test:macos-arm64:
6969 - bazel-bep-*.json
7070 - bazel-exec.log
7171
72+ # Windows splits the build from the Go tests, unlike the other platforms: the
73+ # runner has 16 CPUs, and compiling the rest of the repo alongside ~1k
74+ # race-instrumented tests starves them enough that tests waiting on wall-clock
75+ # time fail. This job covers everything but the Go tests.
7276bazel:test:windows-amd64 :
73- extends : [ .bazel:runner:windows-amd64, .bazel:test ]
77+ extends : [.bazel:runner:windows-amd64, .bazel:test]
7478 variables :
7579 POWERSHELL_SCRIPT : >-
76- bazel test --keep_going --config=no-dd-agent-go-tests
77- //... --
80+ bazel test --config=gorace --config=no-dd-agent-go-tests --keep_going //... --
7881 -//bazel/rules/dd_packaging/...
7982 -//packages/agent/linux/...
8083
81- # Per-flavor test jobs. Each runs the tests for one agent flavor, mirroring the
82- # dda inv test --flavor=<f> topology. --config=<flavor> sets
83- # --test_tag_filters=flavor_<flavor>, selecting only the matching go_test variants.
84- .bazel:test:flavor :
85- extends : [ .bazel:test, .bazel:test:reporting ]
86- script :
87- - DD_API_KEY=$($CI_PROJECT_DIR/tools/ci/fetch_secret.sh $AGENT_API_KEY_ORG2 token) || echo 'Failed to fetch an API key, no metrics will be emitted'; export DD_API_KEY
88- - !reference [.bazel:test:reporting:ci_links]
89- - bazel test --keep_going --remote_download_outputs=toplevel --build_event_json_file=$BEP_FILE --build_tests_only --config=$FLAVOR //pkg/... //comp/... //cmd/...
90- - dda inv -- -e bazel.ensure-test-parity --bep $BEP_FILE --flavor-name $FLAVOR --emit-metrics
91-
92- # macOS flavor variant: re-installs dda in both script and after_script since
93- # macOS shell executors run each phase in a fresh shell.
94- .bazel:test:flavor:macos :
95- extends : .bazel:test:flavor
96- script :
97- - !reference [.install_python_dependencies]
98- - !reference [.bazel:test:flavor, script]
99- after_script :
100- - !reference [.install_python_dependencies]
101- - !reference [.bazel:test:reporting, after_script]
102-
103- bazel:test:linux-amd64:base :
104- extends : [ .bazel:runner:linux-amd64, .bazel:test:flavor ]
105- variables :
106- FLAVOR : base
107-
108- bazel:test:linux-amd64:dogstatsd :
109- extends : [ .bazel:runner:linux-amd64, .bazel:test:flavor ]
110- variables :
111- FLAVOR : dogstatsd
112-
113- bazel:test:linux-amd64:heroku :
114- extends : [ .bazel:runner:linux-amd64, .bazel:test:flavor ]
115- variables :
116- FLAVOR : heroku
117-
118- bazel:test:linux-amd64:iot :
119- extends : [ .bazel:runner:linux-amd64, .bazel:test:flavor ]
120- variables :
121- FLAVOR : iot
122-
123- bazel:test:linux-arm64:base :
124- extends : [ .bazel:runner:linux-arm64, .bazel:test:flavor ]
125- variables :
126- FLAVOR : base
127-
128- bazel:test:linux-arm64:dogstatsd :
129- extends : [ .bazel:runner:linux-arm64, .bazel:test:flavor ]
130- variables :
131- FLAVOR : dogstatsd
132-
133- bazel:test:linux-arm64:heroku :
134- extends : [ .bazel:runner:linux-arm64, .bazel:test:flavor ]
135- variables :
136- FLAVOR : heroku
137-
138- bazel:test:linux-arm64:iot :
139- extends : [ .bazel:runner:linux-arm64, .bazel:test:flavor ]
140- variables :
141- FLAVOR : iot
142-
143- bazel:test:macos-amd64:base :
144- extends : [ .bazel:runner:macos-amd64, .bazel:test:flavor:macos ]
145- variables :
146- FLAVOR : base
147-
148- bazel:test:macos-amd64:dogstatsd :
149- extends : [ .bazel:runner:macos-amd64, .bazel:test:flavor:macos ]
150- variables :
151- FLAVOR : dogstatsd
152-
153- bazel:test:macos-arm64:base :
154- extends : [ .bazel:runner:macos-arm64, .bazel:test:flavor:macos ]
155- variables :
156- FLAVOR : base
157-
158- bazel:test:macos-arm64:dogstatsd :
159- extends : [ .bazel:runner:macos-arm64, .bazel:test:flavor:macos ]
160- variables :
161- FLAVOR : dogstatsd
162-
163- # Windows can't extend .bazel:test:flavor: the Windows runner template consumes
164- # POWERSHELL_SCRIPT instead of `script:`, and the test pattern needs to exclude
165- # Linux-only packaging targets.
166- bazel:test:windows-amd64:base :
167- extends : [ .bazel:runner:windows-amd64, .bazel:test ]
84+ bazel:test:windows-amd64:go :
85+ extends : [.bazel:runner:windows-amd64, .bazel:test]
16886 variables :
16987 POWERSHELL_SCRIPT : >-
170- bazel test --keep_going --build_tests_only --config=base
171- --build_event_json_file=$CI_PROJECT_DIR/bazel-bep-base.json
172- //pkg/... //comp/... //cmd/...;
173- dda inv -- -e bazel.ensure-test-parity
174- --bep $CI_PROJECT_DIR/bazel-bep-base.json
175- --flavor-name base
176- artifacts :
177- when : always
178- paths :
179- - bazel-bep-*.json
180- expire_in : 1 week
88+ bazel test --config=gorace --config=dd-agent-go-tests-only --build_tests_only --keep_going //... --
89+ -//bazel/rules/dd_packaging/...
90+ -//packages/agent/linux/...
0 commit comments