]> Cypherpunks repositories - gostls13.git/commitdiff
image/gif,image/jpeg,image/png: skip FuzzDecode in testing short mode
authorJoel Sing <joel@sing.id.au>
Tue, 27 Sep 2022 08:30:01 +0000 (18:30 +1000)
committerRoland Shoemaker <roland@golang.org>
Tue, 27 Sep 2022 15:57:34 +0000 (15:57 +0000)
The image/gif.FuzzDecode takes an excessive amount of time to run on various
builders - skip these in testing short mode. Likewise for image/jpeg and
image/png.

Fixes #55839

Change-Id: I1049d06b9dcbbc7dbc4f53d3c49b64e2254eabbd
Reviewed-on: https://go-review.googlesource.com/c/go/+/435175
Reviewed-by: Roland Shoemaker <roland@golang.org>
TryBot-Result: Gopher Robot <gobot@golang.org>
Run-TryBot: Bryan Mills <bcmills@google.com>
Reviewed-by: Bryan Mills <bcmills@google.com>
src/image/gif/fuzz_test.go
src/image/jpeg/fuzz_test.go
src/image/png/fuzz_test.go

index 3ddf15d80f33e8ad718cb373ee0d1f4e632a7e8e..a4bc06ed69c8fecd567c3ffe61c10eb4b9921eef 100644 (file)
@@ -14,6 +14,10 @@ import (
 )
 
 func FuzzDecode(f *testing.F) {
+       if testing.Short() {
+               f.Skip("Skipping in short mode")
+       }
+
        testdata, err := os.ReadDir("../testdata")
        if err != nil {
                f.Fatalf("failed to read testdata directory: %s", err)
index 716f06f43cff2476d38a4ca788c290ad42e35f8a..bd534a921d7ce0078915cd16657dc775b6ac948d 100644 (file)
@@ -14,6 +14,10 @@ import (
 )
 
 func FuzzDecode(f *testing.F) {
+       if testing.Short() {
+               f.Skip("Skipping in short mode")
+       }
+
        testdata, err := os.ReadDir("../testdata")
        if err != nil {
                f.Fatalf("failed to read testdata directory: %s", err)
index 22b3ef082a458e04a62cab0bfc66111716a3311b..4b639459e71598fbf8a1dfeee642330c7fbe8567 100644 (file)
@@ -14,6 +14,10 @@ import (
 )
 
 func FuzzDecode(f *testing.F) {
+       if testing.Short() {
+               f.Skip("Skipping in short mode")
+       }
+
        testdata, err := os.ReadDir("../testdata")
        if err != nil {
                f.Fatalf("failed to read testdata directory: %s", err)