Skip to content

Commit

Permalink
Add a test with collisions
Browse files Browse the repository at this point in the history
Signed-off-by: David Gageot <david@gageot.net>
  • Loading branch information
dgageot committed Aug 28, 2019
1 parent be369d9 commit 2e796f1
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions pkg/skaffold/build/local/docker_test.go
Expand Up @@ -58,6 +58,13 @@ func TestDockerCLIBuild(t *testing.T) {
extraEnv: []string{"OTHER=VALUE"},
expectedEnv: []string{"KEY=VALUE", "OTHER=VALUE", "DOCKER_BUILDKIT=1"},
},
{
description: "env var collisions",
localBuild: latest.LocalBuild{UseBuildkit: true},
extraEnv: []string{"KEY=OTHER_VALUE", "DOCKER_BUILDKIT=0"},
// env var collisions are handled by cmd.Run(). Last one wins.
expectedEnv: []string{"KEY=VALUE", "KEY=OTHER_VALUE", "DOCKER_BUILDKIT=0", "DOCKER_BUILDKIT=1"},
},
}

for _, test := range tests {
Expand Down

0 comments on commit 2e796f1

Please sign in to comment.