MCPcopy
hub / github.com/google/cadvisor / newTestContainerData

Function newTestContainerData

lib/manager/container_test.go:62–64  ·  view source on GitHub ↗

Create a containerData instance for a test and add a default GetSpec mock.

(t *testing.T)

Source from the content-addressed store, hash-verified

60
61// Create a containerData instance for a test and add a default GetSpec mock.
62func newTestContainerData(t *testing.T) (*containerData, *containertest.MockContainerHandler, *memory.InMemoryCache, *clock.FakeClock) {
63 return setupContainerData(t, itest.GenerateRandomContainerSpec(4))
64}
65
66func TestUpdateSubcontainers(t *testing.T) {
67 subcontainers := []info.ContainerReference{

Calls 1

setupContainerDataFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…