Skip to content

Commit

Permalink
fix(accountapp): add missing default image.pullPolicy and unit tests (
Browse files Browse the repository at this point in the history
jenkins-infra#593)

* fix(accountapp): add missing default `image.pullPolicy` and unit tests

* bump chart version
  • Loading branch information
lemeurherve authored Aug 11, 2023
1 parent 2d6c206 commit 9390d3c
Show file tree
Hide file tree
Showing 6 changed files with 33 additions and 16 deletions.
1 change: 1 addition & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ jobs:
strategy:
matrix:
chart:
- accountapp
- artifact-caching-proxy
- httpredirector
- jenkins-jobs
Expand Down
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.5.26
version: 0.6.0
15 changes: 0 additions & 15 deletions charts/accountapp/templates/tests/test-connection.yaml

This file was deleted.

24 changes: 24 additions & 0 deletions charts/accountapp/tests/defaults_test.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
suite: default tests
values:
- ../values.yaml
- secrets_default_values.yaml
templates:
- deployment.yaml
- ingress.yaml
- secret.yaml # Direct dependency of deployment.yaml
tests:
- it: should create an ingress by default
template: ingress.yaml
asserts:
- hasDocuments:
count: 1
- it: should define the default deployment with default imagePullPolicy
template: deployment.yaml
asserts:
- hasDocuments:
count: 1
- isKind:
of: Deployment
- equal:
path: spec.template.spec.containers[0].imagePullPolicy
value: IfNotPresent
6 changes: 6 additions & 0 deletions charts/accountapp/tests/secrets_default_values.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
ldap:
password: ldap-password
jira:
password: jira-password
smtp:
password: smtp-password
1 change: 1 addition & 0 deletions charts/accountapp/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ replicaCount: 1
image:
repository: jenkinsciinfra/account-app
tag: 0.4.29
pullPolicy: IfNotPresent
imagePullSecrets: []
nameOverride: ""
fullnameOverride: ""
Expand Down

0 comments on commit 9390d3c

Please sign in to comment.