kubernetes: k8s.io/kubernetes/pkg/kubelet/runtimeclass/testing Index | Files

package testing

import "k8s.io/kubernetes/pkg/kubelet/runtimeclass/testing"

Index

Package Files

fake_manager.go

Constants

const (
    // SandboxRuntimeClass is a valid RuntimeClass pre-populated in the populated dynamic client.
    SandboxRuntimeClass = "sandbox"
    // SandboxRuntimeHandler is the handler associated with the SandboxRuntimeClass.
    SandboxRuntimeHandler = "kata-containers"

    // EmptyRuntimeClass is a valid RuntimeClass without a handler pre-populated in the populated dynamic client.
    EmptyRuntimeClass = "native"
)

func NewPopulatedClient Uses

func NewPopulatedClient() clientset.Interface

NewPopulatedClient creates a fake client for use with the runtimeclass.Manager, and populates it with a few test RuntimeClass objects.

func NewRuntimeClass Uses

func NewRuntimeClass(name, handler string) *nodev1beta1.RuntimeClass

NewRuntimeClass is a helper to generate a RuntimeClass resource with the given name & handler.

func StartManagerSync Uses

func StartManagerSync(m *runtimeclass.Manager) func()

StartManagerSync starts the manager, and waits for the informer cache to sync. Returns a function to stop the manager, which should be called with a defer:

defer StartManagerSync(t, m)()

Package testing imports 5 packages (graph) and is imported by 34 packages. Updated 2019-03-26. Refresh now. Tools for package owners.