Check the memory ContainerStats.
(t *testing.T)
| 263 | |
| 264 | // Check the memory ContainerStats. |
| 265 | func TestDockerContainerMemoryStats(t *testing.T) { |
| 266 | fm := framework.New(t) |
| 267 | defer fm.Cleanup() |
| 268 | |
| 269 | // Wait for the container to show up. |
| 270 | containerID := fm.Docker().RunBusybox("ping", "www.google.com") |
| 271 | waitForContainer(containerID, fm) |
| 272 | |
| 273 | request := &info.ContainerInfoRequest{ |
| 274 | NumStats: 1, |
| 275 | } |
| 276 | containerInfo, err := fm.Cadvisor().Client().DockerContainer(containerID, request) |
| 277 | require.NoError(t, err) |
| 278 | sanityCheck(containerID, containerInfo, t) |
| 279 | |
| 280 | // Checks for MemoryStats. |
| 281 | checkMemoryStats(t, containerInfo.Stats[0].Memory) |
| 282 | } |
| 283 | |
| 284 | // Check the network ContainerStats. |
| 285 | func TestDockerContainerNetworkStats(t *testing.T) { |
nothing calls this directly
no test coverage detected
searching dependent graphs…