diff options
| author | Sean Liao <sean@liao.dev> | 2022-03-22 21:08:23 +0000 |
|---|---|---|
| committer | Dmitri Shuralyov <dmitshur@google.com> | 2022-03-23 12:42:04 +0000 |
| commit | ff8a11c2e8d564390fa226f37c21838a704b586f (patch) | |
| tree | 922c0ca7102225934fbac5bc77713b6cc1d46c49 /_content/doc/tutorial | |
| parent | 9343ecdf8a7ba2832db2c88439a00c2d5a87cb28 (diff) | |
| download | go-x-website-ff8a11c2e8d564390fa226f37c21838a704b586f.tar.xz | |
_content/doc/tutorial: fix typos in fuzz tutorial
Fixes golang/go#51372
Fixes golang/go#51871
Change-Id: I64580e1608b75cb4e6f0d39ccc43f432e0c2dfca
Reviewed-on: https://go-review.googlesource.com/c/website/+/394814
Reviewed-by: Ian Lance Taylor <iant@google.com>
Trust: Dmitri Shuralyov <dmitshur@google.com>
Diffstat (limited to '_content/doc/tutorial')
| -rw-r--r-- | _content/doc/tutorial/fuzz.md | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/_content/doc/tutorial/fuzz.md b/_content/doc/tutorial/fuzz.md index 450d1664..d135d1c4 100644 --- a/_content/doc/tutorial/fuzz.md +++ b/_content/doc/tutorial/fuzz.md @@ -268,23 +268,23 @@ Note the syntax differences between the unit test and the fuzz test: - The function begins with FuzzXxx instead of TestXxx, and takes `*testing.F` instead of `*testing.T` -- Where you would expect to a see a `t.Run` execution, you instead see `f.Fuzz` +- Where you would expect to see a `t.Run` execution, you instead see `f.Fuzz` which takes a fuzz target function whose parameters are `*testing.T` and the types to be fuzzed. The inputs from your unit test are provided as seed corpus inputs using `f.Add`. -2. Ensure the new package, `unicode/utf8` has been imported. +Ensure the new package, `unicode/utf8` has been imported. - ``` - package main +``` +package main - import ( - "testing" - "unicode/utf8" - ) - ``` +import ( + "testing" + "unicode/utf8" +) +``` - With the unit test converted to a fuzz test, it’s time to run the test again. +With the unit test converted to a fuzz test, it’s time to run the test again. ### Run the code |
