File tree Expand file tree Collapse file tree 1 file changed +8
-3
lines changed
Expand file tree Collapse file tree 1 file changed +8
-3
lines changed Original file line number Diff line number Diff line change @@ -23,13 +23,18 @@ docker run --rm -e MODBUS_UPSTREAM=192.168.1.100:502 -e LOG_LEVEL=DEBUG mbproxy
2323## Testing
2424
2525``` bash
26- # Run all tests
26+ # Run all tests with race detector (uses full golang image)
2727docker build --target test .
2828
29- # Or run tests interactively
30- docker run --rm -v $( pwd) :/app -w /app golang:1.24 go test ./...
29+ # Or run tests interactively (without race detector in alpine)
30+ docker run --rm -v $( pwd) :/app -w /app golang:1.24 go test -v ./...
31+
32+ # With race detector (requires full golang image, not alpine)
33+ docker run --rm -v $( pwd) :/app -w /app golang:1.24 go test -v -race ./...
3134```
3235
36+ Note: Race detector requires CGO, which is not available in alpine images. The Dockerfile test stage uses the full golang image for this reason.
37+
3338## Code Style
3439
3540- Run ` go fmt ` on all code before committing
You can’t perform that action at this time.
0 commit comments