1
0
mirror of https://github.com/golang/go synced 2024-09-29 23:24:29 -06:00
go/doc
Changkun Ou 2f54081adf testing: do not require os.Exit in TestMain
If TestMain reports a wrong exit code to os.Exit, the test will be
exited with exist code inconsist with test results.

This CL eliminates the requirement of calling os.Exit in TestMain.
Now, m.Run records the execution status of its test, the outer
main func will call os.Exit with that exit code if TestMain does
not call os.Exit.

If TestMain does not call m.Run, the outer main func remain calls
os.Exit(0) as before.

Fixes #34129

Change-Id: I9598023e03b0a6260f0217f34df41c231c7d6489
Reviewed-on: https://go-review.googlesource.com/c/go/+/219639
Reviewed-by: Ian Lance Taylor <iant@golang.org>
2020-03-17 00:45:15 +00:00
..
articles doc: race condition in unsynchronized send/close 2020-03-02 08:42:10 +00:00
codewalk doc: convert remaining bash tests to Go 2019-11-14 21:33:00 +00:00
gopher doc/gopher: add model sheet 2018-07-18 04:00:10 +00:00
play doc/play: match the hello world snippet in x/website 2019-10-23 22:43:37 +00:00
progs doc: convert remaining bash tests to Go 2019-11-14 21:33:00 +00:00
asm.html doc: update ppc64 section for asm.html 2019-09-16 14:12:02 +00:00
cmd.html doc: remove extra br tags 2020-02-23 01:23:41 +00:00
contrib.html doc: add Go 1.14 to release history 2020-02-25 16:16:10 +00:00
contribute.html doc: 2020 is the Year of the Gopher 2020-01-02 17:36:29 +00:00
debugging_with_gdb.html runtime: support all as parameter in gdb goroutine commands. 2019-04-29 18:11:11 +00:00
diagnostics.html doc: document GODEBUG options to disable use of instruction set extensions 2018-12-18 14:59:36 +00:00
editors.html doc: fix spelling of comp[]hensive to comp[r]ehensive 2018-10-12 22:59:05 +00:00
effective_go.html doc: update Effective Go with 1.14 language changes 2020-02-28 20:15:38 +00:00
gccgo_contribute.html all: remove trailing whitespace from HTML files 2019-09-18 18:32:20 +00:00
gccgo_install.html all: remove trailing whitespace from HTML files 2019-09-18 18:32:20 +00:00
go1.1.html doc: s/tool chain/toolchain/ 2018-01-09 21:47:03 +00:00
go1.2.html doc: use HTTPS for links 2018-06-13 13:45:01 +00:00
go1.3.html doc: rewrite reference to plan9.bell-labs.com to 9p.io 2019-08-19 21:42:54 +00:00
go1.4.html doc: use HTTPS for links 2018-06-13 13:45:01 +00:00
go1.5.html
go1.6.html doc: align documents link 2019-08-26 17:33:52 +00:00
go1.7.html doc: align documents link 2019-08-26 17:33:52 +00:00
go1.8.html doc: align documents link 2019-08-26 17:33:52 +00:00
go1.9.html doc: rename HTML element IDs to avoid duplicates 2020-02-05 14:32:50 +00:00
go1.10.html doc: align documents link 2019-08-26 17:33:52 +00:00
go1.11.html doc: rename HTML element IDs to avoid duplicates 2020-02-05 14:32:50 +00:00
go1.12.html doc: align documents link 2019-08-26 17:33:52 +00:00
go1.13.html doc: rename HTML element IDs to avoid duplicates 2020-02-05 14:32:50 +00:00
go1.14.html doc/go1.14: document that unparsable URL in net/url.Error is now quoted 2020-03-06 14:41:22 +00:00
go1.15.html testing: do not require os.Exit in TestMain 2020-03-17 00:45:15 +00:00
go1.html doc: change anchor URLs from golang.org/dl/ to /dl/ 2018-01-20 04:13:12 +00:00
go1compat.html doc: s/tool chain/toolchain/ 2018-01-09 21:47:03 +00:00
go_faq.html all: remove trailing whitespace from HTML files 2019-09-18 18:32:20 +00:00
go_mem.html doc/mem: remove unnecessary pre tags within same snippet 2020-03-03 09:28:34 +00:00
go_spec.html spec: add missing space in EBNF 2020-01-15 05:32:51 +00:00
go-logo-black.png
go-logo-blue.png
go-logo-white.png
help.html doc: remove a Google+ link since it doesn't exist anymore 2019-06-18 03:41:59 +00:00
ie.css
install-source.html doc: add missing p in install from source page 2019-12-07 15:57:30 +00:00
install.html doc/install.html: streamline the “Test your installation” step and make it module-agnostic 2020-02-05 18:27:48 +00:00
share.png
tos.html