forked from moby/buildkit
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
test: enabling integration tests on windows
Starting off with this one as a POC on the approach, before we proceed to complete the rest under `/frontend/dockerfile`. Tests covered so far: - [x] `/frontend/dockerfile: testEnvEmptyFormatting` - [x] `/frontend/dockerfile: testDockerignoreOverride` - [x] `/frontend/dockerfile: caseEmptyDestDir` Starts addressing moby#4485 Signed-off-by: Anthony Nandaa <profnandaa@gmail.com>
- Loading branch information
1 parent
e83d79a
commit dbce339
Showing
9 changed files
with
125 additions
and
43 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,6 @@ | ||
//go:build !windows | ||
// +build !windows | ||
|
||
package integration | ||
|
||
var pins = map[string]map[string]string{ | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
//go:build !windows | ||
// +build !windows | ||
|
||
package integration | ||
|
||
import "runtime" | ||
|
||
func officialImages(names ...string) map[string]string { | ||
ns := runtime.GOARCH | ||
if ns == "arm64" { | ||
ns = "arm64v8" | ||
} else if ns != "amd64" { | ||
ns = "library" | ||
} | ||
m := map[string]string{} | ||
for _, name := range names { | ||
ref := "docker.io/" + ns + "/" + name | ||
if pns, ok := pins[name]; ok { | ||
if dgst, ok := pns[ns]; ok { | ||
ref += "@" + dgst | ||
} | ||
} | ||
m["library/"+name] = ref | ||
} | ||
return m | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
package integration | ||
|
||
func officialImages(names ...string) map[string]string { | ||
m := map[string]string{} | ||
for _, name := range names { | ||
// select available refs from the mirror map | ||
// so that we mirror only those needed for the tests | ||
if ref, ok := windowsImagesMirrorMap[name]; ok { | ||
m["library/"+name] = ref | ||
} | ||
} | ||
return m | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters