Skip to content

Commit

Permalink
test(helm-chart): add tests for local/global values (#3265)
Browse files Browse the repository at this point in the history
  • Loading branch information
mowies authored Mar 18, 2024
1 parent e6eaf5f commit b072e5e
Show file tree
Hide file tree
Showing 36 changed files with 12,662 additions and 549 deletions.
40 changes: 9 additions & 31 deletions .github/scripts/.helm-tests/certificates-only/result.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,33 +5,27 @@ kind: ServiceAccount
metadata:
name: certificate-operator
namespace: "helmtests"
annotations:
ciao: commonannotation
labels:
app.kubernetes.io/component: rbac
app.kubernetes.io/part-of: keptn
app.kubernetes.io/instance: keptn-test
app.kubernetes.io/managed-by: Helm
app.kubernetes.io/name: cert-manager
app.kubernetes.io/version: vmyversion
app.kubernetes.io/version: v2.1.0
helm.sh/chart: cert-manager-0.2.2
mamma: test
---
# Source: keptn/charts/certManager/templates/certificate-operator-rbac.yaml
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRole
metadata:
name: certificate-operator-role
namespace: "helmtests"
annotations:
ciao: commonannotation
labels:
app.kubernetes.io/instance: keptn-test
app.kubernetes.io/managed-by: Helm
app.kubernetes.io/name: cert-manager
app.kubernetes.io/version: vmyversion
app.kubernetes.io/version: v2.1.0
helm.sh/chart: cert-manager-0.2.2
mamma: test
rules:
- apiGroups:
- admissionregistration.k8s.io
Expand Down Expand Up @@ -78,18 +72,15 @@ kind: ClusterRoleBinding
metadata:
name: certificate-operator-rolebinding
namespace: "helmtests"
annotations:
ciao: commonannotation
labels:
app.kubernetes.io/component: rbac
app.kubernetes.io/created-by: certificate-operator
app.kubernetes.io/part-of: keptn
app.kubernetes.io/instance: keptn-test
app.kubernetes.io/managed-by: Helm
app.kubernetes.io/name: cert-manager
app.kubernetes.io/version: vmyversion
app.kubernetes.io/version: v2.1.0
helm.sh/chart: cert-manager-0.2.2
mamma: test
roleRef:
apiGroup: rbac.authorization.k8s.io
kind: ClusterRole
Expand All @@ -105,15 +96,12 @@ kind: Role
metadata:
name: certificate-operator-role
namespace: "helmtests"
annotations:
ciao: commonannotation
labels:
app.kubernetes.io/instance: keptn-test
app.kubernetes.io/managed-by: Helm
app.kubernetes.io/name: cert-manager
app.kubernetes.io/version: vmyversion
app.kubernetes.io/version: v2.1.0
helm.sh/chart: cert-manager-0.2.2
mamma: test
rules:
- apiGroups:
- ""
Expand All @@ -140,19 +128,15 @@ kind: RoleBinding
metadata:
name: certificate-operator-leader-election-rolebinding
namespace: "helmtests"
annotations:
ciao: commonannotation
labels:
app.kubernetes.io/component: rbac
app.kubernetes.io/created-by: certificate-operator
app.kubernetes.io/part-of: keptn
app.kubernetes.io/instance: keptn-test
app.kubernetes.io/managed-by: Helm
app.kubernetes.io/name: cert-manager
app.kubernetes.io/version: vmyversion
app.kubernetes.io/version: v2.1.0
helm.sh/chart: cert-manager-0.2.2
mamma: test
ciao: commonannotation
roleRef:
apiGroup: rbac.authorization.k8s.io
kind: Role
Expand All @@ -168,18 +152,15 @@ kind: RoleBinding
metadata:
name: certificate-operator-role-binding
namespace: "helmtests"
annotations:
ciao: commonannotation
labels:
app.kubernetes.io/component: rbac
app.kubernetes.io/created-by: certificate-operator
app.kubernetes.io/part-of: keptn
app.kubernetes.io/instance: keptn-test
app.kubernetes.io/managed-by: Helm
app.kubernetes.io/name: cert-manager
app.kubernetes.io/version: vmyversion
app.kubernetes.io/version: v2.1.0
helm.sh/chart: cert-manager-0.2.2
mamma: test
roleRef:
apiGroup: rbac.authorization.k8s.io
kind: Role
Expand All @@ -195,18 +176,15 @@ kind: Deployment
metadata:
name: certificate-operator
namespace: "helmtests"
annotations:
ciao: commonannotation
labels:
app.kubernetes.io/component: keptn-cert-manager
app.kubernetes.io/part-of: keptn
control-plane: certificate-operator
app.kubernetes.io/instance: keptn-test
app.kubernetes.io/managed-by: Helm
app.kubernetes.io/name: cert-manager
app.kubernetes.io/version: vmyversion
app.kubernetes.io/version: v2.1.0
helm.sh/chart: cert-manager-0.2.2
mamma: test
spec:
replicas: 1
selector:
Expand Down Expand Up @@ -239,7 +217,7 @@ spec:
value: "true"
- name: KUBERNETES_CLUSTER_DOMAIN
value: cluster.local
image: testreg/keptn/certificate-operator:v0.0.0
image: ghcr.io/keptn/certificate-operator:v0.0.0
imagePullPolicy: IfNotPresent
name: certificate-operator
resources:
Expand Down Expand Up @@ -271,7 +249,7 @@ spec:
port: 8081
initialDelaySeconds: 5
periodSeconds: 10
imagePullSecrets: []

securityContext:
runAsNonRoot: true
serviceAccountName: certificate-operator
Expand Down
10 changes: 0 additions & 10 deletions .github/scripts/.helm-tests/certificates-only/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,3 @@ lifecycleOperator:
enabled: false
metricsOperator:
enabled: false

global:
certManagerEnabled: true
imageRegistry: "testreg"
imagePullSecrets: []
commonAnnotations:
ciao: commonannotation
commonLabels:
mamma : "test"
app.kubernetes.io/version: vmyversion
Loading

0 comments on commit b072e5e

Please sign in to comment.