(f *testing.F)
| 28 | ) |
| 29 | |
| 30 | func FuzzImagesCheck(f *testing.F) { |
| 31 | f.Fuzz(func(t *testing.T, data []byte) { |
| 32 | f := fuzz.NewConsumer(data) |
| 33 | desc := ocispec.Descriptor{} |
| 34 | err := f.GenerateStruct(&desc) |
| 35 | if err != nil { |
| 36 | return |
| 37 | } |
| 38 | tmpDir := t.TempDir() |
| 39 | cs, err := local.NewStore(tmpDir) |
| 40 | if err != nil { |
| 41 | return |
| 42 | } |
| 43 | _, _, _, _, _ = images.Check(context.Background(), cs, desc, platforms.Default()) |
| 44 | }) |
| 45 | } |