Documentation ¶
Overview ¶
genfuzzfuncs is an early stage prototype for automatically generating fuzz functions, similar in spirit to cweill/gotests.
For example, if you run genfuzzfuncs against github.com/google/uuid, it generates a uuid_fuzz.go file with 30 or so functions like:
func Fuzz_UUID_MarshalText(u1 uuid.UUID) { u1.MarshalText() } func Fuzz_UUID_UnmarshalText(u1 *uuid.UUID, data []byte) { if u1 == nil { return } u1.UnmarshalText(data) }
You can then edit or delete indivdual fuzz funcs as desired, and then fuzz using the rich signature fuzzing support in thepudds/fzgo, such as:
fzgo test -fuzz=. ./...
Click to show internal directories.
Click to hide internal directories.