Skip to content

Commit fd8f6a4

Browse files
author
Per Goncalves da Silva
committed
Move v2.0.0 e2e test to v1.3.0 due to lack of webhook support
Signed-off-by: Per Goncalves da Silva <pegoncal@redhat.com>
1 parent 1022774 commit fd8f6a4

File tree

6 files changed

+274
-5
lines changed

6 files changed

+274
-5
lines changed

test/e2e/cluster_extension_install_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -732,7 +732,7 @@ func TestClusterExtensionInstallReResolvesWhenCatalogIsPatched(t *testing.T) {
732732
assert.Equal(ct, metav1.ConditionTrue, cond.Status)
733733
assert.Equal(ct, ocv1.ReasonSucceeded, cond.Reason)
734734
assert.Contains(ct, cond.Message, "Installed bundle")
735-
assert.Contains(ct, clusterExtension.Status.Install.Bundle.Version, "2.0.0")
735+
assert.Contains(ct, clusterExtension.Status.Install.Bundle.Version, "1.3.0")
736736
}
737737
}, pollDuration, pollInterval)
738738

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
apiVersion: v1
2+
kind: ConfigMap
3+
metadata:
4+
name: test-configmap
5+
annotations:
6+
shouldNotTemplate: >
7+
The namespace is {{ $labels.namespace }}. The templated
8+
$labels.namespace is NOT expected to be processed by OLM's
9+
rendering engine for registry+v1 bundles.
10+
data:
11+
version: "v1.3.0"
12+
name: "test-configmap"
Lines changed: 190 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,190 @@
1+
apiVersion: operators.coreos.com/v1alpha1
2+
kind: ClusterServiceVersion
3+
metadata:
4+
annotations:
5+
alm-examples: '[]'
6+
capabilities: Basic Install
7+
createdAt: "2025-07-03T15:15:31Z"
8+
operators.operatorframework.io/builder: operator-sdk-v1.40.0+git
9+
operators.operatorframework.io/project_layout: go.kubebuilder.io/v4
10+
name: test-operator.v1.0.0
11+
namespace: placeholder
12+
spec:
13+
apiservicedefinitions: {}
14+
customresourcedefinitions:
15+
owned:
16+
- description: TestOperator is the Schema for the testoperators API.
17+
displayName: Test Operator
18+
kind: TestOperator
19+
name: testoperators.testolm.operatorframework.io
20+
version: v1
21+
description: Test OLM Operator
22+
displayName: OLM Test Operator
23+
icon:
24+
- base64data: ""
25+
mediatype: ""
26+
install:
27+
spec:
28+
clusterPermissions:
29+
- rules:
30+
- apiGroups:
31+
- testolm.operatorframework.io
32+
resources:
33+
- testoperators
34+
verbs:
35+
- create
36+
- delete
37+
- get
38+
- list
39+
- patch
40+
- update
41+
- watch
42+
- apiGroups:
43+
- testolm.operatorframework.io
44+
resources:
45+
- testoperators/finalizers
46+
verbs:
47+
- update
48+
- apiGroups:
49+
- testolm.operatorframework.io
50+
resources:
51+
- testoperators/status
52+
verbs:
53+
- get
54+
- patch
55+
- update
56+
- apiGroups:
57+
- authentication.k8s.io
58+
resources:
59+
- tokenreviews
60+
verbs:
61+
- create
62+
- apiGroups:
63+
- authorization.k8s.io
64+
resources:
65+
- subjectaccessreviews
66+
verbs:
67+
- create
68+
serviceAccountName: test-operator-controller-manager
69+
deployments:
70+
- label:
71+
app.kubernetes.io/managed-by: kustomize
72+
app.kubernetes.io/name: test-operator
73+
control-plane: controller-manager
74+
name: test-operator-controller-manager
75+
spec:
76+
replicas: 1
77+
selector:
78+
matchLabels:
79+
app.kubernetes.io/name: test-operator
80+
control-plane: controller-manager
81+
strategy: {}
82+
template:
83+
metadata:
84+
annotations:
85+
kubectl.kubernetes.io/default-container: manager
86+
labels:
87+
app.kubernetes.io/name: test-operator
88+
control-plane: controller-manager
89+
spec:
90+
containers:
91+
- args:
92+
- --leader-elect
93+
- --health-probe-bind-address=:8081
94+
command:
95+
- /manager
96+
env:
97+
- name: WATCH_NAMESPACE
98+
valueFrom:
99+
fieldRef:
100+
fieldPath: metadata.annotations['olm.targetNamespaces']
101+
image: docker-registry.operator-controller-e2e.svc.cluster.local:5000/controllers/test-operator:v1.0.0
102+
livenessProbe:
103+
httpGet:
104+
path: /healthz
105+
port: 8081
106+
initialDelaySeconds: 15
107+
periodSeconds: 20
108+
name: manager
109+
readinessProbe:
110+
httpGet:
111+
path: /readyz
112+
port: 8081
113+
initialDelaySeconds: 5
114+
periodSeconds: 10
115+
resources:
116+
limits:
117+
cpu: 500m
118+
memory: 128Mi
119+
requests:
120+
cpu: 10m
121+
memory: 64Mi
122+
securityContext:
123+
allowPrivilegeEscalation: false
124+
capabilities:
125+
drop:
126+
- ALL
127+
securityContext:
128+
runAsNonRoot: true
129+
seccompProfile:
130+
type: RuntimeDefault
131+
serviceAccountName: test-operator-controller-manager
132+
terminationGracePeriodSeconds: 10
133+
permissions:
134+
- rules:
135+
- apiGroups:
136+
- ""
137+
resources:
138+
- configmaps
139+
verbs:
140+
- get
141+
- list
142+
- watch
143+
- create
144+
- update
145+
- patch
146+
- delete
147+
- apiGroups:
148+
- coordination.k8s.io
149+
resources:
150+
- leases
151+
verbs:
152+
- get
153+
- list
154+
- watch
155+
- create
156+
- update
157+
- patch
158+
- delete
159+
- apiGroups:
160+
- ""
161+
resources:
162+
- events
163+
verbs:
164+
- create
165+
- patch
166+
serviceAccountName: test-operator-controller-manager
167+
strategy: deployment
168+
installModes:
169+
- supported: true
170+
type: OwnNamespace
171+
- supported: true
172+
type: SingleNamespace
173+
- supported: false
174+
type: MultiNamespace
175+
- supported: true
176+
type: AllNamespaces
177+
keywords:
178+
- test
179+
- operator
180+
links:
181+
- name: V1
182+
url: https://github.com/operator-framework/operator-controller
183+
maintainers:
184+
- email: operator-framework-olm-dev@googlegroups.com
185+
name: community
186+
maturity: alpha
187+
provider:
188+
name: operator-framework
189+
url: https://github.com/operator-framework/operator-controller
190+
version: 1.0.0
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,61 @@
1+
apiVersion: apiextensions.k8s.io/v1
2+
kind: CustomResourceDefinition
3+
metadata:
4+
annotations:
5+
controller-gen.kubebuilder.io/version: v0.18.0
6+
creationTimestamp: null
7+
name: testoperators.testolm.operatorframework.io
8+
spec:
9+
group: testolm.operatorframework.io
10+
names:
11+
kind: TestOperator
12+
listKind: TestOperatorList
13+
plural: testoperators
14+
singular: testoperator
15+
scope: Namespaced
16+
versions:
17+
- name: v1
18+
schema:
19+
openAPIV3Schema:
20+
description: TestOperator is the Schema for the testoperators API.
21+
properties:
22+
apiVersion:
23+
description: |-
24+
APIVersion defines the versioned schema of this representation of an object.
25+
Servers should convert recognized schemas to the latest internal value, and
26+
may reject unrecognized values.
27+
More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources
28+
type: string
29+
kind:
30+
description: |-
31+
Kind is a string value representing the REST resource this object represents.
32+
Servers may infer this from the endpoint the client submits requests to.
33+
Cannot be updated.
34+
In CamelCase.
35+
More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds
36+
type: string
37+
metadata:
38+
type: object
39+
spec:
40+
description: TestOperatorSpec defines the desired state of TestOperator.
41+
properties:
42+
message:
43+
type: string
44+
type: object
45+
status:
46+
description: TestOperatorStatus defines the observed state of TestOperator.
47+
properties:
48+
echo:
49+
type: string
50+
type: object
51+
type: object
52+
served: true
53+
storage: true
54+
subresources:
55+
status: {}
56+
status:
57+
acceptedNames:
58+
kind: ""
59+
plural: ""
60+
conditions: null
61+
storedVersions: null
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
annotations:
2+
operators.operatorframework.io.bundle.mediatype.v1: registry+v1
3+
operators.operatorframework.io.bundle.manifests.v1: manifests/
4+
operators.operatorframework.io.bundle.metadata.v1: metadata/
5+
operators.operatorframework.io.bundle.package.v1: test
6+
operators.operatorframework.io.bundle.channels.v1: beta

testdata/images/catalogs/test-catalog/v2/configs/catalog.yaml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7,15 +7,15 @@ schema: olm.channel
77
name: beta
88
package: test
99
entries:
10-
- name: test-operator.2.0.0
10+
- name: test-operator.1.3.0
1111
replaces: test-operator.1.2.0
1212
---
1313
schema: olm.bundle
14-
name: test-operator.2.0.0
14+
name: test-operator.1.3.0
1515
package: test
16-
image: docker-registry.operator-controller-e2e.svc.cluster.local:5000/bundles/registry-v1/test-operator:v2.0.0
16+
image: docker-registry.operator-controller-e2e.svc.cluster.local:5000/bundles/registry-v1/test-operator:v1.3.0
1717
properties:
1818
- type: olm.package
1919
value:
2020
packageName: test
21-
version: 2.0.0
21+
version: 1.3.0

0 commit comments

Comments
 (0)