1
0
mirror of https://github.com/docker/docker-credential-helpers.git synced 2026-06-13 16:01:28 +05:30

Add a Docker Credentials label support for linux

Signed-off-by: Nassim 'Nass' Eddequiouaq <eddequiouaq.nassim@gmail.com>
This commit is contained in:
Nassim 'Nass' Eddequiouaq
2017-03-08 17:08:43 +01:00
parent 406812bf8e
commit f7f2744e6d
4 changed files with 22 additions and 13 deletions
+3 -2
View File
@@ -13,6 +13,7 @@ func TestSecretServiceHelper(t *testing.T) {
ServerURL: "https://foobar.docker.io:2376/v1",
Username: "foobar",
Secret: "foobarbaz",
Label: credentials.CredsLabel,
}
helper := Secretservice{}
@@ -36,12 +37,12 @@ func TestSecretServiceHelper(t *testing.T) {
if err := helper.Delete(creds.ServerURL); err != nil {
t.Fatal(err)
}
auths, err := helper.List()
auths, err := helper.List(credentials.CredsLabel)
if err != nil || len(auths) == 0 {
t.Fatal(err)
}
helper.Add(creds)
if newauths, err := helper.List(); (len(newauths) - len(auths)) != 1 {
if newauths, err := helper.List(credentials.CredsLabel); (len(newauths) - len(auths)) != 1 {
t.Fatal(err)
}
}