-
Notifications
You must be signed in to change notification settings - Fork 367
Unit tests failing on CentOS #228
Description
Using the following configuration:
CentOS Linux 7 (Core)
kata-runtime : 0.1.0
commit : 8088a62
OCI specs: 1.0.1
Docker version 18.03.0-ce, build 0520e24
go version go1.9.5 linux/amd64
kata-shim version 0.0.1-2bdea2e41109b6b71c600899e1bf5794b125200d
kata-proxy version 0.0.1-de18929631091cb1f079b2e6e1caa3e4625f4930
QEMU emulator version 2.11.1 (v2.11.1)
I did the following steps
$ go get -d github.com/kata-containers/runtime
$ export RUNTIME="kata-runtime"
$ make test
However, some unit tests are failing, this behavior is also seen in the Jenkins jobs that were enabled for the runtime and shim repositories (kata-containers/ci#13). Here is a small summary of unit tests that are failing:
--- FAIL: TestStartStopSandboxHyperstartAgentSuccessfulWithCNMNetwork (0.01s)
cc_proxy_mock.go:89: [CCProxyMock] listening on /tmp/cc-proxy-test882053419/cc-proxy-test.sock
api_test.go:1471: fork/exec /usr/bin/virtcontainers/bin/test/hook: no such file or directory
cc_proxy_mock.go:89: [CCProxyMock] Client connection already closed
cc_proxy_mock.go:89: [CCProxyMock] Stopped
--- FAIL: TestCCShimStartSuccessful (0.00s)
cc_shim_test.go:60: This test should pass (sandbox {id: hypervisor: agent: storage: network: config:0xc4201fed80 volumes:[] containers:[] runPath: configPath: state:{State: BlockIndex:0 Fstype: HotpluggedDrive:false} networkNS:{NetNsPath: NetNsCreated:false Endpoints:[]} annotationsLock: wg:}, params {Container:testContainer Token:testToken URL:foo:///foo/clear-containers/proxy.sock Console: Terminal:false Detach:false PID:0 CreateNS:[] EnterNS:[]}, expectFail false): fork/exec /usr/bin/virtcontainers/bin/test/cc-shim: no such file or directory
--- FAIL: TestCCShimStartDetachSuccessful (0.00s)
cc_shim_test.go:60: This test should pass (sandbox {id: hypervisor: agent: storage: network: config:0xc4201fefc0 volumes:[] containers:[] runPath: configPath: state:{State: BlockIndex:0 Fstype: HotpluggedDrive:false} networkNS:{NetNsPath: NetNsCreated:false Endpoints:[]} annotationsLock: wg:}, params {Container:testContainer Token:testToken URL:foo:///foo/clear-containers/proxy.sock Console: Terminal:false Detach:true PID:0 CreateNS:[] EnterNS:[]}, expectFail false): fork/exec /usr/bin/virtcontainers/bin/test/cc-shim: no such file or directory
--- FAIL: TestCCShimStartWithConsoleSuccessful (0.00s)
cc_shim_test.go:344: Console created for tests:/dev/pts/1
cc_shim_test.go:60: This test should pass (sandbox {id: hypervisor: agent: storage: network: config:0xc420308000 volumes:[] containers:[] runPath: configPath: state:{State: BlockIndex:0 Fstype: HotpluggedDrive:false} networkNS:{NetNsPath: NetNsCreated:false Endpoints:[]} annotationsLock: wg:}, params {Container:testContainer Token:testToken URL:foo:///foo/clear-containers/proxy.sock Console:/dev/pts/1 Terminal:false Detach:false PID:0 CreateNS:[] EnterNS:[]}, expectFail false): fork/exec /usr/bin/virtcontainers/bin/test/cc-shim: no such file or directory
=== RUN TestRunHook
--- FAIL: TestRunHook (0.00s)
hook_test.go:84: unexpected failure: fork/exec /usr/bin/virtcontainers/bin/test/hook: no such file or directory
=== RUN TestRunHookTimeout
--- FAIL: TestRunHookTimeout (0.00s)
hook_test.go:84: unexpected failure: fork/exec /usr/bin/virtcontainers/bin/test/hook: no such file or directory
--- FAIL: TestKataShimStartSuccessful (0.00s)
kata_shim_test.go:54: This test should pass (sandbox {id: hypervisor: agent: storage: network: config:0xc4200bf8c0 volumes:[] containers:[] runPath: configPath: state:{State: BlockIndex:0 Fstype: HotpluggedDrive:false} networkNS:{NetNsPath: NetNsCreated:false Endpoints:[]} annotationsLock: wg:}, params {Container:testContainer Token:testToken URL:foo:///foo/kata-containers/proxy.sock Console: Terminal:false Detach:false PID:0 CreateNS:[] EnterNS:[]}, expectFail false): fork/exec /usr/bin/virtcontainers/bin/test/kata-shim: no such file or directory
--- FAIL: TestKataShimStartDetachSuccessful (0.00s)
kata_shim_test.go:54: This test should pass (sandbox {id: hypervisor: agent: storage: network: config:0xc4200bfb00 volumes:[] containers:[] runPath: configPath: state:{State: BlockIndex:0 Fstype: HotpluggedDrive:false} networkNS:{NetNsPath: NetNsCreated:false Endpoints:[]} annotationsLock: wg:}, params {Container:testContainer Token:testToken URL:foo:///foo/kata-containers/proxy.sock Console: Terminal:false Detach:true PID:0 CreateNS:[] EnterNS:[]}, expectFail false): fork/exec /usr/bin/virtcontainers/bin/test/kata-shim: no such file or directory
=== RUN TestKataShimStartWithConsoleNonExistingFailure
--- PASS: TestKataShimStartWithConsoleNonExistingFailure (0.00s)
=== RUN TestKataShimStartWithConsoleSuccessful
--- FAIL: TestKataShimStartWithConsoleSuccessful (0.00s)
kata_shim_test.go:290: Console created for tests:/dev/pts/1
kata_shim_test.go:54: This test should pass (sandbox {id: hypervisor: agent: storage: network: config:0xc42043a000 volumes:[] containers:[] runPath: configPath: state:{State: BlockIndex:0 Fstype: HotpluggedDrive:false} networkNS:{NetNsPath: NetNsCreated:false Endpoints:[]} annotationsLock: wg:}, params {Container:testContainer Token:testToken URL:foo:///foo/kata-containers/proxy.sock Console:/dev/pts/1 Terminal:false Detach:false PID:0 CreateNS:[] EnterNS:[]}, expectFail false): fork/exec /usr/bin/virtcontainers/bin/test/kata-shim: no such file or directory
--- FAIL: TestGetFileFromNSSuccessful (0.00s)
nsenter_test.go:99
Expected nil, but got: &errors.errorString{s:"failed to Statfs "/proc/self/ns/cgroup": no such file or directory"}
Messages: Should have succeeded: failed to Statfs "/proc/self/ns/cgroup": no such file or directory
nsenter_test.go:100
Error: Expected value not to be nil.
--- FAIL: TestNsEnterSuccessful (0.01s)
Error Trace: nsenter_test.go:221
Error: Expected nil, but got: &errors.errorString{s:"failed to open target ns: failed to Statfs "/proc/90176/ns/cgroup": no such file or directory"}
Messages: failed to open target ns: failed to Statfs "/proc/90176/ns/cgroup": no such file or directory
Error Trace: nsenter_test.go:251
Error: Not equal:
expected: "cgroup"
actual: "0"
Error Trace: nsenter_test.go:251
Error: Not equal:
expected: "ipc:[4026532104]"
actual: "0"
Error Trace: nsenter_test.go:251
Error: Not equal:
expected: "net:[4026532107]"
actual: "0"
FAIL github.com/kata-containers/runtime/virtcontainers 1.343s
FAIL github.com/kata-containers/runtime/virtcontainers/pkg/nsenter 0.024s