Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(accountapp): fix templating and unit test (#725) #726

Merged
merged 1 commit into from
Sep 21, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion charts/accountapp/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@ description: A Helm chart for accounts.jenkins.io
maintainers:
- name: timja
name: accountapp
version: 0.6.13
version: 0.6.14
29 changes: 29 additions & 0 deletions charts/accountapp/tests/custom_values_test.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
suite: Test with custom values
templates:
- deployment.yaml
- ingress.yaml
- secret.yaml # Direct dependency of deployment.yaml
tests:
- it: should create a Secret with the correct value
set:
ldap:
password: ldap-password
jira:
password: jira-password
smtp:
password: smtp-password
template: secret.yaml
asserts:
- hasDocuments:
count: 1
- isKind:
of: Secret
- equal:
path: data.ldapPassword
value: bGRhcC1wYXNzd29yZA==
- equal:
path: data.jiraPassword
value: amlyYS1wYXNzd29yZA==
- equal:
path: data.smtpPassword
value: c210cC1wYXNzd29yZA==
3 changes: 0 additions & 3 deletions charts/accountapp/tests/defaults_test.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,4 @@
suite: default tests
values:
- ../values.yaml
- secrets_default_values.yaml
templates:
- deployment.yaml
- ingress.yaml
Expand Down
6 changes: 0 additions & 6 deletions charts/accountapp/tests/secrets_default_values.yaml

This file was deleted.

6 changes: 3 additions & 3 deletions charts/accountapp/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -46,10 +46,10 @@ ldap:
url: ldaps://ldap.jenkins.io:636/
managerDn: cn=admin,dc=jenkins-ci,dc=org
newUserBaseDn: ou=people,dc=jenkins-ci,dc=org
password: null
password: ""
jira:
username: accountapp
password: null
password: ""
url: https://issues.jenkins.io/
seats: 2
seniority: 12
Expand All @@ -59,7 +59,7 @@ smtp:
sender: [email protected]
port: 587
user: null
password: null
password: ""
appUrl: https://accounts.jenkins.io
election:
open: 1970-01-01
Expand Down