AGENTS.md documents 'Test unit: go test ./pkg/...' and 'E2E tests:
go test -tags e2e ./pkg/e2e/'. Both statements were false: no file in
pkg/e2e carried an e2e build constraint, so the -tags flag was a no-op
and the 'unit' command actually launched the full e2e suite — requiring
a Docker daemon and the locally built binary, creating and destroying
containers, for up to 20 minutes. CI only avoided this by grepping e2e
out of the package list (Dockerfile).
Every *_test.go in pkg/e2e now carries //go:build e2e (merged with the
existing !windows constraints), and the Makefile e2e targets pass the
tag. The documented commands become true:
- go test ./pkg/... -> pkg/e2e reports [no test files]
- go test -tags e2e ./pkg/e2e -> runs the suite
AGENTS.md now also states the daemon/binary prerequisites explicitly.
Part of #14074 (A: the code misdescribes its own structure).
Signed-off-by: Nicolas De Loof <nicolas.deloof@gmail.com>
- pull: the CLI's Pulled/Skipped report is the observable, so the five
scenarios (always-pull, present-locally, build-only, failure,
--ignore-pull-failures) legitimately match output; models are inline
and the whole compose-pull fixture tree — including the orphaned
duplicate-images directory no test referenced — is removed.
- networks: aliases, links, ipam, network_mode: service, subnet change,
mac_address and interface_name become scenarios. The subnet-change
scenario locks what actually happens: the network is replaced but the
container is reconnected, not recreated (NotRecreated), which the
legacy test never distinguished. TestNetworks (fixed host ports,
HTTP fixture services) and TestNetworkRecreate (OR-shaped output
assertion) stay legacy.
Signed-off-by: Nicolas De Loof <nicolas.deloof@gmail.com>
Format the code with gofumpt to prevent my IDE from reformatting
every time I open a file. gofumpt provides a superset of gofmt,
so should not impact users that are not using gofumpt.
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>