diff options
author | Ashley Cui <acui@redhat.com> | 2021-03-02 16:14:10 -0500 |
---|---|---|
committer | Ashley Cui <acui@redhat.com> | 2021-03-02 16:55:21 -0500 |
commit | 9391bfc520c55ff66c1547561bd3189dd911c8cb (patch) | |
tree | 31ca1e5dabfdc3b8abc1c92c72052125db74c0ba /test | |
parent | 426178a49991106ffe222f12cc42409ae78dd257 (diff) | |
download | podman-9391bfc520c55ff66c1547561bd3189dd911c8cb.tar.gz podman-9391bfc520c55ff66c1547561bd3189dd911c8cb.tar.bz2 podman-9391bfc520c55ff66c1547561bd3189dd911c8cb.zip |
Add version field to secret compat list/inspect api
Docker api expects secrets endpoint to have a version field. So, the
version field is added into the compat endpoint only. The version field
is always 1, since Docker uses the version to keep track of updates to
the secret, and currently we cannot update a secret.
Signed-off-by: Ashley Cui <acui@redhat.com>
Diffstat (limited to 'test')
-rw-r--r-- | test/apiv2/50-secrets.at | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/test/apiv2/50-secrets.at b/test/apiv2/50-secrets.at index 69e1f3ae9..c4ffb5883 100644 --- a/test/apiv2/50-secrets.at +++ b/test/apiv2/50-secrets.at @@ -14,15 +14,18 @@ t POST secrets/create '"Name":"mysecret","Data":"c2VjcmV0","Labels":{"fail":"fai t POST secrets/create '"Name":"mysecret","Data":"c2VjcmV0"' 409 # secret inspect -t GET secrets/mysecret 200\ - .Spec.Name=mysecret +t GET secrets/mysecret 200 \ + .Spec.Name=mysecret \ + .Version.Index=1 # secret inspect non-existent secret t GET secrets/bogus 404 # secret list -t GET secrets 200\ - length=1 +t GET secrets 200 \ + length=1 \ + .[0].Spec.Name=mysecret \ + .[0].Version.Index=1 # secret list unsupported filters t GET secrets?filters='{"name":["foo1"]}' 400 |