Skip to content
Snippets Groups Projects
Commit ecb60160 authored by OZGCloud's avatar OZGCloud
Browse files

OZG-5238 Cleaned Up deployment helm test

parent b475a2cf
No related branches found
No related tags found
No related merge requests found
...@@ -28,14 +28,14 @@ release: ...@@ -28,14 +28,14 @@ release:
namespace: sh-helm-test namespace: sh-helm-test
templates: templates:
- templates/deployment.yaml - templates/deployment.yaml
tests:
- it: should have a volume for the mongodb certificate
set: set:
ozgcloud: ozgcloud:
bundesland: sh bundesland: sh
bezeichner: helm bezeichner: helm
sso: sso:
serverUrl: https://sso.company.local serverUrl: https://sso.company.local
tests:
- it: should have a volume for the mongodb certificate
asserts: asserts:
- contains: - contains:
path: spec.template.spec.volumes path: spec.template.spec.volumes
...@@ -45,12 +45,6 @@ tests: ...@@ -45,12 +45,6 @@ tests:
secretName: ozg-mongodb-tls-cert secretName: ozg-mongodb-tls-cert
optional: true optional: true
- it: should mount mongodb certificate volume - it: should mount mongodb certificate volume
set:
ozgcloud:
bundesland: sh
bezeichner: helm
sso:
serverUrl: https://sso.company.local
asserts: asserts:
- contains: - contains:
path: spec.template.spec.containers[0].volumeMounts path: spec.template.spec.containers[0].volumeMounts
...@@ -61,11 +55,6 @@ tests: ...@@ -61,11 +55,6 @@ tests:
readOnly: true readOnly: true
- it: should configure internal mongodb if not useExternal - it: should configure internal mongodb if not useExternal
set: set:
ozgcloud:
bundesland: sh
bezeichner: helm
sso:
serverUrl: https://sso.company.local
database.useExternal: false database.useExternal: false
asserts: asserts:
- contains: - contains:
...@@ -84,11 +73,6 @@ tests: ...@@ -84,11 +73,6 @@ tests:
value: administration-database value: administration-database
- it: should configure external mongodb if useExternal - it: should configure external mongodb if useExternal
set: set:
ozgcloud:
bundesland: sh
bezeichner: helm
sso:
serverUrl: https://sso.company.local
database.useExternal: true database.useExternal: true
asserts: asserts:
- contains: - contains:
......
...@@ -27,14 +27,14 @@ templates: ...@@ -27,14 +27,14 @@ templates:
release: release:
name: administration name: administration
namespace: helm-test namespace: helm-test
tests:
- it: should use default image pull secret
set: set:
ozgcloud: ozgcloud:
bundesland: sh bundesland: sh
bezeichner: helm bezeichner: helm
sso: sso:
serverUrl: https://sso.company.local serverUrl: https://sso.company.local
tests:
- it: should use default image pull secret
asserts: asserts:
- contains: - contains:
path: spec.template.spec.imagePullSecrets path: spec.template.spec.imagePullSecrets
...@@ -42,11 +42,6 @@ tests: ...@@ -42,11 +42,6 @@ tests:
name: administration-image-pull-secret name: administration-image-pull-secret
- it: should use customizable image pull secret - it: should use customizable image pull secret
set: set:
ozgcloud:
bundesland: sh
bezeichner: helm
sso:
serverUrl: https://sso.company.local
imagePullSecret: custom-image-pull-secret imagePullSecret: custom-image-pull-secret
asserts: asserts:
- contains: - contains:
......
...@@ -27,14 +27,15 @@ templates: ...@@ -27,14 +27,15 @@ templates:
release: release:
name: administration name: administration
namespace: helm-test namespace: helm-test
tests:
- it: should have customizable resources
set: set:
ozgcloud: ozgcloud:
bundesland: sh bundesland: sh
bezeichner: helm bezeichner: helm
sso: sso:
serverUrl: https://sso.company.local serverUrl: https://sso.company.local
tests:
- it: should have customizable resources
set:
resources: { "test": 1 } resources: { "test": 1 }
asserts: asserts:
- equal: - equal:
......
...@@ -28,14 +28,15 @@ release: ...@@ -28,14 +28,15 @@ release:
namespace: sh-helm-test namespace: sh-helm-test
templates: templates:
- templates/deployment.yaml - templates/deployment.yaml
tests:
- it: should override the spring profiles
set: set:
ozgcloud: ozgcloud:
bundesland: sh bundesland: sh
bezeichner: helm bezeichner: helm
sso: sso:
serverUrl: https://sso.company.local serverUrl: https://sso.company.local
tests:
- it: should override the spring profiles
set:
env.overrideSpringProfiles: oc,dev,ea env.overrideSpringProfiles: oc,dev,ea
asserts: asserts:
- isKind: - isKind:
...@@ -46,12 +47,6 @@ tests: ...@@ -46,12 +47,6 @@ tests:
name: spring_profiles_active name: spring_profiles_active
value: oc,dev,ea value: oc,dev,ea
- it: should generate the spring profiles - it: should generate the spring profiles
set:
ozgcloud:
bundesland: sh
bezeichner: helm
sso:
serverUrl: https://sso.company.local
asserts: asserts:
- isKind: - isKind:
of: Deployment of: Deployment
......
...@@ -27,16 +27,15 @@ release: ...@@ -27,16 +27,15 @@ release:
name: administration name: administration
templates: templates:
- templates/deployment.yaml - templates/deployment.yaml
set:
ozgcloud.environment: "default"
tests:
- it: should have metadata values
set: set:
ozgcloud: ozgcloud:
environment: "default"
bundesland: sh bundesland: sh
bezeichner: helm bezeichner: helm
sso: sso:
serverUrl: https://sso.company.local serverUrl: https://sso.company.local
tests:
- it: should have metadata values
asserts: asserts:
- isKind: - isKind:
of: Deployment of: Deployment
...@@ -49,12 +48,6 @@ tests: ...@@ -49,12 +48,6 @@ tests:
- exists: - exists:
path: metadata.labels path: metadata.labels
- it: should have correct general settings - it: should have correct general settings
set:
ozgcloud:
bundesland: sh
bezeichner: helm
sso:
serverUrl: https://sso.company.local
asserts: asserts:
- equal: - equal:
path: spec.progressDeadlineSeconds path: spec.progressDeadlineSeconds
...@@ -83,12 +76,6 @@ tests: ...@@ -83,12 +76,6 @@ tests:
path: spec.strategy.type path: spec.strategy.type
value: "RollingUpdate" value: "RollingUpdate"
- it: should have correct template configuration - it: should have correct template configuration
set:
ozgcloud:
bundesland: sh
bezeichner: helm
sso:
serverUrl: https://sso.company.local
asserts: asserts:
- equal: - equal:
path: spec.template.metadata.labels["app.kubernetes.io/instance"] path: spec.template.metadata.labels["app.kubernetes.io/instance"]
...@@ -128,12 +115,6 @@ tests: ...@@ -128,12 +115,6 @@ tests:
path: spec.template.spec.terminationGracePeriodSeconds path: spec.template.spec.terminationGracePeriodSeconds
value: 300000000 value: 300000000
- it: should have correct container configuration - it: should have correct container configuration
set:
ozgcloud:
bundesland: sh
bezeichner: helm
sso:
serverUrl: https://sso.company.local
asserts: asserts:
- equal: - equal:
path: spec.template.spec.containers[0].name path: spec.template.spec.containers[0].name
......
...@@ -29,15 +29,14 @@ templates: ...@@ -29,15 +29,14 @@ templates:
- templates/deployment.yaml - templates/deployment.yaml
set: set:
Release.Name: "administration" Release.Name: "administration"
ozgcloud.environment: "default"
tests:
- it: should have volumeMounts on it's container
set:
ozgcloud: ozgcloud:
environment: "default"
bundesland: sh bundesland: sh
bezeichner: helm bezeichner: helm
sso: sso:
serverUrl: https://sso.company.local serverUrl: https://sso.company.local
tests:
- it: should have volumeMounts on it's container
asserts: asserts:
- equal: - equal:
path: spec.template.spec.containers[0].volumeMounts[0].name path: spec.template.spec.containers[0].volumeMounts[0].name
...@@ -64,12 +63,6 @@ tests: ...@@ -64,12 +63,6 @@ tests:
path: spec.template.spec.containers[0].volumeMounts[1].readOnly path: spec.template.spec.containers[0].volumeMounts[1].readOnly
value: true value: true
- it: should have volumes on it's spec - it: should have volumes on it's spec
set:
ozgcloud:
bundesland: sh
bezeichner: helm
sso:
serverUrl: https://sso.company.local
asserts: asserts:
- equal: - equal:
path: spec.template.spec.volumes[0].name path: spec.template.spec.volumes[0].name
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment