Documentation ¶
Index ¶
- func BuildKubeConfigFile(config *restclient.Config) string
- func InitTestSchedulerWithOptions(t *testing.T, testCtx *testutils.TestContext, startScheduler bool, ...) *testutils.TestContext
- func IntegrationEtcdServers() []string
- func MakeNodesAndPods(labels map[string]string, existingPodsNum, allNodesNum int) (existingPods []*corev1.Pod, allNodes []*corev1.Node)
- func MakePG(name, namespace string, min int32, creationTime *time.Time, ...) *v1alpha1.PodGroup
- func MakePod(podName string, namespace string, memReq int64, cpuReq int64, priority int32, ...) *corev1.Pod
- func NewFakeSharedLister(pods []*v1.Pod, nodes []*v1.Node) framework.SharedLister
- func NewFramework(fns []st.RegisterPluginFunc, cfgs []config.PluginConfig, profileName string, ...) (framework.Framework, error)
- func NewPodNominator() framework.PodNominator
- func NominatedNodeName(pod *v1.Pod) string
- func PrintPods(t *testing.T, cs clientset.Interface, ns string)
- func StartApi(t *testing.T, stopCh <-chan struct{}) (client.Interface, *rest.Config)
- type TestServerSetup
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func BuildKubeConfigFile ¶
func BuildKubeConfigFile(config *restclient.Config) string
func InitTestSchedulerWithOptions ¶
func InitTestSchedulerWithOptions( t *testing.T, testCtx *testutils.TestContext, startScheduler bool, opts ...scheduler.Option, ) *testutils.TestContext
InitTestSchedulerWithOptions initializes a test environment and creates a scheduler with default configuration and other options. TODO(Huang-Wei): refactor the same function in the upstream, and remove here.
func IntegrationEtcdServers ¶
func IntegrationEtcdServers() []string
func MakeNodesAndPods ¶
func NewFakeSharedLister ¶
func NewFramework ¶
func NewFramework(fns []st.RegisterPluginFunc, cfgs []config.PluginConfig, profileName string, opts ...runtime.Option) (framework.Framework, error)
NewFramework is a variant version of st.NewFramework - with extra PluginConfig slice as input.
func NewPodNominator ¶
func NewPodNominator() framework.PodNominator
NewPodNominator creates a nominatedPodMap as a backing of framework.PodNominator.
func NominatedNodeName ¶
NominatedNodeName returns nominated node name of a Pod.
Types ¶
type TestServerSetup ¶
type TestServerSetup struct { ModifyServerRunOptions func(*options.ServerRunOptions) ModifyServerConfig func(*controlplane.Config) }
TestServerSetup holds configuration information for a kube-apiserver test server.
Click to show internal directories.
Click to hide internal directories.