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
b8b92a11
Commit
b8b92a11
authored
Sep 30, 2016
by
Kevin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix kubectl taint e2e flake: add retries for removing taint
parent
b71def75
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
5 deletions
+5
-5
kubectl.go
test/e2e/kubectl.go
+5
-5
No files found.
test/e2e/kubectl.go
View file @
b8b92a11
...
@@ -1293,7 +1293,7 @@ var _ = framework.KubeDescribe("Kubectl client", func() {
...
@@ -1293,7 +1293,7 @@ var _ = framework.KubeDescribe("Kubectl client", func() {
By
(
"adding the taint "
+
testTaint
.
ToString
()
+
" to a node"
)
By
(
"adding the taint "
+
testTaint
.
ToString
()
+
" to a node"
)
runKubectlRetryOrDie
(
"taint"
,
"nodes"
,
nodeName
,
testTaint
.
ToString
())
runKubectlRetryOrDie
(
"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
.
RunKubectl
OrDie
(
"describe"
,
"node"
,
nodeName
)
output
:=
runKubectlRetry
OrDie
(
"describe"
,
"node"
,
nodeName
)
requiredStrings
:=
[][]
string
{
requiredStrings
:=
[][]
string
{
{
"Name:"
,
nodeName
},
{
"Name:"
,
nodeName
},
{
"Taints:"
},
{
"Taints:"
},
...
@@ -1304,7 +1304,7 @@ var _ = framework.KubeDescribe("Kubectl client", func() {
...
@@ -1304,7 +1304,7 @@ var _ = framework.KubeDescribe("Kubectl client", func() {
By
(
"removing the taint "
+
testTaint
.
ToString
()
+
" of a node"
)
By
(
"removing the taint "
+
testTaint
.
ToString
()
+
" of a node"
)
runKubectlRetryOrDie
(
"taint"
,
"nodes"
,
nodeName
,
testTaint
.
Key
+
":"
+
string
(
testTaint
.
Effect
)
+
"-"
)
runKubectlRetryOrDie
(
"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
.
RunKubectl
OrDie
(
"describe"
,
"node"
,
nodeName
)
output
=
runKubectlRetry
OrDie
(
"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
)
}
}
...
@@ -1325,7 +1325,7 @@ var _ = framework.KubeDescribe("Kubectl client", func() {
...
@@ -1325,7 +1325,7 @@ var _ = framework.KubeDescribe("Kubectl client", func() {
By
(
"adding the taint "
+
testTaint
.
ToString
()
+
" to a node"
)
By
(
"adding the taint "
+
testTaint
.
ToString
()
+
" to a node"
)
runKubectlRetryOrDie
(
"taint"
,
"nodes"
,
nodeName
,
testTaint
.
ToString
())
runKubectlRetryOrDie
(
"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
.
RunKubectl
OrDie
(
"describe"
,
"node"
,
nodeName
)
output
:=
runKubectlRetry
OrDie
(
"describe"
,
"node"
,
nodeName
)
requiredStrings
:=
[][]
string
{
requiredStrings
:=
[][]
string
{
{
"Name:"
,
nodeName
},
{
"Name:"
,
nodeName
},
{
"Taints:"
},
{
"Taints:"
},
...
@@ -1341,7 +1341,7 @@ var _ = framework.KubeDescribe("Kubectl client", func() {
...
@@ -1341,7 +1341,7 @@ var _ = framework.KubeDescribe("Kubectl client", func() {
By
(
"adding another taint "
+
newTestTaint
.
ToString
()
+
" to the node"
)
By
(
"adding another taint "
+
newTestTaint
.
ToString
()
+
" to the node"
)
runKubectlRetryOrDie
(
"taint"
,
"nodes"
,
nodeName
,
newTestTaint
.
ToString
())
runKubectlRetryOrDie
(
"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
.
RunKubectl
OrDie
(
"describe"
,
"node"
,
nodeName
)
output
=
runKubectlRetry
OrDie
(
"describe"
,
"node"
,
nodeName
)
requiredStrings
=
[][]
string
{
requiredStrings
=
[][]
string
{
{
"Name:"
,
nodeName
},
{
"Name:"
,
nodeName
},
{
"Taints:"
},
{
"Taints:"
},
...
@@ -1352,7 +1352,7 @@ var _ = framework.KubeDescribe("Kubectl client", func() {
...
@@ -1352,7 +1352,7 @@ var _ = framework.KubeDescribe("Kubectl client", func() {
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"
)
runKubectlRetryOrDie
(
"taint"
,
"nodes"
,
nodeName
,
testTaint
.
Key
+
"-"
)
runKubectlRetryOrDie
(
"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
.
RunKubectl
OrDie
(
"describe"
,
"node"
,
nodeName
)
output
=
runKubectlRetry
OrDie
(
"describe"
,
"node"
,
nodeName
)
if
strings
.
Contains
(
output
,
testTaint
.
Key
)
{
if
strings
.
Contains
(
output
,
testTaint
.
Key
)
{
framework
.
Failf
(
"Failed removing taints "
+
testTaint
.
Key
+
" of the node "
+
nodeName
)
framework
.
Failf
(
"Failed removing taints "
+
testTaint
.
Key
+
" of the node "
+
nodeName
)
}
}
...
...
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