gpu/internal/rendertest: allow nil pixel check functions

Signed-off-by: Elias Naur <mail@eliasnaur.com>
This commit is contained in:
Elias Naur
2025-02-18 14:55:46 +00:00
parent 77709d1771
commit 0d23240556
3 changed files with 10 additions and 14 deletions
+3 -1
View File
@@ -90,7 +90,9 @@ func run(t *testing.T, f func(o *op.Ops), c func(r result)) {
name := fmt.Sprintf("%s-%d-bad.png", t.Name(), i)
saveImage(t, name, img)
}
c(result{t: t, img: img})
if c != nil {
c(result{t: t, img: img})
}
}
}