Skip to content

Commit

Permalink
ci: add clearer breakdown of test stages and dependencies between jobs (
Browse files Browse the repository at this point in the history
  • Loading branch information
brettlangdon authored Dec 16, 2024
1 parent 62766b0 commit 6de35c8
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 5 deletions.
11 changes: 7 additions & 4 deletions .gitlab/tests.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
stages:
- tests
- precheck
- hatch
- riot

variables:
RIOT_RUN_CMD: riot -P -v run --exitfirst --pass-env -s
Expand All @@ -22,7 +24,7 @@ variables:

.test_base_hatch:
extends: .testrunner
stage: tests
stage: hatch
# Hatch doesn't use pre-built wheels or venvs so we can start them right away
needs: []
parallel: 4
Expand Down Expand Up @@ -57,7 +59,7 @@ variables:

build_base_venvs:
extends: .testrunner
stage: tests
stage: riot
parallel:
matrix:
- PYTHON_VERSION: ["3.7", "3.8", "3.9", "3.10", "3.11", "3.12"]
Expand All @@ -76,9 +78,10 @@ build_base_venvs:
- ddtrace/internal/datadog/profiling/crashtracker/crashtracker_exe*
- ddtrace/internal/datadog/profiling/test/test_*

# Do not define a `needs:` in order to depend on the whole `precheck` stage
.test_base_riot:
extends: .testrunner
stage: tests
stage: riot
needs: [ build_base_venvs ]
parallel: 4
services:
Expand Down
2 changes: 1 addition & 1 deletion scripts/gen_gitlab_config.py
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@ def check(name: str, command: str, paths: t.Set[str]) -> None:
with TESTS_GEN.open("a") as f:
print(f'"{name}":', file=f)
print(" extends: .testrunner", file=f)
print(" stage: tests", file=f)
print(" stage: precheck", file=f)
print(" needs: []", file=f)
print(" script:", file=f)
print(f" - {command}", file=f)
Expand Down

0 comments on commit 6de35c8

Please sign in to comment.