Stop using the deprecated method CurrentGinkgoTestDescription
Besides, the using of method might lead to a `concurrent map writes` issue per the discussion here: https://github.com/onsi/ginkgo/issues/970 Signed-off-by: Dave Chen <dave.chen@arm.com>
This commit is contained in:
@@ -22,7 +22,7 @@ import (
|
||||
"strconv"
|
||||
"time"
|
||||
|
||||
"k8s.io/api/core/v1"
|
||||
v1 "k8s.io/api/core/v1"
|
||||
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||
internalapi "k8s.io/cri-api/pkg/apis"
|
||||
runtimeapi "k8s.io/cri-api/pkg/apis/runtime/v1"
|
||||
@@ -264,7 +264,7 @@ func containerGCTest(f *framework.Framework, test testRun) {
|
||||
return nil
|
||||
}, garbageCollectDuration, runtimePollInterval).Should(gomega.BeNil())
|
||||
|
||||
if ginkgo.CurrentGinkgoTestDescription().Failed && framework.TestContext.DumpLogsOnFailure {
|
||||
if ginkgo.CurrentSpecReport().Failed() && framework.TestContext.DumpLogsOnFailure {
|
||||
logNodeEvents(f)
|
||||
logPodEvents(f)
|
||||
}
|
||||
|
Reference in New Issue
Block a user