A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://github.com/sshelll/gott below:

GitHub - sshelll/gott: Alternatives to ‘go test’, this is an amazing tool to run

Go test tool with terminal UI.

Gott v2 is published!

Now You can use gott to parse go test files and get the test name from the gott output instead of exec it!

For example:

go test -v -test.run $(gott -print -file=/aa/bb/xx_test.go)

Please check v2/help.txt for more information.

Use go install github.com/sshelll/gott/v2@latest to get it!

go version >= 1.17, clone this repo and exec go build . should be ok,or you can exec the command below:

go install github.com/sshelll/gott@latest

go version <= 1.16, go to Release page and download the executable file(MacOS Only, I'm lazy...)

Use gott instead of go test

Or you can exec gott -p to get the test name, in this way you won't run go test

For example:

go test -v => gott -v

go test -v -race => gott -v -race

go test -gcflags="all=-l -N" => gott -gcflags=\"all=-l -N\"

go test -gcflags=all=-l -race -coverprofile=coverage.out => gott \"all=-l -N\" -race -coverprofile=coverage.out

gott -p => you will get a go test func name

Use the script below to debug a test with dlv:

#!/bin/zsh

fn=$(gott -p)

if [ ! $fn ]; then exit 0; fi

dlv test --build-flags=-test.run $fn

Use gott -h to get more details


RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4