Update the integration test.

Signed-off-by: Lantao Liu <lantaol@google.com>
This commit is contained in:
Lantao Liu 2019-01-08 17:44:08 -08:00
parent 60f73b6cf1
commit 03aafaa1cf

View File

@ -20,6 +20,9 @@ package containerd
import (
"runtime"
"testing"
"github.com/containerd/containerd/platforms"
)
const (
@ -48,3 +51,20 @@ func init() {
testImage = "docker.io/library/alpine:latest"
}
}
func TestImagePullSchema1WithEmptyLayers(t *testing.T) {
client, err := newClient(t, address)
if err != nil {
t.Fatal(err)
}
defer client.Close()
ctx, cancel := testContext(t)
defer cancel()
schema1TestImageWithEmptyLayers := "gcr.io/google-containers/busybox@sha256:d8d3bc2c183ed2f9f10e7258f84971202325ee6011ba137112e01e30f206de67"
_, err = client.Pull(ctx, schema1TestImageWithEmptyLayers, WithPlatform(platforms.DefaultString()), WithSchema1Conversion, WithPullUnpack)
if err != nil {
t.Fatal(err)
}
}