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
b10e16e8
Unverified
Commit
b10e16e8
authored
May 17, 2019
by
Kubernetes Prow Robot
Committed by
GitHub
May 17, 2019
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #77955 from oomichi/use-ExpectNoError-upgrades
Use ExpectNoError() for e2e/upgrades
parents
c48c3f40
333f3d8b
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
24 additions
and
13 deletions
+24
-13
cassandra.go
test/e2e/upgrades/cassandra.go
+4
-2
etcd.go
test/e2e/upgrades/etcd.go
+4
-2
kube_proxy_migration.go
test/e2e/upgrades/kube_proxy_migration.go
+12
-7
mysql.go
test/e2e/upgrades/mysql.go
+4
-2
No files found.
test/e2e/upgrades/cassandra.go
View file @
b10e16e8
...
@@ -100,8 +100,10 @@ func (t *CassandraUpgradeTest) Setup(f *framework.Framework) {
...
@@ -100,8 +100,10 @@ func (t *CassandraUpgradeTest) Setup(f *framework.Framework) {
e2elog
.
Logf
(
"Service endpoint is up"
)
e2elog
.
Logf
(
"Service endpoint is up"
)
ginkgo
.
By
(
"Adding 2 dummy users"
)
ginkgo
.
By
(
"Adding 2 dummy users"
)
gomega
.
Expect
(
t
.
addUser
(
"Alice"
))
.
NotTo
(
gomega
.
HaveOccurred
())
err
=
t
.
addUser
(
"Alice"
)
gomega
.
Expect
(
t
.
addUser
(
"Bob"
))
.
NotTo
(
gomega
.
HaveOccurred
())
framework
.
ExpectNoError
(
err
)
err
=
t
.
addUser
(
"Bob"
)
framework
.
ExpectNoError
(
err
)
t
.
successfulWrites
=
2
t
.
successfulWrites
=
2
ginkgo
.
By
(
"Verifying that the users exist"
)
ginkgo
.
By
(
"Verifying that the users exist"
)
...
...
test/e2e/upgrades/etcd.go
View file @
b10e16e8
...
@@ -95,8 +95,10 @@ func (t *EtcdUpgradeTest) Setup(f *framework.Framework) {
...
@@ -95,8 +95,10 @@ func (t *EtcdUpgradeTest) Setup(f *framework.Framework) {
e2elog
.
Logf
(
"Service endpoint is up"
)
e2elog
.
Logf
(
"Service endpoint is up"
)
ginkgo
.
By
(
"Adding 2 dummy users"
)
ginkgo
.
By
(
"Adding 2 dummy users"
)
gomega
.
Expect
(
t
.
addUser
(
"Alice"
))
.
NotTo
(
gomega
.
HaveOccurred
())
err
=
t
.
addUser
(
"Alice"
)
gomega
.
Expect
(
t
.
addUser
(
"Bob"
))
.
NotTo
(
gomega
.
HaveOccurred
())
framework
.
ExpectNoError
(
err
)
err
=
t
.
addUser
(
"Bob"
)
framework
.
ExpectNoError
(
err
)
t
.
successfulWrites
=
2
t
.
successfulWrites
=
2
ginkgo
.
By
(
"Verifying that the users exist"
)
ginkgo
.
By
(
"Verifying that the users exist"
)
...
...
test/e2e/upgrades/kube_proxy_migration.go
View file @
b10e16e8
...
@@ -30,7 +30,6 @@ import (
...
@@ -30,7 +30,6 @@ import (
e2elog
"k8s.io/kubernetes/test/e2e/framework/log"
e2elog
"k8s.io/kubernetes/test/e2e/framework/log"
"github.com/onsi/ginkgo"
"github.com/onsi/ginkgo"
"github.com/onsi/gomega"
)
)
const
(
const
(
...
@@ -50,7 +49,8 @@ func (KubeProxyUpgradeTest) Name() string { return "[sig-network] kube-proxy-upg
...
@@ -50,7 +49,8 @@ func (KubeProxyUpgradeTest) Name() string { return "[sig-network] kube-proxy-upg
// Setup verifies kube-proxy static pods is running before upgrade.
// Setup verifies kube-proxy static pods is running before upgrade.
func
(
t
*
KubeProxyUpgradeTest
)
Setup
(
f
*
framework
.
Framework
)
{
func
(
t
*
KubeProxyUpgradeTest
)
Setup
(
f
*
framework
.
Framework
)
{
ginkgo
.
By
(
"Waiting for kube-proxy static pods running and ready"
)
ginkgo
.
By
(
"Waiting for kube-proxy static pods running and ready"
)
gomega
.
Expect
(
waitForKubeProxyStaticPodsRunning
(
f
.
ClientSet
))
.
NotTo
(
gomega
.
HaveOccurred
())
err
:=
waitForKubeProxyStaticPodsRunning
(
f
.
ClientSet
)
framework
.
ExpectNoError
(
err
)
}
}
// Test validates if kube-proxy is migrated from static pods to DaemonSet.
// Test validates if kube-proxy is migrated from static pods to DaemonSet.
...
@@ -62,10 +62,12 @@ func (t *KubeProxyUpgradeTest) Test(f *framework.Framework, done <-chan struct{}
...
@@ -62,10 +62,12 @@ func (t *KubeProxyUpgradeTest) Test(f *framework.Framework, done <-chan struct{}
<-
done
<-
done
ginkgo
.
By
(
"Waiting for kube-proxy static pods disappear"
)
ginkgo
.
By
(
"Waiting for kube-proxy static pods disappear"
)
gomega
.
Expect
(
waitForKubeProxyStaticPodsDisappear
(
c
))
.
NotTo
(
gomega
.
HaveOccurred
())
err
:=
waitForKubeProxyStaticPodsDisappear
(
c
)
framework
.
ExpectNoError
(
err
)
ginkgo
.
By
(
"Waiting for kube-proxy DaemonSet running and ready"
)
ginkgo
.
By
(
"Waiting for kube-proxy DaemonSet running and ready"
)
gomega
.
Expect
(
waitForKubeProxyDaemonSetRunning
(
c
))
.
NotTo
(
gomega
.
HaveOccurred
())
err
=
waitForKubeProxyDaemonSetRunning
(
c
)
framework
.
ExpectNoError
(
err
)
}
}
// Teardown does nothing.
// Teardown does nothing.
...
@@ -82,7 +84,8 @@ func (KubeProxyDowngradeTest) Name() string { return "[sig-network] kube-proxy-d
...
@@ -82,7 +84,8 @@ func (KubeProxyDowngradeTest) Name() string { return "[sig-network] kube-proxy-d
// Setup verifies kube-proxy DaemonSet is running before upgrade.
// Setup verifies kube-proxy DaemonSet is running before upgrade.
func
(
t
*
KubeProxyDowngradeTest
)
Setup
(
f
*
framework
.
Framework
)
{
func
(
t
*
KubeProxyDowngradeTest
)
Setup
(
f
*
framework
.
Framework
)
{
ginkgo
.
By
(
"Waiting for kube-proxy DaemonSet running and ready"
)
ginkgo
.
By
(
"Waiting for kube-proxy DaemonSet running and ready"
)
gomega
.
Expect
(
waitForKubeProxyDaemonSetRunning
(
f
.
ClientSet
))
.
NotTo
(
gomega
.
HaveOccurred
())
err
:=
waitForKubeProxyDaemonSetRunning
(
f
.
ClientSet
)
framework
.
ExpectNoError
(
err
)
}
}
// Test validates if kube-proxy is migrated from DaemonSet to static pods.
// Test validates if kube-proxy is migrated from DaemonSet to static pods.
...
@@ -94,10 +97,12 @@ func (t *KubeProxyDowngradeTest) Test(f *framework.Framework, done <-chan struct
...
@@ -94,10 +97,12 @@ func (t *KubeProxyDowngradeTest) Test(f *framework.Framework, done <-chan struct
<-
done
<-
done
ginkgo
.
By
(
"Waiting for kube-proxy DaemonSet disappear"
)
ginkgo
.
By
(
"Waiting for kube-proxy DaemonSet disappear"
)
gomega
.
Expect
(
waitForKubeProxyDaemonSetDisappear
(
c
))
.
NotTo
(
gomega
.
HaveOccurred
())
err
:=
waitForKubeProxyDaemonSetDisappear
(
c
)
framework
.
ExpectNoError
(
err
)
ginkgo
.
By
(
"Waiting for kube-proxy static pods running and ready"
)
ginkgo
.
By
(
"Waiting for kube-proxy static pods running and ready"
)
gomega
.
Expect
(
waitForKubeProxyStaticPodsRunning
(
c
))
.
NotTo
(
gomega
.
HaveOccurred
())
err
=
waitForKubeProxyStaticPodsRunning
(
c
)
framework
.
ExpectNoError
(
err
)
}
}
// Teardown does nothing.
// Teardown does nothing.
...
...
test/e2e/upgrades/mysql.go
View file @
b10e16e8
...
@@ -110,8 +110,10 @@ func (t *MySQLUpgradeTest) Setup(f *framework.Framework) {
...
@@ -110,8 +110,10 @@ func (t *MySQLUpgradeTest) Setup(f *framework.Framework) {
e2elog
.
Logf
(
"Service endpoint is up"
)
e2elog
.
Logf
(
"Service endpoint is up"
)
ginkgo
.
By
(
"Adding 2 names to the database"
)
ginkgo
.
By
(
"Adding 2 names to the database"
)
gomega
.
Expect
(
t
.
addName
(
strconv
.
Itoa
(
t
.
nextWrite
)))
.
NotTo
(
gomega
.
HaveOccurred
())
err
=
t
.
addName
(
strconv
.
Itoa
(
t
.
nextWrite
))
gomega
.
Expect
(
t
.
addName
(
strconv
.
Itoa
(
t
.
nextWrite
)))
.
NotTo
(
gomega
.
HaveOccurred
())
framework
.
ExpectNoError
(
err
)
err
=
t
.
addName
(
strconv
.
Itoa
(
t
.
nextWrite
))
framework
.
ExpectNoError
(
err
)
ginkgo
.
By
(
"Verifying that the 2 names have been inserted"
)
ginkgo
.
By
(
"Verifying that the 2 names have been inserted"
)
count
,
err
:=
t
.
countNames
()
count
,
err
:=
t
.
countNames
()
...
...
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