Skip to content

Commit

Permalink
Merge pull request containerd#10851 from athos-ribeiro/test-segfault
Browse files Browse the repository at this point in the history
test: prevent segfault in imageverifier test
  • Loading branch information
mxpv authored Dec 13, 2024
2 parents 60e73c3 + 1617fd7 commit 7b5cbd8
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pkg/imageverifier/bindir/bindir_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -175,7 +175,7 @@ func TestBinDirVerifyImage(t *testing.T) {
})

j, err := v.VerifyImage(ctx, "registry.example.com/image:abc", ocispec.Descriptor{})
assert.NoError(t, err)
require.NoError(t, err)
assert.True(t, j.OK, "expected OK, got not OK with reason: %v", j.Reason)
assert.Less(t, len(j.Reason), len(bins)*(outputLimitBytes+1024), "reason is: %v", j.Reason) // 1024 leaves margin for the formatting around the reason.
})
Expand Down

0 comments on commit 7b5cbd8

Please sign in to comment.