Skip to content

Commit aeed2e6

Browse files
committed
remove creationtimestamp: null for envtests
1 parent 9bbfe0c commit aeed2e6

5 files changed

Lines changed: 0 additions & 13 deletions

File tree

internal/controller/postgrescluster/cluster_test.go

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -576,7 +576,6 @@ apiVersion: v1
576576
kind: Service
577577
`))
578578
assert.Assert(t, cmp.MarshalMatches(service.ObjectMeta, `
579-
creationTimestamp: null
580579
labels:
581580
postgres-operator.crunchydata.com/cluster: pg5
582581
postgres-operator.crunchydata.com/role: primary
@@ -605,7 +604,6 @@ ownerReferences:
605604
apiVersion: v1
606605
kind: Endpoints
607606
metadata:
608-
creationTimestamp: null
609607
labels:
610608
postgres-operator.crunchydata.com/cluster: pg5
611609
postgres-operator.crunchydata.com/role: primary
@@ -695,7 +693,6 @@ apiVersion: v1
695693
kind: Service
696694
`))
697695
assert.Assert(t, cmp.MarshalMatches(service.ObjectMeta, `
698-
creationTimestamp: null
699696
labels:
700697
postgres-operator.crunchydata.com/cluster: pg2
701698
postgres-operator.crunchydata.com/role: replica

internal/controller/postgrescluster/patroni_test.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,6 @@ apiVersion: v1
5151
kind: Service
5252
`))
5353
assert.Assert(t, cmp.MarshalMatches(service.ObjectMeta, `
54-
creationTimestamp: null
5554
labels:
5655
postgres-operator.crunchydata.com/cluster: pg2
5756
postgres-operator.crunchydata.com/patroni: pg2-ha

internal/controller/postgrescluster/pgadmin_test.go

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -141,7 +141,6 @@ func TestGeneratePGAdminService(t *testing.T) {
141141
assert.Assert(t, !specified)
142142

143143
assert.Assert(t, cmp.MarshalMatches(service.ObjectMeta, `
144-
creationTimestamp: null
145144
name: my-cluster-pgadmin
146145
namespace: my-ns
147146
`))
@@ -158,7 +157,6 @@ apiVersion: v1
158157
kind: Service
159158
`))
160159
assert.Assert(t, cmp.MarshalMatches(service.ObjectMeta, `
161-
creationTimestamp: null
162160
labels:
163161
postgres-operator.crunchydata.com/cluster: my-cluster
164162
postgres-operator.crunchydata.com/role: pgadmin
@@ -501,7 +499,6 @@ func TestReconcilePGAdminStatefulSet(t *testing.T) {
501499
assert.Assert(t, cmp.MarshalMatches(template.ObjectMeta, `
502500
annotations:
503501
kubectl.kubernetes.io/default-container: pgadmin
504-
creationTimestamp: null
505502
labels:
506503
postgres-operator.crunchydata.com/cluster: test-cluster
507504
postgres-operator.crunchydata.com/data: pgadmin
@@ -615,7 +612,6 @@ terminationGracePeriodSeconds: 30
615612
annotations:
616613
annotation1: annotationvalue
617614
kubectl.kubernetes.io/default-container: pgadmin
618-
creationTimestamp: null
619615
labels:
620616
label1: labelvalue
621617
postgres-operator.crunchydata.com/cluster: custom-cluster

internal/controller/postgrescluster/pgbouncer_test.go

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,6 @@ func TestGeneratePGBouncerService(t *testing.T) {
5151
assert.Assert(t, !specified)
5252

5353
assert.Assert(t, cmp.MarshalMatches(service.ObjectMeta, `
54-
creationTimestamp: null
5554
name: pg7-pgbouncer
5655
namespace: ns5
5756
`))
@@ -70,7 +69,6 @@ apiVersion: v1
7069
kind: Service
7170
`))
7271
assert.Assert(t, cmp.MarshalMatches(service.ObjectMeta, `
73-
creationTimestamp: null
7472
labels:
7573
postgres-operator.crunchydata.com/cluster: pg7
7674
postgres-operator.crunchydata.com/role: pgbouncer
@@ -387,7 +385,6 @@ func TestGeneratePGBouncerDeployment(t *testing.T) {
387385
assert.Assert(t, !specified)
388386

389387
assert.Assert(t, cmp.MarshalMatches(deploy.ObjectMeta, `
390-
creationTimestamp: null
391388
name: test-cluster-pgbouncer
392389
namespace: ns3
393390
`))

internal/controller/standalone_pgadmin/statefulset_test.go

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,6 @@ func TestReconcilePGAdminStatefulSet(t *testing.T) {
8282
assert.Assert(t, cmp.MarshalMatches(template.ObjectMeta, `
8383
annotations:
8484
kubectl.kubernetes.io/default-container: pgadmin
85-
creationTimestamp: null
8685
labels:
8786
postgres-operator.crunchydata.com/data: pgadmin
8887
postgres-operator.crunchydata.com/pgadmin: test-standalone-pgadmin
@@ -187,7 +186,6 @@ terminationGracePeriodSeconds: 30
187186
annotations:
188187
annotation1: annotationvalue
189188
kubectl.kubernetes.io/default-container: pgadmin
190-
creationTimestamp: null
191189
labels:
192190
label1: labelvalue
193191
postgres-operator.crunchydata.com/data: pgadmin

0 commit comments

Comments
 (0)