Skip to content

Commit

Permalink
Merge pull request #2289 from AkihiroSuda/fix-TestGetContainerStateAf…
Browse files Browse the repository at this point in the history
…terUpdate

Fix TestGetContainerStateAfterUpdate on cgroup v2
  • Loading branch information
crosbymichael authored Apr 6, 2020
2 parents 0c7a9c0 + 4540b59 commit d5e91b1
Showing 1 changed file with 6 additions and 5 deletions.
11 changes: 6 additions & 5 deletions libcontainer/container_linux_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,11 @@ import (
)

type mockCgroupManager struct {
pids []int
allPids []int
stats *cgroups.Stats
paths map[string]string
pids []int
allPids []int
stats *cgroups.Stats
paths map[string]string
unifiedPath string
}

type mockIntelRdtManager struct {
Expand Down Expand Up @@ -55,7 +56,7 @@ func (m *mockCgroupManager) GetPaths() map[string]string {
}

func (m *mockCgroupManager) GetUnifiedPath() (string, error) {
return "", fmt.Errorf("unimplemented")
return m.unifiedPath, nil
}

func (m *mockCgroupManager) Freeze(state configs.FreezerState) error {
Expand Down

0 comments on commit d5e91b1

Please sign in to comment.