Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add tags support #23

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,8 @@ Flags:
sent as short argument to go test
-timeout string
sent as timeout argument to go test
-tags string
sent as tags argument to go test
-v sent as v argument to go test
```

Expand Down
5 changes: 5 additions & 0 deletions main.go
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ var (
cpu string
parallel string
timeout string
tags string
short bool
v bool
x bool
Expand All @@ -38,6 +39,7 @@ func init() {
flag.StringVar(&cpu, "cpu", "", "sent as cpu argument to go test")
flag.StringVar(&parallel, "parallel", "", "sent as parallel argument to go test")
flag.StringVar(&timeout, "timeout", "", "sent as timeout argument to go test")
flag.StringVar(&tags, "tags", "", "sent as tags argument to go test")
flag.BoolVar(&short, "short", false, "sent as short argument to go test")
flag.BoolVar(&v, "v", false, "sent as v argument to go test")
flag.BoolVar(&x, "x", false, "sent as x argument to go test")
Expand Down Expand Up @@ -143,6 +145,9 @@ func buildOptionalTestArgs(coverpkg, covermode, cpu, parallel, timeout string, s
if timeout != "" {
args = append(args, "-timeout", timeout)
}
if tags != "" {
args = append(args, "-tags", tags)
}
if short {
args = append(args, "-short")
}
Expand Down