فهرست منبع

c8d/integration/TestBuildOnBuildCache skip parent check

Parent is a graph-driver only field which is stored in the ImageStore.
It's not available when using containerd snapshotters.

Signed-off-by: Paweł Gronowski <pawel.gronowski@docker.com>
Paweł Gronowski 1 سال پیش
والد
کامیت
14af90b868
1فایلهای تغییر یافته به همراه7 افزوده شده و 3 حذف شده
  1. 7 3
      integration-cli/docker_api_build_test.go

+ 7 - 3
integration-cli/docker_api_build_test.go

@@ -303,9 +303,13 @@ func (s *DockerAPISuite) TestBuildOnBuildCache(c *testing.T) {
 	client := testEnv.APIClient()
 
 	// check parentID is correct
-	image, _, err := client.ImageInspectWithRaw(context.Background(), childID)
-	assert.NilError(c, err)
-	assert.Check(c, is.Equal(parentID, image.Parent))
+	// Parent is graphdriver-only
+	if !testEnv.UsingSnapshotter() {
+		image, _, err := client.ImageInspectWithRaw(context.Background(), childID)
+		assert.NilError(c, err)
+
+		assert.Check(c, is.Equal(parentID, image.Parent))
+	}
 }
 
 func (s *DockerRegistrySuite) TestBuildCopyFromForcePull(c *testing.T) {