From 6b5fd0393b5aeeb7de08c3d5088c5b7adb251de0 Mon Sep 17 00:00:00 2001 From: xBlaz3kx Date: Sun, 7 Dec 2025 12:58:01 +0100 Subject: [PATCH] chore: run tests with race checks only on linux & darwin --- Makefile | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/Makefile b/Makefile index 278bb91edc..9169261142 100644 --- a/Makefile +++ b/Makefile @@ -80,7 +80,14 @@ test-ui:: test:: @echo "Running testsuite" - CGO_ENABLED=0 go test $(BUILD_TAGS) ./... + @OS=$$(go env GOOS); \ + if [ "$$OS" = "linux" ]; then \ + CGO_ENABLED=1 go test -race $(BUILD_TAGS) ./...; \ + elif [ "$$OS" = "darwin" ]; then \ + CGO_ENABLED=0 go test -race $(BUILD_TAGS) ./...; \ + else \ + CGO_ENABLED=0 go test $(BUILD_TAGS) ./...; \ + fi porcelain:: gofmt -w -l $$(find . -name '*.go')