summaryrefslogtreecommitdiff
path: root/pkg/api/handlers/utils/handler_test.go
diff options
context:
space:
mode:
authorOpenShift Merge Robot <openshift-merge-robot@users.noreply.github.com>2021-03-04 09:46:24 -0500
committerGitHub <noreply@github.com>2021-03-04 09:46:24 -0500
commit87a78c059dc2fb72ba54805d5488f3e619ae46f1 (patch)
treea6c7ca6a504f71b1af2307fcdfbbae6787d73b6b /pkg/api/handlers/utils/handler_test.go
parent17cacea3fa2bf0df20572720b9a0a3be35f2ef7b (diff)
parentf86d64130838fbeb75ea2776a2f2b6c4a49e58b3 (diff)
downloadpodman-87a78c059dc2fb72ba54805d5488f3e619ae46f1.tar.gz
podman-87a78c059dc2fb72ba54805d5488f3e619ae46f1.tar.bz2
podman-87a78c059dc2fb72ba54805d5488f3e619ae46f1.zip
Merge pull request #9601 from jwhonce/issues/9207
Use version package to track all versions
Diffstat (limited to 'pkg/api/handlers/utils/handler_test.go')
-rw-r--r--pkg/api/handlers/utils/handler_test.go5
1 files changed, 3 insertions, 2 deletions
diff --git a/pkg/api/handlers/utils/handler_test.go b/pkg/api/handlers/utils/handler_test.go
index d9fd22b80..18a1d2678 100644
--- a/pkg/api/handlers/utils/handler_test.go
+++ b/pkg/api/handlers/utils/handler_test.go
@@ -7,17 +7,18 @@ import (
"net/http/httptest"
"testing"
+ "github.com/containers/podman/v3/version"
"github.com/gorilla/mux"
)
func TestSupportedVersion(t *testing.T) {
req, err := http.NewRequest("GET",
- fmt.Sprintf("/v%s/libpod/testing/versions", APIVersion[LibpodTree][CurrentAPIVersion]),
+ fmt.Sprintf("/v%s/libpod/testing/versions", version.APIVersion[version.Libpod][version.CurrentAPI]),
nil)
if err != nil {
t.Fatal(err)
}
- req = mux.SetURLVars(req, map[string]string{"version": APIVersion[LibpodTree][CurrentAPIVersion].String()})
+ req = mux.SetURLVars(req, map[string]string{"version": version.APIVersion[version.Libpod][version.CurrentAPI].String()})
rr := httptest.NewRecorder()
handler := http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) {