]> Cypherpunks repositories - gostls13.git/commitdiff
cmd/go: enable fuzz testing for FreeBSD
authorAyan George <ayan@ayan.net>
Tue, 11 Jan 2022 21:37:46 +0000 (16:37 -0500)
committerKatie Hockman <katie@golang.org>
Wed, 12 Jan 2022 19:47:40 +0000 (19:47 +0000)
Add "freebsd" to GOOS for which sys.FuzzSupported() returns true
and add freebsd to the build tags to fuzz test source.

Fixes #46554
Change-Id: I5f695ecc8f09c0ab4279ced23b4715b788fcade0
Reviewed-on: https://go-review.googlesource.com/c/go/+/377855
Trust: Bryan Mills <bcmills@google.com>
Trust: Katie Hockman <katie@golang.org>
Run-TryBot: Katie Hockman <katie@golang.org>
TryBot-Result: Gopher Robot <gobot@golang.org>
Reviewed-by: Katie Hockman <katie@golang.org>
src/cmd/internal/sys/supported.go
src/internal/fuzz/minimize_test.go
src/internal/fuzz/sys_posix.go
src/internal/fuzz/sys_unimplemented.go

index f25aaabddd60ea8c044bc7f8ae5a6068d8796f0e..82b65511de469279fbe03c377537b069ba04bf4f 100644 (file)
@@ -50,7 +50,7 @@ func ASanSupported(goos, goarch string) bool {
 // ('go test -fuzz=.').
 func FuzzSupported(goos, goarch string) bool {
        switch goos {
-       case "darwin", "linux", "windows":
+       case "darwin", "freebsd", "linux", "windows":
                return true
        default:
                return false
index 6e5f3184b4e06fb69841436817172be3825c7c99..2db26338967e27c77899d0fde55840ed4fc6af95 100644 (file)
@@ -2,7 +2,7 @@
 // Use of this source code is governed by a BSD-style
 // license that can be found in the LICENSE file.
 
-//go:build darwin || linux || windows
+//go:build darwin || freebsd || linux || windows
 
 package fuzz
 
index 89c86c1ebbf22f9dc04d34ba54ef4e251bad9f56..fec6054f671cc8e83039cfa694f0d52f88b89c79 100644 (file)
@@ -2,7 +2,7 @@
 // Use of this source code is governed by a BSD-style
 // license that can be found in the LICENSE file.
 
-//go:build darwin || linux
+//go:build darwin || freebsd || linux
 
 package fuzz
 
index 123a32583c54cc90003c5663441f9ffe744e2f54..f84dae6a61fddb649e68ca18c93af9b71c63f2db 100644 (file)
@@ -4,7 +4,7 @@
 
 // If you update this constraint, also update cmd/internal/sys.FuzzSupported.
 //
-//go:build !darwin && !linux && !windows
+//go:build !darwin && !freebsd && !linux && !windows
 
 package fuzz