mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-10-29 21:01:02 +00:00
use scheduler.Option in initTestSchedulerWithOptions
This commit is contained in:
@@ -449,7 +449,7 @@ func TestPreFilterPlugin(t *testing.T) {
|
||||
// Create the master and the scheduler with the test plugin set.
|
||||
context := initTestSchedulerWithOptions(t,
|
||||
initTestMaster(t, "prefilter-plugin", nil),
|
||||
false, nil, registry, plugins, emptyPluginConfig, false, time.Second)
|
||||
false, nil, registry, plugins, emptyPluginConfig, time.Second)
|
||||
|
||||
defer cleanupTest(t, context)
|
||||
|
||||
@@ -627,7 +627,7 @@ func TestReservePlugin(t *testing.T) {
|
||||
// Create the master and the scheduler with the test plugin set.
|
||||
context := initTestSchedulerWithOptions(t,
|
||||
initTestMaster(t, "reserve-plugin", nil),
|
||||
false, nil, registry, plugins, emptyPluginConfig, false, time.Second)
|
||||
false, nil, registry, plugins, emptyPluginConfig, time.Second)
|
||||
defer cleanupTest(t, context)
|
||||
|
||||
cs := context.clientSet
|
||||
@@ -691,7 +691,7 @@ func TestPrebindPlugin(t *testing.T) {
|
||||
// Create the master and the scheduler with the test plugin set.
|
||||
context := initTestSchedulerWithOptions(t,
|
||||
initTestMaster(t, "prebind-plugin", nil),
|
||||
false, nil, registry, plugins, preBindPluginConfig, false, time.Second)
|
||||
false, nil, registry, plugins, preBindPluginConfig, time.Second)
|
||||
defer cleanupTest(t, context)
|
||||
|
||||
cs := context.clientSet
|
||||
@@ -792,7 +792,7 @@ func TestUnreservePlugin(t *testing.T) {
|
||||
// Create the master and the scheduler with the test plugin set.
|
||||
context := initTestSchedulerWithOptions(t,
|
||||
initTestMaster(t, "unreserve-plugin", nil),
|
||||
false, nil, registry, plugins, pluginConfig, false, time.Second)
|
||||
false, nil, registry, plugins, pluginConfig, time.Second)
|
||||
defer cleanupTest(t, context)
|
||||
|
||||
cs := context.clientSet
|
||||
@@ -907,7 +907,7 @@ func TestBindPlugin(t *testing.T) {
|
||||
|
||||
// Create the master and the scheduler with the test plugin set.
|
||||
context := initTestSchedulerWithOptions(t, testContext,
|
||||
false, nil, registry, plugins, pluginConfig, false, time.Second)
|
||||
false, nil, registry, plugins, pluginConfig, time.Second)
|
||||
defer cleanupTest(t, context)
|
||||
|
||||
cs := context.clientSet
|
||||
@@ -1079,7 +1079,7 @@ func TestPostBindPlugin(t *testing.T) {
|
||||
// Create the master and the scheduler with the test plugin set.
|
||||
context := initTestSchedulerWithOptions(t,
|
||||
initTestMaster(t, "postbind-plugin", nil),
|
||||
false, nil, registry, plugins, pluginConfig, false, time.Second)
|
||||
false, nil, registry, plugins, pluginConfig, time.Second)
|
||||
defer cleanupTest(t, context)
|
||||
|
||||
cs := context.clientSet
|
||||
@@ -1160,7 +1160,7 @@ func TestPermitPlugin(t *testing.T) {
|
||||
// Create the master and the scheduler with the test plugin set.
|
||||
context := initTestSchedulerWithOptions(t,
|
||||
initTestMaster(t, "permit-plugin", nil),
|
||||
false, nil, registry, plugins, pluginConfig, false, time.Second)
|
||||
false, nil, registry, plugins, pluginConfig, time.Second)
|
||||
defer cleanupTest(t, context)
|
||||
|
||||
cs := context.clientSet
|
||||
@@ -1272,7 +1272,7 @@ func TestCoSchedulingWithPermitPlugin(t *testing.T) {
|
||||
// Create the master and the scheduler with the test plugin set.
|
||||
context := initTestSchedulerWithOptions(t,
|
||||
initTestMaster(t, "permit-plugin", nil),
|
||||
false, nil, registry, plugins, pluginConfig, false, time.Second)
|
||||
false, nil, registry, plugins, pluginConfig, time.Second)
|
||||
defer cleanupTest(t, context)
|
||||
|
||||
cs := context.clientSet
|
||||
@@ -1362,7 +1362,7 @@ func TestFilterPlugin(t *testing.T) {
|
||||
// Create the master and the scheduler with the test plugin set.
|
||||
context := initTestSchedulerWithOptions(t,
|
||||
initTestMaster(t, "filter-plugin", nil),
|
||||
false, nil, registry, plugin, emptyPluginConfig, false, time.Second)
|
||||
false, nil, registry, plugin, emptyPluginConfig, time.Second)
|
||||
defer cleanupTest(t, context)
|
||||
|
||||
cs := context.clientSet
|
||||
@@ -1422,7 +1422,7 @@ func TestPostFilterPlugin(t *testing.T) {
|
||||
// Create the master and the scheduler with the test plugin set.
|
||||
context := initTestSchedulerWithOptions(t,
|
||||
initTestMaster(t, "post-filter-plugin", nil),
|
||||
false, nil, registry, pluginsConfig, emptyPluginConfig, false, time.Second)
|
||||
false, nil, registry, pluginsConfig, emptyPluginConfig, time.Second)
|
||||
defer cleanupTest(t, context)
|
||||
|
||||
cs := context.clientSet
|
||||
@@ -1487,7 +1487,7 @@ func TestPreemptWithPermitPlugin(t *testing.T) {
|
||||
// Create the master and the scheduler with the test plugin set.
|
||||
context := initTestSchedulerWithOptions(t,
|
||||
initTestMaster(t, "preempt-with-permit-plugin", nil),
|
||||
false, nil, registry, plugins, pluginConfig, false, time.Second)
|
||||
false, nil, registry, plugins, pluginConfig, time.Second)
|
||||
defer cleanupTest(t, context)
|
||||
|
||||
cs := context.clientSet
|
||||
@@ -1558,7 +1558,7 @@ func initTestContextForScorePlugin(t *testing.T, plugins *schedulerconfig.Plugin
|
||||
// Create the master and the scheduler with the test plugin set.
|
||||
context := initTestSchedulerWithOptions(t,
|
||||
initTestMaster(t, "score-plugin", nil),
|
||||
false, nil, registry, plugins, emptyPluginConfig, false, time.Second)
|
||||
false, nil, registry, plugins, emptyPluginConfig, time.Second)
|
||||
|
||||
cs := context.clientSet
|
||||
_, err := createNodes(cs, "test-node", nil, 10)
|
||||
|
||||
Reference in New Issue
Block a user