aboutsummaryrefslogtreecommitdiffhomepage
path: root/internal/app/outcome_test.go
diff options
context:
space:
mode:
Diffstat (limited to 'internal/app/outcome_test.go')
-rw-r--r--internal/app/outcome_test.go9
1 files changed, 5 insertions, 4 deletions
diff --git a/internal/app/outcome_test.go b/internal/app/outcome_test.go
index a16f0a10..81fb6c7d 100644
--- a/internal/app/outcome_test.go
+++ b/internal/app/outcome_test.go
@@ -16,10 +16,11 @@ func TestOutcomeStateValid(t *testing.T) {
}{
{"nil", nil, false},
{"zero", new(outcomeState), false},
- {"id", &outcomeState{Container: new(hst.ContainerConfig), EnvPaths: new(EnvPaths)}, false},
- {"container", &outcomeState{ID: new(state.ID), EnvPaths: new(EnvPaths)}, false},
- {"envpaths", &outcomeState{ID: new(state.ID), Container: new(hst.ContainerConfig)}, false},
- {"valid", &outcomeState{ID: new(state.ID), Container: new(hst.ContainerConfig), EnvPaths: new(EnvPaths)}, true},
+ {"shim", &outcomeState{Shim: &shimParams{PrivPID: -1, Ops: []outcomeOp{}}, Container: new(hst.ContainerConfig), EnvPaths: new(EnvPaths)}, false},
+ {"id", &outcomeState{Shim: &shimParams{PrivPID: 1, Ops: []outcomeOp{}}, Container: new(hst.ContainerConfig), EnvPaths: new(EnvPaths)}, false},
+ {"container", &outcomeState{Shim: &shimParams{PrivPID: 1, Ops: []outcomeOp{}}, ID: new(state.ID), EnvPaths: new(EnvPaths)}, false},
+ {"envpaths", &outcomeState{Shim: &shimParams{PrivPID: 1, Ops: []outcomeOp{}}, ID: new(state.ID), Container: new(hst.ContainerConfig)}, false},
+ {"valid", &outcomeState{Shim: &shimParams{PrivPID: 1, Ops: []outcomeOp{}}, ID: new(state.ID), Container: new(hst.ContainerConfig), EnvPaths: new(EnvPaths)}, true},
}
for _, tc := range testCases {
t.Run(tc.name, func(t *testing.T) {