File tree Expand file tree Collapse file tree 1 file changed +15
-1
lines changed Expand file tree Collapse file tree 1 file changed +15
-1
lines changed Original file line number Diff line number Diff line change 628628 } ;
629629 } ;
630630 } ;
631+ gotest = mkOption {
632+ description = "gotest hook" ;
633+ type = types . submodule {
634+ imports = [ hookModule ] ;
635+ options . settings = {
636+ flags = mkOption {
637+ type = types . str ;
638+ description = "Flags passed to gotest. See all available [here](https://pkg.go.dev/cmd/go#hdr-Test_packages)." ;
639+ default = "" ;
640+ example = "-tags integration" ;
641+ } ;
642+ } ;
643+ } ;
644+ } ;
631645 headache = mkOption {
632646 description = "headache hook" ;
633647 type = types . submodule {
@@ -2898,7 +2912,7 @@ lib.escapeShellArgs (lib.concatMap (ext: [ "--ghc-opt" "-X${ext}" ]) hooks.fourm
28982912
28992913 # test each directory one by one
29002914 for dir in "'' ${sorted_dirs[@]}"; do
2901- ${ hooks . gotest . package } /bin/go test "./$dir"
2915+ ${ hooks . gotest . package } /bin/go test ${ hooks . gotest . settings . flags } "./$dir"
29022916 done
29032917 '' ;
29042918 in
You can’t perform that action at this time.
0 commit comments