Skip to content

Commit e978ef3

Browse files
4a6f656crolandshoemaker
authored andcommitted
image/gif,image/jpeg,image/png: skip FuzzDecode in testing short mode
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 <[email protected]> TryBot-Result: Gopher Robot <[email protected]> Run-TryBot: Bryan Mills <[email protected]> Reviewed-by: Bryan Mills <[email protected]>
1 parent 789e798 commit e978ef3

File tree

3 files changed

+12
-0
lines changed

3 files changed

+12
-0
lines changed

src/image/gif/fuzz_test.go

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,10 @@ import (
1414
)
1515

1616
func FuzzDecode(f *testing.F) {
17+
if testing.Short() {
18+
f.Skip("Skipping in short mode")
19+
}
20+
1721
testdata, err := os.ReadDir("../testdata")
1822
if err != nil {
1923
f.Fatalf("failed to read testdata directory: %s", err)

src/image/jpeg/fuzz_test.go

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,10 @@ import (
1414
)
1515

1616
func FuzzDecode(f *testing.F) {
17+
if testing.Short() {
18+
f.Skip("Skipping in short mode")
19+
}
20+
1721
testdata, err := os.ReadDir("../testdata")
1822
if err != nil {
1923
f.Fatalf("failed to read testdata directory: %s", err)

src/image/png/fuzz_test.go

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,10 @@ import (
1414
)
1515

1616
func FuzzDecode(f *testing.F) {
17+
if testing.Short() {
18+
f.Skip("Skipping in short mode")
19+
}
20+
1721
testdata, err := os.ReadDir("../testdata")
1822
if err != nil {
1923
f.Fatalf("failed to read testdata directory: %s", err)

0 commit comments

Comments
 (0)