mirror of
https://github.com/bjw-s-labs/helm-charts.git
synced 2025-07-04 00:47:04 +02:00
49 lines
1.2 KiB
YAML
49 lines
1.2 KiB
YAML
---
|
|
# yaml-language-server: $schema=https://raw.githubusercontent.com/helm-unittest/helm-unittest/main/schema/helm-testsuite.json
|
|
suite: pod imagePullSecrets
|
|
templates:
|
|
- common.yaml
|
|
tests:
|
|
- it: default should pass
|
|
asserts:
|
|
- documentIndex: 0
|
|
isKind:
|
|
of: Deployment
|
|
- documentIndex: 0
|
|
notExists:
|
|
path: spec.template.spec.imagePullSecrets
|
|
|
|
- it: defaultPodOption should pass
|
|
set:
|
|
defaultPodOptions:
|
|
imagePullSecrets:
|
|
- name: my-pull-secret
|
|
asserts:
|
|
- documentIndex: 0
|
|
isKind:
|
|
of: Deployment
|
|
- documentIndex: 0
|
|
equal:
|
|
path: spec.template.spec.imagePullSecrets
|
|
value:
|
|
- name: my-pull-secret
|
|
|
|
- it: defaultPodOption with pod override should pass
|
|
set:
|
|
defaultPodOptions:
|
|
imagePullSecrets:
|
|
- name: my-pull-secret
|
|
controllers:
|
|
main:
|
|
pod:
|
|
imagePullSecrets:
|
|
- name: my-other-secret
|
|
asserts:
|
|
- documentIndex: 0
|
|
isKind:
|
|
of: Deployment
|
|
- documentIndex: 0
|
|
equal:
|
|
path: spec.template.spec.imagePullSecrets
|
|
value:
|
|
- name: my-other-secret
|