Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 6 additions & 1 deletion .github/workflows/release-test-tools.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -59,10 +59,15 @@ jobs:
password: ${{ secrets.GITHUB_TOKEN }}

- name: Build and push multi-arch test-tools image
# This workflow runs inside the template repo, not a downstream
# consumer, so the Dockerfile lives at `dockerfile/...`, not
# `template/dockerfile/...` (the latter is only the subtree path
# downstream repos see and is what build-worker.yaml uses since
# that workflow executes in the downstream's checkout).
uses: docker/build-push-action@v6
with:
context: .
file: template/dockerfile/Dockerfile.test-tools
file: dockerfile/Dockerfile.test-tools
platforms: linux/amd64,linux/arm64
tags: ${{ steps.tags.outputs.tags }}
push: true
5 changes: 3 additions & 2 deletions doc/test/TEST.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# TEST.md

Template self-tests: **663 tests** total (620 unit + 43 integration).
Template self-tests: **664 tests** total (621 unit + 43 integration).

## Test Files

Expand Down Expand Up @@ -181,7 +181,7 @@ conditional GPU deploy block + GUI env/volumes + extra volumes from
| `empty extras => no extra mount lines` | empty list |
| `with GUI+GPU+extras => all sections present` | fully loaded |

### test/unit/template_spec.bats (114)
### test/unit/template_spec.bats (115)

| Test | Description |
|------|-------------|
Expand Down Expand Up @@ -289,6 +289,7 @@ conditional GPU deploy block + GUI env/volumes + extra volumes from
| `release-test-tools.yaml exists and pushes to ghcr.io/ycpss91255-docker/test-tools` | GHCR publisher |
| `release-test-tools.yaml declares packages:write permission` | ghcr auth scope |
| `release-test-tools.yaml builds multi-arch (amd64 + arm64)` | arch coverage |
| `release-test-tools.yaml uses template-repo-local Dockerfile path` | no subtree path confusion |
| `run.sh contains XDG_SESSION_TYPE check` | X11/Wayland branch |
| `run.sh contains xhost +SI:localuser for wayland` | Wayland xhost |
| `run.sh contains xhost +local: for X11` | X11 xhost |
Expand Down
13 changes: 13 additions & 0 deletions test/unit/template_spec.bats
Original file line number Diff line number Diff line change
Expand Up @@ -797,6 +797,19 @@ EOF
assert_success
}

@test "release-test-tools.yaml uses template-repo-local Dockerfile path" {
# Regression: this workflow runs in the template repo, so Dockerfile.test-tools
# path must be `dockerfile/...` (not `template/dockerfile/...` which is the
# downstream subtree path used by build-worker.yaml).
local _yaml="/source/.github/workflows/release-test-tools.yaml"
[[ -f "${_yaml}" ]] || skip "release-test-tools.yaml not present in /source"
run grep -E '^\s*file: dockerfile/Dockerfile\.test-tools$' "${_yaml}"
assert_success
# And must NOT have the subtree-prefixed path:
run grep -c 'file: template/dockerfile/Dockerfile.test-tools' "${_yaml}"
assert_output "0"
}

# ════════════════════════════════════════════════════════════════════
# run.sh: XDG_SESSION_TYPE branching
# ════════════════════════════════════════════════════════════════════
Expand Down
Loading