Sfoglia il codice sorgente

Use gotestsum in Lefthook when possible

DarthSim 6 mesi fa
parent
commit
bd548e00e8
1 ha cambiato i file con 5 aggiunte e 1 eliminazioni
  1. 5 1
      .lefthook/pre-push/test

+ 5 - 1
.lefthook/pre-push/test

@@ -10,4 +10,8 @@ fi
 export CGO_LDFLAGS_ALLOW="-s|-w"
 export CGO_CFLAGS_ALLOW="-Xpreprocessor"
 
-go test ./...
+if [ -x "$(which gotestsum)" ]; then
+  gotestsum ./...
+else
+  go test -v ./...
+fi