mirror of
https://github.com/GoogleContainerTools/kaniko
synced 2026-10-03 17:05:39 +02:00
Add test for setting root user explicitly
This commit is contained in:
@@ -62,6 +62,17 @@ func Test_addDefaultHOME(t *testing.T) {
|
||||
"HOME=/",
|
||||
},
|
||||
},
|
||||
{
|
||||
name: "HOME isn't set, user is set to root",
|
||||
user: "root",
|
||||
initial: []string{
|
||||
"PATH=/something/else",
|
||||
},
|
||||
expected: []string{
|
||||
"PATH=/something/else",
|
||||
"HOME=/root",
|
||||
},
|
||||
},
|
||||
}
|
||||
for _, test := range tests {
|
||||
t.Run(test.name, func(t *testing.T) {
|
||||
|
||||
Reference in New Issue
Block a user