Implement Tags method on ManifestService

This commit is contained in:
Stephen J Day 2014-12-09 11:06:51 -08:00
parent 45c29be442
commit c71089c653
5 changed files with 67 additions and 0 deletions

View file

@ -99,6 +99,20 @@ func TestManifestStorage(t *testing.T) {
if !reflect.DeepEqual(fetchedManifest, sm) {
t.Fatalf("fetched manifest not equal: %#v != %#v", fetchedManifest, sm)
}
// Grabs the tags and check that this tagged manifest is present
tags, err := ms.Tags(name)
if err != nil {
t.Fatalf("unexpected error fetching tags: %v", err)
}
if len(tags) != 1 {
t.Fatalf("unexpected tags returned: %v", tags)
}
if tags[0] != tag {
t.Fatalf("unexpected tag found in tags: %v != %v", tags, []string{tag})
}
}
type layerKey struct {