summaryrefslogtreecommitdiff
path: root/client/container_inspect_test.go
diff options
context:
space:
mode:
Diffstat (limited to 'client/container_inspect_test.go')
-rw-r--r--client/container_inspect_test.go8
1 files changed, 4 insertions, 4 deletions
diff --git a/client/container_inspect_test.go b/client/container_inspect_test.go
index 0dc8ac3753..f1a6f4ac7d 100644
--- a/client/container_inspect_test.go
+++ b/client/container_inspect_test.go
@@ -15,7 +15,7 @@ import (
func TestContainerInspectError(t *testing.T) {
client := &Client{
- transport: newMockClient(nil, errorMock(http.StatusInternalServerError, "Server error")),
+ client: newMockClient(errorMock(http.StatusInternalServerError, "Server error")),
}
_, err := client.ContainerInspect(context.Background(), "nothing")
@@ -26,7 +26,7 @@ func TestContainerInspectError(t *testing.T) {
func TestContainerInspectContainerNotFound(t *testing.T) {
client := &Client{
- transport: newMockClient(nil, errorMock(http.StatusNotFound, "Server error")),
+ client: newMockClient(errorMock(http.StatusNotFound, "Server error")),
}
_, err := client.ContainerInspect(context.Background(), "unknown")
@@ -38,7 +38,7 @@ func TestContainerInspectContainerNotFound(t *testing.T) {
func TestContainerInspect(t *testing.T) {
expectedURL := "/containers/container_id/json"
client := &Client{
- transport: newMockClient(nil, func(req *http.Request) (*http.Response, error) {
+ client: newMockClient(func(req *http.Request) (*http.Response, error) {
if !strings.HasPrefix(req.URL.Path, expectedURL) {
return nil, fmt.Errorf("Expected URL '%s', got '%s'", expectedURL, req.URL)
}
@@ -76,7 +76,7 @@ func TestContainerInspect(t *testing.T) {
func TestContainerInspectNode(t *testing.T) {
client := &Client{
- transport: newMockClient(nil, func(req *http.Request) (*http.Response, error) {
+ client: newMockClient(func(req *http.Request) (*http.Response, error) {
content, err := json.Marshal(types.ContainerJSON{
ContainerJSONBase: &types.ContainerJSONBase{
ID: "container_id",