]> Cypherpunks repositories - gostls13.git/commitdiff
cmd/go: rearrange help for 'go test'
authorRob Pike <r@golang.org>
Thu, 9 Feb 2012 03:12:18 +0000 (14:12 +1100)
committerRob Pike <r@golang.org>
Thu, 9 Feb 2012 03:12:18 +0000 (14:12 +1100)
Put the 'go test' flags into 'go help test', so 'go help testflags'
is about the flags for the compiled test binary.

R=golang-dev, rsc
CC=golang-dev
https://golang.org/cl/5641060

src/cmd/go/test.go

index e0523534135cd486520b601dd48fe136edb0f037..bc2af619c245e0d02fcfefff71f27019a94bd445 100644 (file)
@@ -56,23 +56,7 @@ compiled.)
 The package is built in a temporary directory so it does not interfere with the
 non-test installation.
 
-See 'go help testflag' for details about flags handled by 'go test'
-and the test binary.
-
-See 'go help importpath' for more about import paths.
-
-See also: go build, go vet.
-       `,
-}
-
-var helpTestflag = &Command{
-       UsageLine: "testflag",
-       Short:     "description of testing flags",
-       Long: `
-The 'go test' command takes both flags that apply to 'go test' itself
-and flags that apply to the resulting test binary.
-
-The flags handled by 'go test' are:
+The flags handled by 'go test' itself are:
 
        -c  Compile the test binary to pkg.test but do not run it.
 
@@ -90,7 +74,23 @@ The flags handled by 'go test' are:
 
        -x  Print each subcommand go test executes.
 
-The resulting test binary, called pkg.test, where pkg is the name of the
+The test binary also accepts flags that control execution of the test; these
+flags are also accessible by 'go test'.  See 'go help testflag' for details.
+
+See 'go help importpath' for more about import paths.
+
+See also: go build, go vet.
+       `,
+}
+
+var helpTestflag = &Command{
+       UsageLine: "testflag",
+       Short:     "description of testing flags",
+       Long: `
+The 'go test' command takes both flags that apply to 'go test' itself
+and flags that apply to the resulting test binary.
+
+The test binary, called pkg.test, where pkg is the name of the
 directory containing the package sources, has its own flags:
 
        -test.v