Skip to content

Commit db670ee

Browse files
committed
test: rename Localhost to LocalHost, typos
1 parent 762b2ef commit db670ee

3 files changed

Lines changed: 8 additions & 8 deletions

File tree

pkg/rules/seccompAny_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,7 @@ func Test_SeccompAny(t *testing.T) {
9898

9999
count := SeccompAny(json)
100100
expectedCount := 0
101-
if tc.expectedProfileType == tcprofSeccompRuntimeDefault || tc.expectedProfileType == tcprofSeccompLocalhost {
101+
if tc.expectedProfileType == tcprofSeccompRuntimeDefault || tc.expectedProfileType == tcprofSeccompLocalHost {
102102
expectedCount = 1
103103
}
104104

pkg/rules/seccompTestCases.go

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -174,7 +174,7 @@ const (
174174
tcprofSeccompProfileMissing tcSeccompProfileType = ""
175175
tcprofSeccompUnconfined tcSeccompProfileType = "Unconfined"
176176
tcprofSeccompRuntimeDefault tcSeccompProfileType = "RuntimeDefault"
177-
tcprofSeccompLocalhost tcSeccompProfileType = "LocalHost"
177+
tcprofSeccompLocalHost tcSeccompProfileType = "LocalHost"
178178
)
179179

180180
var testCasesSeccomp = []struct {
@@ -199,7 +199,7 @@ var testCasesSeccomp = []struct {
199199
},
200200
{
201201
description: "LocalHost seccompProfile found inside .spec.securityContext",
202-
expectedProfileType: tcprofSeccompLocalhost,
202+
expectedProfileType: tcprofSeccompLocalHost,
203203
manifest: tcmanSeccompProfileInSecCtxLH,
204204
},
205205
{
@@ -214,11 +214,11 @@ var testCasesSeccomp = []struct {
214214
},
215215
{
216216
description: "LocalHost seccompProfile found inside .spec.containers[*].securityContext",
217-
expectedProfileType: tcprofSeccompLocalhost,
217+
expectedProfileType: tcprofSeccompLocalHost,
218218
manifest: tcmanSeccompProfileInContainerLH,
219219
},
220220
{
221-
description: "seccompProfile found inside .spec.initContainers[*].securityContext",
221+
description: "RuntimeDefault seccompProfile found inside .spec.initContainers[*].securityContext",
222222
expectedProfileType: tcprofSeccompRuntimeDefault,
223223
manifest: tcmanSeccompProfileInInitRD,
224224
},
@@ -229,7 +229,7 @@ var testCasesSeccomp = []struct {
229229
},
230230
{
231231
description: "LocalHost seccompProfile found inside .spec.initContainers[*].securityContext",
232-
expectedProfileType: tcprofSeccompLocalhost,
232+
expectedProfileType: tcprofSeccompLocalHost,
233233
manifest: tcmanSeccompProfileInInitLH,
234234
},
235235
{
@@ -244,7 +244,7 @@ var testCasesSeccomp = []struct {
244244
},
245245
{
246246
description: "LocalHost seccompProfile found inside .spec.ephemeralContainers[*].securityContext",
247-
expectedProfileType: tcprofSeccompLocalhost,
247+
expectedProfileType: tcprofSeccompLocalHost,
248248
manifest: tcmanSeccompProfileInEphLH,
249249
},
250250
}

test/asset/score-0-dep-seccomp-unconfined-initcontainer.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ spec:
1818
name: sotrustworthy-container
1919
initContainers:
2020
- image: sotrustworthy:latest
21-
name: sotrustworthy-ephemeralcontainer
21+
name: sotrustworthy-initcontainer
2222
securityContext:
2323
seccompProfile:
2424
type: Unconfined

0 commit comments

Comments
 (0)