MCPcopy
hub / github.com/opencontainers/runc / TestFactoryLoadNotExists

Function TestFactoryLoadNotExists

libcontainer/factory_linux_test.go:16–25  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

14)
15
16func TestFactoryLoadNotExists(t *testing.T) {
17 stateDir := t.TempDir()
18 _, err := Load(stateDir, "nocontainer")
19 if err == nil {
20 t.Fatal("expected nil error loading non-existing container")
21 }
22 if !errors.Is(err, ErrNotExist) {
23 t.Fatalf("expected ErrNotExist, got %v", err)
24 }
25}
26
27func TestFactoryLoadContainer(t *testing.T) {
28 root := t.TempDir()

Callers

nothing calls this directly

Calls 1

LoadFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…