@@ -69,6 +69,7 @@ func describe() {
69
69
70
70
ginkgo .By ("checking the pod total EPC size annotation is correctly set" )
71
71
gomega .Expect (pod .Annotations ["sgx.intel.com/epc" ]).To (gomega .Equal ("1Mi" ))
72
+ gomega .Expect (pod .Annotations ["epc-limit.nri.io/container.test" ]).To (gomega .Equal ("1048576" ))
72
73
})
73
74
ginkgo .It ("mutates created pods when the container contains the quote generation libraries" , func (ctx context.Context ) {
74
75
ginkgo .By ("submitting the pod" )
@@ -79,6 +80,7 @@ func describe() {
79
80
80
81
ginkgo .By ("checking the pod total EPC size annotation is correctly set" )
81
82
gomega .Expect (pod .Annotations ["sgx.intel.com/epc" ]).To (gomega .Equal ("1Mi" ))
83
+ gomega .Expect (pod .Annotations ["epc-limit.nri.io/container.test" ]).To (gomega .Equal ("1048576" ))
82
84
})
83
85
ginkgo .It ("mutates created pods when the container uses aesmd from a side-car container to generate quotes" , func (ctx context.Context ) {
84
86
ginkgo .By ("submitting the pod" )
@@ -93,6 +95,8 @@ func describe() {
93
95
gomega .Expect (pod .Spec .Containers [0 ].Env [0 ].Value ).To (gomega .Equal ("1" ))
94
96
ginkgo .By ("checking the pod total EPC size annotation is correctly set" )
95
97
gomega .Expect (pod .Annotations ["sgx.intel.com/epc" ]).To (gomega .Equal ("2Mi" ))
98
+ gomega .Expect (pod .Annotations ["epc-limit.nri.io/container.test" ]).To (gomega .Equal ("1048576" ))
99
+ gomega .Expect (pod .Annotations ["epc-limit.nri.io/container.aesmd" ]).To (gomega .Equal ("1048576" ))
96
100
})
97
101
ginkgo .It ("mutates created pods where one container uses host/daemonset aesmd to generate quotes" , func (ctx context.Context ) {
98
102
ginkgo .By ("submitting the pod" )
@@ -106,6 +110,7 @@ func describe() {
106
110
gomega .Expect (pod .Spec .Containers [0 ].Env [0 ].Value ).To (gomega .Equal ("1" ))
107
111
ginkgo .By ("checking the pod total EPC size annotation is correctly set" )
108
112
gomega .Expect (pod .Annotations ["sgx.intel.com/epc" ]).To (gomega .Equal ("1Mi" ))
113
+ gomega .Expect (pod .Annotations ["epc-limit.nri.io/container.test" ]).To (gomega .Equal ("1048576" ))
109
114
})
110
115
ginkgo .It ("mutates created pods where three containers use host/daemonset aesmd to generate quotes" , func (ctx context.Context ) {
111
116
ginkgo .By ("submitting the pod" )
@@ -125,6 +130,9 @@ func describe() {
125
130
gomega .Expect (pod .Spec .Containers [2 ].Env [0 ].Value ).To (gomega .Equal ("1" ))
126
131
ginkgo .By ("checking the pod total EPC size annotation is correctly set" )
127
132
gomega .Expect (pod .Annotations ["sgx.intel.com/epc" ]).To (gomega .Equal ("3Mi" ))
133
+ gomega .Expect (pod .Annotations ["epc-limit.nri.io/container.test1" ]).To (gomega .Equal ("1048576" ))
134
+ gomega .Expect (pod .Annotations ["epc-limit.nri.io/container.test2" ]).To (gomega .Equal ("1048576" ))
135
+ gomega .Expect (pod .Annotations ["epc-limit.nri.io/container.test3" ]).To (gomega .Equal ("1048576" ))
128
136
})
129
137
ginkgo .It ("checks that Volumes and VolumeMounts are created only once" , func (ctx context.Context ) {
130
138
ginkgo .By ("submitting the pod" )
0 commit comments