From: Rodolfo Carvalho Date: Tue, 17 Mar 2020 10:41:45 +0000 (+0000) Subject: testing: use "exit code" in documentation consistently X-Git-Tag: go1.15beta1~838 X-Git-Url: http://www.git.cypherpunks.su/?a=commitdiff_plain;h=0eeec4f25dc6eccc4e76ab91053e2b4823c72714;p=gostls13.git testing: use "exit code" in documentation consistently The documentation for m.Run says it returns an "exit code" to pass to os.Exit. The argument to os.Exit is named "code". While "exit code", "exit status" and "exit status code" are all valid ways to refer to the same concept, prefer to stick to one form for consistency and to avoid confusing users. Change-Id: If76ee3fab5cc99c79e05ac1a4e413790a9c93d60 GitHub-Last-Rev: 85a081d2f03c2cf9e8e519916986c59c86aebf57 GitHub-Pull-Request: golang/go#37899 Reviewed-on: https://go-review.googlesource.com/c/go/+/223778 Reviewed-by: Gabriel Aszalos Reviewed-by: Ian Lance Taylor Run-TryBot: Gabriel Aszalos TryBot-Result: Gobot Gobot --- diff --git a/src/testing/testing.go b/src/testing/testing.go index 039d3e6209..5c78d9b741 100644 --- a/src/testing/testing.go +++ b/src/testing/testing.go @@ -218,7 +218,7 @@ // then the generated test will call TestMain(m) instead of running the tests // directly. TestMain runs in the main goroutine and can do whatever setup // and teardown is necessary around a call to m.Run. m.Run will return an exit -// status that may be passed to os.Exit. If TestMain returns, the test wrapper +// code that may be passed to os.Exit. If TestMain returns, the test wrapper // will pass the result of m.Run to os.Exit itself. When TestMain is called, // flag.Parse has not been run. If TestMain depends on command-line flags, // including those of the testing package, it should call flag.Parse explicitly.