File tree Expand file tree Collapse file tree 2 files changed +98
-0
lines changed
charts/ingress-nginx/tests Expand file tree Collapse file tree 2 files changed +98
-0
lines changed Original file line number Diff line number Diff line change
1
+ suite : Controller > ServiceAccount
2
+ templates :
3
+ - controller-serviceaccount.yaml
4
+
5
+ tests :
6
+ - it : should not create a ServiceAccount if `serviceAccount.create` is false
7
+ set :
8
+ serviceAccount.create : false
9
+ asserts :
10
+ - hasDocuments :
11
+ count : 0
12
+
13
+ - it : should create a ServiceAccount if `serviceAccount.create` is true
14
+ set :
15
+ serviceAccount.create : true
16
+ asserts :
17
+ - hasDocuments :
18
+ count : 1
19
+ - isKind :
20
+ of : ServiceAccount
21
+ - equal :
22
+ path : metadata.name
23
+ value : RELEASE-NAME-ingress-nginx
24
+
25
+ - it : should create a ServiceAccount with specified name if `serviceAccount.name` is set
26
+ set :
27
+ serviceAccount.name : ingress-nginx-admission-test-sa
28
+ asserts :
29
+ - hasDocuments :
30
+ count : 1
31
+ - isKind :
32
+ of : ServiceAccount
33
+ - equal :
34
+ path : metadata.name
35
+ value : ingress-nginx-admission-test-sa
36
+
37
+ - it : should create a ServiceAccount with token auto-mounting disabled if `serviceAccount.automountServiceAccountToken` is false
38
+ set :
39
+ serviceAccount.automountServiceAccountToken : false
40
+ asserts :
41
+ - hasDocuments :
42
+ count : 1
43
+ - isKind :
44
+ of : ServiceAccount
45
+ - equal :
46
+ path : automountServiceAccountToken
47
+ value : false
Original file line number Diff line number Diff line change
1
+ suite : Default Backend > ServiceAccount
2
+ templates :
3
+ - default-backend-serviceaccount.yaml
4
+
5
+ tests :
6
+ - it : should not create a ServiceAccount if `defaultBackend.serviceAccount.create` is false
7
+ set :
8
+ defaultBackend.enabled : true
9
+ defaultBackend.serviceAccount.create : false
10
+ asserts :
11
+ - hasDocuments :
12
+ count : 0
13
+
14
+ - it : should create a ServiceAccount if `defaultBackend.serviceAccount.create` is true
15
+ set :
16
+ defaultBackend.enabled : true
17
+ defaultBackend.serviceAccount.create : true
18
+ asserts :
19
+ - hasDocuments :
20
+ count : 1
21
+ - isKind :
22
+ of : ServiceAccount
23
+ - equal :
24
+ path : metadata.name
25
+ value : RELEASE-NAME-ingress-nginx-backend
26
+
27
+ - it : should create a ServiceAccount with specified name if `defaultBackend.serviceAccount.name` is set
28
+ set :
29
+ defaultBackend.enabled : true
30
+ defaultBackend.serviceAccount.name : ingress-nginx-admission-test-sa
31
+ asserts :
32
+ - hasDocuments :
33
+ count : 1
34
+ - isKind :
35
+ of : ServiceAccount
36
+ - equal :
37
+ path : metadata.name
38
+ value : ingress-nginx-admission-test-sa
39
+
40
+ - it : should create a ServiceAccount with token auto-mounting disabled if `defaultBackend.serviceAccount.automountServiceAccountToken` is false
41
+ set :
42
+ defaultBackend.enabled : true
43
+ defaultBackend.serviceAccount.automountServiceAccountToken : false
44
+ asserts :
45
+ - hasDocuments :
46
+ count : 1
47
+ - isKind :
48
+ of : ServiceAccount
49
+ - equal :
50
+ path : automountServiceAccountToken
51
+ value : false
You can’t perform that action at this time.
0 commit comments