mirror of
https://github.com/moby/moby.git
synced 2022-11-09 12:21:53 -05:00
Adding support for network/id/endpoints in api
Signed-off-by: Madhu Venugopal <madhu@docker.com>
This commit is contained in:
parent
5ee5e2452f
commit
b5a6c849e3
2 changed files with 3 additions and 3 deletions
|
@ -89,7 +89,7 @@ func (h *httpHandler) initRouter() {
|
|||
{"/networks/" + nwID, nil, procGetNetwork},
|
||||
{"/networks/" + nwID + "/endpoints", []string{"name", epName}, procGetEndpoints},
|
||||
{"/networks/" + nwID + "/endpoints", []string{"partial-id", epPID}, procGetEndpoints},
|
||||
|
||||
{"/networks/" + nwID + "/endpoints", nil, procGetEndpoints},
|
||||
{"/networks/" + nwID + "/endpoints/" + epID, nil, procGetEndpoint},
|
||||
},
|
||||
"POST": {
|
||||
|
|
|
@ -1391,8 +1391,8 @@ func TestEndToEnd(t *testing.T) {
|
|||
t.Fatal(err)
|
||||
}
|
||||
handleRequest(rsp, req)
|
||||
if rsp.statusCode != http.StatusNotFound {
|
||||
t.Fatalf("Expected StatusNotFound. Got (%d): %s", rsp.statusCode, rsp.body)
|
||||
if rsp.statusCode != http.StatusOK {
|
||||
t.Fatalf("Expected StatusOK. Got (%d): %s", rsp.statusCode, rsp.body)
|
||||
}
|
||||
|
||||
req, err = http.NewRequest("GET", "/networks/"+nid+"/endpoints?name=bla", nil)
|
||||
|
|
Loading…
Add table
Reference in a new issue