blob: 869d3a690e996aa17713cbf2a6c596fc4b7b49b3 [file] [log] [blame]
Mohammed Naser65cda132024-05-02 14:34:08 -04001suite: Controller > HPA
2templates:
3 - controller-hpa.yaml
4
5tests:
Mohammed Naser7d1623e2024-06-17 09:12:39 -04006 - it: should create an HPA if `controller.autoscaling.enabled` is true
Mohammed Naser65cda132024-05-02 14:34:08 -04007 set:
Mohammed Naser65cda132024-05-02 14:34:08 -04008 controller.autoscaling.enabled: true
9 asserts:
10 - hasDocuments:
11 count: 1
12 - isKind:
13 of: HorizontalPodAutoscaler
14 - equal:
15 path: metadata.name
16 value: RELEASE-NAME-ingress-nginx-controller
Mohammed Naser7d1623e2024-06-17 09:12:39 -040017
18 - it: should not create an HPA if `controller.autoscaling.enabled` is true and `controller.keda.enabled` is true
19 set:
20 controller.autoscaling.enabled: true
21 controller.keda.enabled: true
22 asserts:
23 - hasDocuments:
24 count: 0
25
26 - it: should not create an HPA if `controller.kind` is "DaemonSet"
27 set:
28 controller.kind: DaemonSet
29 asserts:
30 - hasDocuments:
31 count: 0