MCPcopy
hub / github.com/containerd/containerd / PodSandboxConfigWithCleanup

Function PodSandboxConfigWithCleanup

integration/main_test.go:314–324  ·  view source on GitHub ↗
(t *testing.T, name, ns string, opts ...PodSandboxOpts)

Source from the content-addressed store, hash-verified

312}
313
314func PodSandboxConfigWithCleanup(t *testing.T, name, ns string, opts ...PodSandboxOpts) (string, *runtime.PodSandboxConfig) {
315 sbConfig := PodSandboxConfig(name, ns, opts...)
316 sb, err := runtimeService.RunPodSandbox(sbConfig, *runtimeHandler)
317 require.NoError(t, err)
318 t.Cleanup(func() {
319 assert.NoError(t, runtimeService.StopPodSandbox(sb))
320 assert.NoError(t, runtimeService.RemovePodSandbox(sb))
321 })
322
323 return sb, sbConfig
324}
325
326// Set Windows HostProcess on the pod.
327func WithWindowsHostProcessPod(p *runtime.PodSandboxConfig) {

Callers 15

TestUsernsVolumeCopyUpFunction · 0.85
TestContainerRestartFunction · 0.85
TestLongContainerLogFunction · 0.85
TestAdditionalGidsFunction · 0.85
TestContainerdImageFunction · 0.85
TestWindowsRootfsSizeFunction · 0.85
TestVolumeCopyUpFunction · 0.85

Calls 5

PodSandboxConfigFunction · 0.85
RunPodSandboxMethod · 0.65
CleanupMethod · 0.65
StopPodSandboxMethod · 0.65
RemovePodSandboxMethod · 0.65

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…