MCPcopy
hub / github.com/containerd/containerd / checkCopy

Function checkCopy

plugins/content/local/store_test.go:349–358  ·  view source on GitHub ↗
(t checker, size int64, dst io.Writer, src io.Reader)

Source from the content-addressed store, hash-verified

347}
348
349func checkCopy(t checker, size int64, dst io.Writer, src io.Reader) {
350 nn, err := io.Copy(dst, src)
351 if err != nil {
352 t.Fatal(err)
353 }
354
355 if nn != size {
356 t.Fatal("incorrect number of bytes copied")
357 }
358}
359
360func checkBlobPath(t *testing.T, cs content.Store, dgst digest.Digest) string {
361 path, err := cs.(*store).blobPath(dgst)

Callers 1

TestContentWriterFunction · 0.85

Calls 2

CopyMethod · 0.80
FatalMethod · 0.80

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…