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
949cf9e9
Commit
949cf9e9
authored
Nov 23, 2015
by
k8s-merge-robot
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #17180 from mesosphere/skipped-cleanup
Auto commit by PR queue bot
parents
25ddd24f
2d3c3e1d
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
19 changed files
with
285 additions
and
262 deletions
+285
-262
conformance-test.sh
hack/conformance-test.sh
+1
-1
e2e.sh
hack/jenkins/e2e.sh
+18
-18
upgrade-e2e-test.sh
hack/upgrade-e2e-test.sh
+1
-1
cluster_size_autoscaling.go
test/e2e/cluster_size_autoscaling.go
+5
-5
cluster_upgrade.go
test/e2e/cluster_upgrade.go
+1
-3
density.go
test/e2e/density.go
+8
-17
e2e_test.go
test/e2e/e2e_test.go
+1
-1
empty_dir.go
test/e2e/empty_dir.go
+7
-5
example_cluster_dns.go
test/e2e/example_cluster_dns.go
+161
-0
example_k8petstore.go
test/e2e/example_k8petstore.go
+1
-1
examples.go
test/e2e/examples.go
+11
-166
horizontal_pod_autoscaling.go
test/e2e/horizontal_pod_autoscaling.go
+11
-9
initial_resources.go
test/e2e/initial_resources.go
+2
-2
latency.go
test/e2e/latency.go
+2
-3
load.go
test/e2e/load.go
+2
-2
persistent_volumes.go
test/e2e/persistent_volumes.go
+2
-2
security_context.go
test/e2e/security_context.go
+1
-1
util.go
test/e2e/util.go
+38
-0
volumes.go
test/e2e/volumes.go
+12
-25
No files found.
hack/conformance-test.sh
View file @
949cf9e9
...
@@ -83,5 +83,5 @@ echo "Conformance test checking conformance with Kubernetes version 1.0"
...
@@ -83,5 +83,5 @@ echo "Conformance test checking conformance with Kubernetes version 1.0"
declare
-x
KUBERNETES_CONFORMANCE_TEST
=
"y"
declare
-x
KUBERNETES_CONFORMANCE_TEST
=
"y"
declare
-x
NUM_MINIONS
=
4
declare
-x
NUM_MINIONS
=
4
hack/ginkgo-e2e.sh
-ginkgo
.focus
=
'\[Conformance\]'
hack/ginkgo-e2e.sh
-ginkgo
.focus
=
'\[Conformance\]'
-ginkgo
.skip
=
'\[Skipped\]'
exit
$?
exit
$?
hack/jenkins/e2e.sh
View file @
949cf9e9
...
@@ -103,7 +103,7 @@ if [[ "${KUBERNETES_PROVIDER}" == "aws" ]]; then
...
@@ -103,7 +103,7 @@ if [[ "${KUBERNETES_PROVIDER}" == "aws" ]]; then
if
[[
"
${
PERFORMANCE
:-}
"
==
"true"
]]
;
then
if
[[
"
${
PERFORMANCE
:-}
"
==
"true"
]]
;
then
:
${
MASTER_SIZE
:
=
"m3.xlarge"
}
:
${
MASTER_SIZE
:
=
"m3.xlarge"
}
:
${
NUM_MINIONS
:
=
"100"
}
:
${
NUM_MINIONS
:
=
"100"
}
:
${
GINKGO_TEST_ARGS
:
=
"--ginkgo.focus=
\[
Performance
\
s
suite
\
]
"
}
:
${
GINKGO_TEST_ARGS
:
=
"--ginkgo.focus=
\[
Performance
\]
"
}
else
else
:
${
MASTER_SIZE
:
=
"m3.large"
}
:
${
MASTER_SIZE
:
=
"m3.large"
}
:
${
MINION_SIZE
:
=
"m3.large"
}
:
${
MINION_SIZE
:
=
"m3.large"
}
...
@@ -118,9 +118,9 @@ CURRENT_RELEASE_PUBLISHED_VERSION="ci/latest-1.1"
...
@@ -118,9 +118,9 @@ CURRENT_RELEASE_PUBLISHED_VERSION="ci/latest-1.1"
# Specialized to skip when running reboot tests.
# Specialized to skip when running reboot tests.
REBOOT_SKIP_TESTS
=(
REBOOT_SKIP_TESTS
=(
"
Skipped
"
"
\[
Skipped
\]
"
"Restart
\s
should
\s
restart
\s
all
\s
nodes"
"Restart
\s
should
\s
restart
\s
all
\s
nodes"
"
Example
"
"
\[
Example
\]
"
)
)
# Specialized tests which should be skipped by default for projects.
# Specialized tests which should be skipped by default for projects.
...
@@ -291,7 +291,7 @@ case ${JOB_NAME} in
...
@@ -291,7 +291,7 @@ case ${JOB_NAME} in
kubernetes-e2e-gce-examples
)
kubernetes-e2e-gce-examples
)
:
${
E2E_CLUSTER_NAME
:
=
"jenkins-gce-e2e-examples"
}
:
${
E2E_CLUSTER_NAME
:
=
"jenkins-gce-e2e-examples"
}
:
${
E2E_NETWORK
:
=
"e2e-examples"
}
:
${
E2E_NETWORK
:
=
"e2e-examples"
}
:
${
GINKGO_TEST_ARGS
:
=
"--ginkgo.focus=
Example
"
}
:
${
GINKGO_TEST_ARGS
:
=
"--ginkgo.focus=
\[
Example
\]
"
}
:
${
KUBE_GCE_INSTANCE_PREFIX
:
=
"e2e-examples"
}
:
${
KUBE_GCE_INSTANCE_PREFIX
:
=
"e2e-examples"
}
:
${
PROJECT
:
=
"kubernetes-jenkins"
}
:
${
PROJECT
:
=
"kubernetes-jenkins"
}
;;
;;
...
@@ -300,7 +300,7 @@ case ${JOB_NAME} in
...
@@ -300,7 +300,7 @@ case ${JOB_NAME} in
kubernetes-e2e-gce-autoscaling
)
kubernetes-e2e-gce-autoscaling
)
:
${
E2E_CLUSTER_NAME
:
=
"jenkins-gce-e2e-autoscaling"
}
:
${
E2E_CLUSTER_NAME
:
=
"jenkins-gce-e2e-autoscaling"
}
:
${
E2E_NETWORK
:
=
"e2e-autoscaling"
}
:
${
E2E_NETWORK
:
=
"e2e-autoscaling"
}
:
${
GINKGO_TEST_ARGS
:
=
"--ginkgo.focus=
Autoscaling
\s
Suite
"
}
:
${
GINKGO_TEST_ARGS
:
=
"--ginkgo.focus=
\[
Autoscaling
\]
"
}
:
${
KUBE_GCE_INSTANCE_PREFIX
:
=
"e2e-autoscaling"
}
:
${
KUBE_GCE_INSTANCE_PREFIX
:
=
"e2e-autoscaling"
}
:
${
PROJECT
:
=
"k8s-jnks-e2e-gce-autoscaling"
}
:
${
PROJECT
:
=
"k8s-jnks-e2e-gce-autoscaling"
}
:
${
FAIL_ON_GCP_RESOURCE_LEAK
:
=
"true"
}
:
${
FAIL_ON_GCP_RESOURCE_LEAK
:
=
"true"
}
...
@@ -425,7 +425,7 @@ case ${JOB_NAME} in
...
@@ -425,7 +425,7 @@ case ${JOB_NAME} in
kubernetes-e2e-gce-scalability
)
kubernetes-e2e-gce-scalability
)
:
${
E2E_CLUSTER_NAME
:
=
"jenkins-gce-e2e-scalability"
}
:
${
E2E_CLUSTER_NAME
:
=
"jenkins-gce-e2e-scalability"
}
:
${
E2E_NETWORK
:
=
"e2e-scalability"
}
:
${
E2E_NETWORK
:
=
"e2e-scalability"
}
:
${
GINKGO_TEST_ARGS
:
=
"--ginkgo.focus=
Performance
\s
suite
"
}
:
${
GINKGO_TEST_ARGS
:
=
"--ginkgo.focus=
\[
Performance
\]
"
}
:
${
KUBE_GCE_INSTANCE_PREFIX
:
=
"e2e-scalability"
}
:
${
KUBE_GCE_INSTANCE_PREFIX
:
=
"e2e-scalability"
}
:
${
PROJECT
:
=
"kubernetes-jenkins"
}
:
${
PROJECT
:
=
"kubernetes-jenkins"
}
# Override GCE defaults.
# Override GCE defaults.
...
@@ -444,7 +444,7 @@ case ${JOB_NAME} in
...
@@ -444,7 +444,7 @@ case ${JOB_NAME} in
kubernetes-e2e-gce-scalability-1.1
)
kubernetes-e2e-gce-scalability-1.1
)
:
${
E2E_CLUSTER_NAME
:
=
"jenkins-gce-e2e-scalability-1.1"
}
:
${
E2E_CLUSTER_NAME
:
=
"jenkins-gce-e2e-scalability-1.1"
}
:
${
E2E_NETWORK
:
=
"e2e-scalability-1-1"
}
:
${
E2E_NETWORK
:
=
"e2e-scalability-1-1"
}
:
${
GINKGO_TEST_ARGS
:
=
"--ginkgo.focus=
Performance
\s
suite
"
}
:
${
GINKGO_TEST_ARGS
:
=
"--ginkgo.focus=
\[
Performance
\]
"
}
:
${
JENKINS_PUBLISHED_VERSION
:
=
"ci/latest-1.1"
}
:
${
JENKINS_PUBLISHED_VERSION
:
=
"ci/latest-1.1"
}
:
${
KUBE_GCE_INSTANCE_PREFIX
:
=
"e2e-scalability-1-1"
}
:
${
KUBE_GCE_INSTANCE_PREFIX
:
=
"e2e-scalability-1-1"
}
:
${
KUBE_GCS_STAGING_PATH_SUFFIX
:
=
"scalability-1.1"
}
:
${
KUBE_GCS_STAGING_PATH_SUFFIX
:
=
"scalability-1.1"
}
...
@@ -650,7 +650,7 @@ case ${JOB_NAME} in
...
@@ -650,7 +650,7 @@ case ${JOB_NAME} in
${
REBOOT_SKIP_TESTS
[@]
:+
${
REBOOT_SKIP_TESTS
[@]
}}
\
${
REBOOT_SKIP_TESTS
[@]
:+
${
REBOOT_SKIP_TESTS
[@]
}}
\
)
--ginkgo.focus=
$(
join_regex_no_empty
\
)
--ginkgo.focus=
$(
join_regex_no_empty
\
${
DISRUPTIVE_TESTS
[@]
:+
${
DISRUPTIVE_TESTS
[@]
}}
\
${
DISRUPTIVE_TESTS
[@]
:+
${
DISRUPTIVE_TESTS
[@]
}}
\
"
Autoscaling
\s
Suite.*via
\s
r
eplicationController"
\
"
\[
Autoscaling
\]\s
R
eplicationController"
\
"GCE
\s
L7
\s
LoadBalancer
\s
Controller"
"GCE
\s
L7
\s
LoadBalancer
\s
Controller"
)
"
}
)
"
}
:
${
JENKINS_PUBLISHED_VERSION
:
=
"ci/latest-1.1"
}
:
${
JENKINS_PUBLISHED_VERSION
:
=
"ci/latest-1.1"
}
...
@@ -862,7 +862,7 @@ case ${JOB_NAME} in
...
@@ -862,7 +862,7 @@ case ${JOB_NAME} in
:
${
E2E_UP
:
=
"false"
}
:
${
E2E_UP
:
=
"false"
}
:
${
E2E_TEST
:
=
"true"
}
:
${
E2E_TEST
:
=
"true"
}
:
${
E2E_DOWN
:
=
"false"
}
:
${
E2E_DOWN
:
=
"false"
}
:
${
GINKGO_TEST_ARGS
:
=
"--ginkgo.focus=
Skipped.*Cluster
\s
u
pgrade.*upgrade-master"
}
:
${
GINKGO_TEST_ARGS
:
=
"--ginkgo.focus=
Cluster
\s
U
pgrade.*upgrade-master"
}
;;
;;
kubernetes-upgrade-gke-step3-e2e-old
)
kubernetes-upgrade-gke-step3-e2e-old
)
...
@@ -896,7 +896,7 @@ case ${JOB_NAME} in
...
@@ -896,7 +896,7 @@ case ${JOB_NAME} in
:
${
E2E_UP
:
=
"false"
}
:
${
E2E_UP
:
=
"false"
}
:
${
E2E_TEST
:
=
"true"
}
:
${
E2E_TEST
:
=
"true"
}
:
${
E2E_DOWN
:
=
"false"
}
:
${
E2E_DOWN
:
=
"false"
}
:
${
GINKGO_TEST_ARGS
:
=
"--ginkgo.focus=
Skipped.*Cluster
\s
u
pgrade.*upgrade-cluster"
}
:
${
GINKGO_TEST_ARGS
:
=
"--ginkgo.focus=
Cluster
\s
U
pgrade.*upgrade-cluster"
}
;;
;;
kubernetes-upgrade-gke-step5-e2e-old
)
kubernetes-upgrade-gke-step5-e2e-old
)
...
@@ -977,7 +977,7 @@ case ${JOB_NAME} in
...
@@ -977,7 +977,7 @@ case ${JOB_NAME} in
:
${
E2E_UP
:
=
"false"
}
:
${
E2E_UP
:
=
"false"
}
:
${
E2E_TEST
:
=
"true"
}
:
${
E2E_TEST
:
=
"true"
}
:
${
E2E_DOWN
:
=
"false"
}
:
${
E2E_DOWN
:
=
"false"
}
:
${
GINKGO_TEST_ARGS
:
=
"--ginkgo.focus=
Skipped.*Cluster
\s
u
pgrade.*upgrade-master --upgrade-target=release/latest"
}
:
${
GINKGO_TEST_ARGS
:
=
"--ginkgo.focus=
Cluster
\s
U
pgrade.*upgrade-master --upgrade-target=release/latest"
}
;;
;;
kubernetes-upgrade-stable-latest-gke-step3-e2e-old
)
kubernetes-upgrade-stable-latest-gke-step3-e2e-old
)
...
@@ -1013,7 +1013,7 @@ case ${JOB_NAME} in
...
@@ -1013,7 +1013,7 @@ case ${JOB_NAME} in
:
${
E2E_UP
:
=
"false"
}
:
${
E2E_UP
:
=
"false"
}
:
${
E2E_TEST
:
=
"true"
}
:
${
E2E_TEST
:
=
"true"
}
:
${
E2E_DOWN
:
=
"false"
}
:
${
E2E_DOWN
:
=
"false"
}
:
${
GINKGO_TEST_ARGS
:
=
"--ginkgo.focus=
Skipped.*Cluster
\s
u
pgrade.*upgrade-cluster --upgrade-target=release/latest"
}
:
${
GINKGO_TEST_ARGS
:
=
"--ginkgo.focus=
Cluster
\s
U
pgrade.*upgrade-cluster --upgrade-target=release/latest"
}
;;
;;
kubernetes-upgrade-stable-latest-gke-step5-e2e-old
)
kubernetes-upgrade-stable-latest-gke-step5-e2e-old
)
...
@@ -1092,7 +1092,7 @@ case ${JOB_NAME} in
...
@@ -1092,7 +1092,7 @@ case ${JOB_NAME} in
:
${
E2E_UP
:
=
"false"
}
:
${
E2E_UP
:
=
"false"
}
:
${
E2E_TEST
:
=
"true"
}
:
${
E2E_TEST
:
=
"true"
}
:
${
E2E_DOWN
:
=
"false"
}
:
${
E2E_DOWN
:
=
"false"
}
:
${
GINKGO_TEST_ARGS
:
=
"--ginkgo.focus=
Skipped.*Cluster
\s
u
pgrade.*upgrade-master --upgrade-target=
${
CURRENT_RELEASE_PUBLISHED_VERSION
}
"
}
:
${
GINKGO_TEST_ARGS
:
=
"--ginkgo.focus=
Cluster
\s
U
pgrade.*upgrade-master --upgrade-target=
${
CURRENT_RELEASE_PUBLISHED_VERSION
}
"
}
;;
;;
kubernetes-upgrade-1.0-current-release-gke-step3-e2e-old
)
kubernetes-upgrade-1.0-current-release-gke-step3-e2e-old
)
...
@@ -1128,7 +1128,7 @@ case ${JOB_NAME} in
...
@@ -1128,7 +1128,7 @@ case ${JOB_NAME} in
:
${
E2E_UP
:
=
"false"
}
:
${
E2E_UP
:
=
"false"
}
:
${
E2E_TEST
:
=
"true"
}
:
${
E2E_TEST
:
=
"true"
}
:
${
E2E_DOWN
:
=
"false"
}
:
${
E2E_DOWN
:
=
"false"
}
:
${
GINKGO_TEST_ARGS
:
=
"--ginkgo.focus=
Skipped.*Cluster
\s
u
pgrade.*upgrade-cluster --upgrade-target=
${
CURRENT_RELEASE_PUBLISHED_VERSION
}
"
}
:
${
GINKGO_TEST_ARGS
:
=
"--ginkgo.focus=
Cluster
\s
U
pgrade.*upgrade-cluster --upgrade-target=
${
CURRENT_RELEASE_PUBLISHED_VERSION
}
"
}
;;
;;
kubernetes-upgrade-1.0-current-release-gke-step5-e2e-old
)
kubernetes-upgrade-1.0-current-release-gke-step5-e2e-old
)
...
@@ -1204,7 +1204,7 @@ case ${JOB_NAME} in
...
@@ -1204,7 +1204,7 @@ case ${JOB_NAME} in
:
${
E2E_UP
:
=
"false"
}
:
${
E2E_UP
:
=
"false"
}
:
${
E2E_TEST
:
=
"true"
}
:
${
E2E_TEST
:
=
"true"
}
:
${
E2E_DOWN
:
=
"false"
}
:
${
E2E_DOWN
:
=
"false"
}
:
${
GINKGO_TEST_ARGS
:
=
"--ginkgo.focus=
Skipped.*Cluster
\s
u
pgrade.*upgrade-master"
}
:
${
GINKGO_TEST_ARGS
:
=
"--ginkgo.focus=
Cluster
\s
U
pgrade.*upgrade-master"
}
:
${
NUM_MINIONS
:
=5
}
:
${
NUM_MINIONS
:
=5
}
:
${
KUBE_ENABLE_DEPLOYMENTS
:
=true
}
:
${
KUBE_ENABLE_DEPLOYMENTS
:
=true
}
:
${
KUBE_ENABLE_DAEMONSETS
:
=true
}
:
${
KUBE_ENABLE_DAEMONSETS
:
=true
}
...
@@ -1239,7 +1239,7 @@ case ${JOB_NAME} in
...
@@ -1239,7 +1239,7 @@ case ${JOB_NAME} in
:
${
E2E_UP
:
=
"false"
}
:
${
E2E_UP
:
=
"false"
}
:
${
E2E_TEST
:
=
"true"
}
:
${
E2E_TEST
:
=
"true"
}
:
${
E2E_DOWN
:
=
"false"
}
:
${
E2E_DOWN
:
=
"false"
}
:
${
GINKGO_TEST_ARGS
:
=
"--ginkgo.focus=
Skipped.*Cluster
\s
u
pgrade.*upgrade-cluster"
}
:
${
GINKGO_TEST_ARGS
:
=
"--ginkgo.focus=
Cluster
\s
U
pgrade.*upgrade-cluster"
}
:
${
NUM_MINIONS
:
=5
}
:
${
NUM_MINIONS
:
=5
}
:
${
KUBE_ENABLE_DEPLOYMENTS
:
=true
}
:
${
KUBE_ENABLE_DEPLOYMENTS
:
=true
}
:
${
KUBE_ENABLE_DAEMONSETS
:
=true
}
:
${
KUBE_ENABLE_DAEMONSETS
:
=true
}
...
@@ -1316,7 +1316,7 @@ case ${JOB_NAME} in
...
@@ -1316,7 +1316,7 @@ case ${JOB_NAME} in
:
${
E2E_UP
:
=
"false"
}
:
${
E2E_UP
:
=
"false"
}
:
${
E2E_TEST
:
=
"true"
}
:
${
E2E_TEST
:
=
"true"
}
:
${
E2E_DOWN
:
=
"false"
}
:
${
E2E_DOWN
:
=
"false"
}
:
${
GINKGO_TEST_ARGS
:
=
"--ginkgo.focus=
Skipped.*Cluster
\s
u
pgrade.*upgrade-master --upgrade-target=
${
CURRENT_RELEASE_PUBLISHED_VERSION
}
"
}
:
${
GINKGO_TEST_ARGS
:
=
"--ginkgo.focus=
Cluster
\s
U
pgrade.*upgrade-master --upgrade-target=
${
CURRENT_RELEASE_PUBLISHED_VERSION
}
"
}
:
${
KUBE_GCE_INSTANCE_PREFIX
:
=
"e2e-upgrade-1-0"
}
:
${
KUBE_GCE_INSTANCE_PREFIX
:
=
"e2e-upgrade-1-0"
}
:
${
NUM_MINIONS
:
=5
}
:
${
NUM_MINIONS
:
=5
}
:
${
KUBE_ENABLE_DEPLOYMENTS
:
=true
}
:
${
KUBE_ENABLE_DEPLOYMENTS
:
=true
}
...
@@ -1353,7 +1353,7 @@ case ${JOB_NAME} in
...
@@ -1353,7 +1353,7 @@ case ${JOB_NAME} in
:
${
E2E_UP
:
=
"false"
}
:
${
E2E_UP
:
=
"false"
}
:
${
E2E_TEST
:
=
"true"
}
:
${
E2E_TEST
:
=
"true"
}
:
${
E2E_DOWN
:
=
"false"
}
:
${
E2E_DOWN
:
=
"false"
}
:
${
GINKGO_TEST_ARGS
:
=
"--ginkgo.focus=
Skipped.*Cluster
\s
u
pgrade.*upgrade-cluster --upgrade-target=
${
CURRENT_RELEASE_PUBLISHED_VERSION
}
"
}
:
${
GINKGO_TEST_ARGS
:
=
"--ginkgo.focus=
Cluster
\s
U
pgrade.*upgrade-cluster --upgrade-target=
${
CURRENT_RELEASE_PUBLISHED_VERSION
}
"
}
:
${
KUBE_GCE_INSTANCE_PREFIX
:
=
"e2e-upgrade-1-0"
}
:
${
KUBE_GCE_INSTANCE_PREFIX
:
=
"e2e-upgrade-1-0"
}
:
${
NUM_MINIONS
:
=5
}
:
${
NUM_MINIONS
:
=5
}
:
${
KUBE_ENABLE_DEPLOYMENTS
:
=true
}
:
${
KUBE_ENABLE_DEPLOYMENTS
:
=true
}
...
...
hack/upgrade-e2e-test.sh
View file @
949cf9e9
...
@@ -16,7 +16,7 @@
...
@@ -16,7 +16,7 @@
# This does a checked upgrade of the MASTER using the locally built release, then runs e2e.
# This does a checked upgrade of the MASTER using the locally built release, then runs e2e.
echo
"Running the checked master upgrade."
echo
"Running the checked master upgrade."
go run
"
$(
dirname
$0
)
/e2e.go"
-build
-up
-v
-test
-test_args
=
'--ginkgo.focus=
Skipped.*Cluster\su
pgrade.*gce-upgrade'
-check_version_skew
=
false
go run
"
$(
dirname
$0
)
/e2e.go"
-build
-up
-v
-test
-test_args
=
'--ginkgo.focus=
Cluster\sU
pgrade.*gce-upgrade'
-check_version_skew
=
false
if
[
$?
-eq
0
]
;
then
if
[
$?
-eq
0
]
;
then
echo
"Master upgrade complete. Running e2e on the upgraded cluster."
echo
"Master upgrade complete. Running e2e on the upgraded cluster."
go run
"
$(
dirname
$0
)
/e2e.go"
-v
-version
=
""
-test
-check_version_skew
=
false
go run
"
$(
dirname
$0
)
/e2e.go"
-v
-version
=
""
-test
-check_version_skew
=
false
...
...
test/e2e/cluster_size_autoscaling.go
View file @
949cf9e9
...
@@ -34,7 +34,7 @@ const (
...
@@ -34,7 +34,7 @@ const (
scaleDownTimeout
=
30
*
time
.
Minute
scaleDownTimeout
=
30
*
time
.
Minute
)
)
var
_
=
Describe
(
"
Autoscaling
"
,
func
()
{
var
_
=
Describe
(
"
[Autoscaling] [Skipped]
"
,
func
()
{
f
:=
NewFramework
(
"autoscaling"
)
f
:=
NewFramework
(
"autoscaling"
)
var
nodeCount
int
var
nodeCount
int
var
coresPerNode
int
var
coresPerNode
int
...
@@ -57,7 +57,7 @@ var _ = Describe("Autoscaling", func() {
...
@@ -57,7 +57,7 @@ var _ = Describe("Autoscaling", func() {
cleanUpAutoscaler
()
cleanUpAutoscaler
()
})
})
It
(
"
[Skipped][Autoscaling Suite] s
hould scale cluster size based on cpu utilization"
,
func
()
{
It
(
"
S
hould scale cluster size based on cpu utilization"
,
func
()
{
setUpAutoscaler
(
"cpu/node_utilization"
,
0.4
,
nodeCount
,
nodeCount
+
1
)
setUpAutoscaler
(
"cpu/node_utilization"
,
0.4
,
nodeCount
,
nodeCount
+
1
)
// Consume 50% CPU
// Consume 50% CPU
...
@@ -71,7 +71,7 @@ var _ = Describe("Autoscaling", func() {
...
@@ -71,7 +71,7 @@ var _ = Describe("Autoscaling", func() {
expectNoError
(
waitForClusterSize
(
f
.
Client
,
nodeCount
,
scaleDownTimeout
))
expectNoError
(
waitForClusterSize
(
f
.
Client
,
nodeCount
,
scaleDownTimeout
))
})
})
It
(
"
[Skipped][Autoscaling Suite] s
hould scale cluster size based on cpu reservation"
,
func
()
{
It
(
"
S
hould scale cluster size based on cpu reservation"
,
func
()
{
setUpAutoscaler
(
"cpu/node_reservation"
,
0.5
,
nodeCount
,
nodeCount
+
1
)
setUpAutoscaler
(
"cpu/node_reservation"
,
0.5
,
nodeCount
,
nodeCount
+
1
)
ReserveCpu
(
f
,
"cpu-reservation"
,
600
*
nodeCount
*
coresPerNode
)
ReserveCpu
(
f
,
"cpu-reservation"
,
600
*
nodeCount
*
coresPerNode
)
...
@@ -81,7 +81,7 @@ var _ = Describe("Autoscaling", func() {
...
@@ -81,7 +81,7 @@ var _ = Describe("Autoscaling", func() {
expectNoError
(
waitForClusterSize
(
f
.
Client
,
nodeCount
,
scaleDownTimeout
))
expectNoError
(
waitForClusterSize
(
f
.
Client
,
nodeCount
,
scaleDownTimeout
))
})
})
It
(
"
[Skipped][Autoscaling Suite] s
hould scale cluster size based on memory utilization"
,
func
()
{
It
(
"
S
hould scale cluster size based on memory utilization"
,
func
()
{
setUpAutoscaler
(
"memory/node_utilization"
,
0.6
,
nodeCount
,
nodeCount
+
1
)
setUpAutoscaler
(
"memory/node_utilization"
,
0.6
,
nodeCount
,
nodeCount
+
1
)
// Consume 60% of total memory capacity
// Consume 60% of total memory capacity
...
@@ -96,7 +96,7 @@ var _ = Describe("Autoscaling", func() {
...
@@ -96,7 +96,7 @@ var _ = Describe("Autoscaling", func() {
expectNoError
(
waitForClusterSize
(
f
.
Client
,
nodeCount
,
scaleDownTimeout
))
expectNoError
(
waitForClusterSize
(
f
.
Client
,
nodeCount
,
scaleDownTimeout
))
})
})
It
(
"
[Skipped][Autoscaling Suite] s
hould scale cluster size based on memory reservation"
,
func
()
{
It
(
"
S
hould scale cluster size based on memory reservation"
,
func
()
{
setUpAutoscaler
(
"memory/node_reservation"
,
0.5
,
nodeCount
,
nodeCount
+
1
)
setUpAutoscaler
(
"memory/node_reservation"
,
0.5
,
nodeCount
,
nodeCount
+
1
)
ReserveMemory
(
f
,
"memory-reservation"
,
nodeCount
*
memCapacityMb
*
6
/
10
)
ReserveMemory
(
f
,
"memory-reservation"
,
nodeCount
*
memCapacityMb
*
6
/
10
)
...
...
test/e2e/cluster_upgrade.go
View file @
949cf9e9
...
@@ -144,9 +144,8 @@ func nodeUpgradeGKE(v string) error {
...
@@ -144,9 +144,8 @@ func nodeUpgradeGKE(v string) error {
return
err
return
err
}
}
var
_
=
Describe
(
"
Skipped
"
,
func
()
{
var
_
=
Describe
(
"
Cluster Upgrade [Skipped]
"
,
func
()
{
Describe
(
"Cluster upgrade"
,
func
()
{
svcName
,
replicas
:=
"baz"
,
2
svcName
,
replicas
:=
"baz"
,
2
var
rcName
,
ip
,
v
string
var
rcName
,
ip
,
v
string
var
ingress
api
.
LoadBalancerIngress
var
ingress
api
.
LoadBalancerIngress
...
@@ -283,7 +282,6 @@ var _ = Describe("Skipped", func() {
...
@@ -283,7 +282,6 @@ var _ = Describe("Skipped", func() {
expectNoError
(
validate
(
f
,
svcName
,
rcName
,
ingress
,
replicas
))
expectNoError
(
validate
(
f
,
svcName
,
rcName
,
ingress
,
replicas
))
})
})
})
})
})
})
})
func
testMasterUpgrade
(
ip
,
v
string
,
mUp
func
(
v
string
)
error
)
{
func
testMasterUpgrade
(
ip
,
v
string
,
mUp
func
(
v
string
)
error
)
{
...
...
test/e2e/density.go
View file @
949cf9e9
...
@@ -70,11 +70,11 @@ func extractLatencyMetrics(latencies []podLatencyData) LatencyMetric {
...
@@ -70,11 +70,11 @@ func extractLatencyMetrics(latencies []podLatencyData) LatencyMetric {
return
LatencyMetric
{
Perc50
:
perc50
,
Perc90
:
perc90
,
Perc99
:
perc99
}
return
LatencyMetric
{
Perc50
:
perc50
,
Perc90
:
perc90
,
Perc99
:
perc99
}
}
}
// This test suite can take a long time to run,
so by default it is added to
// This test suite can take a long time to run,
and can affect or be affected by other tests.
// the ginkgo.skip list (see driver.go).
//
So by default it is added to
the ginkgo.skip list (see driver.go).
// To run this suite you must explicitly ask for it by setting the
// To run this suite you must explicitly ask for it by setting the
// -t/--test flag or ginkgo.focus flag.
// -t/--test flag or ginkgo.focus flag.
var
_
=
Describe
(
"Density"
,
func
()
{
var
_
=
Describe
(
"Density
[Skipped]
"
,
func
()
{
var
c
*
client
.
Client
var
c
*
client
.
Client
var
nodeCount
int
var
nodeCount
int
var
RCName
string
var
RCName
string
...
@@ -151,10 +151,7 @@ var _ = Describe("Density", func() {
...
@@ -151,10 +151,7 @@ var _ = Describe("Density", func() {
}
}
})
})
// Tests with "Skipped" substring in their name will be skipped when running
// e2e test suite without --ginkgo.focus & --ginkgo.skip flags.
type
Density
struct
{
type
Density
struct
{
skip
bool
// Controls if e2e latency tests should be run (they are slow)
// Controls if e2e latency tests should be run (they are slow)
runLatencyTest
bool
runLatencyTest
bool
podsPerNode
int
podsPerNode
int
...
@@ -163,25 +160,19 @@ var _ = Describe("Density", func() {
...
@@ -163,25 +160,19 @@ var _ = Describe("Density", func() {
}
}
densityTests
:=
[]
Density
{
densityTests
:=
[]
Density
{
// This test should not be run in a regular jenkins run, because it is not isolated enough
// (metrics from other tests affects this one).
// TODO: Reenable once we can measure latency only from a single test.
// TODO: Expose runLatencyTest as ginkgo flag.
// TODO: Expose runLatencyTest as ginkgo flag.
{
podsPerNode
:
3
,
skip
:
true
,
runLatencyTest
:
false
,
interval
:
10
*
time
.
Second
},
{
podsPerNode
:
3
,
runLatencyTest
:
false
,
interval
:
10
*
time
.
Second
},
{
podsPerNode
:
30
,
skip
:
true
,
runLatencyTest
:
true
,
interval
:
10
*
time
.
Second
},
{
podsPerNode
:
30
,
runLatencyTest
:
true
,
interval
:
10
*
time
.
Second
},
// More than 30 pods per node is outside our v1.0 goals.
// More than 30 pods per node is outside our v1.0 goals.
// We might want to enable those tests in the future.
// We might want to enable those tests in the future.
{
podsPerNode
:
50
,
skip
:
true
,
runLatencyTest
:
false
,
interval
:
10
*
time
.
Second
},
{
podsPerNode
:
50
,
runLatencyTest
:
false
,
interval
:
10
*
time
.
Second
},
{
podsPerNode
:
100
,
skip
:
true
,
runLatencyTest
:
false
,
interval
:
1
*
time
.
Second
},
{
podsPerNode
:
100
,
runLatencyTest
:
false
,
interval
:
1
*
time
.
Second
},
}
}
for
_
,
testArg
:=
range
densityTests
{
for
_
,
testArg
:=
range
densityTests
{
name
:=
fmt
.
Sprintf
(
"should allow starting %d pods per node"
,
testArg
.
podsPerNode
)
name
:=
fmt
.
Sprintf
(
"should allow starting %d pods per node"
,
testArg
.
podsPerNode
)
if
testArg
.
podsPerNode
==
30
{
if
testArg
.
podsPerNode
==
30
{
name
=
"[Performance suite] "
+
name
name
=
"[Performance] "
+
name
}
if
testArg
.
skip
{
name
=
"[Skipped] "
+
name
}
}
itArg
:=
testArg
itArg
:=
testArg
It
(
name
,
func
()
{
It
(
name
,
func
()
{
...
...
test/e2e/e2e_test.go
View file @
949cf9e9
...
@@ -123,7 +123,7 @@ func TestE2E(t *testing.T) {
...
@@ -123,7 +123,7 @@ func TestE2E(t *testing.T) {
// Disable skipped tests unless they are explicitly requested.
// Disable skipped tests unless they are explicitly requested.
if
config
.
GinkgoConfig
.
FocusString
==
""
&&
config
.
GinkgoConfig
.
SkipString
==
""
{
if
config
.
GinkgoConfig
.
FocusString
==
""
&&
config
.
GinkgoConfig
.
SkipString
==
""
{
config
.
GinkgoConfig
.
SkipString
=
"Skipped"
config
.
GinkgoConfig
.
SkipString
=
`\[Skipped\]`
}
}
gomega
.
RegisterFailHandler
(
ginkgo
.
Fail
)
gomega
.
RegisterFailHandler
(
ginkgo
.
Fail
)
...
...
test/e2e/empty_dir.go
View file @
949cf9e9
...
@@ -37,22 +37,24 @@ var _ = Describe("EmptyDir volumes", func() {
...
@@ -37,22 +37,24 @@ var _ = Describe("EmptyDir volumes", func() {
f
:=
NewFramework
(
"emptydir"
)
f
:=
NewFramework
(
"emptydir"
)
// TODO: Enable security context everywhere and remove skip for FSGroup
// TODO: Remove [Skipped] when security context is enabled everywhere
It
(
"new files should be created with FSGroup ownership when container is root [Conformance] [Skipped]"
,
func
()
{
Context
(
"when FSGroup is specified [Skipped]"
,
func
()
{
It
(
"new files should be created with FSGroup ownership when container is root [Conformance]"
,
func
()
{
doTestSetgidFSGroup
(
f
,
testImageRootUid
,
api
.
StorageMediumMemory
)
doTestSetgidFSGroup
(
f
,
testImageRootUid
,
api
.
StorageMediumMemory
)
})
})
It
(
"new files should be created with FSGroup ownership when container is non-root [Conformance] [Skipped
]"
,
func
()
{
It
(
"new files should be created with FSGroup ownership when container is non-root [Conformance
]"
,
func
()
{
doTestSetgidFSGroup
(
f
,
testImageNonRootUid
,
api
.
StorageMediumMemory
)
doTestSetgidFSGroup
(
f
,
testImageNonRootUid
,
api
.
StorageMediumMemory
)
})
})
It
(
"volume on default medium should have the correct mode using FSGroup [Conformance] [Skipped
]"
,
func
()
{
It
(
"volume on default medium should have the correct mode using FSGroup [Conformance
]"
,
func
()
{
doTestVolumeModeFSGroup
(
f
,
testImageRootUid
,
api
.
StorageMediumDefault
)
doTestVolumeModeFSGroup
(
f
,
testImageRootUid
,
api
.
StorageMediumDefault
)
})
})
It
(
"volume on tmpfs should have the correct mode using FSGroup [Conformance] [Skipped
]"
,
func
()
{
It
(
"volume on tmpfs should have the correct mode using FSGroup [Conformance
]"
,
func
()
{
doTestVolumeModeFSGroup
(
f
,
testImageRootUid
,
api
.
StorageMediumMemory
)
doTestVolumeModeFSGroup
(
f
,
testImageRootUid
,
api
.
StorageMediumMemory
)
})
})
})
It
(
"volume on tmpfs should have the correct mode [Conformance]"
,
func
()
{
It
(
"volume on tmpfs should have the correct mode [Conformance]"
,
func
()
{
doTestVolumeMode
(
f
,
testImageRootUid
,
api
.
StorageMediumMemory
)
doTestVolumeMode
(
f
,
testImageRootUid
,
api
.
StorageMediumMemory
)
...
...
test/e2e/example_cluster_dns.go
0 → 100644
View file @
949cf9e9
/*
Copyright 2015 The Kubernetes Authors All rights reserved.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
*/
package
e2e
import
(
"fmt"
"path/filepath"
"time"
"k8s.io/kubernetes/pkg/api"
client
"k8s.io/kubernetes/pkg/client/unversioned"
"k8s.io/kubernetes/pkg/fields"
"k8s.io/kubernetes/pkg/labels"
.
"github.com/onsi/ginkgo"
.
"github.com/onsi/gomega"
)
const
(
dnsReadyTimeout
=
time
.
Minute
)
const
queryDnsPythonTemplate
string
=
`
import socket
try:
socket.gethostbyname('%s')
print 'ok'
except:
print 'err'`
var
_
=
Describe
(
"[Example] ClusterDns"
,
func
()
{
framework
:=
NewFramework
(
"cluster-dns"
)
var
c
*
client
.
Client
BeforeEach
(
func
()
{
c
=
framework
.
Client
})
It
(
"should create pod that uses dns [Conformance]"
,
func
()
{
mkpath
:=
func
(
file
string
)
string
{
return
filepath
.
Join
(
testContext
.
RepoRoot
,
"examples/cluster-dns"
,
file
)
}
// contrary to the example, this test does not use contexts, for simplicity
// namespaces are passed directly.
// Also, for simplicity, we don't use yamls with namespaces, but we
// create testing namespaces instead.
backendRcYaml
:=
mkpath
(
"dns-backend-rc.yaml"
)
backendRcName
:=
"dns-backend"
backendSvcYaml
:=
mkpath
(
"dns-backend-service.yaml"
)
backendSvcName
:=
"dns-backend"
backendPodName
:=
"dns-backend"
frontendPodYaml
:=
mkpath
(
"dns-frontend-pod.yaml"
)
frontendPodName
:=
"dns-frontend"
frontendPodContainerName
:=
"dns-frontend"
podOutput
:=
"Hello World!"
// we need two namespaces anyway, so let's forget about
// the one created in BeforeEach and create two new ones.
namespaces
:=
[]
*
api
.
Namespace
{
nil
,
nil
}
for
i
:=
range
namespaces
{
var
err
error
namespaces
[
i
],
err
=
createTestingNS
(
fmt
.
Sprintf
(
"dnsexample%d"
,
i
),
c
)
if
testContext
.
DeleteNamespace
{
if
namespaces
[
i
]
!=
nil
{
defer
deleteNS
(
c
,
namespaces
[
i
]
.
Name
,
5
*
time
.
Minute
/* namespace deletion timeout */
)
}
Expect
(
err
)
.
NotTo
(
HaveOccurred
())
}
else
{
Logf
(
"Found DeleteNamespace=false, skipping namespace deletion!"
)
}
}
for
_
,
ns
:=
range
namespaces
{
runKubectlOrDie
(
"create"
,
"-f"
,
backendRcYaml
,
getNsCmdFlag
(
ns
))
}
for
_
,
ns
:=
range
namespaces
{
runKubectlOrDie
(
"create"
,
"-f"
,
backendSvcYaml
,
getNsCmdFlag
(
ns
))
}
// wait for objects
for
_
,
ns
:=
range
namespaces
{
waitForRCPodsRunning
(
c
,
ns
.
Name
,
backendRcName
)
waitForService
(
c
,
ns
.
Name
,
backendSvcName
,
true
,
poll
,
serviceStartTimeout
)
}
// it is not enough that pods are running because they may be set to running, but
// the application itself may have not been initialized. Just query the application.
for
_
,
ns
:=
range
namespaces
{
label
:=
labels
.
SelectorFromSet
(
labels
.
Set
(
map
[
string
]
string
{
"name"
:
backendRcName
}))
pods
,
err
:=
c
.
Pods
(
ns
.
Name
)
.
List
(
label
,
fields
.
Everything
())
Expect
(
err
)
.
NotTo
(
HaveOccurred
())
err
=
podsResponding
(
c
,
ns
.
Name
,
backendPodName
,
false
,
pods
)
Expect
(
err
)
.
NotTo
(
HaveOccurred
(),
"waiting for all pods to respond"
)
Logf
(
"found %d backend pods responding in namespace %s"
,
len
(
pods
.
Items
),
ns
.
Name
)
err
=
serviceResponding
(
c
,
ns
.
Name
,
backendSvcName
)
Expect
(
err
)
.
NotTo
(
HaveOccurred
(),
"waiting for the service to respond"
)
}
// Now another tricky part:
// It may happen that the service name is not yet in DNS.
// So if we start our pod, it will fail. We must make sure
// the name is already resolvable. So let's try to query DNS from
// the pod we have, until we find our service name.
// This complicated code may be removed if the pod itself retried after
// dns error or timeout.
// This code is probably unnecessary, but let's stay on the safe side.
label
:=
labels
.
SelectorFromSet
(
labels
.
Set
(
map
[
string
]
string
{
"name"
:
backendPodName
}))
pods
,
err
:=
c
.
Pods
(
namespaces
[
0
]
.
Name
)
.
List
(
label
,
fields
.
Everything
())
if
err
!=
nil
||
pods
==
nil
||
len
(
pods
.
Items
)
==
0
{
Failf
(
"no running pods found"
)
}
podName
:=
pods
.
Items
[
0
]
.
Name
queryDns
:=
fmt
.
Sprintf
(
queryDnsPythonTemplate
,
backendSvcName
+
"."
+
namespaces
[
0
]
.
Name
)
_
,
err
=
lookForStringInPodExec
(
namespaces
[
0
]
.
Name
,
podName
,
[]
string
{
"python"
,
"-c"
,
queryDns
},
"ok"
,
dnsReadyTimeout
)
Expect
(
err
)
.
NotTo
(
HaveOccurred
(),
"waiting for output from pod exec"
)
updatedPodYaml
:=
prepareResourceWithReplacedString
(
frontendPodYaml
,
"dns-backend.development.cluster.local"
,
fmt
.
Sprintf
(
"dns-backend.%s.cluster.local"
,
namespaces
[
0
]
.
Name
))
// create a pod in each namespace
for
_
,
ns
:=
range
namespaces
{
newKubectlCommand
(
"create"
,
"-f"
,
"-"
,
getNsCmdFlag
(
ns
))
.
withStdinData
(
updatedPodYaml
)
.
execOrDie
()
}
// wait until the pods have been scheduler, i.e. are not Pending anymore. Remember
// that we cannot wait for the pods to be running because our pods terminate by themselves.
for
_
,
ns
:=
range
namespaces
{
err
:=
waitForPodNotPending
(
c
,
ns
.
Name
,
frontendPodName
)
expectNoError
(
err
)
}
// wait for pods to print their result
for
_
,
ns
:=
range
namespaces
{
_
,
err
:=
lookForStringInLog
(
ns
.
Name
,
frontendPodName
,
frontendPodContainerName
,
podOutput
,
podStartTimeout
)
Expect
(
err
)
.
NotTo
(
HaveOccurred
())
}
})
})
func
getNsCmdFlag
(
ns
*
api
.
Namespace
)
string
{
return
fmt
.
Sprintf
(
"--namespace=%v"
,
ns
.
Name
)
}
test/e2e/k8petstore.go
→
test/e2e/
example_
k8petstore.go
View file @
949cf9e9
...
@@ -150,7 +150,7 @@ T:
...
@@ -150,7 +150,7 @@ T:
Ω
(
totalTransactions
)
.
Should
(
BeNumerically
(
">"
,
minExpected
))
Ω
(
totalTransactions
)
.
Should
(
BeNumerically
(
">"
,
minExpected
))
}
}
var
_
=
Describe
(
"[
Skipped][Example] Pet Store
"
,
func
()
{
var
_
=
Describe
(
"[
Example] Pet Store [Skipped]
"
,
func
()
{
// The number of minions dictates total number of generators/transaction expectations.
// The number of minions dictates total number of generators/transaction expectations.
var
minionCount
int
var
minionCount
int
...
...
test/e2e/examples.go
View file @
949cf9e9
This diff is collapsed.
Click to expand it.
test/e2e/horizontal_pod_autoscaling.go
View file @
949cf9e9
...
@@ -17,7 +17,6 @@ limitations under the License.
...
@@ -17,7 +17,6 @@ limitations under the License.
package
e2e
package
e2e
import
(
import
(
"fmt"
"time"
"time"
"k8s.io/kubernetes/pkg/api"
"k8s.io/kubernetes/pkg/api"
...
@@ -33,29 +32,32 @@ const (
...
@@ -33,29 +32,32 @@ const (
stabilityTimeout
=
10
*
time
.
Minute
stabilityTimeout
=
10
*
time
.
Minute
)
)
var
_
=
Describe
(
"Horizontal pod autoscaling"
,
func
()
{
var
_
=
Describe
(
"Horizontal pod autoscaling (scale resource: CPU) [Skipped]"
,
func
()
{
var
rc
*
ResourceConsumer
var
rc
*
ResourceConsumer
f
:=
NewFramework
(
"horizontal-pod-autoscaling"
)
f
:=
NewFramework
(
"horizontal-pod-autoscaling"
)
titleUp
:=
"
%s should scale from 1 pod to 3 pods and from 3 to 5 (via %s, with scale resource: CPU)
"
titleUp
:=
"
Should scale from 1 pod to 3 pods and from 3 to 5
"
titleDown
:=
"
%s should scale from 5 pods to 3 pods and from 3 to 1 (via %s, with scale resource: CPU)
"
titleDown
:=
"
Should scale from 5 pods to 3 pods and from 3 to 1
"
Describe
(
"Deployment"
,
func
()
{
// CPU tests via deployments
// CPU tests via deployments
It
(
fmt
.
Sprintf
(
titleUp
,
"[Skipped]"
,
kindDeployment
)
,
func
()
{
It
(
titleUp
,
func
()
{
scaleUp
(
"deployment"
,
kindDeployment
,
rc
,
f
)
scaleUp
(
"deployment"
,
kindDeployment
,
rc
,
f
)
})
})
It
(
fmt
.
Sprintf
(
titleDown
,
"[Skipped]"
,
kindDeployment
)
,
func
()
{
It
(
titleDown
,
func
()
{
scaleDown
(
"deployment"
,
kindDeployment
,
rc
,
f
)
scaleDown
(
"deployment"
,
kindDeployment
,
rc
,
f
)
})
})
})
Describe
(
"ReplicationController"
,
func
()
{
// CPU tests via replication controllers
// CPU tests via replication controllers
It
(
fmt
.
Sprintf
(
titleUp
,
"[Skipped][Autoscaling Suite]"
,
kindRC
)
,
func
()
{
It
(
titleUp
,
func
()
{
scaleUp
(
"rc"
,
kindRC
,
rc
,
f
)
scaleUp
(
"rc"
,
kindRC
,
rc
,
f
)
})
})
It
(
fmt
.
Sprintf
(
titleDown
,
"[Skipped][Autoscaling Suite]"
,
kindRC
)
,
func
()
{
It
(
titleDown
,
func
()
{
scaleDown
(
"rc"
,
kindRC
,
rc
,
f
)
scaleDown
(
"rc"
,
kindRC
,
rc
,
f
)
})
})
})
})
})
func
scaleUp
(
name
,
kind
string
,
rc
*
ResourceConsumer
,
f
*
Framework
)
{
func
scaleUp
(
name
,
kind
string
,
rc
*
ResourceConsumer
,
f
*
Framework
)
{
...
...
test/e2e/initial_resources.go
View file @
949cf9e9
...
@@ -26,10 +26,10 @@ import (
...
@@ -26,10 +26,10 @@ import (
"k8s.io/kubernetes/pkg/api"
"k8s.io/kubernetes/pkg/api"
)
)
var
_
=
Describe
(
"Initial Resources"
,
func
()
{
var
_
=
Describe
(
"Initial Resources
[Skipped]
"
,
func
()
{
f
:=
NewFramework
(
"initial-resources"
)
f
:=
NewFramework
(
"initial-resources"
)
It
(
"
[Skipped]
should set initial resources based on historical data"
,
func
()
{
It
(
"should set initial resources based on historical data"
,
func
()
{
// Cleanup data in InfluxDB that left from previous tests.
// Cleanup data in InfluxDB that left from previous tests.
influxdbClient
,
err
:=
getInfluxdbClient
(
f
.
Client
)
influxdbClient
,
err
:=
getInfluxdbClient
(
f
.
Client
)
expectNoError
(
err
,
"failed to create influxdb client"
)
expectNoError
(
err
,
"failed to create influxdb client"
)
...
...
test/e2e/latency.go
View file @
949cf9e9
...
@@ -39,7 +39,7 @@ import (
...
@@ -39,7 +39,7 @@ import (
.
"github.com/onsi/gomega"
.
"github.com/onsi/gomega"
)
)
var
_
=
Describe
(
"[Performance
Suite] Latency
"
,
func
()
{
var
_
=
Describe
(
"[Performance
] Latency [Skipped]
"
,
func
()
{
var
c
*
client
.
Client
var
c
*
client
.
Client
var
nodeCount
int
var
nodeCount
int
var
additionalPodsPrefix
string
var
additionalPodsPrefix
string
...
@@ -100,8 +100,7 @@ var _ = Describe("[Performance Suite] Latency", func() {
...
@@ -100,8 +100,7 @@ var _ = Describe("[Performance Suite] Latency", func() {
}
}
})
})
// Skipped to avoid running in e2e
It
(
"pod start latency should be acceptable"
,
func
()
{
It
(
"[Skipped] pod start latency should be acceptable"
,
func
()
{
runLatencyTest
(
nodeCount
,
c
,
ns
)
runLatencyTest
(
nodeCount
,
c
,
ns
)
})
})
})
})
...
...
test/e2e/load.go
View file @
949cf9e9
...
@@ -47,7 +47,7 @@ const (
...
@@ -47,7 +47,7 @@ const (
// the ginkgo.skip list (see driver.go).
// the ginkgo.skip list (see driver.go).
// To run this suite you must explicitly ask for it by setting the
// To run this suite you must explicitly ask for it by setting the
// -t/--test flag or ginkgo.focus flag.
// -t/--test flag or ginkgo.focus flag.
var
_
=
Describe
(
"
Load capacity
"
,
func
()
{
var
_
=
Describe
(
"
[Performance] Load capacity [Skipped]
"
,
func
()
{
var
c
*
client
.
Client
var
c
*
client
.
Client
var
nodeCount
int
var
nodeCount
int
var
ns
string
var
ns
string
...
@@ -97,7 +97,7 @@ var _ = Describe("Load capacity", func() {
...
@@ -97,7 +97,7 @@ var _ = Describe("Load capacity", func() {
}
}
for
_
,
testArg
:=
range
loadTests
{
for
_
,
testArg
:=
range
loadTests
{
name
:=
fmt
.
Sprintf
(
"
[Skipped] [Performance suite]
should be able to handle %v pods per node"
,
testArg
.
podsPerNode
)
name
:=
fmt
.
Sprintf
(
"should be able to handle %v pods per node"
,
testArg
.
podsPerNode
)
itArg
:=
testArg
itArg
:=
testArg
It
(
name
,
func
()
{
It
(
name
,
func
()
{
...
...
test/e2e/persistent_volumes.go
View file @
949cf9e9
...
@@ -31,7 +31,7 @@ import (
...
@@ -31,7 +31,7 @@ import (
// Marked with [Skipped] to skip the test by default (see driver.go),
// Marked with [Skipped] to skip the test by default (see driver.go),
// the test needs privileged containers, which are disabled by default.
// the test needs privileged containers, which are disabled by default.
// Run the test with "go run hack/e2e.go ... --ginkgo.focus=PersistentVolume"
// Run the test with "go run hack/e2e.go ... --ginkgo.focus=PersistentVolume"
var
_
=
Describe
(
"
[Skipped] persistentVolumes
"
,
func
()
{
var
_
=
Describe
(
"
PersistentVolumes [Skipped]
"
,
func
()
{
framework
:=
NewFramework
(
"pv"
)
framework
:=
NewFramework
(
"pv"
)
var
c
*
client
.
Client
var
c
*
client
.
Client
var
ns
string
var
ns
string
...
@@ -41,7 +41,7 @@ var _ = Describe("[Skipped] persistentVolumes", func() {
...
@@ -41,7 +41,7 @@ var _ = Describe("[Skipped] persistentVolumes", func() {
ns
=
framework
.
Namespace
.
Name
ns
=
framework
.
Namespace
.
Name
})
})
It
(
"
PersistentVolume
"
,
func
()
{
It
(
"
NFS volume can be created, bound, retrieved, unbound, and used by a pod
"
,
func
()
{
config
:=
VolumeTestConfig
{
config
:=
VolumeTestConfig
{
namespace
:
ns
,
namespace
:
ns
,
prefix
:
"nfs"
,
prefix
:
"nfs"
,
...
...
test/e2e/security_context.go
View file @
949cf9e9
...
@@ -57,7 +57,7 @@ func scTestPod(hostIPC bool, hostPID bool) *api.Pod {
...
@@ -57,7 +57,7 @@ func scTestPod(hostIPC bool, hostPID bool) *api.Pod {
return
pod
return
pod
}
}
var
_
=
Describe
(
"
[Skipped] Security Context
"
,
func
()
{
var
_
=
Describe
(
"
Security Context [Skipped]
"
,
func
()
{
framework
:=
NewFramework
(
"security-context"
)
framework
:=
NewFramework
(
"security-context"
)
It
(
"should support pod.Spec.SecurityContext.SupplementalGroups"
,
func
()
{
It
(
"should support pod.Spec.SecurityContext.SupplementalGroups"
,
func
()
{
...
...
test/e2e/util.go
View file @
949cf9e9
...
@@ -2462,3 +2462,41 @@ func waitForIngressAddress(c *client.Client, ns, ingName string, timeout time.Du
...
@@ -2462,3 +2462,41 @@ func waitForIngressAddress(c *client.Client, ns, ingName string, timeout time.Du
})
})
return
address
,
err
return
address
,
err
}
}
// Looks for the given string in the log of a specific pod container
func
lookForStringInLog
(
ns
,
podName
,
container
,
expectedString
string
,
timeout
time
.
Duration
)
(
result
string
,
err
error
)
{
return
lookForString
(
expectedString
,
timeout
,
func
()
string
{
return
runKubectlOrDie
(
"log"
,
podName
,
container
,
fmt
.
Sprintf
(
"--namespace=%v"
,
ns
))
})
}
// Looks for the given string in a file in a specific pod container
func
lookForStringInFile
(
ns
,
podName
,
container
,
file
,
expectedString
string
,
timeout
time
.
Duration
)
(
result
string
,
err
error
)
{
return
lookForString
(
expectedString
,
timeout
,
func
()
string
{
return
runKubectlOrDie
(
"exec"
,
podName
,
"-c"
,
container
,
fmt
.
Sprintf
(
"--namespace=%v"
,
ns
),
"--"
,
"cat"
,
file
)
})
}
// Looks for the given string in the output of a command executed in a specific pod container
func
lookForStringInPodExec
(
ns
,
podName
string
,
command
[]
string
,
expectedString
string
,
timeout
time
.
Duration
)
(
result
string
,
err
error
)
{
return
lookForString
(
expectedString
,
timeout
,
func
()
string
{
// use the first container
args
:=
[]
string
{
"exec"
,
podName
,
fmt
.
Sprintf
(
"--namespace=%v"
,
ns
),
"--"
}
args
=
append
(
args
,
command
...
)
return
runKubectlOrDie
(
args
...
)
})
}
// Looks for the given string in the output of fn, repeatedly calling fn until
// the timeout is reached or the string is found. Returns last log and possibly
// error if the string was not found.
func
lookForString
(
expectedString
string
,
timeout
time
.
Duration
,
fn
func
()
string
)
(
result
string
,
err
error
)
{
for
t
:=
time
.
Now
();
time
.
Since
(
t
)
<
timeout
;
time
.
Sleep
(
poll
)
{
result
=
fn
()
if
strings
.
Contains
(
result
,
expectedString
)
{
return
}
}
err
=
fmt
.
Errorf
(
"Failed to find
\"
%s
\"
, last result:
\"
%s
\"
"
,
expectedString
,
result
)
return
}
test/e2e/volumes.go
View file @
949cf9e9
...
@@ -312,7 +312,10 @@ func deleteCinderVolume(name string) error {
...
@@ -312,7 +312,10 @@ func deleteCinderVolume(name string) error {
return
err
return
err
}
}
var
_
=
Describe
(
"Volumes"
,
func
()
{
// Marked with [Skipped] to skip the test by default (see driver.go),
// these tests needs privileged containers, which are disabled by default.
// Run the test with "go run hack/e2e.go ... --ginkgo.focus=Volume"
var
_
=
Describe
(
"Volumes [Skipped]"
,
func
()
{
framework
:=
NewFramework
(
"volume"
)
framework
:=
NewFramework
(
"volume"
)
// If 'false', the test won't clear its volumes upon completion. Useful for debugging,
// If 'false', the test won't clear its volumes upon completion. Useful for debugging,
...
@@ -331,10 +334,7 @@ var _ = Describe("Volumes", func() {
...
@@ -331,10 +334,7 @@ var _ = Describe("Volumes", func() {
// NFS
// NFS
////////////////////////////////////////////////////////////////////////
////////////////////////////////////////////////////////////////////////
// Marked with [Skipped] to skip the test by default (see driver.go),
Describe
(
"NFS"
,
func
()
{
// the test needs privileged containers, which are disabled by default.
// Run the test with "go run hack/e2e.go ... --ginkgo.focus=Volume"
Describe
(
"[Skipped] NFS"
,
func
()
{
It
(
"should be mountable"
,
func
()
{
It
(
"should be mountable"
,
func
()
{
config
:=
VolumeTestConfig
{
config
:=
VolumeTestConfig
{
namespace
:
namespace
.
Name
,
namespace
:
namespace
.
Name
,
...
@@ -368,10 +368,7 @@ var _ = Describe("Volumes", func() {
...
@@ -368,10 +368,7 @@ var _ = Describe("Volumes", func() {
// Gluster
// Gluster
////////////////////////////////////////////////////////////////////////
////////////////////////////////////////////////////////////////////////
// Marked with [Skipped] to skip the test by default (see driver.go),
Describe
(
"GlusterFS"
,
func
()
{
// the test needs privileged containers, which are disabled by default.
// Run the test with "go run hack/e2e.go ... --ginkgo.focus=Volume"
Describe
(
"[Skipped] GlusterFS"
,
func
()
{
It
(
"should be mountable"
,
func
()
{
It
(
"should be mountable"
,
func
()
{
config
:=
VolumeTestConfig
{
config
:=
VolumeTestConfig
{
namespace
:
namespace
.
Name
,
namespace
:
namespace
.
Name
,
...
@@ -445,13 +442,12 @@ var _ = Describe("Volumes", func() {
...
@@ -445,13 +442,12 @@ var _ = Describe("Volumes", func() {
// iSCSI
// iSCSI
////////////////////////////////////////////////////////////////////////
////////////////////////////////////////////////////////////////////////
// Marked with [Skipped] to skip the test by default (see driver.go),
// The test needs privileged containers, which are disabled by default.
// the test needs privileged containers, which are disabled by default.
// Also, make sure that iscsiadm utility and iscsi target kernel modules
// Also, make sure that iscsiadm utility and iscsi target kernel modules
// are installed on all nodes!
// are installed on all nodes!
// Run the test with "go run hack/e2e.go ... --ginkgo.focus=iSCSI"
// Run the test with "go run hack/e2e.go ... --ginkgo.focus=iSCSI"
Describe
(
"
[Skipped]
iSCSI"
,
func
()
{
Describe
(
"iSCSI"
,
func
()
{
It
(
"should be mountable"
,
func
()
{
It
(
"should be mountable"
,
func
()
{
config
:=
VolumeTestConfig
{
config
:=
VolumeTestConfig
{
namespace
:
namespace
.
Name
,
namespace
:
namespace
.
Name
,
...
@@ -492,12 +488,7 @@ var _ = Describe("Volumes", func() {
...
@@ -492,12 +488,7 @@ var _ = Describe("Volumes", func() {
// Ceph RBD
// Ceph RBD
////////////////////////////////////////////////////////////////////////
////////////////////////////////////////////////////////////////////////
// Marked with [Skipped] to skip the test by default (see driver.go),
Describe
(
"Ceph RBD"
,
func
()
{
// the test needs privileged containers, which are disabled by default.
// Run the test with "go run hack/e2e.go ... --ginkgo.focus=RBD"
// Run the test with "go run hack/e2e.go ... --ginkgo.focus=Volume"
Describe
(
"[Skipped] Ceph RBD"
,
func
()
{
It
(
"should be mountable"
,
func
()
{
It
(
"should be mountable"
,
func
()
{
config
:=
VolumeTestConfig
{
config
:=
VolumeTestConfig
{
namespace
:
namespace
.
Name
,
namespace
:
namespace
.
Name
,
...
@@ -569,10 +560,7 @@ var _ = Describe("Volumes", func() {
...
@@ -569,10 +560,7 @@ var _ = Describe("Volumes", func() {
// Ceph
// Ceph
////////////////////////////////////////////////////////////////////////
////////////////////////////////////////////////////////////////////////
// Marked with [Skipped] to skip the test by default (see driver.go),
Describe
(
"CephFS"
,
func
()
{
// the test needs privileged containers, which are disabled by default.
// Run the test with "go run hack/e2e.go ... --ginkgo.focus=Volume"
Describe
(
"[Skipped] CephFS"
,
func
()
{
It
(
"should be mountable"
,
func
()
{
It
(
"should be mountable"
,
func
()
{
config
:=
VolumeTestConfig
{
config
:=
VolumeTestConfig
{
namespace
:
namespace
.
Name
,
namespace
:
namespace
.
Name
,
...
@@ -638,13 +626,12 @@ var _ = Describe("Volumes", func() {
...
@@ -638,13 +626,12 @@ var _ = Describe("Volumes", func() {
// OpenStack Cinder
// OpenStack Cinder
////////////////////////////////////////////////////////////////////////
////////////////////////////////////////////////////////////////////////
// Marked with [Skipped] to skip the test by default (see driver.go),
// This test assumes that OpenStack client tools are installed
// The test assumes that OpenStack client tools are installed
// (/usr/bin/nova, /usr/bin/cinder and /usr/bin/keystone)
// (/usr/bin/nova, /usr/bin/cinder and /usr/bin/keystone)
// and that the usual OpenStack authentication env. variables are set
// and that the usual OpenStack authentication env. variables are set
// (OS_USERNAME, OS_PASSWORD, OS_TENANT_NAME at least).
// (OS_USERNAME, OS_PASSWORD, OS_TENANT_NAME at least).
Describe
(
"
[Skipped]
Cinder"
,
func
()
{
Describe
(
"Cinder"
,
func
()
{
It
(
"should be mountable"
,
func
()
{
It
(
"should be mountable"
,
func
()
{
config
:=
VolumeTestConfig
{
config
:=
VolumeTestConfig
{
namespace
:
namespace
.
Name
,
namespace
:
namespace
.
Name
,
...
...
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