34 lines
1009 B
YAML
34 lines
1009 B
YAML
suite: "Controller Deployment imagePullSecrets"
|
|
templates:
|
|
- deployment.yaml
|
|
tests:
|
|
- it: should not render imagePullSecrets by default
|
|
release:
|
|
name: "test-name"
|
|
namespace: "test-namespace"
|
|
asserts:
|
|
- notExists:
|
|
path: spec.template.spec.imagePullSecrets
|
|
|
|
- it: should render imagePullSecrets and forward them as args when configured
|
|
set:
|
|
imagePullSecrets:
|
|
- name: regcred
|
|
- name: another
|
|
release:
|
|
name: "test-name"
|
|
namespace: "test-namespace"
|
|
asserts:
|
|
- equal:
|
|
path: spec.template.spec.imagePullSecrets[0].name
|
|
value: regcred
|
|
- equal:
|
|
path: spec.template.spec.imagePullSecrets[1].name
|
|
value: another
|
|
- contains:
|
|
path: spec.template.spec.containers[0].args
|
|
content: "--auto-scaler-image-pull-secrets=regcred"
|
|
- contains:
|
|
path: spec.template.spec.containers[0].args
|
|
content: "--auto-scaler-image-pull-secrets=another"
|