check / check (push) Failing after 1s
The test and format scripts regenerated mfer/mf.pb.go whenever mfer/mf.proto looked newer by mtime, which a fresh checkout often causes, so make check could rewrite a committed file and needed protoc. Nothing regenerates it any more except make generate (script/generate), which refuses to run unless protoc 33.4 and protoc-gen-go v1.36.11, the versions that wrote the committed file, are on PATH, and records the hash of mf.proto in mfer/mf.proto.sha256. A Go test compares that hash with mf.proto and fails, naming make generate, when they differ. The mtime rule, the unused protoc-gen-go v1.28.1 install rule, make clean's deletion of mf.pb.go and the Dockerfile's touch workarounds are removed. Model: opus-5-5
18 lines
327 B
Bash
Executable File
18 lines
327 B
Bash
Executable File
#!/bin/sh
|
|
# script/test: run the test suite.
|
|
set -eu
|
|
|
|
ROOT="$(cd "$(dirname "$0")/.." && pwd -P)"
|
|
|
|
main() {
|
|
cd "$ROOT"
|
|
go test -timeout 30s -race -cover ./... ||
|
|
{
|
|
echo "--- Rerunning with -v for details ---"
|
|
go test -timeout 30s -race -v ./...
|
|
exit 1
|
|
}
|
|
}
|
|
|
|
main "$@"
|