From 5e5156afa32238b522926510e90256c027f9294f Mon Sep 17 00:00:00 2001 From: Stephen J Day Date: Tue, 18 Jul 2017 14:48:55 -0700 Subject: [PATCH] api: url typo in specification Signed-off-by: Stephen J Day --- docs/spec/api.md | 2 +- docs/spec/api.md.tmpl | 2 +- registry/api/v2/routes_test.go | 6 +++--- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/docs/spec/api.md b/docs/spec/api.md index efa55cfcf..81d44e1be 100644 --- a/docs/spec/api.md +++ b/docs/spec/api.md @@ -676,7 +676,7 @@ the upload will not be considered complete. The format for the final chunk will be as follows: ``` -PUT /v2//blob/uploads/?digest= +PUT /v2//blobs/uploads/?digest= Content-Length: Content-Range: - Content-Type: application/octet-stream diff --git a/docs/spec/api.md.tmpl b/docs/spec/api.md.tmpl index cf7f92971..f96d33467 100644 --- a/docs/spec/api.md.tmpl +++ b/docs/spec/api.md.tmpl @@ -676,7 +676,7 @@ the upload will not be considered complete. The format for the final chunk will be as follows: ``` -PUT /v2//blob/uploads/?digest= +PUT /v2//blobs/uploads/?digest= Content-Length: Content-Range: - Content-Type: application/octet-stream diff --git a/registry/api/v2/routes_test.go b/registry/api/v2/routes_test.go index f632d981c..6c77e2815 100644 --- a/registry/api/v2/routes_test.go +++ b/registry/api/v2/routes_test.go @@ -180,8 +180,8 @@ func TestRouterWithPathTraversals(t *testing.T) { testCases := []routeTestCase{ { RouteName: RouteNameBlobUploadChunk, - RequestURI: "/v2/foo/../../blob/uploads/D95306FA-FAD3-4E36-8D41-CF1C93EF8286", - ExpectedURI: "/blob/uploads/D95306FA-FAD3-4E36-8D41-CF1C93EF8286", + RequestURI: "/v2/foo/../../blobs/uploads/D95306FA-FAD3-4E36-8D41-CF1C93EF8286", + ExpectedURI: "/blobs/uploads/D95306FA-FAD3-4E36-8D41-CF1C93EF8286", StatusCode: http.StatusNotFound, }, { @@ -202,7 +202,7 @@ func TestRouterWithBadCharacters(t *testing.T) { testCases := []routeTestCase{ { RouteName: RouteNameBlobUploadChunk, - RequestURI: "/v2/foo/blob/uploads/不95306FA-FAD3-4E36-8D41-CF1C93EF8286", + RequestURI: "/v2/foo/blobs/uploads/不95306FA-FAD3-4E36-8D41-CF1C93EF8286", StatusCode: http.StatusNotFound, }, {