go/src/testing
Bryan C. Mills f985833dec testing: panic in Fuzz if the function returns a value
Otherwise, the behavior of a fuzz target that returns an error could
be confusing.

Fuzz is already documented to require a function “with no return
value”, so this fixes the implementation to match the existing
documentation.

Fixes #51222

Change-Id: I44ca7ee10960214c92f5ac066ac8484c8bb9cd6f
Reviewed-on: https://go-review.googlesource.com/c/go/+/386175
Trust: Bryan Mills <bcmills@google.com>
Run-TryBot: Bryan Mills <bcmills@google.com>
Reviewed-by: Robert Findley <rfindley@google.com>
Reviewed-by: Nooras Saba‎ <saba@golang.org>
TryBot-Result: Gopher Robot <gobot@golang.org>
2022-02-16 16:06:39 +00:00
..
fstest all: gofmt -w -r 'interface{} -> any' src 2021-12-13 18:45:54 +00:00
internal/testdeps all: gofmt -w -r 'interface{} -> any' src 2021-12-13 18:45:54 +00:00
iotest
quick all: gofmt -w -r 'interface{} -> any' src 2021-12-13 18:45:54 +00:00
allocs.go
allocs_test.go all: gofmt -w -r 'interface{} -> any' src 2021-12-13 18:45:54 +00:00
benchmark.go testing: remove redundant type conversion 2021-10-31 18:13:09 +00:00
benchmark_test.go testing: remove data races so that parallel benchmarks can safely call .Fatal* and .Skip* 2021-04-19 22:06:05 +00:00
cover.go
example.go all: gofmt -w -r 'interface{} -> any' src 2021-12-13 18:45:54 +00:00
export_test.go
fuzz.go testing: panic in Fuzz if the function returns a value 2022-02-16 16:06:39 +00:00
helper_test.go testing: skip panics when picking the line number for decoration 2021-09-16 23:50:23 +00:00
helperfuncs_test.go testing: skip panics when picking the line number for decoration 2021-09-16 23:50:23 +00:00
match.go testing: reduce memory used by subtest names 2021-11-01 02:47:30 +00:00
match_test.go testing: reduce memory used by subtest names 2021-11-01 02:47:30 +00:00
panic_test.go
run_example.go all: go fix -fix=buildtag std cmd (except for bootstrap deps, vendor) 2021-10-28 18:17:57 +00:00
run_example_js.go all: go fix -fix=buildtag std cmd (except for bootstrap deps, vendor) 2021-10-28 18:17:57 +00:00
sub_test.go [dev.fuzz] all: merge master (d137b74) into dev.fuzz 2021-05-17 11:03:09 -04:00
testing.go testing: remove TODO and link to fuzz docs 2022-02-04 22:27:25 +00:00
testing_other.go testing: retry spurious errors from RemoveAll for temp directories 2021-12-14 19:53:20 +00:00
testing_test.go testing: drop unusual characters from TempDir directory name 2021-06-17 04:32:50 +00:00
testing_windows.go testing: retry spurious errors from RemoveAll for temp directories 2021-12-14 19:53:20 +00:00