]> Cypherpunks.ru repositories - gostls13.git/commit
testing: only snapshot coverage during fuzzing
authorRoland Shoemaker <roland@golang.org>
Fri, 7 Jan 2022 20:18:30 +0000 (12:18 -0800)
committerRoland Shoemaker <roland@golang.org>
Mon, 10 Jan 2022 21:48:09 +0000 (21:48 +0000)
commit1f411e9b6d8849014653c89a9df77b8aadd082e6
tree53ed960c82bb3f446596b6d17e2167faf1cca965
parent8b9b365493220a7bfd87fd3c27301e43baa35a0d
testing: only snapshot coverage during fuzzing

Only snapshot/reset coverage counters when we are actually fuzzing.
This prevents a race when running corpus/seed values during the testing
phase.

Fixes #50488

Change-Id: I7dd5a0353a296c0b13eede29ad9af7c78814fa2d
Reviewed-on: https://go-review.googlesource.com/c/go/+/376554
Trust: Katie Hockman <katie@golang.org>
Reviewed-by: Katie Hockman <katie@golang.org>
Trust: Roland Shoemaker <roland@golang.org>
Run-TryBot: Roland Shoemaker <roland@golang.org>
TryBot-Result: Gopher Robot <gobot@golang.org>
src/cmd/go/testdata/script/test_fuzz_test_race.txt [new file with mode: 0644]
src/testing/fuzz.go