MCPcopy Index your code
hub / github.com/containerd/containerd / TestImagePullAllPlatforms

Function TestImagePullAllPlatforms

integration/client/client_test.go:316–349  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

314}
315
316func TestImagePullAllPlatforms(t *testing.T) {
317 client, err := newClient(t, address)
318 if err != nil {
319 t.Fatal(err)
320 }
321 defer client.Close()
322 ctx, cancel := testContext(t)
323 defer cancel()
324
325 cs := client.ContentStore()
326 img, err := client.Fetch(ctx, imagelist.Get(imagelist.Pause))
327 if err != nil {
328 t.Fatal(err)
329 }
330 index := img.Target
331 manifests, err := images.Children(ctx, cs, index)
332 if err != nil {
333 t.Fatal(err)
334 }
335 for _, manifest := range manifests {
336 children, err := images.Children(ctx, cs, manifest)
337 if err != nil {
338 t.Fatal("Th")
339 }
340 // check if childless data type has blob in content store
341 for _, desc := range children {
342 ra, err := cs.ReaderAt(ctx, desc)
343 if err != nil {
344 t.Fatal(err)
345 }
346 ra.Close()
347 }
348 }
349}
350
351func TestImagePullSomePlatforms(t *testing.T) {
352 client, err := newClient(t, address)

Callers

nothing calls this directly

Calls 8

newClientFunction · 0.85
testContextFunction · 0.85
FatalMethod · 0.80
CloseMethod · 0.65
ContentStoreMethod · 0.65
FetchMethod · 0.65
GetMethod · 0.65
ReaderAtMethod · 0.65

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…