Browse code

add docker import test with a tag. Fixes #7714

Signed-off-by: Lei Jitang <leijitang@huawei.com>

Lei Jitang authored on 2014/08/26 16:03:38
Showing 1 changed files
... ...
@@ -29,7 +29,7 @@ func TestExportContainerAndImportImage(t *testing.T) {
29 29
 	out, _, err = runCommandWithOutput(exportCmd)
30 30
 	errorOut(err, t, fmt.Sprintf("failed to export container: %v %v", out, err))
31 31
 
32
-	importCmdFinal := `cat /tmp/testexp.tar | docker import - testexp`
32
+	importCmdFinal := `cat /tmp/testexp.tar | docker import - repo/testexp:v1`
33 33
 	importCmd := exec.Command("bash", "-c", importCmdFinal)
34 34
 	out, _, err = runCommandWithOutput(importCmd)
35 35
 	errorOut(err, t, fmt.Sprintf("failed to import image: %v %v", out, err))
... ...
@@ -41,7 +41,7 @@ func TestExportContainerAndImportImage(t *testing.T) {
41 41
 	errorOut(err, t, fmt.Sprintf("output should've been an image id: %v %v", out, err))
42 42
 
43 43
 	deleteContainer(cleanedContainerID)
44
-	deleteImages("testexp")
44
+	deleteImages("repo/testexp:v1")
45 45
 
46 46
 	os.Remove("/tmp/testexp.tar")
47 47