mirror of https://github.com/k3s-io/k3s
Merge pull request #69466 from mooncak/fix_test_issues
Remove the duplicated words in test filespull/58/head
commit
664d797245
|
@ -159,7 +159,7 @@ func (e *E2EServices) startKubelet() (*server, error) {
|
||||||
kubeletConfigFlags = append(kubeletConfigFlags, "file-check-frequency")
|
kubeletConfigFlags = append(kubeletConfigFlags, "file-check-frequency")
|
||||||
|
|
||||||
// Assign a fixed CIDR to the node because there is no node controller.
|
// Assign a fixed CIDR to the node because there is no node controller.
|
||||||
// Note: this MUST be in sync with with the IP in
|
// Note: this MUST be in sync with the IP in
|
||||||
// - cluster/gce/config-test.sh and
|
// - cluster/gce/config-test.sh and
|
||||||
// - test/e2e_node/conformance/run_test.sh.
|
// - test/e2e_node/conformance/run_test.sh.
|
||||||
kc.PodCIDR = "10.100.0.0/24"
|
kc.PodCIDR = "10.100.0.0/24"
|
||||||
|
|
|
@ -241,7 +241,7 @@ func contactOthers(state *State) {
|
||||||
if err != nil {
|
if err != nil {
|
||||||
log.Fatalf("Unable to create client; error: %v\n", err)
|
log.Fatalf("Unable to create client; error: %v\n", err)
|
||||||
}
|
}
|
||||||
// Double check that that worked by getting the server version.
|
// Double check that worked by getting the server version.
|
||||||
if v, err := client.Discovery().ServerVersion(); err != nil {
|
if v, err := client.Discovery().ServerVersion(); err != nil {
|
||||||
log.Fatalf("Unable to get server version: %v\n", err)
|
log.Fatalf("Unable to get server version: %v\n", err)
|
||||||
} else {
|
} else {
|
||||||
|
|
|
@ -397,7 +397,7 @@ func getTestRequests(namespace string) []struct {
|
||||||
return requests
|
return requests
|
||||||
}
|
}
|
||||||
|
|
||||||
// The TestAuthMode* tests tests a large number of URLs and checks that they
|
// The TestAuthMode* tests a large number of URLs and checks that they
|
||||||
// are FORBIDDEN or not, depending on the mode. They do not attempt to do
|
// are FORBIDDEN or not, depending on the mode. They do not attempt to do
|
||||||
// detailed verification of behaviour beyond authorization. They are not
|
// detailed verification of behaviour beyond authorization. They are not
|
||||||
// fuzz tests.
|
// fuzz tests.
|
||||||
|
|
|
@ -66,7 +66,7 @@ func testLabels() map[string]string {
|
||||||
return map[string]string{"name": "test"}
|
return map[string]string{"name": "test"}
|
||||||
}
|
}
|
||||||
|
|
||||||
// newDeployment returns a RollingUpdate Deployment with with a fake container image
|
// newDeployment returns a RollingUpdate Deployment with a fake container image
|
||||||
func newDeployment(name, ns string, replicas int32) *apps.Deployment {
|
func newDeployment(name, ns string, replicas int32) *apps.Deployment {
|
||||||
return &apps.Deployment{
|
return &apps.Deployment{
|
||||||
TypeMeta: metav1.TypeMeta{
|
TypeMeta: metav1.TypeMeta{
|
||||||
|
|
|
@ -79,7 +79,7 @@ func newHeadlessService(namespace string) *v1.Service {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// newSTS returns a StatefulSet with with a fake container image
|
// newSTS returns a StatefulSet with a fake container image
|
||||||
func newSTS(name, namespace string, replicas int) *v1beta1.StatefulSet {
|
func newSTS(name, namespace string, replicas int) *v1beta1.StatefulSet {
|
||||||
replicasCopy := int32(replicas)
|
replicasCopy := int32(replicas)
|
||||||
return &v1beta1.StatefulSet{
|
return &v1beta1.StatefulSet{
|
||||||
|
|
Loading…
Reference in New Issue