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
c47bb43c
Commit
c47bb43c
authored
Sep 20, 2016
by
Kevin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix node update taints conflict in kubectl taint e2e
parent
aa60583e
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
6 deletions
+5
-6
kubectl.go
test/e2e/kubectl.go
+5
-6
No files found.
test/e2e/kubectl.go
View file @
c47bb43c
...
@@ -1292,7 +1292,7 @@ var _ = framework.KubeDescribe("Kubectl client", func() {
...
@@ -1292,7 +1292,7 @@ var _ = framework.KubeDescribe("Kubectl client", func() {
nodeName
:=
node
.
Name
nodeName
:=
node
.
Name
By
(
"adding the taint "
+
testTaint
.
ToString
()
+
" to a node"
)
By
(
"adding the taint "
+
testTaint
.
ToString
()
+
" to a node"
)
framework
.
RunKubectl
OrDie
(
"taint"
,
"nodes"
,
nodeName
,
testTaint
.
ToString
())
runKubectlRetry
OrDie
(
"taint"
,
"nodes"
,
nodeName
,
testTaint
.
ToString
())
By
(
"verifying the node has the taint "
+
testTaint
.
ToString
())
By
(
"verifying the node has the taint "
+
testTaint
.
ToString
())
output
:=
framework
.
RunKubectlOrDie
(
"describe"
,
"node"
,
nodeName
)
output
:=
framework
.
RunKubectlOrDie
(
"describe"
,
"node"
,
nodeName
)
requiredStrings
:=
[][]
string
{
requiredStrings
:=
[][]
string
{
...
@@ -1303,13 +1303,12 @@ var _ = framework.KubeDescribe("Kubectl client", func() {
...
@@ -1303,13 +1303,12 @@ var _ = framework.KubeDescribe("Kubectl client", func() {
checkOutput
(
output
,
requiredStrings
)
checkOutput
(
output
,
requiredStrings
)
By
(
"removing the taint "
+
testTaint
.
ToString
()
+
" of a node"
)
By
(
"removing the taint "
+
testTaint
.
ToString
()
+
" of a node"
)
framework
.
RunKubectl
OrDie
(
"taint"
,
"nodes"
,
nodeName
,
testTaint
.
Key
+
":"
+
string
(
testTaint
.
Effect
)
+
"-"
)
runKubectlRetry
OrDie
(
"taint"
,
"nodes"
,
nodeName
,
testTaint
.
Key
+
":"
+
string
(
testTaint
.
Effect
)
+
"-"
)
By
(
"verifying the node doesn't have the taint "
+
testTaint
.
Key
)
By
(
"verifying the node doesn't have the taint "
+
testTaint
.
Key
)
output
=
framework
.
RunKubectlOrDie
(
"describe"
,
"node"
,
nodeName
)
output
=
framework
.
RunKubectlOrDie
(
"describe"
,
"node"
,
nodeName
)
if
strings
.
Contains
(
output
,
testTaint
.
Key
)
{
if
strings
.
Contains
(
output
,
testTaint
.
Key
)
{
framework
.
Failf
(
"Failed removing taint "
+
testTaint
.
Key
+
" of the node "
+
nodeName
)
framework
.
Failf
(
"Failed removing taint "
+
testTaint
.
Key
+
" of the node "
+
nodeName
)
}
}
})
})
It
(
"should remove all the taints with the same key off a node"
,
func
()
{
It
(
"should remove all the taints with the same key off a node"
,
func
()
{
...
@@ -1325,7 +1324,7 @@ var _ = framework.KubeDescribe("Kubectl client", func() {
...
@@ -1325,7 +1324,7 @@ var _ = framework.KubeDescribe("Kubectl client", func() {
nodeName
:=
node
.
Name
nodeName
:=
node
.
Name
By
(
"adding the taint "
+
testTaint
.
ToString
()
+
" to a node"
)
By
(
"adding the taint "
+
testTaint
.
ToString
()
+
" to a node"
)
framework
.
RunKubectl
OrDie
(
"taint"
,
"nodes"
,
nodeName
,
testTaint
.
ToString
())
runKubectlRetry
OrDie
(
"taint"
,
"nodes"
,
nodeName
,
testTaint
.
ToString
())
By
(
"verifying the node has the taint "
+
testTaint
.
ToString
())
By
(
"verifying the node has the taint "
+
testTaint
.
ToString
())
output
:=
framework
.
RunKubectlOrDie
(
"describe"
,
"node"
,
nodeName
)
output
:=
framework
.
RunKubectlOrDie
(
"describe"
,
"node"
,
nodeName
)
requiredStrings
:=
[][]
string
{
requiredStrings
:=
[][]
string
{
...
@@ -1341,7 +1340,7 @@ var _ = framework.KubeDescribe("Kubectl client", func() {
...
@@ -1341,7 +1340,7 @@ var _ = framework.KubeDescribe("Kubectl client", func() {
Effect
:
api
.
TaintEffectPreferNoSchedule
,
Effect
:
api
.
TaintEffectPreferNoSchedule
,
}
}
By
(
"adding another taint "
+
newTestTaint
.
ToString
()
+
" to the node"
)
By
(
"adding another taint "
+
newTestTaint
.
ToString
()
+
" to the node"
)
framework
.
RunKubectl
OrDie
(
"taint"
,
"nodes"
,
nodeName
,
newTestTaint
.
ToString
())
runKubectlRetry
OrDie
(
"taint"
,
"nodes"
,
nodeName
,
newTestTaint
.
ToString
())
By
(
"verifying the node has the taint "
+
newTestTaint
.
ToString
())
By
(
"verifying the node has the taint "
+
newTestTaint
.
ToString
())
output
=
framework
.
RunKubectlOrDie
(
"describe"
,
"node"
,
nodeName
)
output
=
framework
.
RunKubectlOrDie
(
"describe"
,
"node"
,
nodeName
)
requiredStrings
=
[][]
string
{
requiredStrings
=
[][]
string
{
...
@@ -1352,7 +1351,7 @@ var _ = framework.KubeDescribe("Kubectl client", func() {
...
@@ -1352,7 +1351,7 @@ var _ = framework.KubeDescribe("Kubectl client", func() {
checkOutput
(
output
,
requiredStrings
)
checkOutput
(
output
,
requiredStrings
)
By
(
"removing all taints that have the same key "
+
testTaint
.
Key
+
" of the node"
)
By
(
"removing all taints that have the same key "
+
testTaint
.
Key
+
" of the node"
)
framework
.
RunKubectl
OrDie
(
"taint"
,
"nodes"
,
nodeName
,
testTaint
.
Key
+
"-"
)
runKubectlRetry
OrDie
(
"taint"
,
"nodes"
,
nodeName
,
testTaint
.
Key
+
"-"
)
By
(
"verifying the node doesn't have the taints that have the same key "
+
testTaint
.
Key
)
By
(
"verifying the node doesn't have the taints that have the same key "
+
testTaint
.
Key
)
output
=
framework
.
RunKubectlOrDie
(
"describe"
,
"node"
,
nodeName
)
output
=
framework
.
RunKubectlOrDie
(
"describe"
,
"node"
,
nodeName
)
if
strings
.
Contains
(
output
,
testTaint
.
Key
)
{
if
strings
.
Contains
(
output
,
testTaint
.
Key
)
{
...
...
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