Merge pull request #46517 from rumpl/c8d-windows-pull-linux

c8d: test a backend dependent error on pull
This commit is contained in:
Sebastiaan van Stijn 2023-11-03 09:28:16 +01:00 committed by GitHub
commit 050e6066af
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -214,5 +214,11 @@ func (s *DockerCLIPullSuite) TestPullLinuxImageFailsOnWindows(c *testing.T) {
func (s *DockerCLIPullSuite) TestPullWindowsImageFailsOnLinux(c *testing.T) {
testRequires(c, DaemonIsLinux, Network)
_, _, err := dockerCmdWithError("pull", "mcr.microsoft.com/windows/servercore:ltsc2022")
assert.ErrorContains(c, err, "no matching manifest for linux")
errorMessage := "no matching manifest for linux"
if testEnv.UsingSnapshotter() {
errorMessage = "no match for platform in manifest"
}
assert.ErrorContains(c, err, errorMessage)
}