#578 introduced a new test for StartWithProcUnsetGenError, which is checked by validation/start.go. However, when testing with runc, the test fails because Create() returns exit status 2. It turns out, that's because validateProcessSpec() in runc panics with nil-dereference when its input spec (type of *Process) is nil.
From my understanding, the original idea of the test was probably not to test whether spec.Process is nil or not. It should actually test if process in config.json is valid. So I think we should actually decode a config json file to see if it has a valid process entry.
/cc @liangchenye
#578 introduced a new test for StartWithProcUnsetGenError, which is checked by validation/start.go. However, when testing with runc, the test fails because
Create()returnsexit status 2. It turns out, that's becausevalidateProcessSpec()in runc panics with nil-dereference when its inputspec(type of *Process) is nil.From my understanding, the original idea of the test was probably not to test whether
spec.Processis nil or not. It should actually test ifprocessin config.json is valid. So I think we should actually decode a config json file to see if it has a validprocessentry./cc @liangchenye