.dockerignore keeps root test binaries and coverage out (closes #155) #183

Merged
clawbot merged 1 commits from issue-155-dockerignore-test-coverage into next 2026-10-19 07:42:44 +02:00
Collaborator

Closes #155.

.dockerignore gains /*.test and /*.out in the repository's own section, after the shared content, and its comment there names them. A Go test binary or coverage file left at the repository root, which .gitignore already ignores, went into the build context of every docker build in script/ and was copied into the lint, test and build stages, where the existing-repo checklist asks that such files be kept out.

Checked by enumerating a probe image, as REPO_POLICIES.md asks: a Dockerfile that copies the whole context, built once with the old .dockerignore and once with the new, with x.test and x.out planted at the root and two directories down. The two listings differ only in the root x.test and x.out, which the new one no longer has. The probe images and planted files are removed.

Judgement call: the entries match only at the root, as the issue and the checklist ask, so the same files in a subdirectory still reach the image (the probe shows this). The Go module is at the root, where go test -c and -coverprofile write when run from there.

Model: opus-5-5

Closes https://git.eeqj.de/sneak/netwatch/issues/155. `.dockerignore` gains `/*.test` and `/*.out` in the repository's own section, after the shared content, and its comment there names them. A Go test binary or coverage file left at the repository root, which `.gitignore` already ignores, went into the build context of every `docker build` in `script/` and was copied into the lint, test and build stages, where the existing-repo checklist asks that such files be kept out. Checked by enumerating a probe image, as `REPO_POLICIES.md` asks: a Dockerfile that copies the whole context, built once with the old `.dockerignore` and once with the new, with `x.test` and `x.out` planted at the root and two directories down. The two listings differ only in the root `x.test` and `x.out`, which the new one no longer has. The probe images and planted files are removed. Judgement call: the entries match only at the root, as the issue and the checklist ask, so the same files in a subdirectory still reach the image (the probe shows this). The Go module is at the root, where `go test -c` and `-coverprofile` write when run from there. Model: opus-5-5
clawbot added the needs-review label 2026-10-19 07:35:51 +02:00
clawbot self-assigned this 2026-10-19 07:35:52 +02:00
clawbot added 1 commit 2026-10-19 07:35:52 +02:00
A Go test binary or coverage file left at the repository root, which
.gitignore already ignores, went into the build context of every docker
build in script/ and was copied into the lint, test and build stages.
The repository's own section of .dockerignore now lists /*.test and
/*.out, root-anchored like its other entries.

Checked with a probe image that copies the whole context: x.test and
x.out planted at the root are no longer in it, and nothing else changed.

Model: opus-5-5
Author
Collaborator

Review passed.

Model: opus-5-5

Review passed. Model: opus-5-5
clawbot merged commit a42a220bb7 into next 2026-10-19 07:42:44 +02:00
clawbot deleted branch issue-155-dockerignore-test-coverage 2026-10-19 07:42:44 +02:00
clawbot removed the needs-review label 2026-10-19 07:42:44 +02:00
Sign in to join this conversation.
No Reviewers
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: sneak/netwatch#183