File tree Expand file tree Collapse file tree 4 files changed +6
-8
lines changed Expand file tree Collapse file tree 4 files changed +6
-8
lines changed Original file line number Diff line number Diff line change 11# Copyright Contributors to the Open Cluster Management project
22
33# Stage 1: Use image builder to build the target binaries
4- FROM registry.ci.openshift.org/stolostron/builder:go1.23 -linux AS builder
4+ FROM registry.ci.openshift.org/stolostron/builder:go1.24 -linux AS builder
55
66ENV COMPONENT=config-policy-controller
77ENV REPO_PATH=/go/src/github.com/open-cluster-management/${COMPONENT}
Original file line number Diff line number Diff line change 44package controllers
55
66import (
7- "context"
87 "fmt"
98 "reflect"
109 "sync"
@@ -72,7 +71,7 @@ func TestReconcile(t *testing.T) {
7271 },
7372 }
7473
75- res , err := r .Reconcile (context . TODO (), req )
74+ res , err := r .Reconcile (t . Context (), req )
7675 if err != nil {
7776 t .Fatalf ("reconcile: (%v)" , err )
7877 }
Original file line number Diff line number Diff line change 44package controllers
55
66import (
7- "context"
87 "crypto/rand"
98 "testing"
109
@@ -75,7 +74,7 @@ func TestGetEncryptionConfig(t *testing.T) {
7574
7675 policy := getEmptyPolicy ()
7776
78- config , err := r .getEncryptionConfig (context . TODO (), & policy )
77+ config , err := r .getEncryptionConfig (t . Context (), & policy )
7978 Expect (err ).ToNot (HaveOccurred ())
8079 Expect (config ).ToNot (BeNil ())
8180 Expect (config .AESKey ).ToNot (BeNil ())
@@ -100,7 +99,7 @@ func TestGetEncryptionConfigInvalidIV(t *testing.T) {
10099 },
101100 }
102101
103- _ , err := r .getEncryptionConfig (context . TODO (), & policy )
102+ _ , err := r .getEncryptionConfig (t . Context (), & policy )
104103 Expect (err .Error ()).To (
105104 Equal (
106105 "the policy annotation of \" policy.open-cluster-management.io/encryption-iv\" is not Base64: illegal " +
@@ -117,7 +116,7 @@ func TestGetEncryptionConfigNoSecret(t *testing.T) {
117116
118117 policy := getEmptyPolicy ()
119118
120- _ , err := r .getEncryptionConfig (context . TODO (), & policy )
119+ _ , err := r .getEncryptionConfig (t . Context (), & policy )
121120 Expect (err .Error ()).To (
122121 Equal (
123122 `failed to get the encryption key from Secret local-cluster/policy-encryption-key: secrets ` +
Original file line number Diff line number Diff line change 11module open-cluster-management.io/config-policy-controller
22
3- go 1.23 .0
3+ go 1.24 .0
44
55require (
66 github.com/Masterminds/sprig/v3 v3.2.3
You can’t perform that action at this time.
0 commit comments