Skip to content
This repository was archived by the owner on May 12, 2021. It is now read-only.

Commit cb32d28

Browse files
author
Sebastien Boeuf
committed
test: Fix mockContainer
Latest libcontainer vendoring update introduced a new function as part of the Container Go interface, OCIState(). The mockContainer interface needs to implement this too, otherwise the tests won't compile. Signed-off-by: Sebastien Boeuf <sebastien.boeuf@intel.com>
1 parent 3e12793 commit cb32d28

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

mockcontainer.go

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ import (
1212

1313
"github.com/opencontainers/runc/libcontainer"
1414
"github.com/opencontainers/runc/libcontainer/configs"
15+
"github.com/opencontainers/runtime-spec/specs-go"
1516
)
1617

1718
type mockContainer struct {
@@ -33,6 +34,10 @@ func (m *mockContainer) State() (*libcontainer.State, error) {
3334
return nil, nil
3435
}
3536

37+
func (m *mockContainer) OCIState() (*specs.State, error) {
38+
return nil, nil
39+
}
40+
3641
func (m *mockContainer) Config() configs.Config {
3742
return configs.Config{
3843
Capabilities: &configs.Capabilities{},

0 commit comments

Comments
 (0)