Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
K
k3s
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Jacklull
k3s
Commits
6b949a1a
Commit
6b949a1a
authored
Jun 23, 2017
by
Bobby (Babak) Salamat
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Remove e2e test that checked scheduler priority function for ReplicationController spreading
parent
1a93dd60
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
0 additions
and
46 deletions
+0
-46
priorities.go
test/e2e/scheduling/priorities.go
+0
-46
No files found.
test/e2e/scheduling/priorities.go
View file @
6b949a1a
...
...
@@ -84,52 +84,6 @@ var _ = framework.KubeDescribe("SchedulerPriorities [Serial]", func() {
Expect
(
err
)
.
NotTo
(
HaveOccurred
())
})
It
(
"Pods created by ReplicationController should spread to different node"
,
func
()
{
By
(
"Create a pod for each node to make the nodes have almost same cpu/mem usage ratio"
)
createBalancedPodForNodes
(
f
,
cs
,
ns
,
nodeList
.
Items
,
podRequestedResource
,
0.6
)
By
(
"Create an RC with the same number of replicas as the schedualble nodes. One pod should be scheduled on each node."
)
config
:=
testutils
.
RCConfig
{
Client
:
f
.
ClientSet
,
InternalClient
:
f
.
InternalClientset
,
Name
:
"scheduler-priority-selector-spreading"
,
Namespace
:
ns
,
Image
:
framework
.
GetPauseImageName
(
f
.
ClientSet
),
Replicas
:
len
(
nodeList
.
Items
),
CreatedPods
:
&
[]
*
v1
.
Pod
{},
Labels
:
map
[
string
]
string
{
"name"
:
"scheduler-priority-selector-spreading"
},
CpuRequest
:
podRequestedResource
.
Requests
.
Cpu
()
.
MilliValue
(),
MemRequest
:
podRequestedResource
.
Requests
.
Memory
()
.
Value
(),
}
Expect
(
framework
.
RunRC
(
config
))
.
NotTo
(
HaveOccurred
())
// Cleanup the replication controller when we are done.
defer
func
()
{
// Resize the replication controller to zero to get rid of pods.
if
err
:=
framework
.
DeleteRCAndPods
(
f
.
ClientSet
,
f
.
InternalClientset
,
f
.
Namespace
.
Name
,
"scheduler-priority-selector-spreading"
);
err
!=
nil
{
framework
.
Logf
(
"Failed to cleanup replication controller %v: %v."
,
"scheduler-priority-selector-spreading"
,
err
)
}
}()
pods
,
err
:=
framework
.
PodsCreated
(
f
.
ClientSet
,
f
.
Namespace
.
Name
,
"scheduler-priority-selector-spreading"
,
int32
(
len
(
nodeList
.
Items
)))
Expect
(
err
)
.
NotTo
(
HaveOccurred
())
By
(
"Ensuring each pod is running"
)
result
:=
map
[
string
]
bool
{}
for
_
,
pod
:=
range
pods
.
Items
{
if
pod
.
DeletionTimestamp
!=
nil
{
continue
}
err
=
f
.
WaitForPodRunning
(
pod
.
Name
)
Expect
(
err
)
.
NotTo
(
HaveOccurred
())
result
[
pod
.
Spec
.
NodeName
]
=
true
framework
.
PrintAllKubeletPods
(
cs
,
pod
.
Spec
.
NodeName
)
}
By
(
"Verify the pods were scheduled to each node"
)
if
len
(
nodeList
.
Items
)
!=
len
(
result
)
{
framework
.
Failf
(
"Pods are not spread to each node."
)
}
})
It
(
"Pod should be prefer scheduled to node that satisify the NodeAffinity"
,
func
()
{
nodeName
:=
GetNodeThatCanRunPod
(
f
)
By
(
"Trying to apply a label on the found node."
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment