Merge pull request #83714 from tanjunchen/fix-staticcheck-test/e2e/windows

fix staticcheck  failures in test/e2e/windows
This commit is contained in:
Kubernetes Prow Robot 2019-11-26 19:43:20 -08:00 committed by GitHub
commit 6a48f55e56
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 2 additions and 12 deletions

View File

@ -79,7 +79,6 @@ test/e2e/storage/utils
test/e2e/storage/vsphere
test/e2e/upgrades
test/e2e/upgrades/storage
test/e2e/windows
test/images/agnhost/dns
test/images/agnhost/inclusterclient
test/images/agnhost/net/nat

View File

@ -36,7 +36,6 @@ go_library(
"//staging/src/k8s.io/client-go/tools/cache:go_default_library",
"//staging/src/k8s.io/kubelet/config/v1beta1:go_default_library",
"//test/e2e/framework:go_default_library",
"//test/e2e/framework/kubelet:go_default_library",
"//test/e2e/framework/metrics:go_default_library",
"//test/e2e/framework/network:go_default_library",
"//test/e2e/framework/node:go_default_library",

View File

@ -30,7 +30,6 @@ import (
"k8s.io/apimachinery/pkg/watch"
"k8s.io/client-go/tools/cache"
"k8s.io/kubernetes/test/e2e/framework"
e2ekubelet "k8s.io/kubernetes/test/e2e/framework/kubelet"
e2emetrics "k8s.io/kubernetes/test/e2e/framework/metrics"
e2epod "k8s.io/kubernetes/test/e2e/framework/pod"
imageutils "k8s.io/kubernetes/test/utils/image"
@ -75,8 +74,6 @@ var _ = SIGDescribe("[Feature:Windows] Density [Serial] [Slow]", func() {
type densityTest struct {
// number of pods
podsNr int
// number of background pods
bgPodsNr int
// interval between creating pod (rate control)
interval time.Duration
// create pods in 'batch' or 'sequence'
@ -84,8 +81,6 @@ type densityTest struct {
// API QPS limit
APIQPSLimit int
// performance limits
cpuLimits e2ekubelet.ContainersCPUSummary
memLimits e2ekubelet.ResourceUsagePerContainer
podStartupLimits e2emetrics.LatencyMetric
podBatchStartupLimit time.Duration
}
@ -97,7 +92,7 @@ func runDensityBatchTest(f *framework.Framework, testArg densityTest) (time.Dura
)
var (
mutex = &sync.Mutex{}
watchTimes = make(map[string]metav1.Time, 0)
watchTimes = make(map[string]metav1.Time)
stopCh = make(chan struct{})
)
@ -278,5 +273,4 @@ func deletePodsSync(f *framework.Framework, pods []*v1.Pod) {
}(pod)
}
wg.Wait()
return
}

View File

@ -28,9 +28,6 @@ import (
"github.com/onsi/ginkgo"
)
const dnsTestPodHostName = "dns-querier-1"
const dnsTestServiceName = "dns-test-service"
var _ = SIGDescribe("DNS", func() {
ginkgo.BeforeEach(func() {
@ -76,6 +73,7 @@ var _ = SIGDescribe("DNS", func() {
framework.Logf("ipconfig /all:\n%s", stdout)
dnsRegex, err := regexp.Compile(`DNS Servers[\s*.]*:(\s*[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3})+`)
framework.ExpectNoError(err)
if dnsRegex.MatchString(stdout) {
match := dnsRegex.FindString(stdout)