diff --git a/pkg/pod/status.go b/pkg/pod/status.go index 7c52ca4ce32..e9a7595faf1 100644 --- a/pkg/pod/status.go +++ b/pkg/pod/status.go @@ -39,10 +39,6 @@ import ( ) const ( - // ReasonCouldntGetTask indicates that the reason for the failure status is that the - // Task couldn't be found - ReasonCouldntGetTask = "CouldntGetTask" - // ReasonFailedResolution indicated that the reason for failure status is // that references within the TaskRun could not be resolved ReasonFailedResolution = "TaskRunResolutionFailed" diff --git a/test/resolvers_test.go b/test/resolvers_test.go index 4d1449531f9..5d2cf416dbf 100644 --- a/test/resolvers_test.go +++ b/test/resolvers_test.go @@ -35,7 +35,7 @@ import ( "github.com/goccy/kpoward" "github.com/jenkins-x/go-scm/scm/factory" resolverconfig "github.com/tektoncd/pipeline/pkg/apis/config/resolver" - "github.com/tektoncd/pipeline/pkg/pod" + v1 "github.com/tektoncd/pipeline/pkg/apis/pipeline/v1" "github.com/tektoncd/pipeline/pkg/reconciler/pipelinerun" "github.com/tektoncd/pipeline/pkg/resolution/resolver/git" "github.com/tektoncd/pipeline/test/parse" @@ -193,7 +193,7 @@ spec: t.Logf("Waiting for PipelineRun %s in namespace %s to complete", prName, namespace) if err := WaitForPipelineRunState(ctx, c, prName, timeout, Chain( - FailedWithReason(pod.ReasonCouldntGetTask, prName), + FailedWithReason(v1.PipelineRunReasonCouldntGetTask, prName), FailedWithMessage("fail to fetch Artifact Hub resource: requested resource 'https://artifacthub.io/api/v1/packages/tekton-task/tekton-catalog-tasks/git-clone-this-does-not-exist' not found on hub", prName), ), "PipelineRunFailed", v1Version); err != nil { t.Fatalf("Error waiting for PipelineRun to finish with expected error: %s", err) @@ -357,7 +357,7 @@ spec: t.Logf("Waiting for PipelineRun %s in namespace %s to complete", prName, namespace) if err := WaitForPipelineRunState(ctx, c, prName, timeout, Chain( - FailedWithReason(pod.ReasonCouldntGetTask, prName), + FailedWithReason(v1.PipelineRunReasonCouldntGetTask, prName), FailedWithMessage(expectedErr, prName), ), "PipelineRunFailed", v1Version); err != nil { t.Fatalf("Error waiting for PipelineRun to finish with expected error: %s", err) diff --git a/test/tektonbundles_test.go b/test/tektonbundles_test.go index de300c5b5f0..cbd391c3903 100644 --- a/test/tektonbundles_test.go +++ b/test/tektonbundles_test.go @@ -37,7 +37,6 @@ import ( "github.com/google/go-containerregistry/pkg/v1/mutate" "github.com/google/go-containerregistry/pkg/v1/tarball" "github.com/tektoncd/pipeline/pkg/apis/pipeline/v1beta1" - "github.com/tektoncd/pipeline/pkg/pod" "github.com/tektoncd/pipeline/pkg/reconciler/pipelinerun" "github.com/tektoncd/pipeline/test/parse" corev1 "k8s.io/api/core/v1" @@ -300,7 +299,7 @@ spec: t.Logf("Waiting for PipelineRun in namespace %s to finish", namespace) if err := WaitForPipelineRunState(ctx, c, pipelineRunName, timeout, Chain( - FailedWithReason(pod.ReasonCouldntGetTask, pipelineRunName), + FailedWithReason(v1.PipelineRunReasonCouldntGetTask, pipelineRunName), FailedWithMessage("does not contain a dev.tekton.image.apiVersion annotation", pipelineRunName), ), "PipelineRunFailed", v1beta1Version); err != nil { t.Fatalf("Error waiting for PipelineRun to finish with expected error: %s", err)