const testResourceName …
func newWrappedManagerImpl(socketPath string, manager *ManagerImpl) *wrappedManagerImpl { … }
type wrappedManagerImpl …
func (m *wrappedManagerImpl) PluginListAndWatchReceiver(r string, resp *pluginapi.ListAndWatchResponse) { … }
func tmpSocketDir() (socketDir, socketName, pluginSocketName string, err error) { … }
func TestNewManagerImpl(t *testing.T) { … }
func TestNewManagerImplStart(t *testing.T) { … }
func TestNewManagerImplStartProbeMode(t *testing.T) { … }
func TestDevicePluginReRegistration(t *testing.T) { … }
func TestDevicePluginReRegistrationProbeMode(t *testing.T) { … }
func setupDeviceManager(t *testing.T, devs []*pluginapi.Device, callback monitorCallback, socketName string,
topology []cadvisorapi.Node) (Manager, <-chan interface{ … }
func setupDevicePlugin(t *testing.T, devs []*pluginapi.Device, pluginSocketName string) *plugin.Stub { … }
func setupPluginManager(t *testing.T, pluginSocketName string, m Manager) pluginmanager.PluginManager { … }
func runPluginManager(pluginManager pluginmanager.PluginManager) { … }
func setup(t *testing.T, devs []*pluginapi.Device, callback monitorCallback, socketName string, pluginSocketName string) (Manager, <-chan interface{ … }
func setupInProbeMode(t *testing.T, devs []*pluginapi.Device, callback monitorCallback, socketName string, pluginSocketName string) (Manager, <-chan interface{ … }
func cleanup(t *testing.T, m Manager, p *plugin.Stub) { … }
func TestUpdateCapacityAllocatable(t *testing.T) { … }
func TestGetAllocatableDevicesMultipleResources(t *testing.T) { … }
func TestGetAllocatableDevicesHealthTransition(t *testing.T) { … }
func checkAllocatableDevicesConsistsOf(as *assert.Assertions, devInstances DeviceInstances, expectedDevs []string) { … }
func constructDevices(devices []string) checkpoint.DevicesPerNUMA { … }
type containerAllocateResponseBuilder …
type containerAllocateResponseBuilderOption …
func withDevices(devices map[string]string) containerAllocateResponseBuilderOption { … }
func withMounts(mounts map[string]string) containerAllocateResponseBuilderOption { … }
func withEnvs(envs map[string]string) containerAllocateResponseBuilderOption { … }
func withCDIDevices(cdiDevices ...string) containerAllocateResponseBuilderOption { … }
func newContainerAllocateResponse(opts ...containerAllocateResponseBuilderOption) *pluginapi.ContainerAllocateResponse { … }
func (b *containerAllocateResponseBuilder) Build() *pluginapi.ContainerAllocateResponse { … }
func TestCheckpoint(t *testing.T) { … }
type activePodsStub …
func (a *activePodsStub) getActivePods() []*v1.Pod { … }
func (a *activePodsStub) updateActivePods(newPods []*v1.Pod) { … }
type MockEndpoint …
func (m *MockEndpoint) preStartContainer(devs []string) (*pluginapi.PreStartContainerResponse, error) { … }
func (m *MockEndpoint) getPreferredAllocation(available, mustInclude []string, size int) (*pluginapi.PreferredAllocationResponse, error) { … }
func (m *MockEndpoint) allocate(devs []string) (*pluginapi.AllocateResponse, error) { … }
func (m *MockEndpoint) setStopTime(t time.Time) { … }
func (m *MockEndpoint) isStopped() bool { … }
func (m *MockEndpoint) stopGracePeriodExpired() bool { … }
func makePod(limits v1.ResourceList) *v1.Pod { … }
func getTestManager(tmpDir string, activePods ActivePodsFunc, testRes []TestResource) (*wrappedManagerImpl, error) { … }
type TestResource …
func TestFilterByAffinity(t *testing.T) { … }
func TestPodContainerDeviceAllocation(t *testing.T) { … }
func TestPodContainerDeviceToAllocate(t *testing.T) { … }
func TestDevicesToAllocateConflictWithUpdateAllocatedDevices(t *testing.T) { … }
func TestGetDeviceRunContainerOptions(t *testing.T) { … }
func TestInitContainerDeviceAllocation(t *testing.T) { … }
func TestRestartableInitContainerDeviceAllocation(t *testing.T) { … }
func TestUpdatePluginResources(t *testing.T) { … }
func TestDevicePreStartContainer(t *testing.T) { … }
func TestResetExtendedResource(t *testing.T) { … }
func allocateStubFunc() func(devs []string) (*pluginapi.AllocateResponse, error) { … }
func makeDevice(devOnNUMA checkpoint.DevicesPerNUMA, topology bool) map[string]pluginapi.Device { … }
func TestGetTopologyHintsWithUpdates(t *testing.T) { … }
func TestUpdateAllocatedResourcesStatus(t *testing.T) { … }
func sortResourceHealth(resources []v1.ResourceHealth) { … }
func sortContainerStatuses(statuses []v1.ContainerStatus) { … }
func TestFeatureGateResourceHealthStatus(t *testing.T) { … }