Skip to content

Commit 3af20c0

Browse files
committed
cmd/go: document test -json
Added in CL 76873 but forgot to add the flag docs. Change-Id: I448f85cc8cf51399c0d799691226b94f88f327da Reviewed-on: https://go-review.googlesource.com/77030 Run-TryBot: Russ Cox <[email protected]> Reviewed-by: Caleb Spare <[email protected]> Reviewed-by: Brad Fitzpatrick <[email protected]> TryBot-Result: Gobot Gobot <[email protected]>
1 parent e33794f commit 3af20c0

File tree

2 files changed

+8
-0
lines changed

2 files changed

+8
-0
lines changed

src/cmd/go/alldocs.go

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -813,6 +813,10 @@
813813
// Install packages that are dependencies of the test.
814814
// Do not run the test.
815815
//
816+
// -json
817+
// Convert test output to JSON suitable for automated processing.
818+
// See 'go doc test2json' for the encoding details.
819+
//
816820
// -o file
817821
// Compile the test binary to the named file.
818822
// The test still runs (unless -c or -i is specified).

src/cmd/go/internal/test/test.go

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -143,6 +143,10 @@ In addition to the build flags, the flags handled by 'go test' itself are:
143143
Install packages that are dependencies of the test.
144144
Do not run the test.
145145
146+
-json
147+
Convert test output to JSON suitable for automated processing.
148+
See 'go doc test2json' for the encoding details.
149+
146150
-o file
147151
Compile the test binary to the named file.
148152
The test still runs (unless -c or -i is specified).

0 commit comments

Comments
 (0)