mirror of https://github.com/docker/cli.git
change minor mistake of spelling
Signed-off-by: allencloud <allen.sun@daocloud.io>
This commit is contained in:
parent
368e309073
commit
693328f346
|
@ -244,7 +244,7 @@ func (e secretNotFoundError) Error() string {
|
||||||
return fmt.Sprintf("Error: no such secret: %s", e.name)
|
return fmt.Sprintf("Error: no such secret: %s", e.name)
|
||||||
}
|
}
|
||||||
|
|
||||||
// NoFound indicates that this error type is of NotFound
|
// NotFound indicates that this error type is of NotFound
|
||||||
func (e secretNotFoundError) NotFound() bool {
|
func (e secretNotFoundError) NotFound() bool {
|
||||||
return true
|
return true
|
||||||
}
|
}
|
||||||
|
|
|
@ -31,7 +31,7 @@ func TestNodeInspectNodeNotFound(t *testing.T) {
|
||||||
|
|
||||||
_, _, err := client.NodeInspectWithRaw(context.Background(), "unknown")
|
_, _, err := client.NodeInspectWithRaw(context.Background(), "unknown")
|
||||||
if err == nil || !IsErrNodeNotFound(err) {
|
if err == nil || !IsErrNodeNotFound(err) {
|
||||||
t.Fatalf("expected an nodeNotFoundError error, got %v", err)
|
t.Fatalf("expected a nodeNotFoundError error, got %v", err)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
2
ping.go
2
ping.go
|
@ -7,7 +7,7 @@ import (
|
||||||
"golang.org/x/net/context"
|
"golang.org/x/net/context"
|
||||||
)
|
)
|
||||||
|
|
||||||
// Ping pings the server and return the value of the "Docker-Experimental" & "API-Version" headers
|
// Ping pings the server and returns the value of the "Docker-Experimental" & "API-Version" headers
|
||||||
func (cli *Client) Ping(ctx context.Context) (types.Ping, error) {
|
func (cli *Client) Ping(ctx context.Context) (types.Ping, error) {
|
||||||
var ping types.Ping
|
var ping types.Ping
|
||||||
req, err := cli.buildRequest("GET", fmt.Sprintf("%s/_ping", cli.basePath), nil, nil)
|
req, err := cli.buildRequest("GET", fmt.Sprintf("%s/_ping", cli.basePath), nil, nil)
|
||||||
|
|
|
@ -31,7 +31,7 @@ func TestSecretInspectSecretNotFound(t *testing.T) {
|
||||||
|
|
||||||
_, _, err := client.SecretInspectWithRaw(context.Background(), "unknown")
|
_, _, err := client.SecretInspectWithRaw(context.Background(), "unknown")
|
||||||
if err == nil || !IsErrSecretNotFound(err) {
|
if err == nil || !IsErrSecretNotFound(err) {
|
||||||
t.Fatalf("expected an secretNotFoundError error, got %v", err)
|
t.Fatalf("expected a secretNotFoundError error, got %v", err)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -31,7 +31,7 @@ func TestServiceInspectServiceNotFound(t *testing.T) {
|
||||||
|
|
||||||
_, _, err := client.ServiceInspectWithRaw(context.Background(), "unknown")
|
_, _, err := client.ServiceInspectWithRaw(context.Background(), "unknown")
|
||||||
if err == nil || !IsErrServiceNotFound(err) {
|
if err == nil || !IsErrServiceNotFound(err) {
|
||||||
t.Fatalf("expected an serviceNotFoundError error, got %v", err)
|
t.Fatalf("expected a serviceNotFoundError error, got %v", err)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue