Browse Source

add namespace method conver

Signed-off-by: chchliang <chen.chuanliang@zte.com.cn>
chchliang 7 years ago
parent
commit
0446b6a04e
1 changed files with 5 additions and 0 deletions
  1. 5 0
      distribution/metadata/v1_id_service_test.go

+ 5 - 0
distribution/metadata/v1_id_service_test.go

@@ -7,6 +7,7 @@ import (
 	"testing"
 
 	"github.com/docker/docker/layer"
+	"github.com/stretchr/testify/require"
 )
 
 func TestV1IDService(t *testing.T) {
@@ -22,6 +23,10 @@ func TestV1IDService(t *testing.T) {
 	}
 	v1IDService := NewV1IDService(metadataStore)
 
+	ns := v1IDService.namespace()
+
+	require.Equal(t, "v1id", ns)
+
 	testVectors := []struct {
 		registry string
 		v1ID     string