mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-12-09 19:29:26 +00:00
test: fix ginkgolinter issues
All of these issues were reported by https://github.com/nunnatsa/ginkgolinter. Fixing these issues is useful (several expressions get simpler, using framework.ExpectNoError is better because it has additional support for failures) and a necessary step for enabling that linter in our golangci-lint invocation.
This commit is contained in:
@@ -1338,7 +1338,7 @@ func listDeploymentReplicaSets(ctx context.Context, c clientset.Interface, ns st
|
||||
options := metav1.ListOptions{LabelSelector: selector.String()}
|
||||
rsList, err := c.AppsV1().ReplicaSets(ns).List(ctx, options)
|
||||
framework.ExpectNoError(err)
|
||||
gomega.Expect(len(rsList.Items)).To(gomega.BeNumerically(">", 0))
|
||||
gomega.Expect(rsList.Items).ToNot(gomega.BeEmpty())
|
||||
return rsList
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user