Documentation ¶
Index ¶
- func InitRegistryAndConfig(t *testing.T, ...) (frameworkruntime.Registry, schedulerconfig.KubeSchedulerProfile)
- func InitTestSchedulerForFrameworkTest(t *testing.T, testCtx *testutils.TestContext, nodeCount int, ...) (*testutils.TestContext, testutils.ShutdownFunc)
- func NewPlugin(plugin framework.Plugin) frameworkruntime.PluginFactory
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func InitRegistryAndConfig ¶ added in v1.28.0
func InitRegistryAndConfig(t *testing.T, factory func(plugin framework.Plugin) frameworkruntime.PluginFactory, plugins ...framework.Plugin) (frameworkruntime.Registry, schedulerconfig.KubeSchedulerProfile)
InitRegistryAndConfig returns registry and plugins config based on give plugins.
func InitTestSchedulerForFrameworkTest ¶ added in v1.28.0
func InitTestSchedulerForFrameworkTest(t *testing.T, testCtx *testutils.TestContext, nodeCount int, opts ...scheduler.Option) (*testutils.TestContext, testutils.ShutdownFunc)
The returned shutdown func will delete created resources and scheduler, resources should be those that will affect the scheduling result, like nodes, pods, etc.. Namespaces should not be deleted here because it's created together with the apiserver, they should be deleted simultaneously or we'll have no namespace. This should only be called when you want to kill the scheduler alone, away from apiserver. For example, in scheduler integration tests, recreating apiserver is performance consuming, then shutdown the scheduler and recreate it between each test case is a better approach.
func NewPlugin ¶ added in v1.28.0
func NewPlugin(plugin framework.Plugin) frameworkruntime.PluginFactory
NewPlugin returns a plugin factory with specified Plugin.
Types ¶
This section is empty.