Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add a flag that lets e2e tests be run against single-node clusters. #25753

Merged
merged 2 commits into from
May 20, 2016
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
8 changes: 7 additions & 1 deletion hack/e2e.go
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,10 @@ var (
"By default, verify that client and server have exact version match. "+
"You can explicitly set to false if you're, e.g., testing client changes "+
"for which the server version doesn't make a difference.")
checkNodeCount = flag.Bool("check_node_count", true, ""+
"By default, verify that the cluster has at least two nodes."+
"You can explicitly set to false if you're, e.g., testing single-node clusters "+
"for which the node count is supposed to be one.")

ctlCmd = flag.String("ctl", "", "If nonempty, pass this as an argument, and call kubectl. Implies -v. (-test, -cfg, -ctl are mutually exclusive)")
)
Expand Down Expand Up @@ -181,7 +185,9 @@ func Test() bool {
log.Fatal("Testing requested, but e2e cluster not up!")
}

ValidateClusterSize()
if *checkNodeCount {
ValidateClusterSize()
}

return finishRunning("Ginkgo tests", exec.Command(filepath.Join(*root, "hack/ginkgo-e2e.sh"), strings.Fields(*testArgs)...))
}
Expand Down
1 change: 1 addition & 0 deletions hack/verify-flags/excluded-flags.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
check_version_skew
check_node_count
concurrent_rc_syncs
file_content
file_mode
Expand Down