-
Notifications
You must be signed in to change notification settings - Fork 9
/
Copy pathdeployment_test.yaml
46 lines (45 loc) · 1.38 KB
/
deployment_test.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
suite: test deployment
templates:
- deployment.yaml
tests:
- it: should work
set:
agent.image.tag: kubernetes-edge
asserts:
- isKind:
of: Deployment
- matchRegex:
path: metadata.name
pattern: RELEASE-NAME-container-agent
- equal:
path: spec.template.spec.containers[0].image
value: circleci/runner-agent:kubernetes-edge
- it: should have the default logging collector configuration
asserts:
- contains:
path: spec.template.spec.containers[0].env
content:
name: KUBE_LOGGING_IMAGE
value: "circleci/logging-collector:3"
- contains:
path: spec.template.spec.containers[0].env
content:
name: KUBE_LOGGING_SECRET
value: "logging-collector-token"
- it: should override the default logging collector configuration
set:
logging.image.registry: foo
logging.image.repository: bar
logging.image.tag: baz
logging.serviceAccount.secret.name: my-custom-secret
asserts:
- contains:
path: spec.template.spec.containers[0].env
content:
name: KUBE_LOGGING_IMAGE
value: "foo/bar:baz"
- contains:
path: spec.template.spec.containers[0].env
content:
name: KUBE_LOGGING_SECRET
value: "my-custom-secret"