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

Upgrade ginkgo to v2.11.0 #2284

Merged
merged 1 commit into from
Dec 3, 2024
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.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ require (
github.com/k8stopologyawareschedwg/noderesourcetopology-api v0.1.1
github.com/mohae/deepcopy v0.0.0-20170603005431-491d3605edfb
github.com/mwitkow/grpc-proxy v0.0.0-20230212185441-f345521cb9c9
github.com/onsi/ginkgo v1.16.5
github.com/onsi/ginkgo/v2 v2.11.0
github.com/onsi/gomega v1.27.10
github.com/opencontainers/runc v1.1.7
github.com/openkruise/kruise-api v1.5.0
Expand Down Expand Up @@ -72,9 +72,11 @@ require (
github.com/emicklei/go-restful/v3 v3.11.0 // indirect
github.com/evanphx/json-patch/v5 v5.6.0 // indirect
github.com/go-logr/stdr v1.2.2 // indirect
github.com/go-task/slim-sprig v0.0.0-20230315185526-52ccab3ef572 // indirect
github.com/gogo/protobuf v1.3.2 // indirect
github.com/google/cel-go v0.16.1 // indirect
github.com/google/gnostic-models v0.6.8 // indirect
github.com/google/pprof v0.0.0-20220829040838-70bd9ae97f40 // indirect
github.com/grpc-ecosystem/grpc-gateway/v2 v2.11.3 // indirect
github.com/stoewer/go-strcase v1.2.0 // indirect
golang.org/x/exp v0.0.0-20220827204233-334a2380cb91 // indirect
Expand Down Expand Up @@ -175,7 +177,6 @@ require (
github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 // indirect
github.com/mwitkow/go-conntrack v0.0.0-20190716064945-2f068394615f // indirect
github.com/mxk/go-flowrate v0.0.0-20140419014527-cca7078d478f // indirect
github.com/nxadm/tail v1.4.8 // indirect
github.com/oklog/ulid v1.3.1 // indirect
github.com/opencontainers/go-digest v1.0.0 // indirect
github.com/opencontainers/image-spec v1.0.3-0.20211202183452-c5a74bcca799 // indirect
Expand Down Expand Up @@ -231,7 +232,6 @@ require (
gopkg.in/gcfg.v1 v1.2.3 // indirect
gopkg.in/inf.v0 v0.9.1 // indirect
gopkg.in/natefinch/lumberjack.v2 v2.2.1 // indirect
gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7 // indirect
gopkg.in/warnings.v0 v0.1.2 // indirect
gopkg.in/yaml.v3 v3.0.1 // indirect
k8s.io/apiextensions-apiserver v0.28.3 // indirect
Expand Down
6 changes: 2 additions & 4 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -757,6 +757,7 @@ github.com/google/pprof v0.0.0-20201218002935-b9804c9f04c2/go.mod h1:kpwsk12EmLe
github.com/google/pprof v0.0.0-20210407192527-94a9f03dee38/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE=
github.com/google/pprof v0.0.0-20210720184732-4bb14d4b1be1/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE=
github.com/google/pprof v0.0.0-20220829040838-70bd9ae97f40 h1:ykKxL12NZd3JmWZnyqarJGsF73M9Xhtrik/FEtEeFRE=
github.com/google/pprof v0.0.0-20220829040838-70bd9ae97f40/go.mod h1:dDKJzRmX4S37WGHujM7tX//fmj1uioxKzKxz3lo4HJo=
github.com/google/renameio v0.1.0/go.mod h1:KWCgfxg9yswjAJkECMjeO8J8rahYeXnNhOm40UhjYkI=
github.com/google/shlex v0.0.0-20191202100458-e7afc7fbc510/go.mod h1:pupxD2MaaD3pAXIBCelhxNneeOaAeabZDe5s4K6zSpQ=
github.com/google/uuid v1.1.1/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo=
Expand Down Expand Up @@ -1007,7 +1008,6 @@ github.com/mxk/go-flowrate v0.0.0-20140419014527-cca7078d478f/go.mod h1:ZdcZmHo+
github.com/ncw/swift v1.0.47/go.mod h1:23YIA4yWVnGwv2dQlN4bB7egfYX6YLn0Yo/S6zZO/ZM=
github.com/niemeyer/pretty v0.0.0-20200227124842-a10e7caefd8e/go.mod h1:zD1mROLANZcx1PVRCS0qkT7pwLkGfwJo4zjcN/Tysno=
github.com/nxadm/tail v1.4.4/go.mod h1:kenIhsEOeOJmVchQTgglprH7qJGnHDVpk1VPCcaMI8A=
github.com/nxadm/tail v1.4.8 h1:nPr65rt6Y5JFSKQO7qToXr7pePgD6Gwiw05lkbyAQTE=
github.com/nxadm/tail v1.4.8/go.mod h1:+ncqLTQzXmGhMZNUePPaPqPvBxHAIsmXswZKocGu+AU=
github.com/oklog/ulid v1.3.1 h1:EGfNDEx6MqHz8B3uNV6QAib1UR2Lm97sHi3ocA6ESJ4=
github.com/oklog/ulid v1.3.1/go.mod h1:CirwcVhetQ6Lv90oh/F+FBtV6XMibvdAFo93nm5qn4U=
Expand All @@ -1019,8 +1019,6 @@ github.com/onsi/ginkgo v1.10.3/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+
github.com/onsi/ginkgo v1.12.0/go.mod h1:oUhWkIvk5aDxtKvDDuw8gItl8pKl42LzjC9KZE0HfGg=
github.com/onsi/ginkgo v1.12.1/go.mod h1:zj2OWP4+oCPe1qIXoGWkgMRwljMUYCdkwsT2108oapk=
github.com/onsi/ginkgo v1.16.4/go.mod h1:dX+/inL/fNMqNlz0e9LfyB9TswhZpCVdJM/Z6Vvnwo0=
github.com/onsi/ginkgo v1.16.5 h1:8xi0RTUf59SOSfEtZMvwTvXYMzG4gV23XVHOZiXNtnE=
github.com/onsi/ginkgo v1.16.5/go.mod h1:+E8gABHa3K6zRBolWtd+ROzc/U5bkGt0FwiG042wbpU=
github.com/onsi/ginkgo/v2 v2.1.3/go.mod h1:vw5CSIxN1JObi/U8gcbwft7ZxR2dgaR70JSE3/PpL4c=
github.com/onsi/ginkgo/v2 v2.1.4/go.mod h1:um6tUpWM/cxCK3/FK8BXqEiUMUwRgSM4JXG47RKZmLU=
github.com/onsi/ginkgo/v2 v2.1.6/go.mod h1:MEH45j8TBi6u9BMogfbp0stKC5cdGjumZj5Y7AG4VIk=
Expand All @@ -1034,6 +1032,7 @@ github.com/onsi/ginkgo/v2 v2.9.1/go.mod h1:FEcmzVcCHl+4o9bQZVab+4dC9+j+91t2FHSzm
github.com/onsi/ginkgo/v2 v2.9.2/go.mod h1:WHcJJG2dIlcCqVfBAwUCrJxSPFb6v4azBwgxeMeDuts=
github.com/onsi/ginkgo/v2 v2.9.4/go.mod h1:gCQYp2Q+kSoIj7ykSVb9nskRSsR6PUj4AiLywzIhbKM=
github.com/onsi/ginkgo/v2 v2.11.0 h1:WgqUCUt/lT6yXoQ8Wef0fsNn5cAuMK7+KT9UFRz2tcU=
github.com/onsi/ginkgo/v2 v2.11.0/go.mod h1:ZhrRA5XmEE3x3rhlzamx/JJvujdZoJ2uvgI7kR0iZvM=
github.com/onsi/gomega v0.0.0-20151007035656-2152b45fa28a/go.mod h1:C1qb7wdrVGGVU+Z6iS04AVkA3Q65CEZX59MT0QO5uiA=
github.com/onsi/gomega v1.5.0/go.mod h1:ex+gbHU/CVuBBDIJjb2X0qEXbFg53c61hWP/1CpauHY=
github.com/onsi/gomega v1.7.0/go.mod h1:ex+gbHU/CVuBBDIJjb2X0qEXbFg53c61hWP/1CpauHY=
Expand Down Expand Up @@ -1857,7 +1856,6 @@ gopkg.in/natefinch/lumberjack.v2 v2.2.1/go.mod h1:YD8tP3GAjkrDg1eZH7EGmyESg/lsYs
gopkg.in/square/go-jose.v2 v2.3.1/go.mod h1:M9dMgbHiYLoDGQrXy7OpJDJWiKiU//h+vD76mk0e1AI=
gopkg.in/square/go-jose.v2 v2.5.1/go.mod h1:M9dMgbHiYLoDGQrXy7OpJDJWiKiU//h+vD76mk0e1AI=
gopkg.in/square/go-jose.v2 v2.6.0/go.mod h1:M9dMgbHiYLoDGQrXy7OpJDJWiKiU//h+vD76mk0e1AI=
gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7 h1:uRGJdciOHaEIrze2W8Q3AKkepLTh2hOroT7a+7czfdQ=
gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7/go.mod h1:dt/ZhP58zS4L8KSrWDmTeBkI65Dw0HsyUHuEVlX15mw=
gopkg.in/warnings.v0 v0.1.2 h1:wFXVbFY8DY5/xOe1ECiWdKCzZlxgshcYVNkBHstARME=
gopkg.in/warnings.v0 v0.1.2/go.mod h1:jksf8JmL6Qr/oQM2OXTHunEvvTAsrWBLb6OOjuVWRNI=
Expand Down
4 changes: 2 additions & 2 deletions test/e2e/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ import (
// test/e2e/lifecycle/framework.go
package lifecycle

import "github.com/onsi/ginkgo"
import "github.com/onsi/ginkgo/v2"

// SIGDescribe annotates the test with the SIG label.
func SIGDescribe(text string, body func()) bool {
Expand All @@ -58,7 +58,7 @@ func SIGDescribe(text string, body func()) bool {
package bootstrap

import (
"github.com/onsi/ginkgo"
"github.com/onsi/ginkgo/v2"
"github.com/koordinator-sh/koordinator/test/e2e/lifecycle"
)
var _ = lifecycle.SIGDescribe("[Feature:BootstrapTokens]", func() {
Expand Down
32 changes: 3 additions & 29 deletions test/e2e/e2e.go
Original file line number Diff line number Diff line change
Expand Up @@ -23,15 +23,12 @@ import (
"fmt"
"os"
"os/exec"
"path"
"path/filepath"
"strings"
"testing"
"time"

"github.com/onsi/ginkgo"
"github.com/onsi/ginkgo/config"
"github.com/onsi/ginkgo/reporters"
"github.com/onsi/ginkgo/v2"
"github.com/onsi/gomega"

v1 "k8s.io/api/core/v1"
Expand All @@ -51,8 +48,6 @@ import (
e2emanifest "github.com/koordinator-sh/koordinator/test/e2e/framework/manifest"
e2enode "github.com/koordinator-sh/koordinator/test/e2e/framework/node"
e2epod "github.com/koordinator-sh/koordinator/test/e2e/framework/pod"
e2ereporters "github.com/koordinator-sh/koordinator/test/e2e/reporters"

// ensure auth plugins are loaded
_ "k8s.io/client-go/plugin/pkg/client/auth"

Expand Down Expand Up @@ -96,29 +91,8 @@ func RunE2ETests(t *testing.T) {

gomega.RegisterFailHandler(framework.Fail)

// Run tests through the Ginkgo runner with output to console + JUnit for Jenkins
var r []ginkgo.Reporter
if framework.TestContext.ReportDir != "" {
// TODO: we should probably only be trying to create this directory once
// rather than once-per-Ginkgo-node.
if err := os.MkdirAll(framework.TestContext.ReportDir, 0755); err != nil {
klog.Errorf("Failed creating report directory: %v", err)
} else {
r = append(r, reporters.NewJUnitReporter(path.Join(framework.TestContext.ReportDir, fmt.Sprintf("junit_%v%02d.xml", framework.TestContext.ReportPrefix, config.GinkgoConfig.ParallelNode))))
}
}

// Stream the progress to stdout and optionally a URL accepting progress updates.
r = append(r, e2ereporters.NewProgressReporter(framework.TestContext.ProgressReportURL))

// The DetailsRepoerter will output details about every test (name, files, lines, etc) which helps
// when documenting our tests.
if len(framework.TestContext.SpecSummaryOutput) > 0 {
r = append(r, e2ereporters.NewDetailsReporterFile(framework.TestContext.SpecSummaryOutput))
}

klog.Infof("Starting e2e run %q on Ginkgo node %d", framework.RunID, config.GinkgoConfig.ParallelNode)
ginkgo.RunSpecsWithDefaultAndCustomReporters(t, "Kubernetes e2e suite", r)
klog.Infof("Starting e2e run %q", framework.RunID)
ginkgo.RunSpecs(t, "Kubernetes e2e suite")
}

// Run a test container to try and contact the Kubernetes api-server from a pod, wait for it
Expand Down
2 changes: 1 addition & 1 deletion test/e2e/e2e_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ import (
// the ginkgo test runner will not detect that this
// directory contains a Ginkgo test suite.
// See https://github.com/kubernetes/kubernetes/issues/74827
// "github.com/onsi/ginkgo"
// "github.com/onsi/ginkgo/v2"

"k8s.io/component-base/version"

Expand Down
4 changes: 2 additions & 2 deletions test/e2e/framework/framework.go
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ import (
"k8s.io/client-go/restmapper"
scaleclient "k8s.io/client-go/scale"

"github.com/onsi/ginkgo"
"github.com/onsi/ginkgo/v2"
"github.com/onsi/gomega"

koordinatorclientset "github.com/koordinator-sh/koordinator/pkg/client/clientset/versioned"
Expand Down Expand Up @@ -634,7 +634,7 @@ func (kc *KubeConfig) FindCluster(name string) *KubeCluster {

// ConformanceIt is wrapper function for ginkgo It. Adds "[Conformance]" tag and makes static analysis easier.
func ConformanceIt(text string, body interface{}, timeout ...float64) bool {
return ginkgo.It(text+" [Conformance]", body, timeout...)
return ginkgo.It(text+" [Conformance]", body, timeout)
}

// KoordinatorDescribe is a wrapper function for ginkgo describe. Adds namespacing.
Expand Down
7 changes: 5 additions & 2 deletions test/e2e/framework/ginkgowrapper/wrapper.go
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ import (
"runtime/debug"
"strings"

"github.com/onsi/ginkgo"
"github.com/onsi/ginkgo/v2"
)

// FailurePanic is the value that will be panicked from Fail.
Expand All @@ -39,7 +39,10 @@ type FailurePanic struct {
}

// String makes FailurePanic look like the old Ginkgo panic when printed.
func (FailurePanic) String() string { return ginkgo.GINKGO_PANIC }
func (FailurePanic) String() string {
ginkgo.Fail("Test failed due to panic", 1)
return "panic"
}

// Fail wraps ginkgo.Fail so that it panics with more useful
// information about the failure. This function will panic with a
Expand Down
2 changes: 1 addition & 1 deletion test/e2e/framework/kubectl/kubectl_utils.go
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ import (
e2elog "github.com/koordinator-sh/koordinator/test/e2e/framework/log"
e2epod "github.com/koordinator-sh/koordinator/test/e2e/framework/pod"

"github.com/onsi/ginkgo"
"github.com/onsi/ginkgo/v2"
)

const (
Expand Down
2 changes: 1 addition & 1 deletion test/e2e/framework/log.go
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ import (
"runtime/debug"
"time"

"github.com/onsi/ginkgo"
"github.com/onsi/ginkgo/v2"

// TODO: Remove the following imports (ref: https://github.com/kubernetes/kubernetes/issues/81245)
e2eginkgowrapper "github.com/koordinator-sh/koordinator/test/e2e/framework/ginkgowrapper"
Expand Down
2 changes: 1 addition & 1 deletion test/e2e/framework/log/logger.go
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ import (
"fmt"
"time"

"github.com/onsi/ginkgo"
"github.com/onsi/ginkgo/v2"

e2eginkgowrapper "github.com/koordinator-sh/koordinator/test/e2e/framework/ginkgowrapper"
)
Expand Down
85 changes: 3 additions & 82 deletions test/e2e/framework/log_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -20,16 +20,10 @@ package framework_test
import (
"errors"
"regexp"
"sort"
"strings"
"testing"

"github.com/onsi/ginkgo"
"github.com/onsi/ginkgo/config"
"github.com/onsi/ginkgo/reporters"
"github.com/onsi/gomega"

"github.com/koordinator-sh/koordinator/test/e2e/framework"
"github.com/onsi/ginkgo/v2"
)

// The line number of the following code is checked in TestFailureOutput below.
Expand All @@ -43,9 +37,9 @@ import (
//
//

func runTests(t *testing.T, reporter ginkgo.Reporter) {
func runTests(t *testing.T) {
// This source code line will be part of the stack dump comparison.
ginkgo.RunSpecsWithDefaultAndCustomReporters(t, "Logging Suite", []ginkgo.Reporter{reporter})
ginkgo.RunSpecs(t, "Logging Suite")
}

var _ = ginkgo.Describe("log", func() {
Expand Down Expand Up @@ -73,63 +67,6 @@ var _ = ginkgo.Describe("log", func() {
})
})

func TestFailureOutput(t *testing.T) {
// Run the Ginkgo suite with output collected by a custom
// reporter in adddition to the default one. To see what the full
// Ginkgo report looks like, run this test with "go test -v".
config.DefaultReporterConfig.FullTrace = true
gomega.RegisterFailHandler(framework.Fail)
fakeT := &testing.T{}
reporter := reporters.NewFakeReporter()
runTests(fakeT, reporter)

// Now check the output.
actual := normalizeReport(*reporter)

// output from AfterEach
commonOutput := "\n\nINFO: after\nFAIL: true is never false either\nExpected\n <bool>: true\nto equal\n <bool>: false\n\nFull Stack Trace\ngithub.com/koordinator-sh/koordinator/test/e2e/framework_test.glob..func1.6()\n\tlog_test.go:71\ngithub.com/koordinator-sh/koordinator/test/e2e/framework_test.runTests()\n\tlog_test.go:47\n\n"

// Sorted by name!
expected := suiteResults{
testResult{
name: "[Top Level] log asserts",
output: "INFO: before\nFAIL: false is never true\nExpected\n <bool>: false\nto equal\n <bool>: true\n\nFull Stack Trace\ngithub.com/koordinator-sh/koordinator/test/e2e/framework_test.glob..func1.3()\n\tlog_test.go:60\ngithub.com/koordinator-sh/koordinator/test/e2e/framework_test.runTests()\n\tlog_test.go:47" + commonOutput,
failure: "false is never true\nExpected\n <bool>: false\nto equal\n <bool>: true",
stack: "github.com/koordinator-sh/koordinator/test/e2e/framework_test.glob..func1.3()\n\tlog_test.go:60\ngithub.com/koordinator-sh/koordinator/test/e2e/framework_test.runTests()\n\tlog_test.go:47\n",
},
testResult{
name: "[Top Level] log equal",
output: "INFO: before\nFAIL: of course it's not equal...\nExpected\n <int>: 0\nto equal\n <int>: 1\n\nFull Stack Trace\ngithub.com/koordinator-sh/koordinator/test/e2e/framework_test.glob..func1.5()\n\tlog_test.go:67\ngithub.com/koordinator-sh/koordinator/test/e2e/framework_test.runTests()\n\tlog_test.go:47" + commonOutput,
failure: "of course it's not equal...\nExpected\n <int>: 0\nto equal\n <int>: 1",
stack: "github.com/koordinator-sh/koordinator/test/e2e/framework_test.glob..func1.5()\n\tlog_test.go:67\ngithub.com/koordinator-sh/koordinator/test/e2e/framework_test.runTests()\n\tlog_test.go:47\n",
},
testResult{
name: "[Top Level] log error",
output: "INFO: before\nFAIL: hard-coded error\nUnexpected error:\n <*errors.errorString>: {\n s: \"an error with a long, useless description\",\n }\n an error with a long, useless description\noccurred\n\nFull Stack Trace\ngithub.com/koordinator-sh/koordinator/test/e2e/framework_test.glob..func1.4()\n\tlog_test.go:64\ngithub.com/koordinator-sh/koordinator/test/e2e/framework_test.runTests()\n\tlog_test.go:47" + commonOutput,
failure: "hard-coded error\nUnexpected error:\n <*errors.errorString>: {\n s: \"an error with a long, useless description\",\n }\n an error with a long, useless description\noccurred",
stack: "github.com/koordinator-sh/koordinator/test/e2e/framework_test.glob..func1.4()\n\tlog_test.go:64\ngithub.com/koordinator-sh/koordinator/test/e2e/framework_test.runTests()\n\tlog_test.go:47\n",
},
testResult{
name: "[Top Level] log fails",
output: "INFO: before\nFAIL: I'm failing.\n\nFull Stack Trace\ngithub.com/koordinator-sh/koordinator/test/e2e/framework_test.glob..func1.2()\n\tlog_test.go:57\ngithub.com/koordinator-sh/koordinator/test/e2e/framework_test.runTests()\n\tlog_test.go:47" + commonOutput,
failure: "I'm failing.",
stack: "github.com/koordinator-sh/koordinator/test/e2e/framework_test.glob..func1.2()\n\tlog_test.go:57\ngithub.com/koordinator-sh/koordinator/test/e2e/framework_test.runTests()\n\tlog_test.go:47\n",
},
}
// Compare individual fields. Comparing the slices leads to unreadable error output when there is any mismatch.
framework.ExpectEqual(len(actual), len(expected), "%d entries in %v", len(expected), actual)
for i, a := range actual {
b := expected[i]
framework.ExpectEqual(a.name, b.name, "name in %d", i)
framework.ExpectEqual(a.output, b.output, "output in %d", i)
framework.ExpectEqual(a.failure, b.failure, "failure in %d", i)
// There may be additional stack entries from the "testing" package at the
// end. We ignore those in the comparison because the line number in them
// varies.
framework.ExpectEqual(a.stack, b.stack, "stack in %d: %s", i, a.stack)
}
}

type testResult struct {
name string
// output written to GinkgoWriter during test.
Expand All @@ -143,22 +80,6 @@ type testResult struct {

type suiteResults []testResult

func normalizeReport(report reporters.FakeReporter) suiteResults {
var results suiteResults
for _, spec := range report.SpecSummaries {
results = append(results, testResult{
name: strings.Join(spec.ComponentTexts, " "),
output: normalizeLocation(stripAddresses(stripTimes(spec.CapturedOutput))),
failure: stripAddresses(stripTimes(spec.Failure.Message)),
stack: normalizeLocation(spec.Failure.Location.FullStackTrace),
})
}
sort.Slice(results, func(i, j int) bool {
return strings.Compare(results[i].name, results[j].name) < 0
})
return results
}

// timePrefix matches "Jul 17 08:08:25.950: " at the beginning of each line.
var timePrefix = regexp.MustCompile(`(?m)^[[:alpha:]]{3} +[[:digit:]]{1,2} +[[:digit:]]{2}:[[:digit:]]{2}:[[:digit:]]{2}.[[:digit:]]{3}: `)

Expand Down
2 changes: 1 addition & 1 deletion test/e2e/framework/node/resource.go
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ import (
"strings"
"time"

"github.com/onsi/ginkgo"
"github.com/onsi/ginkgo/v2"
"github.com/onsi/gomega"

v1 "k8s.io/api/core/v1"
Expand Down
2 changes: 1 addition & 1 deletion test/e2e/framework/nodes_util.go
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ import (
"sync"
"time"

"github.com/onsi/ginkgo"
"github.com/onsi/ginkgo/v2"

v1 "k8s.io/api/core/v1"
"k8s.io/apimachinery/pkg/util/wait"
Expand Down
2 changes: 1 addition & 1 deletion test/e2e/framework/pod/delete.go
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ import (
"fmt"
"time"

"github.com/onsi/ginkgo"
"github.com/onsi/ginkgo/v2"

v1 "k8s.io/api/core/v1"
apierrors "k8s.io/apimachinery/pkg/api/errors"
Expand Down
2 changes: 1 addition & 1 deletion test/e2e/framework/pod/resource.go
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ import (
"strings"
"time"

"github.com/onsi/ginkgo"
"github.com/onsi/ginkgo/v2"
"github.com/onsi/gomega"
v1 "k8s.io/api/core/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
Expand Down
2 changes: 1 addition & 1 deletion test/e2e/framework/pod/wait.go
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ import (
"text/tabwriter"
"time"

"github.com/onsi/ginkgo"
"github.com/onsi/ginkgo/v2"

v1 "k8s.io/api/core/v1"
apierrors "k8s.io/apimachinery/pkg/api/errors"
Expand Down
2 changes: 1 addition & 1 deletion test/e2e/framework/pods.go
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ import (
v1core "k8s.io/client-go/kubernetes/typed/core/v1"
"k8s.io/kubectl/pkg/util/podutils"

"github.com/onsi/ginkgo"
"github.com/onsi/ginkgo/v2"
"github.com/onsi/gomega"

// TODO: Remove the following imports (ref: https://github.com/kubernetes/kubernetes/issues/81245)
Expand Down
Loading