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
0c80a7aa
Commit
0c80a7aa
authored
Apr 27, 2017
by
Mike Danese
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix go vet's from skipped tests
parent
21617a60
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
13 additions
and
7 deletions
+13
-7
client_test.go
test/integration/client/client_test.go
+1
-1
evictions_test.go
test/integration/evictions/evictions_test.go
+1
-1
extender_test.go
test/integration/scheduler/extender_test.go
+9
-3
scheduler_test.go
test/integration/scheduler/scheduler_test.go
+2
-2
No files found.
test/integration/client/client_test.go
View file @
0c80a7aa
...
@@ -561,7 +561,7 @@ func TestSingleWatch(t *testing.T) {
...
@@ -561,7 +561,7 @@ func TestSingleWatch(t *testing.T) {
func
TestMultiWatch
(
t
*
testing
.
T
)
{
func
TestMultiWatch
(
t
*
testing
.
T
)
{
// Disable this test as long as it demonstrates a problem.
// Disable this test as long as it demonstrates a problem.
// TODO: Reenable this test when we get #6059 resolved.
// TODO: Reenable this test when we get #6059 resolved.
return
t
.
Skip
()
const
watcherCount
=
50
const
watcherCount
=
50
rt
.
GOMAXPROCS
(
watcherCount
)
rt
.
GOMAXPROCS
(
watcherCount
)
...
...
test/integration/evictions/evictions_test.go
View file @
0c80a7aa
...
@@ -161,7 +161,7 @@ func TestConcurrentEvictionRequests(t *testing.T) {
...
@@ -161,7 +161,7 @@ func TestConcurrentEvictionRequests(t *testing.T) {
}
}
if
atomic
.
LoadUint32
(
&
numberPodsEvicted
)
!=
numOfEvictions
{
if
atomic
.
LoadUint32
(
&
numberPodsEvicted
)
!=
numOfEvictions
{
t
.
Fatalf
(
"fewer number of successful evictions than expected :"
,
numberPodsEvicted
)
t
.
Fatalf
(
"fewer number of successful evictions than expected :
%d
"
,
numberPodsEvicted
)
}
}
}
}
...
...
test/integration/scheduler/extender_test.go
View file @
0c80a7aa
...
@@ -230,7 +230,10 @@ func machine_2_Prioritizer(pod *v1.Pod, nodes *v1.NodeList) (*schedulerapi.HostP
...
@@ -230,7 +230,10 @@ func machine_2_Prioritizer(pod *v1.Pod, nodes *v1.NodeList) (*schedulerapi.HostP
if
node
.
Name
==
"machine2"
{
if
node
.
Name
==
"machine2"
{
score
=
10
score
=
10
}
}
result
=
append
(
result
,
schedulerapi
.
HostPriority
{
node
.
Name
,
score
})
result
=
append
(
result
,
schedulerapi
.
HostPriority
{
Host
:
node
.
Name
,
Score
:
score
,
})
}
}
return
&
result
,
nil
return
&
result
,
nil
}
}
...
@@ -242,7 +245,10 @@ func machine_3_Prioritizer(pod *v1.Pod, nodes *v1.NodeList) (*schedulerapi.HostP
...
@@ -242,7 +245,10 @@ func machine_3_Prioritizer(pod *v1.Pod, nodes *v1.NodeList) (*schedulerapi.HostP
if
node
.
Name
==
"machine3"
{
if
node
.
Name
==
"machine3"
{
score
=
10
score
=
10
}
}
result
=
append
(
result
,
schedulerapi
.
HostPriority
{
node
.
Name
,
score
})
result
=
append
(
result
,
schedulerapi
.
HostPriority
{
Host
:
node
.
Name
,
Score
:
score
,
})
}
}
return
&
result
,
nil
return
&
result
,
nil
}
}
...
@@ -353,7 +359,7 @@ func DoTestPodScheduling(ns *v1.Namespace, t *testing.T, cs clientset.Interface)
...
@@ -353,7 +359,7 @@ func DoTestPodScheduling(ns *v1.Namespace, t *testing.T, cs clientset.Interface)
Type
:
v1
.
NodeReady
,
Type
:
v1
.
NodeReady
,
Status
:
v1
.
ConditionTrue
,
Status
:
v1
.
ConditionTrue
,
Reason
:
fmt
.
Sprintf
(
"schedulable condition"
),
Reason
:
fmt
.
Sprintf
(
"schedulable condition"
),
LastHeartbeatTime
:
metav1
.
Time
{
time
.
Now
()},
LastHeartbeatTime
:
metav1
.
Time
{
Time
:
time
.
Now
()},
}
}
node
:=
&
v1
.
Node
{
node
:=
&
v1
.
Node
{
Spec
:
v1
.
NodeSpec
{
Unschedulable
:
false
},
Spec
:
v1
.
NodeSpec
{
Unschedulable
:
false
},
...
...
test/integration/scheduler/scheduler_test.go
View file @
0c80a7aa
...
@@ -323,13 +323,13 @@ func DoTestUnschedulableNodes(t *testing.T, cs clientset.Interface, ns *v1.Names
...
@@ -323,13 +323,13 @@ func DoTestUnschedulableNodes(t *testing.T, cs clientset.Interface, ns *v1.Names
Type
:
v1
.
NodeReady
,
Type
:
v1
.
NodeReady
,
Status
:
v1
.
ConditionTrue
,
Status
:
v1
.
ConditionTrue
,
Reason
:
fmt
.
Sprintf
(
"schedulable condition"
),
Reason
:
fmt
.
Sprintf
(
"schedulable condition"
),
LastHeartbeatTime
:
metav1
.
Time
{
time
.
Now
()},
LastHeartbeatTime
:
metav1
.
Time
{
Time
:
time
.
Now
()},
}
}
badCondition
:=
v1
.
NodeCondition
{
badCondition
:=
v1
.
NodeCondition
{
Type
:
v1
.
NodeReady
,
Type
:
v1
.
NodeReady
,
Status
:
v1
.
ConditionUnknown
,
Status
:
v1
.
ConditionUnknown
,
Reason
:
fmt
.
Sprintf
(
"unschedulable condition"
),
Reason
:
fmt
.
Sprintf
(
"unschedulable condition"
),
LastHeartbeatTime
:
metav1
.
Time
{
time
.
Now
()},
LastHeartbeatTime
:
metav1
.
Time
{
Time
:
time
.
Now
()},
}
}
// Create a new schedulable node, since we're first going to apply
// Create a new schedulable node, since we're first going to apply
// the unschedulable condition and verify that pods aren't scheduled.
// the unschedulable condition and verify that pods aren't scheduled.
...
...
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