44 lines
983 B
YAML
44 lines
983 B
YAML
suite: Auth PodDisruptionBudget
|
|
templates:
|
|
- auth/pdb.yaml
|
|
tests:
|
|
- it: not should create a PDB when disabled in values
|
|
set:
|
|
highAvailability:
|
|
podDisruptionBudget:
|
|
enabled: false
|
|
asserts:
|
|
- hasDocuments:
|
|
count: 0
|
|
- it: should create a PDB when enabled in values (pdb.yaml)
|
|
values:
|
|
- ../.lint/pdb.yaml
|
|
asserts:
|
|
- hasDocuments:
|
|
count: 1
|
|
- isKind:
|
|
of: PodDisruptionBudget
|
|
- equal:
|
|
path: spec.minAvailable
|
|
value: 2
|
|
|
|
- it: sets extraLabels on PodDisruptionBudget
|
|
values:
|
|
- ../.lint/pdb.yaml
|
|
set:
|
|
extraLabels:
|
|
podDisruptionBudget:
|
|
foo: bar
|
|
baz: override-me
|
|
auth:
|
|
extraLabels:
|
|
podDisruptionBudget:
|
|
baz: overridden
|
|
asserts:
|
|
- equal:
|
|
path: metadata.labels.foo
|
|
value: bar
|
|
- equal:
|
|
path: metadata.labels.baz
|
|
value: overridden
|